mirror of
https://github.com/moparisthebest/k-9
synced 2024-11-24 10:22:15 -05:00
Make the icon up navigation work in messagelist when displaying a query, tapping it takes you back to the account screen.
This commit is contained in:
parent
6daa8a3c0c
commit
f530af7f8b
@ -673,7 +673,7 @@ public class MessageList extends K9ListActivity implements
|
|||||||
|
|
||||||
mInflater = getLayoutInflater();
|
mInflater = getLayoutInflater();
|
||||||
mActionBar = getSupportActionBar();
|
mActionBar = getSupportActionBar();
|
||||||
if (mQueryString == null) initializeActionBar();
|
initializeActionBar();
|
||||||
initializeLayout();
|
initializeLayout();
|
||||||
|
|
||||||
// Only set "touchable" when we're first starting up the activity.
|
// Only set "touchable" when we're first starting up the activity.
|
||||||
@ -905,13 +905,16 @@ public class MessageList extends K9ListActivity implements
|
|||||||
}
|
}
|
||||||
|
|
||||||
private void initializeActionBar() {
|
private void initializeActionBar() {
|
||||||
mActionBar.setDisplayHomeAsUpEnabled(true);
|
if (mQueryString == null) {
|
||||||
mActionBar.setDisplayShowTitleEnabled(false);
|
mActionBar.setDisplayShowTitleEnabled(false);
|
||||||
mActionBar.setNavigationMode(ActionBar.NAVIGATION_MODE_LIST);
|
mActionBar.setNavigationMode(ActionBar.NAVIGATION_MODE_LIST);
|
||||||
mNavigationSpinner = ActionBarNavigationSpinner.getDefaultSpinner(this);
|
mNavigationSpinner = ActionBarNavigationSpinner.getDefaultSpinner(this);
|
||||||
mActionBar.setListNavigationCallbacks(mNavigationSpinner, this);
|
mActionBar.setListNavigationCallbacks(mNavigationSpinner, this);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
mActionBar.setDisplayHomeAsUpEnabled(true);
|
||||||
|
}
|
||||||
|
|
||||||
private void initializeLayout() {
|
private void initializeLayout() {
|
||||||
mListView = getListView();
|
mListView = getListView();
|
||||||
mListView.setScrollBarStyle(View.SCROLLBARS_OUTSIDE_INSET);
|
mListView.setScrollBarStyle(View.SCROLLBARS_OUTSIDE_INSET);
|
||||||
@ -1448,7 +1451,11 @@ public class MessageList extends K9ListActivity implements
|
|||||||
int itemId = item.getItemId();
|
int itemId = item.getItemId();
|
||||||
switch (itemId) {
|
switch (itemId) {
|
||||||
case android.R.id.home: {
|
case android.R.id.home: {
|
||||||
|
if (mQueryString == null) {
|
||||||
onShowFolderList();
|
onShowFolderList();
|
||||||
|
} else {
|
||||||
|
onAccounts();
|
||||||
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
case R.id.compose: {
|
case R.id.compose: {
|
||||||
|
Loading…
Reference in New Issue
Block a user