List of usage examples for com.google.gwt.user.client Window setStatus
public static void setStatus(String status)
From source file:org.drools.guvnor.client.GuvnorSOAEntryPoint.java
License:Apache License
private void showMain(final String userName) { Window.setStatus(constants.LoadingUserPermissions()); loadConfigurations(userName); }
From source file:org.drools.guvnor.client.JBRMSEntryPoint.java
License:Apache License
private void showMain() { Window.setStatus("Loading user permissions..."); RepositoryServiceFactory.getSecurityService().getUserCapabilities(new GenericCallback<Capabilities>() { public void onSuccess(Capabilities cp) { Window.setStatus(" "); new Viewport(createMain(cp)); }//w ww . ja v a 2s. co m }); }
From source file:org.openremote.modeler.client.presenter.UIDesignerPresenter.java
License:Open Source License
/** * Auto save ui designer layout json.//www.j ava2 s . co m */ public void autoSaveUiDesignerLayout() { if (view.getProfilePanel().isInitialized()) { UtilsProxy.autoSaveUiDesignerLayout(getAllPanels(), IDUtil.currentID(), new AsyncSuccessCallback<AutoSaveResponse>() { @Override public void onSuccess(AutoSaveResponse result) { if (result != null && result.isUpdated()) { Info.display("Info", "UI designer layout saved at " + DateTimeFormat.getFormat("HH:mm:ss").format(new Date())); } Window.setStatus("Auto-Saving: UI designer layout saved at: " + DateTimeFormat.getFormat("HH:mm:ss").format(new Date())); } @Override public void onFailure(Throwable caught) { timer.cancel(); boolean timeout = super.checkTimeout(caught); if (!timeout) { Info.display(new InfoConfig("Error", caught.getMessage() + " " + DateTimeFormat.getFormat("HH:mm:ss").format(new Date()))); } Window.setStatus("Failed to save UI designer layout at: " + DateTimeFormat.getFormat("HH:mm:ss").format(new Date())); } }); Window.setStatus("Saving ...."); } else { Window.setStatus( "Auto-Saving: Unable to save UI designer because panel list has not been initialized. "); } }
From source file:org.openremote.modeler.client.presenter.UIDesignerPresenter.java
License:Open Source License
/** * Save ui designer layout, if the template panel is expanded, save its data, else save the profile panel's data. *///w w w. j a v a 2s . co m public void saveUiDesignerLayout() { if (view.getTemplatePanel() != null && view.getTemplatePanel().isExpanded()) { view.getTemplatePanel().saveTemplateUpdates(); } else { if (view.getProfilePanel().isInitialized()) { UtilsProxy.saveUiDesignerLayout(getAllPanels(), IDUtil.currentID(), new AsyncSuccessCallback<AutoSaveResponse>() { @Override public void onSuccess(AutoSaveResponse result) { if (result != null && result.isUpdated()) { Info.display("Info", "UI designer layout saved at " + DateTimeFormat.getFormat("HH:mm:ss").format(new Date())); } Window.setStatus("UI designer layout saved at: " + DateTimeFormat.getFormat("HH:mm:ss").format(new Date())); } @Override public void onFailure(Throwable caught) { timer.cancel(); boolean timeout = super.checkTimeout(caught); if (!timeout) { if (caught instanceof UIRestoreException) { MessageBox.alert("Error", caught.getMessage(), null); } else { Info.display(new InfoConfig("Error", caught.getMessage() + " " + DateTimeFormat.getFormat("HH:mm:ss").format(new Date()))); } } Window.setStatus("Failed to save UI designer layout at: " + DateTimeFormat.getFormat("HH:mm:ss").format(new Date())); } }); Window.setStatus("Saving ...."); } else { Window.setStatus("Unable to save UI designer because panel list has not been initialized. "); } } }
From source file:org.openremote.modeler.client.view.UIDesignerView.java
License:Open Source License
/** * Auto save ui designer layout json.//from w w w. j a v a 2 s .com */ public void autoSaveUiDesignerLayout() { if (profilePanel.isInitialized()) { UtilsProxy.autoSaveUiDesignerLayout(getAllPanels(), IDUtil.currentID(), new AsyncSuccessCallback<AutoSaveResponse>() { @Override public void onSuccess(AutoSaveResponse result) { if (result != null && result.isUpdated()) { Info.display("Info", "UI designer layout saved at " + DateTimeFormat.getFormat("HH:mm:ss").format(new Date())); } Window.setStatus("Auto-Saving: UI designer layout saved at: " + DateTimeFormat.getFormat("HH:mm:ss").format(new Date())); } @Override public void onFailure(Throwable caught) { timer.cancel(); boolean timeout = super.checkTimeout(caught); if (!timeout) { Info.display(new InfoConfig("Error", caught.getMessage() + " " + DateTimeFormat.getFormat("HH:mm:ss").format(new Date()))); } Window.setStatus("Failed to save UI designer layout at: " + DateTimeFormat.getFormat("HH:mm:ss").format(new Date())); } }); Window.setStatus("Saving ...."); } else { Window.setStatus( "Auto-Saving: Unable to save UI designer because panel list has not been initialized. "); } }
From source file:org.openremote.modeler.client.view.UIDesignerView.java
License:Open Source License
public void saveUiDesignerLayout() { if (templatePanel != null && templatePanel.isExpanded()) { templatePanel.saveTemplateUpdates(); } else {/* w w w .j av a 2 s. co m*/ if (profilePanel.isInitialized()) { UtilsProxy.saveUiDesignerLayout(getAllPanels(), IDUtil.currentID(), new AsyncSuccessCallback<AutoSaveResponse>() { @Override public void onSuccess(AutoSaveResponse result) { if (result != null && result.isUpdated()) { Info.display("Info", "UI designer layout saved at " + DateTimeFormat.getFormat("HH:mm:ss").format(new Date())); } Window.setStatus("UI designer layout saved at: " + DateTimeFormat.getFormat("HH:mm:ss").format(new Date())); } @Override public void onFailure(Throwable caught) { timer.cancel(); boolean timeout = super.checkTimeout(caught); if (!timeout) { Info.display(new InfoConfig("Error", caught.getMessage() + " " + DateTimeFormat.getFormat("HH:mm:ss").format(new Date()))); } Window.setStatus("Failed to save UI designer layout at: " + DateTimeFormat.getFormat("HH:mm:ss").format(new Date())); System.out.println(caught.toString()); } }); Window.setStatus("Saving ...."); } else { Window.setStatus("Unable to save UI designer because panel list has not been initialized. "); } } }