From 1ddc1a914d805cc11e6b603fb617ea5fa630e317 Mon Sep 17 00:00:00 2001 From: Marvin Borner Date: Mon, 10 Sep 2018 18:39:52 +0200 Subject: Added text to login screen :sparkles: --- app/src/main/java/me/texx/Texx/RoutingActivity.kt | 2 +- app/src/main/res/layout/activity_login.xml | 41 +++++++++++++++++++++++ app/src/main/res/values/strings.xml | 8 +++-- 3 files changed, 47 insertions(+), 4 deletions(-) (limited to 'app/src') diff --git a/app/src/main/java/me/texx/Texx/RoutingActivity.kt b/app/src/main/java/me/texx/Texx/RoutingActivity.kt index 805bf5f..4e11c60 100644 --- a/app/src/main/java/me/texx/Texx/RoutingActivity.kt +++ b/app/src/main/java/me/texx/Texx/RoutingActivity.kt @@ -72,7 +72,7 @@ class RoutingActivity : AppCompatActivity() { private fun verifyLogin() { val accessToken: String? = SecureStorage(this@RoutingActivity).get("access_token") // because it may be the first start // synced function of fuel doesn't work here (#331) -> ugly workaround - if (accessToken != null) { + if (accessToken == null) { val userID = EasyPrefrences(this@RoutingActivity).getString("user_id") "/users/$userID".httpGet() // verify by making request to user api // TODO: More secure way of verifying .responseJson { _, response, result -> diff --git a/app/src/main/res/layout/activity_login.xml b/app/src/main/res/layout/activity_login.xml index da8bae3..d5fd089 100644 --- a/app/src/main/res/layout/activity_login.xml +++ b/app/src/main/res/layout/activity_login.xml @@ -27,6 +27,8 @@ android:id="@+id/login_progress" android:layout_width="wrap_content" android:layout_height="wrap_content" + android:layout_centerHorizontal="true" + android:layout_centerVertical="true" android:layout_marginBottom="8dp" android:visibility="gone" /> @@ -40,6 +42,45 @@ android:layout_alignParentTop="@id/image_background"> + + + + + + Loading... - App Settings + + Welcome to Texx. + Let\'s Connect! + Please Login or Register Newly to Texx. + App Settings General Account Enable Dark theme @@ -32,8 +36,6 @@ Report an issue Title Describe your issue - - Hello blank fragment