├── app ├── .gitignore ├── src │ ├── main │ │ ├── res │ │ │ ├── values │ │ │ │ ├── strings.xml │ │ │ │ ├── colors.xml │ │ │ │ └── styles.xml │ │ │ ├── mipmap-hdpi │ │ │ │ ├── ic_launcher.png │ │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-mdpi │ │ │ │ ├── ic_launcher.png │ │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xhdpi │ │ │ │ ├── ic_launcher.png │ │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxhdpi │ │ │ │ ├── ic_launcher.png │ │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxxhdpi │ │ │ │ ├── ic_launcher.png │ │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-anydpi-v26 │ │ │ │ ├── ic_launcher.xml │ │ │ │ └── ic_launcher_round.xml │ │ │ ├── layout │ │ │ │ ├── activity_profile.xml │ │ │ │ ├── activity_login.xml │ │ │ │ └── activity_main.xml │ │ │ ├── drawable-v24 │ │ │ │ └── ic_launcher_foreground.xml │ │ │ └── drawable │ │ │ │ └── ic_launcher_background.xml │ │ ├── java │ │ │ └── simplifiedcoding │ │ │ │ └── net │ │ │ │ └── kotlinretrofittutorial │ │ │ │ ├── models │ │ │ │ ├── User.kt │ │ │ │ ├── LoginResponse.kt │ │ │ │ └── DefaultResponse.kt │ │ │ │ ├── api │ │ │ │ ├── Api.kt │ │ │ │ └── RetrofitClient.kt │ │ │ │ ├── activities │ │ │ │ ├── ProfileActivity.kt │ │ │ │ ├── LoginActivity.kt │ │ │ │ └── MainActivity.kt │ │ │ │ └── storage │ │ │ │ └── SharedPrefManager.kt │ │ └── AndroidManifest.xml │ ├── test │ │ └── java │ │ │ └── simplifiedcoding │ │ │ └── net │ │ │ └── kotlinretrofittutorial │ │ │ └── ExampleUnitTest.kt │ └── androidTest │ │ └── java │ │ └── simplifiedcoding │ │ └── net │ │ └── kotlinretrofittutorial │ │ └── ExampleInstrumentedTest.kt ├── proguard-rules.pro └── build.gradle ├── settings.gradle ├── gradle └── wrapper │ ├── gradle-wrapper.jar │ └── gradle-wrapper.properties ├── .idea ├── vcs.xml ├── runConfigurations.xml ├── gradle.xml ├── codeStyles │ └── Project.xml └── misc.xml ├── .gitignore ├── gradle.properties ├── gradlew.bat └── gradlew /app/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /settings.gradle: -------------------------------------------------------------------------------- 1 | include ':app' 2 | -------------------------------------------------------------------------------- /app/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | KotlinRetrofitTutorial 3 | 4 | -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probelalkhan/kotlin-retrofit-tutorial/HEAD/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probelalkhan/kotlin-retrofit-tutorial/HEAD/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probelalkhan/kotlin-retrofit-tutorial/HEAD/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probelalkhan/kotlin-retrofit-tutorial/HEAD/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probelalkhan/kotlin-retrofit-tutorial/HEAD/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probelalkhan/kotlin-retrofit-tutorial/HEAD/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-hdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probelalkhan/kotlin-retrofit-tutorial/HEAD/app/src/main/res/mipmap-hdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-mdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probelalkhan/kotlin-retrofit-tutorial/HEAD/app/src/main/res/mipmap-mdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probelalkhan/kotlin-retrofit-tutorial/HEAD/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probelalkhan/kotlin-retrofit-tutorial/HEAD/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probelalkhan/kotlin-retrofit-tutorial/HEAD/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /.idea/vcs.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/java/simplifiedcoding/net/kotlinretrofittutorial/models/User.kt: -------------------------------------------------------------------------------- 1 | package simplifiedcoding.net.kotlinretrofittutorial.models 2 | 3 | data class User(val id:Int, val email:String, val name:String, val school:String) -------------------------------------------------------------------------------- /app/src/main/java/simplifiedcoding/net/kotlinretrofittutorial/models/LoginResponse.kt: -------------------------------------------------------------------------------- 1 | package simplifiedcoding.net.kotlinretrofittutorial.models 2 | 3 | data class LoginResponse(val error: Boolean, val message:String, val user: User) -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | *.iml 2 | .gradle 3 | /local.properties 4 | /.idea/caches/build_file_checksums.ser 5 | /.idea/libraries 6 | /.idea/modules.xml 7 | /.idea/workspace.xml 8 | .DS_Store 9 | /build 10 | /captures 11 | .externalNativeBuild 12 | -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | distributionBase=GRADLE_USER_HOME 2 | distributionPath=wrapper/dists 3 | distributionUrl=https\://services.gradle.org/distributions/gradle-4.6-all.zip 4 | zipStoreBase=GRADLE_USER_HOME 5 | zipStorePath=wrapper/dists 6 | -------------------------------------------------------------------------------- /app/src/main/java/simplifiedcoding/net/kotlinretrofittutorial/models/DefaultResponse.kt: -------------------------------------------------------------------------------- 1 | package simplifiedcoding.net.kotlinretrofittutorial.models 2 | 3 | import com.google.gson.annotations.SerializedName 4 | 5 | data class DefaultResponse(val error: Boolean, val message:String) -------------------------------------------------------------------------------- /app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/values/colors.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | #21a7ed 4 | #0a5b85 5 | #0886c7 6 | #375290 7 | #e4e4e4 8 | -------------------------------------------------------------------------------- /app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /app/src/main/res/layout/activity_profile.xml: -------------------------------------------------------------------------------- 1 | 2 | 8 | 9 | -------------------------------------------------------------------------------- /app/src/test/java/simplifiedcoding/net/kotlinretrofittutorial/ExampleUnitTest.kt: -------------------------------------------------------------------------------- 1 | package simplifiedcoding.net.kotlinretrofittutorial 2 | 3 | import org.junit.Test 4 | 5 | import org.junit.Assert.* 6 | 7 | /** 8 | * Example local unit test, which will execute on the development machine (host). 9 | * 10 | * See [testing documentation](http://d.android.com/tools/testing). 11 | */ 12 | class ExampleUnitTest { 13 | @Test 14 | fun addition_isCorrect() { 15 | assertEquals(4, 2 + 2) 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /.idea/runConfigurations.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 11 | 12 | -------------------------------------------------------------------------------- /.idea/gradle.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 17 | 18 | -------------------------------------------------------------------------------- /gradle.properties: -------------------------------------------------------------------------------- 1 | # Project-wide Gradle settings. 2 | # IDE (e.g. Android Studio) users: 3 | # Gradle settings configured through the IDE *will override* 4 | # any settings specified in this file. 5 | # For more details on how to configure your build environment visit 6 | # http://www.gradle.org/docs/current/userguide/build_environment.html 7 | # Specifies the JVM arguments used for the daemon process. 8 | # The setting is particularly useful for tweaking memory settings. 9 | org.gradle.jvmargs=-Xmx1536m 10 | # When configured, Gradle will run in incubating parallel mode. 11 | # This option should only be used with decoupled projects. More details, visit 12 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects 13 | # org.gradle.parallel=true 14 | 15 | -------------------------------------------------------------------------------- /app/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # You can control the set of applied configuration files using the 3 | # proguardFiles setting in build.gradle. 4 | # 5 | # For more details, see 6 | # http://developer.android.com/guide/developing/tools/proguard.html 7 | 8 | # If your project uses WebView with JS, uncomment the following 9 | # and specify the fully qualified class name to the JavaScript interface 10 | # class: 11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 12 | # public *; 13 | #} 14 | 15 | # Uncomment this to preserve the line number information for 16 | # debugging stack traces. 17 | #-keepattributes SourceFile,LineNumberTable 18 | 19 | # If you keep the line number information, uncomment this to 20 | # hide the original source file name. 21 | #-renamesourcefileattribute SourceFile 22 | -------------------------------------------------------------------------------- /app/src/androidTest/java/simplifiedcoding/net/kotlinretrofittutorial/ExampleInstrumentedTest.kt: -------------------------------------------------------------------------------- 1 | package simplifiedcoding.net.kotlinretrofittutorial 2 | 3 | import android.support.test.InstrumentationRegistry 4 | import android.support.test.runner.AndroidJUnit4 5 | 6 | import org.junit.Test 7 | import org.junit.runner.RunWith 8 | 9 | import org.junit.Assert.* 10 | 11 | /** 12 | * Instrumented test, which will execute on an Android device. 13 | * 14 | * See [testing documentation](http://d.android.com/tools/testing). 15 | */ 16 | @RunWith(AndroidJUnit4::class) 17 | class ExampleInstrumentedTest { 18 | @Test 19 | fun useAppContext() { 20 | // Context of the app under test. 21 | val appContext = InstrumentationRegistry.getTargetContext() 22 | assertEquals("simplifiedcoding.net.kotlinretrofittutorial", appContext.packageName) 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /app/src/main/java/simplifiedcoding/net/kotlinretrofittutorial/api/Api.kt: -------------------------------------------------------------------------------- 1 | package simplifiedcoding.net.kotlinretrofittutorial.api 2 | 3 | import retrofit2.Call 4 | import retrofit2.http.Field 5 | import retrofit2.http.FormUrlEncoded 6 | import retrofit2.http.POST 7 | import simplifiedcoding.net.kotlinretrofittutorial.models.DefaultResponse 8 | import simplifiedcoding.net.kotlinretrofittutorial.models.LoginResponse 9 | 10 | interface Api { 11 | 12 | @FormUrlEncoded 13 | @POST("createuser") 14 | fun createUser( 15 | @Field("email") email:String, 16 | @Field("name") name:String, 17 | @Field("password") password:String, 18 | @Field("school") school:String 19 | ):Call 20 | 21 | @FormUrlEncoded 22 | @POST("userlogin") 23 | fun userLogin( 24 | @Field("email") email:String, 25 | @Field("password") password: String 26 | ):Call 27 | } -------------------------------------------------------------------------------- /app/src/main/java/simplifiedcoding/net/kotlinretrofittutorial/activities/ProfileActivity.kt: -------------------------------------------------------------------------------- 1 | package simplifiedcoding.net.kotlinretrofittutorial.activities 2 | 3 | import android.content.Intent 4 | import android.support.v7.app.AppCompatActivity 5 | import android.os.Bundle 6 | import simplifiedcoding.net.kotlinretrofittutorial.R 7 | import simplifiedcoding.net.kotlinretrofittutorial.storage.SharedPrefManager 8 | 9 | class ProfileActivity : AppCompatActivity() { 10 | 11 | override fun onCreate(savedInstanceState: Bundle?) { 12 | super.onCreate(savedInstanceState) 13 | setContentView(R.layout.activity_profile) 14 | } 15 | 16 | 17 | override fun onStart() { 18 | super.onStart() 19 | 20 | if(!SharedPrefManager.getInstance(this).isLoggedIn){ 21 | val intent = Intent(applicationContext, LoginActivity::class.java) 22 | intent.flags = Intent.FLAG_ACTIVITY_NEW_TASK or Intent.FLAG_ACTIVITY_CLEAR_TASK 23 | startActivity(intent) 24 | } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /app/src/main/java/simplifiedcoding/net/kotlinretrofittutorial/api/RetrofitClient.kt: -------------------------------------------------------------------------------- 1 | package simplifiedcoding.net.kotlinretrofittutorial.api 2 | 3 | import android.util.Base64 4 | import okhttp3.OkHttpClient 5 | import retrofit2.Retrofit 6 | import retrofit2.converter.gson.GsonConverterFactory 7 | 8 | object RetrofitClient { 9 | 10 | private val AUTH = "Basic "+ Base64.encodeToString("belalkhan:123456".toByteArray(), Base64.NO_WRAP) 11 | 12 | private const val BASE_URL = "http://192.168.43.207/myapi/public/" 13 | 14 | private val okHttpClient = OkHttpClient.Builder() 15 | .addInterceptor { chain -> 16 | val original = chain.request() 17 | 18 | val requestBuilder = original.newBuilder() 19 | .addHeader("Authorization", AUTH) 20 | .method(original.method(), original.body()) 21 | 22 | val request = requestBuilder.build() 23 | chain.proceed(request) 24 | }.build() 25 | 26 | val instance: Api by lazy{ 27 | val retrofit = Retrofit.Builder() 28 | .baseUrl(BASE_URL) 29 | .addConverterFactory(GsonConverterFactory.create()) 30 | .client(okHttpClient) 31 | .build() 32 | 33 | retrofit.create(Api::class.java) 34 | } 35 | 36 | } -------------------------------------------------------------------------------- /app/build.gradle: -------------------------------------------------------------------------------- 1 | apply plugin: 'com.android.application' 2 | 3 | apply plugin: 'kotlin-android' 4 | 5 | apply plugin: 'kotlin-android-extensions' 6 | 7 | android { 8 | compileSdkVersion 28 9 | defaultConfig { 10 | applicationId "simplifiedcoding.net.kotlinretrofittutorial" 11 | minSdkVersion 21 12 | targetSdkVersion 28 13 | versionCode 1 14 | versionName "1.0" 15 | testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner" 16 | } 17 | buildTypes { 18 | release { 19 | minifyEnabled false 20 | proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' 21 | } 22 | } 23 | } 24 | 25 | dependencies { 26 | implementation fileTree(dir: 'libs', include: ['*.jar']) 27 | implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version" 28 | implementation 'com.android.support:appcompat-v7:28.0.0' 29 | implementation 'com.android.support.constraint:constraint-layout:1.1.3' 30 | testImplementation 'junit:junit:4.12' 31 | androidTestImplementation 'com.android.support.test:runner:1.0.2' 32 | androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2' 33 | 34 | implementation 'com.squareup.retrofit2:retrofit:2.5.0' 35 | implementation 'com.squareup.retrofit2:converter-gson:2.5.0' 36 | } 37 | -------------------------------------------------------------------------------- /.idea/codeStyles/Project.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 15 | 16 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | -------------------------------------------------------------------------------- /app/src/main/res/drawable-v24/ic_launcher_foreground.xml: -------------------------------------------------------------------------------- 1 | 7 | 12 | 13 | 19 | 22 | 25 | 26 | 27 | 28 | 34 | 35 | -------------------------------------------------------------------------------- /app/src/main/java/simplifiedcoding/net/kotlinretrofittutorial/storage/SharedPrefManager.kt: -------------------------------------------------------------------------------- 1 | package simplifiedcoding.net.kotlinretrofittutorial.storage 2 | 3 | import android.content.Context 4 | import simplifiedcoding.net.kotlinretrofittutorial.models.User 5 | 6 | 7 | class SharedPrefManager private constructor(private val mCtx: Context) { 8 | 9 | val isLoggedIn: Boolean 10 | get() { 11 | val sharedPreferences = mCtx.getSharedPreferences(SHARED_PREF_NAME, Context.MODE_PRIVATE) 12 | return sharedPreferences.getInt("id", -1) != -1 13 | } 14 | 15 | val user: User 16 | get() { 17 | val sharedPreferences = mCtx.getSharedPreferences(SHARED_PREF_NAME, Context.MODE_PRIVATE) 18 | return User( 19 | sharedPreferences.getInt("id", -1), 20 | sharedPreferences.getString("email", null), 21 | sharedPreferences.getString("name", null), 22 | sharedPreferences.getString("school", null) 23 | ) 24 | } 25 | 26 | 27 | fun saveUser(user: User) { 28 | 29 | val sharedPreferences = mCtx.getSharedPreferences(SHARED_PREF_NAME, Context.MODE_PRIVATE) 30 | val editor = sharedPreferences.edit() 31 | 32 | editor.putInt("id", user.id) 33 | editor.putString("email", user.email) 34 | editor.putString("name", user.name) 35 | editor.putString("school", user.school) 36 | 37 | editor.apply() 38 | 39 | } 40 | 41 | fun clear() { 42 | val sharedPreferences = mCtx.getSharedPreferences(SHARED_PREF_NAME, Context.MODE_PRIVATE) 43 | val editor = sharedPreferences.edit() 44 | editor.clear() 45 | editor.apply() 46 | } 47 | 48 | companion object { 49 | private val SHARED_PREF_NAME = "my_shared_preff" 50 | private var mInstance: SharedPrefManager? = null 51 | @Synchronized 52 | fun getInstance(mCtx: Context): SharedPrefManager { 53 | if (mInstance == null) { 54 | mInstance = SharedPrefManager(mCtx) 55 | } 56 | return mInstance as SharedPrefManager 57 | } 58 | } 59 | 60 | } -------------------------------------------------------------------------------- /.idea/misc.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 19 | 31 | 32 | 33 | 34 | 35 | 36 | 38 | -------------------------------------------------------------------------------- /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 | set DIRNAME=%~dp0 12 | if "%DIRNAME%" == "" set DIRNAME=. 13 | set APP_BASE_NAME=%~n0 14 | set APP_HOME=%DIRNAME% 15 | 16 | @rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. 17 | set DEFAULT_JVM_OPTS= 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 Windows variants 50 | 51 | if not "%OS%" == "Windows_NT" goto win9xME_args 52 | 53 | :win9xME_args 54 | @rem Slurp the command line arguments. 55 | set CMD_LINE_ARGS= 56 | set _SKIP=2 57 | 58 | :win9xME_args_slurp 59 | if "x%~1" == "x" goto execute 60 | 61 | set CMD_LINE_ARGS=%* 62 | 63 | :execute 64 | @rem Setup the command line 65 | 66 | set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar 67 | 68 | @rem Execute Gradle 69 | "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS% 70 | 71 | :end 72 | @rem End local scope for the variables with windows NT shell 73 | if "%ERRORLEVEL%"=="0" goto mainEnd 74 | 75 | :fail 76 | rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of 77 | rem the _cmd.exe /c_ return code! 78 | if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1 79 | exit /b 1 80 | 81 | :mainEnd 82 | if "%OS%"=="Windows_NT" endlocal 83 | 84 | :omega 85 | -------------------------------------------------------------------------------- /app/src/main/res/layout/activity_login.xml: -------------------------------------------------------------------------------- 1 | 2 | 9 | 10 | 19 | 20 | 30 | 31 | 38 | 39 | 46 | 47 | 48 | 49 | 50 | 62 | 63 |