mirror of
https://github.com/syncthing/syncthing-android.git
synced 2024-11-23 12:51:16 +00:00
Show loading dialog when restarting Syncthing
This commit is contained in:
parent
918c6c4e92
commit
771ff06345
2 changed files with 3 additions and 1 deletions
|
@ -92,9 +92,11 @@ public class MainActivity extends SyncthingActivity
|
||||||
|
|
||||||
if (mLoadingDialog != null) {
|
if (mLoadingDialog != null) {
|
||||||
mLoadingDialog.dismiss();
|
mLoadingDialog.dismiss();
|
||||||
|
mLoadingDialog = null;
|
||||||
}
|
}
|
||||||
if (mDisabledDialog != null) {
|
if (mDisabledDialog != null) {
|
||||||
mDisabledDialog.dismiss();
|
mDisabledDialog.dismiss();
|
||||||
|
mDisabledDialog = null;
|
||||||
}
|
}
|
||||||
mDrawerLayout.setDrawerLockMode(DrawerLayout.LOCK_MODE_UNLOCKED);
|
mDrawerLayout.setDrawerLockMode(DrawerLayout.LOCK_MODE_UNLOCKED);
|
||||||
mDrawerLayout.setDrawerListener(mDrawerToggle);
|
mDrawerLayout.setDrawerListener(mDrawerToggle);
|
||||||
|
|
|
@ -361,7 +361,7 @@ public class SyncthingService extends Service {
|
||||||
* changes.
|
* changes.
|
||||||
*/
|
*/
|
||||||
public void registerOnApiChangeListener(OnApiChangeListener listener) {
|
public void registerOnApiChangeListener(OnApiChangeListener listener) {
|
||||||
// Make sure we don't send an invalid state or syncthing might shwow a "disabled" message
|
// Make sure we don't send an invalid state or syncthing might show a "disabled" message
|
||||||
// when it's just starting up.
|
// when it's just starting up.
|
||||||
listener.onApiChange(mCurrentState);
|
listener.onApiChange(mCurrentState);
|
||||||
mOnApiChangeListeners.add(new WeakReference<>(listener));
|
mOnApiChangeListeners.add(new WeakReference<>(listener));
|
||||||
|
|
Loading…
Reference in a new issue