This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package xx.xxx.xx.view; | |
import android.content.Context; | |
import android.util.AttributeSet; | |
import android.view.ViewGroup; | |
import android.widget.GridView; | |
/** | |
* ScrollViewの中のGridViewでも高さを可変にする<br> | |
* http://stackoverflow.com/questions/8481844/gridview-height-gets-cut |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public void onClick1(View view) { | |
// logcatにメールアドレスが表示される呼び出し方。セキュリティ上好ましくない | |
Uri uri = Uri.parse("mailto:" + mail); | |
Intent intent = new Intent(Intent.ACTION_SENDTO, uri); | |
startActivity(intent); | |
} | |
public void onClick2(View view) { | |
// logcatにメールアドレスが表示されない呼び出し方。セキュリティ上好ましい | |
Uri uri = Uri.parse("mailto:"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.example.AnimationTest1; | |
import android.app.Activity; | |
import android.os.Bundle; | |
import android.view.animation.Animation; | |
import android.view.animation.AnimationUtils; | |
public class AnimationTest1 extends Activity | |
{ | |
@Override |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
mGridView = (GridView) getView().findViewById(R.id.spotsView); | |
mGridView.setOnTouchListener(new GridView.OnTouchListener() { | |
@Override | |
public boolean onTouch(View v, MotionEvent event) { | |
// ScrollViewの中でもうまくGridViewのScrollを効かす | |
int action = event.getAction(); | |
switch (action) { | |
case MotionEvent.ACTION_DOWN: | |
v.getParent().requestDisallowInterceptTouchEvent(true); | |
break; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="utf-8"?> | |
<manifest xmlns:android="http://schemas.android.com/apk/res/android" | |
package="com.sakurafish.android.example.myexamplechooseimage" | |
android:versionCode="1" | |
android:versionName="1.0" > | |
<uses-sdk android:minSdkVersion="7" /> | |
<application | |
android:icon="@drawable/ic_launcher" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Copyright 2015-present Yukari Sakurai | |
* <p/> | |
* Licensed under the Apache License, Version 2.0 (the "License"); | |
* you may not use this file except in compliance with the License. | |
* You may obtain a copy of the License at | |
* <p/> | |
* http://www.apache.org/licenses/LICENSE-2.0 | |
* <p/> | |
* Unless required by applicable law or agreed to in writing, software |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// Kind.swift | |
// ExamRealm1 | |
// | |
// Created by Sakura on 2018/01/22. | |
// Copyright © 2018年 Sakura. All rights reserved. | |
// | |
import Foundation | |
import RealmSwift |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
################################################## | |
# 入力ファイルから出力ファイルに書き出すRubyのプログラム | |
# 入力ファイルはテキストファイルである | |
# テキストはランダムに改行されている | |
# 文字がn文字を超えていたらn文字で改行する | |
# 実行方法はコマンドラインから次のように打ち込む。Ruby必須 | |
# $ ruby newline2.rb | |
################################################## | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
################################################## | |
# 入力ファイル(Unix系OS Macも含む)から出力ファイル(Windows)に書き出すRubyのプログラム | |
# 入力ファイルはテキストファイルである | |
# テキストはランダムに改行されている | |
# 文字がn文字を超えていたらn文字で改行する | |
# 実行方法はコマンドラインから次のように打ち込む。Ruby必須 | |
# $ ruby newline.rb | |
################################################## | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//インスタンス変数の定義 | |
SpeechRecognizer rec; | |
//onCreate()で変数にリスナーをセットする | |
// 音声認識 | |
rec = SpeechRecognizer.createSpeechRecognizer( getApplicationContext() ); | |
rec.setRecognitionListener( new speechListenerAdp() ); | |
//音声認識をスタートする | |
// SpeechRecognizer |
NewerOlder