james-server-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From don...@apache.org
Subject svn commit: r1522406 - in /james/hupa/trunk/client/src/main/java/org/apache/hupa/client/ui: FolderListView.java TopBarView.java
Date Thu, 12 Sep 2013 04:51:57 GMT
Author: dongxu
Date: Thu Sep 12 04:51:57 2013
New Revision: 1522406

URL: http://svn.apache.org/r1522406
Log:
fixed issue#78, cause not be using the HtmlConstant and nameForDisplay which with intents

Modified:
    james/hupa/trunk/client/src/main/java/org/apache/hupa/client/ui/FolderListView.java
    james/hupa/trunk/client/src/main/java/org/apache/hupa/client/ui/TopBarView.java

Modified: james/hupa/trunk/client/src/main/java/org/apache/hupa/client/ui/FolderListView.java
URL: http://svn.apache.org/viewvc/james/hupa/trunk/client/src/main/java/org/apache/hupa/client/ui/FolderListView.java?rev=1522406&r1=1522405&r2=1522406&view=diff
==============================================================================
--- james/hupa/trunk/client/src/main/java/org/apache/hupa/client/ui/FolderListView.java (original)
+++ james/hupa/trunk/client/src/main/java/org/apache/hupa/client/ui/FolderListView.java Thu
Sep 12 04:51:57 2013
@@ -358,12 +358,14 @@ public class FolderListView extends Comp
 		@Override
 		public void render(Context context, LabelNode value, SafeHtmlBuilder sb) {
 			if (value != null) {
-				sb.appendEscaped(value.getName());
-			}
-			if (value.getFolder().getUnseenMessageCount() > 0) {
-				sb.appendHtmlConstant("<span style='position:absolute;right:6px;top:3px;font-weight:bold;'>(");
-				sb.appendHtmlConstant("" + value.getFolder().getUnseenMessageCount());
-				sb.appendHtmlConstant(")</span>");
+				if (value.getFolder().getUnseenMessageCount() > 0) {
+					sb.appendHtmlConstant("<span style='right:6px;top:3px;font-weight:bold;'>");
+					sb.appendHtmlConstant(value.getNameForDisplay());
+					sb.appendHtmlConstant(" (" + value.getFolder().getUnseenMessageCount());
+					sb.appendHtmlConstant(")</span>");
+				} else {
+					sb.appendHtmlConstant(value.getNameForDisplay());
+				}
 			}
 		}
 	}

Modified: james/hupa/trunk/client/src/main/java/org/apache/hupa/client/ui/TopBarView.java
URL: http://svn.apache.org/viewvc/james/hupa/trunk/client/src/main/java/org/apache/hupa/client/ui/TopBarView.java?rev=1522406&r1=1522405&r2=1522406&view=diff
==============================================================================
--- james/hupa/trunk/client/src/main/java/org/apache/hupa/client/ui/TopBarView.java (original)
+++ james/hupa/trunk/client/src/main/java/org/apache/hupa/client/ui/TopBarView.java Thu Sep
12 04:51:57 2013
@@ -166,6 +166,7 @@ public class TopBarView extends Composit
 	
 	@Override
 	public void showUserName(String userName){
+		userLabel.clear();
 		userLabel.add(new HTML(userName));
 	}
 



---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org


Mime
View raw message