diff options
Diffstat (limited to 'app/src/main/java')
-rw-r--r-- | app/src/main/java/com/beam_messenger/beam_messenger/LoginActivity.kt | 10 | ||||
-rw-r--r-- | app/src/main/java/com/beam_messenger/beam_messenger/MainActivity.kt | 16 |
2 files changed, 6 insertions, 20 deletions
diff --git a/app/src/main/java/com/beam_messenger/beam_messenger/LoginActivity.kt b/app/src/main/java/com/beam_messenger/beam_messenger/LoginActivity.kt index 02d1d6f..4572134 100644 --- a/app/src/main/java/com/beam_messenger/beam_messenger/LoginActivity.kt +++ b/app/src/main/java/com/beam_messenger/beam_messenger/LoginActivity.kt @@ -4,7 +4,6 @@ import android.Manifest.permission.READ_CONTACTS import android.animation.Animator import android.animation.AnimatorListenerAdapter import android.annotation.TargetApi -import android.app.ActivityOptions import android.app.LoaderManager.LoaderCallbacks import android.content.CursorLoader import android.content.Intent @@ -19,10 +18,8 @@ import android.provider.ContactsContract import android.support.design.widget.Snackbar import android.support.v7.app.AppCompatActivity import android.text.TextUtils -import android.transition.Explode import android.view.Gravity import android.view.View -import android.view.Window import android.view.inputmethod.EditorInfo import android.widget.ArrayAdapter import android.widget.TextView @@ -40,11 +37,6 @@ class LoginActivity : AppCompatActivity(), LoaderCallbacks<Cursor> { private var mAuthTask: UserLoginTask? = null override fun onCreate(savedInstanceState: Bundle?) { - with(window) { - requestFeature(Window.FEATURE_CONTENT_TRANSITIONS) - exitTransition = Explode() - } - super.onCreate(savedInstanceState) setContentView(R.layout.activity_login) // Set up the login form. @@ -279,7 +271,7 @@ class LoginActivity : AppCompatActivity(), LoaderCallbacks<Cursor> { val intent = Intent(this@LoginActivity, MainActivity::class.java) //intent.putExtra("keyIdentifier", value) - startActivity(intent, ActivityOptions.makeSceneTransitionAnimation(this@LoginActivity).toBundle()) + startActivity(intent) } else { password.error = getString(R.string.error_incorrect_password) password.requestFocus() diff --git a/app/src/main/java/com/beam_messenger/beam_messenger/MainActivity.kt b/app/src/main/java/com/beam_messenger/beam_messenger/MainActivity.kt index 1686589..e759854 100644 --- a/app/src/main/java/com/beam_messenger/beam_messenger/MainActivity.kt +++ b/app/src/main/java/com/beam_messenger/beam_messenger/MainActivity.kt @@ -1,15 +1,12 @@ package com.beam_messenger.beam_messenger -import android.app.ActivityOptions import android.content.Intent import android.os.Bundle -import android.support.design.widget.Snackbar import android.support.design.widget.TabLayout import android.support.v4.app.Fragment import android.support.v4.app.FragmentManager import android.support.v4.app.FragmentPagerAdapter import android.support.v7.app.AppCompatActivity -import android.transition.Fade import android.view.* import kotlinx.android.synthetic.main.activity_main.* import kotlinx.android.synthetic.main.fragment_main.view.* @@ -27,11 +24,6 @@ class MainActivity : AppCompatActivity() { private var mSectionsPagerAdapter: SectionsPagerAdapter? = null override fun onCreate(savedInstanceState: Bundle?) { - with(window) { - requestFeature(Window.FEATURE_CONTENT_TRANSITIONS) - exitTransition = Fade() - } - super.onCreate(savedInstanceState) setContentView(R.layout.activity_main) @@ -47,8 +39,10 @@ class MainActivity : AppCompatActivity() { tabs.addOnTabSelectedListener(TabLayout.ViewPagerOnTabSelectedListener(container)) fab.setOnClickListener { view -> - Snackbar.make(view, "Replace with your own action", Snackbar.LENGTH_LONG) - .setAction("Action", null).show() + val intent = Intent(this@MainActivity, LoginActivity::class.java) + startActivity(intent) + /*Snackbar.make(view, "Replace with your own action", Snackbar.LENGTH_LONG) + .setAction("Action", null).show()*/ } } @@ -67,7 +61,7 @@ class MainActivity : AppCompatActivity() { if (id == R.id.action_settings) { val intent = Intent(this@MainActivity, LoginActivity::class.java) - startActivity(intent, ActivityOptions.makeSceneTransitionAnimation(this).toBundle()) + startActivity(intent) } return super.onOptionsItemSelected(item) |