From 9c9763154ed1d610478eb2bc5a3a756e5cd1711b Mon Sep 17 00:00:00 2001 From: Sander Bogaert Date: Thu, 26 Jul 2012 10:18:51 -0400 Subject: [PATCH] Abbriviate long foldernames. --- src/com/fsck/k9/activity/MessageList.java | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/com/fsck/k9/activity/MessageList.java b/src/com/fsck/k9/activity/MessageList.java index 9d0f4fc29..1bf1e4060 100644 --- a/src/com/fsck/k9/activity/MessageList.java +++ b/src/com/fsck/k9/activity/MessageList.java @@ -517,7 +517,13 @@ public class MessageList extends K9ListActivity implements // regular folder content display if (mFolderName != null) { - mNavigationSpinner.setTitle(mFolderName+" ["+mUnreadMessageCount+"]"); + String folderNameProc = mFolderName; + + if (folderNameProc.length() > 15) { + folderNameProc = mFolderName.substring(0, 15) + "..."; + } + + mNavigationSpinner.setTitle(folderNameProc + " [" + mUnreadMessageCount + "]"); mNavigationSpinner.setSubTitle(mAccount.getEmail()); // query result display @@ -526,7 +532,6 @@ public class MessageList extends K9ListActivity implements setTitle(mTitle); } else { setTitle(getString(R.string.search_results)); - //setSubTitle(mQueryString); } } }