├── .idea ├── .name ├── copyright │ └── profiles_settings.xml ├── scopes │ └── scope_settings.xml ├── encodings.xml ├── vcs.xml ├── libraries │ ├── KiiSDK_2_1___ANDROID_KiiCloudStorageSDK_release_v2_1_25_3237cbd.xml │ ├── wearable_1_0_0.xml │ ├── play_services_wearable_5_0_77.xml │ ├── support_v4_19_1_0.xml │ ├── teleportlib_0_1_1.xml │ ├── support_annotations_20_0_0.xml │ ├── support_v4_20_0_0.xml │ └── support_v13_20_0_0.xml ├── modules.xml ├── gradle.xml ├── compiler.xml └── misc.xml ├── mobile ├── .gitignore ├── src │ ├── main │ │ ├── res │ │ │ ├── drawable-hdpi │ │ │ │ └── ic_launcher.png │ │ │ ├── drawable-mdpi │ │ │ │ └── ic_launcher.png │ │ │ ├── drawable-xhdpi │ │ │ │ └── ic_launcher.png │ │ │ ├── drawable-xxhdpi │ │ │ │ └── ic_launcher.png │ │ │ ├── values │ │ │ │ ├── dimens.xml │ │ │ │ ├── styles.xml │ │ │ │ └── strings.xml │ │ │ ├── values-w820dp │ │ │ │ └── dimens.xml │ │ │ ├── menu │ │ │ │ └── main.xml │ │ │ └── layout │ │ │ │ ├── activity_main.xml │ │ │ │ └── activity_auth.xml │ │ ├── java │ │ │ └── com │ │ │ │ └── kii │ │ │ │ └── demo │ │ │ │ └── wearable │ │ │ │ ├── BootReceiver.java │ │ │ │ ├── AppConfig.java │ │ │ │ ├── Settings.java │ │ │ │ ├── MainActivity.java │ │ │ │ ├── DataService.java │ │ │ │ └── AuthActivity.java │ │ └── AndroidManifest.xml │ └── androidTest │ │ └── java │ │ └── com │ │ └── kii │ │ └── demo │ │ └── wearable │ │ └── ApplicationTest.java ├── libs │ └── KiiSDK 2.1 - ANDROID KiiCloudStorageSDK-release_v2.1.25-3237cbd.jar ├── proguard-rules.pro ├── build.gradle └── mobile.iml ├── wear ├── .gitignore ├── src │ └── main │ │ ├── res │ │ ├── drawable-hdpi │ │ │ └── ic_launcher.png │ │ ├── drawable-mdpi │ │ │ └── ic_launcher.png │ │ ├── drawable-xhdpi │ │ │ └── ic_launcher.png │ │ ├── drawable-xxhdpi │ │ │ └── ic_launcher.png │ │ ├── values │ │ │ └── strings.xml │ │ └── layout │ │ │ ├── activity_my.xml │ │ │ ├── rect_activity_my.xml │ │ │ └── round_activity_my.xml │ │ ├── AndroidManifest.xml │ │ └── java │ │ └── com │ │ └── kii │ │ └── demo │ │ └── wearable │ │ ├── WearService.java │ │ └── WearActivity.java ├── proguard-rules.pro ├── build.gradle └── wear.iml ├── settings.gradle ├── gradle └── wrapper │ ├── gradle-wrapper.jar │ └── gradle-wrapper.properties ├── README.md ├── .gitignore ├── PingHeart.iml ├── gradle.properties ├── gradlew.bat ├── gradlew └── LICENSE /.idea/.name: -------------------------------------------------------------------------------- 1 | PingHeart -------------------------------------------------------------------------------- /mobile/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /wear/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /settings.gradle: -------------------------------------------------------------------------------- 1 | include ':mobile', ':wear' 2 | -------------------------------------------------------------------------------- /.idea/copyright/profiles_settings.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germanviscuso/PingHeart/HEAD/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /wear/src/main/res/drawable-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germanviscuso/PingHeart/HEAD/wear/src/main/res/drawable-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /wear/src/main/res/drawable-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germanviscuso/PingHeart/HEAD/wear/src/main/res/drawable-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /mobile/src/main/res/drawable-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germanviscuso/PingHeart/HEAD/mobile/src/main/res/drawable-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /mobile/src/main/res/drawable-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germanviscuso/PingHeart/HEAD/mobile/src/main/res/drawable-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /wear/src/main/res/drawable-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germanviscuso/PingHeart/HEAD/wear/src/main/res/drawable-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /wear/src/main/res/drawable-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germanviscuso/PingHeart/HEAD/wear/src/main/res/drawable-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /mobile/src/main/res/drawable-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germanviscuso/PingHeart/HEAD/mobile/src/main/res/drawable-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /mobile/src/main/res/drawable-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germanviscuso/PingHeart/HEAD/mobile/src/main/res/drawable-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /.idea/scopes/scope_settings.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 5 | -------------------------------------------------------------------------------- /.idea/encodings.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /.idea/vcs.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /mobile/libs/KiiSDK 2.1 - ANDROID KiiCloudStorageSDK-release_v2.1.25-3237cbd.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/germanviscuso/PingHeart/HEAD/mobile/libs/KiiSDK 2.1 - ANDROID KiiCloudStorageSDK-release_v2.1.25-3237cbd.jar -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | PingHeart 2 | ========= 3 | 4 | This is a sample Android Wear app that uses the heart rate sensor present in Samsung Gear Live watches. 5 | The mobile app connects to Kii Cloud to send the heart rate data. 6 | -------------------------------------------------------------------------------- /mobile/src/main/res/values/dimens.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 16dp 4 | 16dp 5 | 6 | -------------------------------------------------------------------------------- /mobile/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | #Wed Apr 10 15:27:10 PDT 2013 2 | distributionBase=GRADLE_USER_HOME 3 | distributionPath=wrapper/dists 4 | zipStoreBase=GRADLE_USER_HOME 5 | zipStorePath=wrapper/dists 6 | distributionUrl=http\://services.gradle.org/distributions/gradle-1.12-all.zip 7 | -------------------------------------------------------------------------------- /wear/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | PingHeart 5 | Hello Round World! 6 | Hello Square World! 7 | 8 | 9 | -------------------------------------------------------------------------------- /mobile/src/main/res/values-w820dp/dimens.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 64dp 6 | 7 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | .idea/workspace.xml 3 | 4 | # Built application files 5 | *.apk 6 | *.ap_ 7 | 8 | # Files for the Dalvik VM 9 | *.dex 10 | 11 | # Java class files 12 | *.class 13 | 14 | # Generated files 15 | bin/ 16 | gen/ 17 | 18 | # Gradle files 19 | .gradle/ 20 | build/ 21 | 22 | # Local configuration file (sdk path, etc) 23 | local.properties 24 | 25 | # Proguard folder generated by Eclipse 26 | proguard/ 27 | -------------------------------------------------------------------------------- /.idea/libraries/KiiSDK_2_1___ANDROID_KiiCloudStorageSDK_release_v2_1_25_3237cbd.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /mobile/src/androidTest/java/com/kii/demo/wearable/ApplicationTest.java: -------------------------------------------------------------------------------- 1 | package com.kii.demo.wearable; 2 | 3 | import android.app.Application; 4 | import android.test.ApplicationTestCase; 5 | 6 | /** 7 | * Testing Fundamentals 8 | */ 9 | public class ApplicationTest extends ApplicationTestCase { 10 | public ApplicationTest() { 11 | super(Application.class); 12 | } 13 | } -------------------------------------------------------------------------------- /.idea/libraries/wearable_1_0_0.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /mobile/src/main/java/com/kii/demo/wearable/BootReceiver.java: -------------------------------------------------------------------------------- 1 | package com.kii.demo.wearable; 2 | 3 | import android.content.BroadcastReceiver; 4 | import android.content.Context; 5 | import android.content.Intent; 6 | 7 | public class BootReceiver extends BroadcastReceiver { 8 | @Override 9 | public void onReceive(Context context, Intent intent) { 10 | Intent serviceIntent = new Intent(DataService.class.getName()); 11 | context.startService(serviceIntent); 12 | } 13 | } -------------------------------------------------------------------------------- /.idea/modules.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /.idea/libraries/play_services_wearable_5_0_77.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /.idea/libraries/support_v4_19_1_0.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /.idea/libraries/teleportlib_0_1_1.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /.idea/libraries/support_annotations_20_0_0.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /.idea/libraries/support_v4_20_0_0.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /.idea/libraries/support_v13_20_0_0.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /wear/src/main/res/layout/activity_my.xml: -------------------------------------------------------------------------------- 1 | 2 | 13 | 14 | -------------------------------------------------------------------------------- /.idea/gradle.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /mobile/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # By default, the flags in this file are appended to flags specified 3 | # in /Users/i071571/Documents/Dev/android/sdk/tools/proguard/proguard-android.txt 4 | # You can edit the include path and order by changing the proguardFiles 5 | # directive in build.gradle. 6 | # 7 | # For more details, see 8 | # http://developer.android.com/guide/developing/tools/proguard.html 9 | 10 | # Add any project specific keep options here: 11 | 12 | # If your project uses WebView with JS, uncomment the following 13 | # and specify the fully qualified class name to the JavaScript interface 14 | # class: 15 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 16 | # public *; 17 | #} 18 | -------------------------------------------------------------------------------- /wear/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # By default, the flags in this file are appended to flags specified 3 | # in /Users/i071571/Documents/Dev/android/sdk/tools/proguard/proguard-android.txt 4 | # You can edit the include path and order by changing the proguardFiles 5 | # directive in build.gradle. 6 | # 7 | # For more details, see 8 | # http://developer.android.com/guide/developing/tools/proguard.html 9 | 10 | # Add any project specific keep options here: 11 | 12 | # If your project uses WebView with JS, uncomment the following 13 | # and specify the fully qualified class name to the JavaScript interface 14 | # class: 15 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 16 | # public *; 17 | #} 18 | -------------------------------------------------------------------------------- /mobile/src/main/java/com/kii/demo/wearable/AppConfig.java: -------------------------------------------------------------------------------- 1 | package com.kii.demo.wearable; 2 | 3 | import com.kii.cloud.storage.Kii; 4 | 5 | public class AppConfig { 6 | // Kii config. Create an app at developer.kii.com and replace with your Kii app settings here 7 | public static final String KII_APP_ID = "073d2186"; 8 | public static final String KII_APP_KEY = "27e4f6457e1daaa16d1bc7125073ce74"; 9 | public static final Kii.Site KII_SITE = Kii.Site.US; 10 | public static final String USER_BUCKET = "heartrate"; 11 | // Teleport config 12 | public static final String START_ACTIVITY = "startActivity"; 13 | public static final String STOP_ACTIVITY = "stopActivity"; 14 | public static final boolean AUTONOMOUS_OPERATION = false; 15 | } 16 | -------------------------------------------------------------------------------- /.idea/compiler.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 22 | 23 | 24 | -------------------------------------------------------------------------------- /wear/build.gradle: -------------------------------------------------------------------------------- 1 | apply plugin: 'com.android.application' 2 | 3 | 4 | android { 5 | compileSdkVersion 20 6 | buildToolsVersion "20.0.0" 7 | 8 | defaultConfig { 9 | applicationId "com.kii.demo.wearable" 10 | minSdkVersion 20 11 | targetSdkVersion 20 12 | versionCode 1 13 | versionName "1.0" 14 | } 15 | buildTypes { 16 | release { 17 | runProguard false 18 | proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' 19 | } 20 | } 21 | } 22 | 23 | dependencies { 24 | compile fileTree(dir: 'libs', include: ['*.jar']) 25 | compile 'com.google.android.support:wearable:+' 26 | compile 'com.google.android.gms:play-services-wearable:+' 27 | compile 'Teleport:teleportlib:0.1.1' 28 | } 29 | -------------------------------------------------------------------------------- /mobile/build.gradle: -------------------------------------------------------------------------------- 1 | apply plugin: 'com.android.application' 2 | 3 | android { 4 | compileSdkVersion 20 5 | buildToolsVersion "20.0.0" 6 | 7 | defaultConfig { 8 | applicationId "com.kii.demo.wearable" 9 | minSdkVersion 15 10 | targetSdkVersion 20 11 | versionCode 1 12 | versionName "1.0" 13 | } 14 | buildTypes { 15 | release { 16 | runProguard false 17 | proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' 18 | } 19 | } 20 | } 21 | 22 | dependencies { 23 | compile fileTree(dir: 'libs', include: ['*.jar']) 24 | wearApp project(':wear') 25 | compile 'com.google.android.gms:play-services-wearable:+' 26 | compile 'Teleport:teleportlib:0.1.1' 27 | compile files('libs/KiiSDK 2.1 - ANDROID KiiCloudStorageSDK-release_v2.1.25-3237cbd.jar') 28 | } 29 | -------------------------------------------------------------------------------- /PingHeart.iml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /gradle.properties: -------------------------------------------------------------------------------- 1 | # Project-wide Gradle settings. 2 | 3 | # IDE (e.g. Android Studio) users: 4 | # Settings specified in this file will override any Gradle settings 5 | # configured through the IDE. 6 | 7 | # For more details on how to configure your build environment visit 8 | # http://www.gradle.org/docs/current/userguide/build_environment.html 9 | 10 | # Specifies the JVM arguments used for the daemon process. 11 | # The setting is particularly useful for tweaking memory settings. 12 | # Default value: -Xmx10248m -XX:MaxPermSize=256m 13 | # org.gradle.jvmargs=-Xmx2048m -XX:MaxPermSize=512m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8 14 | 15 | # When configured, Gradle will run in incubating parallel mode. 16 | # This option should only be used with decoupled projects. More details, visit 17 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects 18 | # org.gradle.parallel=true -------------------------------------------------------------------------------- /mobile/src/main/res/menu/main.xml: -------------------------------------------------------------------------------- 1 | 4 | 8 | 12 | 16 | 20 | 21 | -------------------------------------------------------------------------------- /wear/src/main/res/layout/rect_activity_my.xml: -------------------------------------------------------------------------------- 1 | 2 | 9 | 10 | 16 | 17 | 21 | 22 | 26 | 27 | 28 | 29 | -------------------------------------------------------------------------------- /wear/src/main/res/layout/round_activity_my.xml: -------------------------------------------------------------------------------- 1 | 2 | 9 | 10 | 16 | 17 | 21 | 22 | 26 | 27 | 28 | 29 | -------------------------------------------------------------------------------- /mobile/src/main/res/layout/activity_main.xml: -------------------------------------------------------------------------------- 1 | 10 | 11 | 18 | 19 | 26 | 27 | 28 | 29 | 30 | -------------------------------------------------------------------------------- /wear/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | 13 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 25 | 26 | 27 | 28 | 29 | 30 | 33 | 34 | 35 | 36 | 37 | -------------------------------------------------------------------------------- /mobile/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | PingHeart 5 | Hello world! 6 | Settings 7 | Log out 8 | Email 9 | Password (optional) 10 | Sign in 11 | Sign in 12 | Register 13 | Repeat 4 digit pin 14 | Enter 4 digit pin 15 | This email address is invalid 16 | Pin is too short 17 | Pins do not match 18 | This pin is incorrect 19 | This field is required 20 | PingHeart 21 | 00.0 22 | Remember me 23 | Start 24 | Stop 25 | Start/Stop Watch 26 | Start/Stop Service 27 | 28 | 29 | -------------------------------------------------------------------------------- /wear/src/main/java/com/kii/demo/wearable/WearService.java: -------------------------------------------------------------------------------- 1 | package com.kii.demo.wearable; 2 | 3 | import android.content.Intent; 4 | 5 | import android.util.Log; 6 | 7 | import com.mariux.teleport.lib.TeleportService; 8 | 9 | public class WearService extends TeleportService { 10 | 11 | private static final String TAG = WearService.class.getName(); 12 | 13 | // Teleport config 14 | public static final String START_ACTIVITY = "startActivity"; 15 | public static final String STOP_ACTIVITY = "stopActivity"; 16 | 17 | @Override 18 | public void onCreate() { 19 | super.onCreate(); 20 | setOnGetMessageTask(new ActivityManagementTask()); 21 | } 22 | 23 | //Task that shows the path of a received message 24 | public class ActivityManagementTask extends TeleportService.OnGetMessageTask { 25 | @Override 26 | protected void onPostExecute(String path) { 27 | if (path.equals(START_ACTIVITY)){ 28 | Intent startIntent = new Intent(getBaseContext(), WearActivity.class); 29 | startIntent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_SINGLE_TOP); 30 | startIntent.putExtra("keep", true); 31 | startActivity(startIntent); 32 | } else if (path.equals(STOP_ACTIVITY)) { 33 | Intent stopIntent = new Intent(getBaseContext(), WearActivity.class); 34 | stopIntent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_SINGLE_TOP); 35 | stopIntent.putExtra("keep", false); 36 | startActivity(stopIntent); 37 | } else { 38 | Log.d(TAG, "Got a message with path: " + path); 39 | } 40 | //let's reset the task (otherwise it will be executed only once) 41 | setOnGetMessageTask(new ActivityManagementTask()); 42 | } 43 | } 44 | } -------------------------------------------------------------------------------- /mobile/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 10 | 14 | 15 | 16 | 17 | 18 | 19 | 22 | 23 | 26 | 27 | 29 | 30 | 31 | 33 | 34 | 36 | 37 | 38 | 39 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | -------------------------------------------------------------------------------- /gradlew.bat: -------------------------------------------------------------------------------- 1 | @if "%DEBUG%" == "" @echo off 2 | @rem ########################################################################## 3 | @rem 4 | @rem Gradle startup script for Windows 5 | @rem 6 | @rem ########################################################################## 7 | 8 | @rem Set local scope for the variables with windows NT shell 9 | if "%OS%"=="Windows_NT" setlocal 10 | 11 | @rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. 12 | set DEFAULT_JVM_OPTS= 13 | 14 | set DIRNAME=%~dp0 15 | if "%DIRNAME%" == "" set DIRNAME=. 16 | set APP_BASE_NAME=%~n0 17 | set APP_HOME=%DIRNAME% 18 | 19 | @rem Find java.exe 20 | if defined JAVA_HOME goto findJavaFromJavaHome 21 | 22 | set JAVA_EXE=java.exe 23 | %JAVA_EXE% -version >NUL 2>&1 24 | if "%ERRORLEVEL%" == "0" goto init 25 | 26 | echo. 27 | echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 28 | echo. 29 | echo Please set the JAVA_HOME variable in your environment to match the 30 | echo location of your Java installation. 31 | 32 | goto fail 33 | 34 | :findJavaFromJavaHome 35 | set JAVA_HOME=%JAVA_HOME:"=% 36 | set JAVA_EXE=%JAVA_HOME%/bin/java.exe 37 | 38 | if exist "%JAVA_EXE%" goto init 39 | 40 | echo. 41 | echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% 42 | echo. 43 | echo Please set the JAVA_HOME variable in your environment to match the 44 | echo location of your Java installation. 45 | 46 | goto fail 47 | 48 | :init 49 | @rem Get command-line arguments, handling Windowz variants 50 | 51 | if not "%OS%" == "Windows_NT" goto win9xME_args 52 | if "%@eval[2+2]" == "4" goto 4NT_args 53 | 54 | :win9xME_args 55 | @rem Slurp the command line arguments. 56 | set CMD_LINE_ARGS= 57 | set _SKIP=2 58 | 59 | :win9xME_args_slurp 60 | if "x%~1" == "x" goto execute 61 | 62 | set CMD_LINE_ARGS=%* 63 | goto execute 64 | 65 | :4NT_args 66 | @rem Get arguments from the 4NT Shell from JP Software 67 | set CMD_LINE_ARGS=%$ 68 | 69 | :execute 70 | @rem Setup the command line 71 | 72 | set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar 73 | 74 | @rem Execute Gradle 75 | "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS% 76 | 77 | :end 78 | @rem End local scope for the variables with windows NT shell 79 | if "%ERRORLEVEL%"=="0" goto mainEnd 80 | 81 | :fail 82 | rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of 83 | rem the _cmd.exe /c_ return code! 84 | if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1 85 | exit /b 1 86 | 87 | :mainEnd 88 | if "%OS%"=="Windows_NT" endlocal 89 | 90 | :omega 91 | -------------------------------------------------------------------------------- /mobile/src/main/res/layout/activity_auth.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 8 | 9 | 14 | 15 | 19 | 20 | 25 | 26 | 35 | 36 | 45 | 46 |