Commit 30a3d9cf authored by Grigory Fedorov's avatar Grigory Fedorov

AccountInfoEditorFragment: "save" button activated only after data change....

AccountInfoEditorFragment: "save" button activated only after data change. todo: save state for rotation.
parent bec8b4b3
...@@ -73,6 +73,7 @@ public class AccountInfoEditor extends ManagedActivity implements Toolbar.OnMenu ...@@ -73,6 +73,7 @@ public class AccountInfoEditor extends ManagedActivity implements Toolbar.OnMenu
toolbar.inflateMenu(SAVE_MENU); toolbar.inflateMenu(SAVE_MENU);
toolbar.setOnMenuItemClickListener(this); toolbar.setOnMenuItemClickListener(this);
toolbar.getMenu().findItem(R.id.action_save).setEnabled(false);
} }
@Override @Override
...@@ -115,6 +116,10 @@ public class AccountInfoEditor extends ManagedActivity implements Toolbar.OnMenu ...@@ -115,6 +116,10 @@ public class AccountInfoEditor extends ManagedActivity implements Toolbar.OnMenu
@Override @Override
public void onVCardSavingFinished() { public void onVCardSavingFinished() {
toolbar.setTitle(R.string.edit_account_user_info); toolbar.setTitle(R.string.edit_account_user_info);
}
@Override
public void enableSave() {
toolbar.getMenu().findItem(R.id.action_save).setEnabled(true); toolbar.getMenu().findItem(R.id.action_save).setEnabled(true);
} }
} }
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