use of com.google.gerrit.client.ui.SmallHeading in project gerrit by GerritCodeReview.
the class ProjectInfoScreen method initProjectActions.
private void initProjectActions(ConfigInfo info) {
actionsGrid.clear(true);
actionsGrid.removeAllRows();
boolean showCreateChange = Gerrit.isSignedIn();
NativeMap<ActionInfo> actions = info.actions();
if (actions == null) {
actions = NativeMap.create().cast();
}
if (actions.isEmpty() && !showCreateChange) {
return;
}
actions.copyKeysIntoChildren("id");
actionsGrid.addHeader(new SmallHeading(AdminConstants.I.headingProjectCommands()));
FlowPanel actionsPanel = new FlowPanel();
actionsPanel.setStyleName(Gerrit.RESOURCES.css().projectActions());
actionsPanel.setVisible(true);
actionsGrid.add(AdminConstants.I.headingCommands(), actionsPanel);
for (String id : actions.keySet()) {
actionsPanel.add(new ActionButton(getProjectKey(), actions.get(id)));
}
// HEAD. This would have to happen on the server side.
if (showCreateChange) {
actionsPanel.add(createChangeAction());
}
if (isOwner && configVisible) {
actionsPanel.add(createEditConfigAction());
}
}
use of com.google.gerrit.client.ui.SmallHeading in project gerrit by GerritCodeReview.
the class AccountGroupMembersScreen method initNoMembersInfo.
private void initNoMembersInfo() {
noMembersInfo = new FlowPanel();
noMembersInfo.setVisible(false);
noMembersInfo.add(new SmallHeading(AdminConstants.I.noMembersInfo()));
add(noMembersInfo);
}
Aggregations