本文整理了Java中com.google.gwt.user.client.Window.alert()
方法的一些代码示例,展示了Window.alert()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Window.alert()
方法的具体详情如下:
包路径:com.google.gwt.user.client.Window
类名称:Window
方法名:alert
[英]Displays a message in a modal dialog box.
[中]在模式对话框中显示消息。
代码示例来源:origin: errai/errai
@Override
public void onFailure() {
//TODO really handle failure like this?
Window.alert("Accelerometer not supported");
}
});
代码示例来源:origin: org.eagle-i/eagle-i-datatools-sweet-gwt
@Override
public void needsRefresh(final String message) {
Window.alert( UIMessages.REFRESH_SINGLE_MESSAGE );
}
};
代码示例来源:origin: org.geomajas.plugin/geomajas-client-gwt2-plugin-tms-example-jar
@Override
public void onFailure(String reason) {
Window.alert("We're very sorry, but something went wrong: " + reason);
}
});
代码示例来源:origin: org.eagle-i/eagle-i-search-gwt
@Override
public void onFailure(final Throwable caught) {
if ( caught instanceof ExternalServiceException ) {
Window.alert( "Error sending message: " + caught.getMessage() );
} else if ( caught instanceof StatusCodeException ) {
Window.alert( ExternalServiceException.getFriendlyStatusUnknownMessage( ) );
} else {
Window.alert( caught.getMessage() );
}
}
});
代码示例来源:origin: com.smartgwt/smartgwt
protected void error(String message) throws IllegalStateException {
if (!GWT.isScript()) {
Window.alert("Error :" + message);
throw new IllegalStateException(message);
}
}
代码示例来源:origin: org.uberfire/uberfire-runtime-plugins-client
@Override
public void onSubmitComplete(final AbstractForm.SubmitCompleteEvent event) {
if ("OK".equalsIgnoreCase(event.getResults())) {
Window.alert("Upload Success");
} else if ("FAIL".equalsIgnoreCase(event.getResults())) {
Window.alert("Upload Failed");
} else if ("FAIL - ALREADY EXISTS".equalsIgnoreCase(event.getResults())) {
Window.alert("File already exists");
}
}
});
代码示例来源:origin: org.kuali.student.lum/ks-lum-ui-common
@Override
public void handleFailure(Throwable caught) {
GWT.log("get displayOnlyActiveLoCategories failed", caught);
Window.alert("Failed to get displayOnlyActiveLoCategories setting");
}
代码示例来源:origin: org.kuali.student.lum/ks-lum-ui-common
@Override
public void onFailure(Throwable caught) {
Window.alert("Failed to retreive data for clu Set with id " + cluSetId);
callback.exec(null);
}
@Override
代码示例来源:origin: org.kie.guvnor/guvnor-m2repo-editor-client
@Override
public void callback(Void v) {
Window.alert("Deleted successfully");
pagedJarTable.refresh();
}
}).deleteJar(getSelectedJars());
代码示例来源:origin: fr.lteconsulting/hexa.core
public boolean mayStop()
{
if( currentActivity == null )
return true;
String res = currentActivity.mayStop();
if( res != null )
{
Window.alert( res );
return false;
}
return true;
}
代码示例来源:origin: com.smartgwt/smartgwt
public void onUncaughtException(Throwable e) {
if (!GWT.isScript()) {
Window.alert("Uncaught exception escaped : " + e.getClass().getName() + "\n" + e.getMessage() +
"\nSee the Development console log for details." +
"\nRegister a GWT.setUncaughtExceptionHandler(..) for custom uncaught exception handling."
);
}
GWT.log("Uncaught exception escaped", e);
}
});
代码示例来源:origin: org.kie.guvnor/guvnor-commons-ui
@Override
public void onSubmitComplete( final FormPanel.SubmitCompleteEvent event ) {
if ( "OK".equalsIgnoreCase( event.getResults() ) ) {
executeCallback( successCallback );
Window.alert( CommonConstants.INSTANCE.UploadSuccess() );
} else {
executeCallback( errorCallback );
Window.alert( CommonConstants.INSTANCE.UploadFailure0( event.getResults() ) );
}
}
代码示例来源:origin: org.kie.uberfire/kie-uberfire-widgets-core-client
public void onSubmitComplete(final FormPanel.SubmitCompleteEvent event) {
if ("OK".equalsIgnoreCase(event.getResults())) {
Window.alert(CoreConstants.INSTANCE.UploadSuccess());
} else if ("FAIL".equalsIgnoreCase(event.getResults())) {
Window.alert(CoreConstants.INSTANCE.UploadFail());
}
BusyPopup.close();
}
});
代码示例来源:origin: org.kuali.student.core/ks-common-ui
@Override
public void handleFailure(Throwable cause) {
GWT.log("Failed to perform search", cause); //FIXME more detail info here
Window.alert("Failed to perform search");
table.displayLoading(false);
}
代码示例来源:origin: org.kuali.student.lum/ks-lum-program
public void onSuccess(final List<ReqComponentTypeInfo> reqComponentTypeInfoList) {
if (reqComponentTypeInfoList == null || reqComponentTypeInfoList.size() == 0) {
GWT.log("Missing Requirement Component Types", null);
Window.alert("Missing Requirement Component Types");
return;
}
editReqCompWidget.setReqCompList(reqComponentTypeInfoList);
editReqCompWidget.setCustomWidgets(getCustomWidgets(reqComponentTypeInfoList));
}
});
代码示例来源:origin: com.allen-sauer.gwt.log/gwt-log
private int setCurrentLogLevelLoggers(int level) {
if (level < getLowestLogLevel()) {
Window.alert("Unable to lower runtime log level to " + level
+ " due to compile time minimum of " + getLowestLogLevel());
level = getLowestLogLevel();
}
remoteLogger.loggersSetCurrentLogLevel(level);
return level;
}
代码示例来源:origin: org.geomajas/geomajas-project-deskmanager-gwt
private void onSetDefaultGeometry() {
if (!getGeometryStatus().equals(GeometryStatus.EDITING)) {
setGeometryOfCurrentGroup(getMaxBoundsAsGeometry());
} else {
Window.alert(MESSAGES.securityGroupWarningStopEditingFirst());
}
}
代码示例来源:origin: org.kie.guvnor/guvnor-commons-ui
public void onClick( ClickEvent arg0 ) {
if ( nameTextBox.getText() == null || "".equals( nameTextBox.getText() ) ) {
Window.alert( CommonConstants.INSTANCE.RenamePopupRenameNamePrompt() );
return;
}
hide();
command.execute( new FileNameAndCommitMessage( nameTextBox.getText(),
checkInCommentTextBox.getText() ) );
}
} );
代码示例来源:origin: org.kie.guvnor/guvnor-guided-rule-editor-client
public void onClick( ClickEvent event ) {
String var = varName.getText();
if ( modeller.isVariableNameUsed( var ) ) {
Window.alert( Constants.INSTANCE.TheVariableName0IsAlreadyTaken( var ) );
return;
}
con.setFieldBinding( var );
modeller.refreshWidget();
popup.hide();
}
} );
代码示例来源:origin: org.kie.guvnor/guvnor-guided-dtable-editor-client
public void onClick( ClickEvent w ) {
if ( !canConditionBeDeleted( (LimitedEntryBRLConditionColumn) c ) ) {
Window.alert( Constants.INSTANCE.UnableToDeleteConditionColumn( c.getHeader() ) );
return;
}
String cm = Constants.INSTANCE.DeleteConditionColumnWarning( c.getHeader() );
if ( Window.confirm( cm ) ) {
dtable.deleteColumn( (LimitedEntryBRLConditionColumn) c );
refreshConditionsWidget();
}
}
} );
内容来源于网络,如有侵权,请联系作者删除!