mirror of
https://github.com/nextcloud/android.git
synced 2024-11-27 09:39:25 +03:00
set action bar title to show "On device"
This commit is contained in:
parent
36bed52eae
commit
6e98e25184
1 changed files with 19 additions and 5 deletions
|
@ -2492,9 +2492,23 @@ public class FileDisplayActivity extends HookActivity
|
|||
browseToRoot();
|
||||
}
|
||||
|
||||
public void setActionBarTitle(@StringRes final int title) {
|
||||
runOnUiThread(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
if (getSupportActionBar() != null) {
|
||||
ThemeUtils.setColoredTitle(getSupportActionBar(), title, getBaseContext());
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@Override
|
||||
public void showFiles(boolean onDeviceOnly) {
|
||||
super.showFiles(onDeviceOnly);
|
||||
if (onDeviceOnly) {
|
||||
setActionBarTitle(R.string.drawer_item_on_device);
|
||||
}
|
||||
getListOfFilesFragment().refreshDirectory();
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue