@Override protected void onInitUI() { super.onInitUI(); agreements = new AgreementTable(); add(agreements); add(new Hyperlink(Util.C.newAgreement(), PageLinks.SETTINGS_NEW_AGREEMENT)); }
@Override protected void onInitUI() { super.onInitUI(); tokenLabel = new CopyableLabel(""); tokenLabel.addStyleName(Gerrit.RESOURCES.css().oauthToken()); expiresLabel = new Label(""); expiresLabel.addStyleName(Gerrit.RESOURCES.css().oauthExpires()); grid = new Grid(2, 2); grid.setStyleName(Gerrit.RESOURCES.css().infoBlock()); grid.addStyleName(Gerrit.RESOURCES.css().oauthInfoBlock()); add(grid); expiredNote = new Label(Util.C.labelOAuthExpired()); expiredNote.setVisible(false); add(expiredNote); row(grid, 0, Util.C.labelOAuthToken(), tokenLabel); row(grid, 1, Util.C.labelOAuthExpires(), expiresLabel); CellFormatter fmt = grid.getCellFormatter(); fmt.addStyleName(0, 0, Gerrit.RESOURCES.css().topmost()); fmt.addStyleName(0, 1, Gerrit.RESOURCES.css().topmost()); fmt.addStyleName(1, 0, Gerrit.RESOURCES.css().bottomheader()); flow = new FlowPanel(); flow.setStyleName(Gerrit.RESOURCES.css().oauthPanel()); add(flow); Label netrcLabel = new Label(Util.C.labelOAuthNetRCEntry()); netrcLabel.setStyleName(Gerrit.RESOURCES.css().oauthPanelNetRCHeading()); flow.add(netrcLabel); netrcValue = new CopyableLabel(""); netrcValue.setStyleName(Gerrit.RESOURCES.css().oauthPanelNetRCEntry()); flow.add(netrcValue); Label cookieLabel = new Label(Util.C.labelOAuthGitCookie()); cookieLabel.setStyleName(Gerrit.RESOURCES.css().oauthPanelCookieHeading()); flow.add(cookieLabel); cookieValue = new CopyableLabel(""); cookieValue.setStyleName(Gerrit.RESOURCES.css().oauthPanelCookieEntry()); flow.add(cookieValue); }