Beispiel #1
0
  private void initUserList(final ClientUser[] list) {
    // The user listing is downloaded by an async call.
    final RootPanel userPanel = RootPanel.get("email");
    userPanel.add(users);
    users.addChangeHandler(
        new ChangeHandler() {
          @Override
          public void onChange(final ChangeEvent event) {
            userChanged();
          }
        });
    users.addItem(SELECT_USER_STRING, "");
    userInfo.clear();
    for (final ClientUser user : list) {
      users.addItem(user.getName(), user.getEmail());
      userInfo.put(user.getEmail(), user);
    }

    // Select the user according to the cookie stored
    final String userEmail = Cookies.getCookie("email");
    selectUser(userEmail);
  }
 private void addConfig(Configuration configuration) {
   configList.addItem(configuration.getName());
   configurations.put(configuration.getName(), configuration);
 }