本文整理汇总了Java中com.smartgwt.client.widgets.form.fields.LinkItem类的典型用法代码示例。如果您正苦于以下问题:Java LinkItem类的具体用法?Java LinkItem怎么用?Java LinkItem使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
LinkItem类属于com.smartgwt.client.widgets.form.fields包,在下文中一共展示了LinkItem类的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: createAcceptTermsOfUse
import com.smartgwt.client.widgets.form.fields.LinkItem; //导入依赖的package包/类
void createAcceptTermsOfUse() {
// linkItem for terms of use
this.linkTerms = new LinkItem("termsOfUse");
this.linkTerms.setLinkTitle(i18n.termsOfUse());
this.linkTerms.setShouldSaveValue(false);
this.linkTerms.addClickHandler(new ClickHandler() {
public void onClick(ClickEvent event) {
EventBus.getMainEventBus().fireEvent(new GetTermsOfUseEvent(PropertiesManager.language));
}
});
this.acceptBox = new CheckboxItem();
this.acceptBox.setName("acceptTerms");
this.acceptBox.setTitle(i18n.acceptTermsOfUse());
this.acceptBox.setValue(false);
this.acceptBox.setRequired(true);
}
示例2: createMenuItem
import com.smartgwt.client.widgets.form.fields.LinkItem; //导入依赖的package包/类
private LinkItem createMenuItem(String title) {
LinkItem linkItem = new LinkItem(title.replace(" ", "_"));
linkItem.setCellStyle("htpMenu");
linkItem.setAlign(Alignment.LEFT);
linkItem.setShowTitle(false);
linkItem.setTitle(title.replace(" ", "_"));
linkItem.setLinkTitle(title);
return linkItem;
}
示例3: createMenuItem
import com.smartgwt.client.widgets.form.fields.LinkItem; //导入依赖的package包/类
private LinkItem createMenuItem(String title) {
LinkItem linkItem = new LinkItem(title.replace(" ", "_"));
linkItem.setCellStyle("htpLinks");
linkItem.setTextBoxStyle("htpLinks");
linkItem.setShowTitle(false);
linkItem.setTitle(title.replace(" ", "_"));
linkItem.setLinkTitle(title);
return linkItem;
}
示例4: initUserLogin
import com.smartgwt.client.widgets.form.fields.LinkItem; //导入依赖的package包/类
private void initUserLogin() {
new LoginLayoutEventBroker(this);
TextItem userNameItem = createUserNameItem();
PasswordItem passwordItem = createPasswordItem();
ButtonItem loginButton = createLoginButton();
LinkItem registerLink = createRegisterLink();
LinkItem forgotPasswordLink = createForgotPasswordLink();
form.setFields(headerItem, userNameItem, passwordItem, loginButton, registerLink, forgotPasswordLink);
addMember(form);
}
示例5: createRegisterLink
import com.smartgwt.client.widgets.form.fields.LinkItem; //导入依赖的package包/类
private LinkItem createRegisterLink() {
LinkItem registerLink = new LinkItem();
registerLink.setShowTitle(false); // only link
registerLink.setDefaultValue(i18n.register());
registerLink.addClickHandler(new ClickHandler() {
@Override
public void onClick(ClickEvent event) {
getMainEventBus().fireEvent(new ChangeLayoutEvent(REGISTER));
}
});
return registerLink;
}
示例6: createForgotPasswordLink
import com.smartgwt.client.widgets.form.fields.LinkItem; //导入依赖的package包/类
private LinkItem createForgotPasswordLink() {
LinkItem forgotPasswordLink = new LinkItem();
forgotPasswordLink.setShowTitle(false); // only link
forgotPasswordLink.setDefaultValue(i18n.forgotPassword());
forgotPasswordLink.addClickHandler(new ClickHandler() {
public void onClick(ClickEvent event) {
getMainEventBus().fireEvent(new ChangeLayoutEvent(PASSWORD));
}
});
return forgotPasswordLink;
}
示例7: RegisterLayout
import com.smartgwt.client.widgets.form.fields.LinkItem; //导入依赖的package包/类
public RegisterLayout() {
super(i18n.registration());
setStyleName("n52_sensorweb_client_form_content");
DataSourceTextField userNameField = new DataSourceTextField("userName", i18n.userName(), 50, true);
DataSourceTextField nameField = new DataSourceTextField("name", i18n.name(), 50, false);
DataSourcePasswordField passwordField = new DataSourcePasswordField("password", i18n.password(), 20, true);
DataSourceTextField emailField = new DataSourceTextField("email", i18n.email(), 100, true);
RegExpValidator emailValidator = new RegExpValidator();
emailValidator.setErrorMessage(i18n.invalidEmail());
emailValidator.setExpression("^([a-zA-Z0-9_.\\-+])[email protected](([a-zA-Z0-9\\-])+\\.)+[a-zA-Z0-9]{2,4}$");
emailField.setValidators(emailValidator);
DataSource dataSource = new DataSource();
dataSource.setFields(userNameField, nameField, passwordField, emailField);
this.form.setDataSource(dataSource);
createNameTextInputs();
createPasswordTextInputs();
createEmailTextInputs();
createAcceptTermsOfUse();
ButtonItem registerButton = createRegisterButton();
LinkItem backToLoginLink = createBackToLoginLink();
this.form.setFields(this.headerItem, this.userNameItem, this.nameItem, this.passwordItem, this.verifyPasswordItem,
this.emailItem, this.verifyEmailItem, this.linkTerms, this.acceptBox, registerButton, backToLoginLink);
addMember(this.form);
setAutoWidth();
}
示例8: createBackToLoginLink
import com.smartgwt.client.widgets.form.fields.LinkItem; //导入依赖的package包/类
private LinkItem createBackToLoginLink() {
LinkItem backToLoginLink = new LinkItem();
backToLoginLink.setShowTitle(false); // only link
backToLoginLink.setDefaultValue(i18n.userLogin());
backToLoginLink.addClickHandler(new ClickHandler() {
@Override
public void onClick(ClickEvent event) {
getMainEventBus().fireEvent(new ChangeLayoutEvent(LOGIN));
}
});
return backToLoginLink;
}
示例9: create
import com.smartgwt.client.widgets.form.fields.LinkItem; //导入依赖的package包/类
public FormItem create() {
return new EnableToggleFormItem(new TextItem(), new LinkItem());
}