diff options
author | Samuel Holland <samuel@sholland.org> | 2017-08-15 17:07:17 -0500 |
---|---|---|
committer | Samuel Holland <samuel@sholland.org> | 2017-08-15 17:07:17 -0500 |
commit | f9b4e9587519cfcae5a566a95baaea4e1b2f731d (patch) | |
tree | 1ac775ef438200a8ad8c4a3c37e58a96b3bde5e7 /app/src | |
parent | 3e1081265641fa1c96b35b9b99823df38a31cbad (diff) |
ConfigActivity: Show the current config in the title
Diffstat (limited to 'app/src')
-rw-r--r-- | app/src/main/java/com/wireguard/android/ConfigActivity.java | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/app/src/main/java/com/wireguard/android/ConfigActivity.java b/app/src/main/java/com/wireguard/android/ConfigActivity.java index b3cde478..baa29766 100644 --- a/app/src/main/java/com/wireguard/android/ConfigActivity.java +++ b/app/src/main/java/com/wireguard/android/ConfigActivity.java @@ -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; |