You are viewing a plain text version of this content. The canonical link for it is here.
Posted to server-dev@james.apache.org by do...@apache.org on 2013/09/12 05:54:11 UTC
svn commit: r1522269 - in
/james/hupa/trunk/client/src/main/java/org/apache/hupa/client:
activity/LoginActivity.java ui/HupaLayout.java ui/LoginView.java
ui/LoginView.ui.xml
Author: dongxu
Date: Thu Sep 12 03:54:11 2013
New Revision: 1522269
URL: http://svn.apache.org/r1522269
Log:
prepare for places and do something for loading related to issue #18
Modified:
james/hupa/trunk/client/src/main/java/org/apache/hupa/client/activity/LoginActivity.java
james/hupa/trunk/client/src/main/java/org/apache/hupa/client/ui/HupaLayout.java
james/hupa/trunk/client/src/main/java/org/apache/hupa/client/ui/LoginView.java
james/hupa/trunk/client/src/main/java/org/apache/hupa/client/ui/LoginView.ui.xml
Modified: james/hupa/trunk/client/src/main/java/org/apache/hupa/client/activity/LoginActivity.java
URL: http://svn.apache.org/viewvc/james/hupa/trunk/client/src/main/java/org/apache/hupa/client/activity/LoginActivity.java?rev=1522269&r1=1522268&r2=1522269&view=diff
==============================================================================
--- james/hupa/trunk/client/src/main/java/org/apache/hupa/client/activity/LoginActivity.java (original)
+++ james/hupa/trunk/client/src/main/java/org/apache/hupa/client/activity/LoginActivity.java Thu Sep 12 03:54:11 2013
@@ -494,6 +494,7 @@ public class LoginActivity extends Abstr
@Override
public void onFailure(ServerFailure error) {
Window.alert(error.getMessage());// TODO a more gentle way
+
display.setLoading(false);
doReset();
// placeController.goTo(new DefaultPlace());
Modified: james/hupa/trunk/client/src/main/java/org/apache/hupa/client/ui/HupaLayout.java
URL: http://svn.apache.org/viewvc/james/hupa/trunk/client/src/main/java/org/apache/hupa/client/ui/HupaLayout.java?rev=1522269&r1=1522268&r2=1522269&view=diff
==============================================================================
--- james/hupa/trunk/client/src/main/java/org/apache/hupa/client/ui/HupaLayout.java (original)
+++ james/hupa/trunk/client/src/main/java/org/apache/hupa/client/ui/HupaLayout.java Thu Sep 12 03:54:11 2013
@@ -277,7 +277,6 @@ public class HupaLayout implements HupaL
public HupaLayout() {
hupaMainPanel = binder.createAndBindUi(this);
messageSpace.setWidgetMinSize(folderArea, 144);
- messageArea.setWidgetMinSize(messageListBox, 72);
messageArea.setWidgetHidden(contactBox, true);
messageArea.setWidgetMinSize(messageListBox, 130);
}
@@ -348,13 +347,7 @@ public class HupaLayout implements HupaL
return new AcceptsOneWidget() {
@Override
public void setWidget(IsWidget w) {
-// Widget widget = Widget.asWidgetOrNull(w);
messageListContainer.setWidget(Widget.asWidgetOrNull(w));
-// messageListContainer.add(Widget.asWidgetOrNull(w));
-// if (messageListContainer.getWidgetCount() > 0)
-// messageListContainer.remove(0);
-// if (widget != null)
-// messageListContainer.add(widget);
}
};
}
Modified: james/hupa/trunk/client/src/main/java/org/apache/hupa/client/ui/LoginView.java
URL: http://svn.apache.org/viewvc/james/hupa/trunk/client/src/main/java/org/apache/hupa/client/ui/LoginView.java?rev=1522269&r1=1522268&r2=1522269&view=diff
==============================================================================
--- james/hupa/trunk/client/src/main/java/org/apache/hupa/client/ui/LoginView.java (original)
+++ james/hupa/trunk/client/src/main/java/org/apache/hupa/client/ui/LoginView.java Thu Sep 12 03:54:11 2013
@@ -75,9 +75,13 @@ import com.google.gwt.event.dom.client.K
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
+<<<<<<< HEAD
import com.google.gwt.resources.client.ClientBundle;
import com.google.gwt.resources.client.CssResource;
import com.google.gwt.resources.client.CssResource.NotStrict;
+=======
+import com.google.gwt.resources.client.CssResource;
+>>>>>>> prepare for places and do something for loading related to issue #18
import com.google.gwt.uibinder.client.UiBinder;
import com.google.gwt.uibinder.client.UiField;
=======
@@ -197,12 +201,16 @@ public class LoginView extends Composite
=======
=======
import com.google.gwt.user.client.ui.FormPanel.SubmitEvent;
+<<<<<<< HEAD
>>>>>>> Change to new mvp framework - first step
=======
>>>>>>> change the LOGIN progress using native MVP instead of gwt-presenter
=======
import com.google.gwt.user.client.ui.FormPanel.SubmitEvent;
>>>>>>> Change to new mvp framework - first step
+=======
+import com.google.gwt.user.client.ui.HTMLPanel;
+>>>>>>> prepare for places and do something for loading related to issue #18
import com.google.gwt.user.client.ui.HasValue;
import com.google.gwt.user.client.ui.Label;
import com.google.gwt.user.client.ui.PasswordTextBox;
@@ -257,6 +265,12 @@ public class LoginView extends Composite
LoginActivity.Displayable {
>>>>>>> refactoring theme 1 - login page
+ @UiField Style style;
+
+ interface Style extends CssResource {
+ String loading();
+ }
+
@Inject
public LoginView() {
initWidget(binder.createAndBindUi(this));
@@ -466,11 +480,19 @@ public class LoginView extends Composite
>>>>>>> change the LOGIN progress using native MVP instead of gwt-presenter
@Override
public void setLoading(boolean load) {
+<<<<<<< HEAD
<<<<<<< HEAD
>>>>>>> change the LOGIN progress using native MVP instead of gwt-presenter
=======
>>>>>>> change the LOGIN progress using native MVP instead of gwt-presenter
+=======
+ if (load) {
+ message.addStyleName(style.loading());
+ } else {
+ message.removeStyleName(style.loading());
+ }
+>>>>>>> prepare for places and do something for loading related to issue #18
}
@Override
@@ -521,6 +543,7 @@ public class LoginView extends Composite
.getElementById("password"));
// wrap the form after inputs so as they are in the dom when are wrapped
@UiField FormPanel formPanel;
+ @UiField HTMLPanel message;
>>>>>>> replace with uibinder
}
Modified: james/hupa/trunk/client/src/main/java/org/apache/hupa/client/ui/LoginView.ui.xml
URL: http://svn.apache.org/viewvc/james/hupa/trunk/client/src/main/java/org/apache/hupa/client/ui/LoginView.ui.xml?rev=1522269&r1=1522268&r2=1522269&view=diff
==============================================================================
--- james/hupa/trunk/client/src/main/java/org/apache/hupa/client/ui/LoginView.ui.xml (original)
+++ james/hupa/trunk/client/src/main/java/org/apache/hupa/client/ui/LoginView.ui.xml Thu Sep 12 03:54:11 2013
@@ -125,7 +125,8 @@
<ui:image field='logo' src='res/hupa-logo-64-transparent.png' />
<ui:image field="shadow" src="res/login_shadow.png" />
<ui:image field="messages" src="res/messages.png" />
- <ui:style>
+ <ui:image field="loading" src="res/ajaxloader.gif" />
+ <ui:style type="org.apache.hupa.client.ui.LoginView.Style">
@sprite .boxBottom {
gwt-image: 'shadow';
background-position: top center;
@@ -153,7 +154,12 @@
white-space: nowrap;
text-align: center;
cursor: default;
- display: none;
+ display: inline-block;
+ }
+
+ @sprite .loading {
+ gwt-image: 'loading';
+ background-position: 2px 6px;
}
</ui:style>
>>>>>>> make login page as one part of the overall layout & splite layout to little one
@@ -161,13 +167,13 @@
<g:FlowPanel ui:field="innerBox">
<g:Image resource='{logo}'></g:Image>
<g:FormPanel ui:field="formPanel">
- <g:FlexTable ui:field="flexTable"/>
+ <g:FlexTable ui:field="flexTable" />
</g:FormPanel>
<g:Button ui:field="loginButton"></g:Button>
</g:FlowPanel>
<g:FlowPanel ui:field="boxBottom" styleName="{style.boxBottom}">
<g:FlowPanel ui:field="messageBox" addStyleNames="{style.message}">
- <g:HTMLPanel addStyleNames="{style.notice}">You have successfully
+ <g:HTMLPanel ui:field="message" addStyleNames="{style.notice}">You have successfully
terminated the
session. Good bye!
</g:HTMLPanel>
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org