ConfigActivity: Show the current config in the title

Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
This commit is contained in:
Samuel Holland 2017-08-15 17:07:17 -05:00
parent cfcda8bd13
commit 2103a28f8f

View File

@ -73,6 +73,10 @@ public class ConfigActivity extends BaseConfigActivity {
// listFragment is guaranteed not to be null at this point by onServiceAvailable().
if (listFragment.getCurrentConfig() != config)
listFragment.setCurrentConfig(config);
// Update the activity's title if the list of configurations is not visible.
if (!isSplitLayout)
setTitle(config != null ? config.getName() : getString(R.string.app_name));
// Update the fragment in the main container.
if (isEditing) {
fm.popBackStackImmediate();
isEditing = false;