Commit f935b85d authored by Yusuke Iwaki's avatar Yusuke Iwaki

fix issue that LoginFragment always shown

parent 8eb83aad
...@@ -8,13 +8,11 @@ import android.support.v4.app.Fragment; ...@@ -8,13 +8,11 @@ import android.support.v4.app.Fragment;
import chat.rocket.android.R; import chat.rocket.android.R;
import chat.rocket.android.fragment.server_config.LoginFragment; import chat.rocket.android.fragment.server_config.LoginFragment;
import chat.rocket.android.fragment.server_config.RetryLoginFragment; import chat.rocket.android.fragment.server_config.RetryLoginFragment;
import chat.rocket.android.fragment.server_config.WaitingFragment;
import chat.rocket.android.helper.TextUtils; import chat.rocket.android.helper.TextUtils;
import chat.rocket.android.model.internal.Session; import chat.rocket.android.model.internal.Session;
import chat.rocket.android.realm_helper.RealmObjectObserver; import chat.rocket.android.realm_helper.RealmObjectObserver;
import chat.rocket.android.realm_helper.RealmStore; import chat.rocket.android.realm_helper.RealmStore;
import chat.rocket.android.service.ConnectivityManager; import chat.rocket.android.service.ConnectivityManager;
import chat.rocket.android.service.RocketChatService;
/** /**
* Activity for Login, Sign-up, and Retry connecting... * Activity for Login, Sign-up, and Retry connecting...
...@@ -50,7 +48,7 @@ public class LoginActivity extends AbstractFragmentActivity { ...@@ -50,7 +48,7 @@ public class LoginActivity extends AbstractFragmentActivity {
.setOnUpdateListener(this::onRenderServerConfigSession); .setOnUpdateListener(this::onRenderServerConfigSession);
setContentView(R.layout.simple_screen); setContentView(R.layout.simple_screen);
showFragment(new WaitingFragment()); showFragment(new LoginFragment());
} }
@Override @Override
...@@ -68,7 +66,6 @@ public class LoginActivity extends AbstractFragmentActivity { ...@@ -68,7 +66,6 @@ public class LoginActivity extends AbstractFragmentActivity {
private void onRenderServerConfigSession(Session session) { private void onRenderServerConfigSession(Session session) {
if (session == null) { if (session == null) {
showFragment(new LoginFragment());
return; return;
} }
...@@ -82,8 +79,6 @@ public class LoginActivity extends AbstractFragmentActivity { ...@@ -82,8 +79,6 @@ public class LoginActivity extends AbstractFragmentActivity {
} }
return; return;
} }
showFragment(new LoginFragment());
} }
@Override @Override
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment