[kune-commits] r1809 - in trunk/src/main/java/cc/kune: core/client/groups/newgroup core/client/ui core/server/manager/impl core/shared/domain gspace/client/options/general
Vicente J. Ruiz Jurado
vjrj_ at ourproject.org
Fri Mar 30 18:38:52 CEST 2012
Author: vjrj_
Date: 2012-03-30 18:38:51 +0200 (Fri, 30 Mar 2012)
New Revision: 1809
Modified:
trunk/src/main/java/cc/kune/core/client/groups/newgroup/GroupFieldFactory.java
trunk/src/main/java/cc/kune/core/client/groups/newgroup/NewGroupPanel.java
trunk/src/main/java/cc/kune/core/client/groups/newgroup/NewGroupPresenter.java
trunk/src/main/java/cc/kune/core/client/ui/DefaultFormUtils.java
trunk/src/main/java/cc/kune/core/server/manager/impl/GroupManagerDefault.java
trunk/src/main/java/cc/kune/core/shared/domain/GroupListMode.java
trunk/src/main/java/cc/kune/gspace/client/options/general/GroupOptGeneralPanel.java
trunk/src/main/java/cc/kune/gspace/client/options/general/GroupOptGeneralPresenter.java
trunk/src/main/java/cc/kune/gspace/client/options/general/GroupOptGeneralView.java
trunk/src/main/java/cc/kune/gspace/client/options/general/UserOptGeneralPanel.java
Log:
CLOSED - # 229: Change between group types (open->closed, mainly)
http://kune.ourproject.org/issues/ticket/229
Modified: trunk/src/main/java/cc/kune/core/client/groups/newgroup/GroupFieldFactory.java
===================================================================
--- trunk/src/main/java/cc/kune/core/client/groups/newgroup/GroupFieldFactory.java 2012-03-30 13:12:37 UTC (rev 1808)
+++ trunk/src/main/java/cc/kune/core/client/groups/newgroup/GroupFieldFactory.java 2012-03-30 16:38:51 UTC (rev 1809)
@@ -22,7 +22,10 @@
import cc.kune.common.shared.i18n.I18nTranslationService;
import cc.kune.core.client.resources.CoreMessages;
import cc.kune.core.client.ui.DefaultForm;
+import cc.kune.core.client.ui.DefaultFormUtils;
+import com.extjs.gxt.ui.client.widget.form.FieldSet;
+import com.extjs.gxt.ui.client.widget.form.Radio;
import com.extjs.gxt.ui.client.widget.form.TextField;
import com.google.inject.Inject;
import com.google.inject.Singleton;
@@ -37,7 +40,28 @@
this.i18n = i18n;
}
- public TextField<String> createUserLongName(final String fieldId) {
+ public Radio createClosedRadio(final FieldSet fieldSet, final String fieldSetId, final String radioId) {
+ final Radio radio = DefaultFormUtils.createRadio(
+ fieldSet,
+ i18n.t("Closed"),
+ fieldSetId,
+ i18n.t("A Closed group is a private project, which contents are only accessible to its members (by default)."),
+ radioId);
+ return radio;
+ }
+
+ public Radio createCommunityRadio(final FieldSet fieldSet, final String fieldSetId,
+ final String radioId) {
+ final Radio radio = DefaultFormUtils.createRadio(
+ fieldSet,
+ i18n.t("Community"),
+ fieldSetId,
+ i18n.t("A community is a group of users with shared interests (for instance the environmental community or the LGBT community). It is open to any new member to join freely without the moderation of the administrators."),
+ radioId);
+ return radio;
+ }
+
+ public TextField<String> createLongName(final String fieldId) {
final TextField<String> field = new TextField<String>();
field.setFieldLabel(i18n.t("Long name"));
field.setName(fieldId);
@@ -50,6 +74,23 @@
return field;
}
+ public Radio createOrgRadio(final FieldSet fieldSet, final String fieldSetId, final String radioId) {
+ final Radio radio = DefaultFormUtils.createRadio(fieldSet, i18n.t("Organization"), fieldSetId,
+ i18n.t("An organization works the same way as a project, "
+ + "except that it must be a legal entity."), radioId);
+ return radio;
+ }
+
+ public Radio createProjectRadio(final FieldSet fieldSet, final String fieldSetId, final String radioId) {
+ final Radio radio = DefaultFormUtils.createRadio(
+ fieldSet,
+ i18n.t("Project"),
+ fieldSetId,
+ i18n.t("A project is a kind of group in which the joining of new members is moderated by the project administrators."),
+ radioId);
+ return radio;
+ }
+
public TextField<String> createUserShortName(final String fieldId) {
final String minMaxText = i18n.t(CoreMessages.FIELD_MUST_BE_BETWEEN_3_AND_15);
final TextField<String> field = new TextField<String>();
@@ -67,4 +108,5 @@
field.setValidationDelay(1000);
return field;
}
+
}
Modified: trunk/src/main/java/cc/kune/core/client/groups/newgroup/NewGroupPanel.java
===================================================================
--- trunk/src/main/java/cc/kune/core/client/groups/newgroup/NewGroupPanel.java 2012-03-30 13:12:37 UTC (rev 1808)
+++ trunk/src/main/java/cc/kune/core/client/groups/newgroup/NewGroupPanel.java 2012-03-30 16:38:51 UTC (rev 1809)
@@ -132,7 +132,7 @@
shortNameField.setTabIndex(1);
form.add(shortNameField);
- longNameField = groupFieldFactory.createUserLongName(LONGNAME_FIELD);
+ longNameField = groupFieldFactory.createLongName(LONGNAME_FIELD);
longNameField.setTabIndex(2);
form.add(longNameField);
@@ -153,42 +153,23 @@
// form.add(createTagField(tag2));
// form.add(createTagField(tag3));
- final FieldSet groupTypeFieldSet = new FieldSet();
- groupTypeFieldSet.setHeading(i18n.t("Group type"));
- groupTypeFieldSet.addStyleName("k-form-fieldset");
- groupTypeFieldSet.setCollapsible(true);
+ final FieldSet groupTypeFieldSet = DefaultFormUtils.createFieldSet(i18n.t("Group type"), "210px");
groupTypeFieldSet.setWidth("210px");
- groupTypeFieldSet.setAutoHeight(true);
-
form.add(groupTypeFieldSet);
- projectRadio = DefaultFormUtils.createRadio(
- groupTypeFieldSet,
- i18n.t("Project"),
- TYPEOFGROUP_FIELD,
- i18n.t("A project is a kind of group in which the joining of new members is moderated by the project administrators."),
+ projectRadio = groupFieldFactory.createProjectRadio(groupTypeFieldSet, TYPEOFGROUP_FIELD,
PROJ_GROUP_TYPE_ID);
projectRadio.setTabIndex(6);
projectRadio.setValue(true);
- orgRadio = DefaultFormUtils.createRadio(groupTypeFieldSet, i18n.t("Organization"),
- TYPEOFGROUP_FIELD, i18n.t("An organization works the same way as a project, "
- + "except that it must be a legal entity."), ORG_GROUP_TYPE_ID);
+ orgRadio = groupFieldFactory.createOrgRadio(groupTypeFieldSet, TYPEOFGROUP_FIELD, ORG_GROUP_TYPE_ID);
orgRadio.setTabIndex(7);
- closedRadio = DefaultFormUtils.createRadio(
- groupTypeFieldSet,
- i18n.t("Closed"),
- TYPEOFGROUP_FIELD,
- i18n.t("A Closed group is a private project, which contents are only accessible to its members (by default)."),
+ closedRadio = groupFieldFactory.createClosedRadio(groupTypeFieldSet, TYPEOFGROUP_FIELD,
CLOSED_GROUP_TYPE_ID);
closedRadio.setTabIndex(8);
- communityRadio = DefaultFormUtils.createRadio(
- groupTypeFieldSet,
- i18n.t("Community"),
- TYPEOFGROUP_FIELD,
- i18n.t("A community is a group of users with shared interests (for instance the environmental community or the LGBT community). It is open to any new member to join freely without the moderation of the administrators."),
+ communityRadio = groupFieldFactory.createCommunityRadio(groupTypeFieldSet, TYPEOFGROUP_FIELD,
COMM_GROUP_TYPE_ID);
communityRadio.setTabIndex(9);
Modified: trunk/src/main/java/cc/kune/core/client/groups/newgroup/NewGroupPresenter.java
===================================================================
--- trunk/src/main/java/cc/kune/core/client/groups/newgroup/NewGroupPresenter.java 2012-03-30 13:12:37 UTC (rev 1808)
+++ trunk/src/main/java/cc/kune/core/client/groups/newgroup/NewGroupPresenter.java 2012-03-30 16:38:51 UTC (rev 1809)
@@ -110,6 +110,7 @@
}
private GroupType getTypeOfGroup() {
+ // Duplicate in GroupOptGeneralPanel
if (getView().isProject()) {
return GroupType.PROJECT;
} else if (getView().isOrganization()) {
Modified: trunk/src/main/java/cc/kune/core/client/ui/DefaultFormUtils.java
===================================================================
--- trunk/src/main/java/cc/kune/core/client/ui/DefaultFormUtils.java 2012-03-30 13:12:37 UTC (rev 1808)
+++ trunk/src/main/java/cc/kune/core/client/ui/DefaultFormUtils.java 2012-03-30 16:38:51 UTC (rev 1809)
@@ -28,6 +28,23 @@
import com.extjs.gxt.ui.client.widget.form.Radio;
public class DefaultFormUtils {
+
+ public static final String BIG_FIELD_SIZE = "310px";
+
+ public static FieldSet createFieldSet(final String heading) {
+ return createFieldSet(heading, BIG_FIELD_SIZE);
+ }
+
+ public static FieldSet createFieldSet(final String heading, final String width) {
+ final FieldSet fieldSet = new FieldSet();
+ fieldSet.setHeading(heading);
+ fieldSet.addStyleName("k-form-fieldset");
+ fieldSet.setCollapsible(false);
+ fieldSet.setWidth(width);
+ fieldSet.setAutoHeight(true);
+ return fieldSet;
+ }
+
public static Radio createRadio(final FieldSet fieldSet, final String radioLabel,
final String radioFieldName, final String radioTip, final String id) {
final Radio radio = new Radio();
Modified: trunk/src/main/java/cc/kune/core/server/manager/impl/GroupManagerDefault.java
===================================================================
--- trunk/src/main/java/cc/kune/core/server/manager/impl/GroupManagerDefault.java 2012-03-30 13:12:37 UTC (rev 1808)
+++ trunk/src/main/java/cc/kune/core/server/manager/impl/GroupManagerDefault.java 2012-03-30 16:38:51 UTC (rev 1809)
@@ -82,6 +82,7 @@
private final LicenseManager licenseManager;
private final KuneBasicProperties properties;
private final ServerToolRegistry serverToolRegistry;
+ private final SocialNetworkCache snCache;
private final Provider<TrashServerTool> trashTool;
private final UserFinder userFinder;
@@ -91,7 +92,7 @@
final KuneBasicProperties properties, final LicenseManager licenseManager,
final LicenseFinder licenseFinder, final FileManager fileManager,
final ServerToolRegistry serverToolRegistry, final Provider<TrashServerTool> trashTool,
- final I18nTranslationService i18n) {
+ final I18nTranslationService i18n, final SocialNetworkCache snCache) {
super(provider, Group.class);
this.finder = finder;
this.userFinder = userFinder;
@@ -103,6 +104,7 @@
this.serverToolRegistry = serverToolRegistry;
this.trashTool = trashTool;
this.i18n = i18n;
+ this.snCache = snCache;
}
@Override
@@ -157,26 +159,14 @@
checkIfLongNameAreInUse(group.getLongName());
final String defaultSiteWorkspaceTheme = kuneProperties.get(KuneProperties.WS_THEMES_DEF);
if (User.isKnownUser(user)) {
- GroupListMode publicVisibility = GroupListMode.EVERYONE;
- SocialNetworkVisibility snVisibility = SocialNetworkVisibility.anyone;
- if (group.getGroupType().equals(GroupType.COMMUNITY)) {
- group.setAdmissionType(AdmissionType.Open);
- } else if (group.getGroupType().equals(GroupType.CLOSED)) {
- group.setAdmissionType(AdmissionType.Closed);
- publicVisibility = GroupListMode.NORMAL;
- snVisibility = SocialNetworkVisibility.onlymembers;
- } else if (group.getGroupType().equals(GroupType.ORGANIZATION)) {
- group.setAdmissionType(AdmissionType.Moderated);
- } else if (group.getGroupType().equals(GroupType.PROJECT)) {
- group.setAdmissionType(AdmissionType.Moderated);
- } else if (group.getGroupType().equals(GroupType.ORPHANED_PROJECT)) {
- group.setAdmissionType(AdmissionType.Open);
- }
+ setAdmissionType(group);
final String licName = group.getDefaultLicense().getShortName();
final License license = licenseFinder.findByShortName(licName);
group.setDefaultLicense(license);
group.setWorkspaceTheme(defaultSiteWorkspaceTheme);
- initSocialNetwork(group, user.getUserGroup(), publicVisibility, snVisibility);
+ final boolean isClosed = group.getGroupType().equals(GroupType.CLOSED);
+ initSocialNetwork(group, user.getUserGroup(), getDefGroupMode(isClosed),
+ getDefSNVisibility(isClosed));
final String title = i18n.t("About [%s]", group.getLongName());
initGroup(user, group, serverToolRegistry.getToolsRegisEnabledForGroups(), title, publicDescrip);
return group;
@@ -249,6 +239,14 @@
return finder.findEnabledTools(id);
}
+ private GroupListMode getDefGroupMode(final boolean isClosed) {
+ return isClosed ? GroupListMode.NORMAL : GroupListMode.EVERYONE;
+ }
+
+ private SocialNetworkVisibility getDefSNVisibility(final boolean isClosed) {
+ return isClosed ? SocialNetworkVisibility.onlymembers : SocialNetworkVisibility.anyone;
+ }
+
@Override
public Group getGroupOfUserWithId(final Long userId) {
return userId != null ? find(User.class, userId).getUserGroup() : null;
@@ -283,14 +281,10 @@
private void initSocialNetwork(final Group group, final Group userGroup,
final GroupListMode publicVisibility, final SocialNetworkVisibility snVisibility) {
- final SocialNetwork network = group.getSocialNetwork();
- final AccessLists lists = network.getAccessLists();
- lists.getEditors().setMode(GroupListMode.NOBODY);
- lists.getViewers().setMode(publicVisibility);
+ final SocialNetwork network = setSocialNetwork(group, publicVisibility, snVisibility);
if (!group.getGroupType().equals(GroupType.ORPHANED_PROJECT)) {
network.addAdmin(userGroup);
}
- network.setVisibility(snVisibility);
}
@Override
@@ -317,6 +311,23 @@
return super.search(query, firstResult, maxResults);
}
+ private void setAdmissionType(final Group group) {
+ final GroupType groupType = group.getGroupType();
+ if (groupType.equals(GroupType.COMMUNITY)) {
+ group.setAdmissionType(AdmissionType.Open);
+ } else {
+ if (groupType.equals(GroupType.CLOSED)) {
+ group.setAdmissionType(AdmissionType.Closed);
+ } else if (groupType.equals(GroupType.ORGANIZATION)) {
+ group.setAdmissionType(AdmissionType.Moderated);
+ } else if (groupType.equals(GroupType.PROJECT)) {
+ group.setAdmissionType(AdmissionType.Moderated);
+ } else if (groupType.equals(GroupType.ORPHANED_PROJECT)) {
+ group.setAdmissionType(AdmissionType.Open);
+ }
+ }
+ }
+
@Override
public void setDefaultContent(final String groupShortName, final Content content) {
final Group group = findByShortName(groupShortName);
@@ -331,6 +342,16 @@
group.setBackgroundMime(mime);
}
+ private SocialNetwork setSocialNetwork(final Group group, final GroupListMode publicVisibility,
+ final SocialNetworkVisibility snVisibility) {
+ final SocialNetwork network = group.getSocialNetwork();
+ final AccessLists lists = network.getAccessLists();
+ lists.getEditors().setMode(GroupListMode.NOBODY);
+ lists.getViewers().setMode(publicVisibility);
+ network.setVisibility(snVisibility);
+ return network;
+ }
+
@Override
public void setToolEnabled(final User userLogged, final String groupShortName, final String tool,
final boolean enabled) {
@@ -366,7 +387,12 @@
}
group.setShortName(shortName);
}
+ group.setGroupType(groupDTO.getGroupType());
+ setAdmissionType(group);
+ final boolean isClosed = group.getGroupType().equals(GroupType.CLOSED);
+ setSocialNetwork(group, getDefGroupMode(isClosed), getDefSNVisibility(isClosed));
persist(group);
+ snCache.expire(group);
return group;
}
Modified: trunk/src/main/java/cc/kune/core/shared/domain/GroupListMode.java
===================================================================
--- trunk/src/main/java/cc/kune/core/shared/domain/GroupListMode.java 2012-03-30 13:12:37 UTC (rev 1808)
+++ trunk/src/main/java/cc/kune/core/shared/domain/GroupListMode.java 2012-03-30 16:38:51 UTC (rev 1809)
@@ -21,6 +21,15 @@
import com.google.gwt.user.client.rpc.IsSerializable;
+/**
+ * The Enum GroupListMode describe the group list behavior
+ */
public enum GroupListMode implements IsSerializable {
- NORMAL, NOBODY, EVERYONE;
+
+ /** EVERYONE: means that everybody is allowed */
+ EVERYONE,
+ /** NOBODY: means that nobody is allowed */
+ NOBODY,
+ /** NORMAL means that that only groups in this list are allowed */
+ NORMAL;
}
Modified: trunk/src/main/java/cc/kune/gspace/client/options/general/GroupOptGeneralPanel.java
===================================================================
--- trunk/src/main/java/cc/kune/gspace/client/options/general/GroupOptGeneralPanel.java 2012-03-30 13:12:37 UTC (rev 1808)
+++ trunk/src/main/java/cc/kune/gspace/client/options/general/GroupOptGeneralPanel.java 2012-03-30 16:38:51 UTC (rev 1809)
@@ -23,15 +23,30 @@
import cc.kune.common.shared.i18n.I18nTranslationService;
import cc.kune.core.client.groups.newgroup.GroupFieldFactory;
import cc.kune.core.client.resources.CoreResources;
+import cc.kune.core.client.ui.DefaultFormUtils;
+import cc.kune.core.shared.dto.GroupType;
+import com.extjs.gxt.ui.client.widget.form.FieldSet;
+import com.extjs.gxt.ui.client.widget.form.Radio;
import com.extjs.gxt.ui.client.widget.form.TextField;
import com.google.inject.Inject;
public class GroupOptGeneralPanel extends EntityOptGeneralPanel implements GroupOptGeneralView {
+ public static final String CLOSED_GROUP_TYPE_ID = "k-gogp-type_of_group_closed";
+ public static final String COMM_GROUP_TYPE_ID = "k-gopg-type_of_group_comm";
private static final String LONG_NAME_FIELD = "k-gogp-longname";
+ public static final String ORG_GROUP_TYPE_ID = "k-gopg-type_of_group_org";
+
+ public static final String PROJ_GROUP_TYPE_ID = "k-gopg-type_of_group_proj";
+
private static final String SHORT_NAME_FIELD = "k-gogp-shortname";
+ public static final String TYPEOFGROUP_FIELD = "k-gogp-type_of_group";
+ private final Radio closedRadio;
+ private final Radio communityRadio;
private final TextField<String> longName;
+ private final Radio orgRadio;
+ private final Radio projectRadio;
private final TextField<String> shortName;
@Inject
@@ -39,12 +54,45 @@
final MaskWidget maskWidget, final GroupFieldFactory groupFieldFactory) {
super(maskWidget, res.emblemSystem(), i18n.t("General"), i18n.t("Change this values:"));
shortName = groupFieldFactory.createUserShortName(SHORT_NAME_FIELD);
- longName = groupFieldFactory.createUserLongName(LONG_NAME_FIELD);
+ longName = groupFieldFactory.createLongName(LONG_NAME_FIELD);
add(shortName);
add(longName);
+
+ final FieldSet groupTypeFieldSet = DefaultFormUtils.createFieldSet(i18n.t("Group type"), "210px");
+ groupTypeFieldSet.setWidth("210px");
+ add(groupTypeFieldSet);
+
+ projectRadio = groupFieldFactory.createProjectRadio(groupTypeFieldSet, TYPEOFGROUP_FIELD,
+ PROJ_GROUP_TYPE_ID);
+ projectRadio.setTabIndex(3);
+ projectRadio.setValue(true);
+
+ orgRadio = groupFieldFactory.createOrgRadio(groupTypeFieldSet, TYPEOFGROUP_FIELD, ORG_GROUP_TYPE_ID);
+ orgRadio.setTabIndex(4);
+
+ closedRadio = groupFieldFactory.createClosedRadio(groupTypeFieldSet, TYPEOFGROUP_FIELD,
+ CLOSED_GROUP_TYPE_ID);
+ closedRadio.setTabIndex(5);
+
+ communityRadio = groupFieldFactory.createCommunityRadio(groupTypeFieldSet, TYPEOFGROUP_FIELD,
+ COMM_GROUP_TYPE_ID);
+ communityRadio.setTabIndex(6);
}
@Override
+ public GroupType getGroupType() {
+ if (projectRadio.getValue()) {
+ return GroupType.PROJECT;
+ } else if (orgRadio.getValue()) {
+ return GroupType.ORGANIZATION;
+ } else if (closedRadio.getValue()) {
+ return GroupType.CLOSED;
+ } else {
+ return GroupType.COMMUNITY;
+ }
+ }
+
+ @Override
public String getLongName() {
return longName.getValue();
}
Modified: trunk/src/main/java/cc/kune/gspace/client/options/general/GroupOptGeneralPresenter.java
===================================================================
--- trunk/src/main/java/cc/kune/gspace/client/options/general/GroupOptGeneralPresenter.java 2012-03-30 13:12:37 UTC (rev 1808)
+++ trunk/src/main/java/cc/kune/gspace/client/options/general/GroupOptGeneralPresenter.java 2012-03-30 16:38:51 UTC (rev 1809)
@@ -78,12 +78,13 @@
@Override
protected void updateInServer() {
if (view.isValid()) {
- NotifyUser.showProgress();
+ NotifyUser.showProgress(i18n.t("Saving"));
final GroupDTO group = session.getCurrentState().getGroup();
final String previousGroupName = group.getShortName();
final StateToken token = group.getStateToken().copy();
group.setShortName(groupView.getShortName());
group.setLongName(groupView.getLongName());
+ group.setGroupType(groupView.getGroupType());
groupService.get().updateGroup(session.getUserHash(), token, group,
new AsyncCallbackSimple<StateAbstractDTO>() {
@Override
Modified: trunk/src/main/java/cc/kune/gspace/client/options/general/GroupOptGeneralView.java
===================================================================
--- trunk/src/main/java/cc/kune/gspace/client/options/general/GroupOptGeneralView.java 2012-03-30 13:12:37 UTC (rev 1808)
+++ trunk/src/main/java/cc/kune/gspace/client/options/general/GroupOptGeneralView.java 2012-03-30 16:38:51 UTC (rev 1809)
@@ -19,8 +19,12 @@
*/
package cc.kune.gspace.client.options.general;
+import cc.kune.core.shared.dto.GroupType;
+
public interface GroupOptGeneralView extends EntityOptGeneralView {
+ GroupType getGroupType();
+
String getLongName();
String getShortName();
Modified: trunk/src/main/java/cc/kune/gspace/client/options/general/UserOptGeneralPanel.java
===================================================================
--- trunk/src/main/java/cc/kune/gspace/client/options/general/UserOptGeneralPanel.java 2012-03-30 13:12:37 UTC (rev 1808)
+++ trunk/src/main/java/cc/kune/gspace/client/options/general/UserOptGeneralPanel.java 2012-03-30 16:38:51 UTC (rev 1809)
@@ -40,8 +40,6 @@
public class UserOptGeneralPanel extends EntityOptGeneralPanel implements UserOptGeneralView {
- private static final String BIG_FIELD_SIZE = "310px";
-
public static final String DAILY_TYPE_ID = "k-ngp-type_daily";
public static final String EMAIL_FIELD = "k-ngp-emial";
public static final String HOURLY_TYPE_ID = "k-ngp-type_hourly";
@@ -78,12 +76,7 @@
email = userFieldFactory.createUserEmail(EMAIL_FIELD);
add(email);
- emailNotifTypeFieldSet = new FieldSet();
- emailNotifTypeFieldSet.setHeading(i18n.t("How often do you want to receive email notifications?"));
- emailNotifTypeFieldSet.addStyleName("k-form-fieldset");
- emailNotifTypeFieldSet.setCollapsible(false);
- emailNotifTypeFieldSet.setWidth(BIG_FIELD_SIZE);
- emailNotifTypeFieldSet.setAutoHeight(true);
+ emailNotifTypeFieldSet = DefaultFormUtils.createFieldSet(i18n.t("How often do you want to receive email notifications?"));
immediateRadio = DefaultFormUtils.createRadio(emailNotifTypeFieldSet, i18n.t("almost immediately"),
TYPEOFEMAILNOTIF_FIELD, i18n.t(
@@ -122,7 +115,7 @@
notVerified.addStyleName("k-3corners");
notVerifLabelAdapter = new AdapterField(notVerified);
notVerifLabelAdapter.setLabelSeparator("");
- notVerifLabelAdapter.setWidth(BIG_FIELD_SIZE);
+ notVerifLabelAdapter.setWidth(DefaultFormUtils.BIG_FIELD_SIZE);
super.add(notVerifLabelAdapter);
resendEmailVerifBtn = new Button(i18n.t("Resend verification email"));
@@ -130,7 +123,7 @@
resendEmailVerifAdapter = new AdapterField(resendEmailVerifBtn);
resendEmailVerifAdapter.setValidateOnBlur(false);
resendEmailVerifAdapter.setLabelSeparator("");
- resendEmailVerifAdapter.setWidth(BIG_FIELD_SIZE);
+ resendEmailVerifAdapter.setWidth(DefaultFormUtils.BIG_FIELD_SIZE);
// resendEmailVerifAdapter.setFieldLabel(i18n.t("Maybe you want receive again our verification email"));
add(resendEmailVerifAdapter);
}
More information about the kune-commits
mailing list