Merge "Fix 'Settings' anchor href in CurrentUserPopupPanel"
This commit is contained in:
@@ -14,6 +14,7 @@
|
||||
|
||||
package com.google.gerrit.client;
|
||||
|
||||
import com.google.gerrit.common.PageLinks;
|
||||
import com.google.gerrit.reviewdb.client.Account;
|
||||
import com.google.gwt.core.client.GWT;
|
||||
import com.google.gwt.uibinder.client.UiBinder;
|
||||
@@ -35,11 +36,14 @@ public class CurrentUserPopupPanel extends PluginSafePopupPanel {
|
||||
Label userEmail;
|
||||
@UiField
|
||||
Anchor logout;
|
||||
@UiField
|
||||
Anchor settings;
|
||||
|
||||
public CurrentUserPopupPanel(Account account, boolean canLogOut) {
|
||||
super(/* auto hide */true, /* modal */false);
|
||||
setWidget(binder.createAndBindUi(this));
|
||||
setStyleName(Gerrit.RESOURCES.css().userInfoPopup());
|
||||
settings.setHref(Gerrit.selfRedirect(PageLinks.SETTINGS));
|
||||
if (account.getFullName() != null) {
|
||||
userName.setText(account.getFullName());
|
||||
}
|
||||
|
||||
@@ -18,7 +18,6 @@ limitations under the License.
|
||||
<ui:UiBinder xmlns:ui='urn:ui:com.google.gwt.uibinder'
|
||||
xmlns:g='urn:import:com.google.gwt.user.client.ui'>
|
||||
<ui:with field='constants' type='com.google.gerrit.client.GerritConstants'/>
|
||||
<ui:import field='com.google.gerrit.common.PageLinks.SETTINGS'/>
|
||||
|
||||
<ui:style>
|
||||
.panel {
|
||||
@@ -39,7 +38,7 @@ limitations under the License.
|
||||
<g:FlowPanel styleName="{style.panel}">
|
||||
<g:Label ui:field='userName' styleName="{style.userName}" />
|
||||
<g:Label ui:field='userEmail' styleName="{style.email}" />
|
||||
<g:Anchor href='{SETTINGS}'>
|
||||
<g:Anchor ui:field='settings'>
|
||||
<ui:text from='{constants.menuSettings}' />
|
||||
</g:Anchor>
|
||||
<g:Anchor ui:field='logout' styleName="{style.logout}">
|
||||
|
||||
Reference in New Issue
Block a user