Shrink the footer to be a single line

This makes the footer take up very little vertical space by putting
all elements on a single line and removing the padding.  This saves a
lot of vertical room on CodeMirrorDemo style screens where the footer
cannot scroll.

Change-Id: I3bd30c9476942c3b7255fcbd815634f4224e772b
This commit is contained in:
Shawn Pearce
2013-07-16 17:54:16 -07:00
parent 426a46d751
commit 82bf85a10a
4 changed files with 10 additions and 19 deletions

View File

@@ -72,7 +72,6 @@ import com.google.gwt.user.client.ui.Grid;
import com.google.gwt.user.client.ui.HTMLTable.CellFormatter;
import com.google.gwt.user.client.ui.InlineHTML;
import com.google.gwt.user.client.ui.InlineLabel;
import com.google.gwt.user.client.ui.Label;
import com.google.gwt.user.client.ui.RootPanel;
import com.google.gwtexpui.clippy.client.CopyableLabel;
import com.google.gwtexpui.user.client.UserAgent;
@@ -434,28 +433,23 @@ public class Gerrit implements EntryPoint {
}
private static void populateBottomMenu(RootPanel btmmenu, HostPageData hpd) {
final Label keyHelp = new Label(C.keyHelp());
keyHelp.setStyleName(RESOURCES.css().keyhelp());
btmmenu.add(keyHelp);
String vs = hpd.version;
if (vs == null || vs.isEmpty()) {
vs = "dev";
}
FlowPanel poweredBy = new FlowPanel();
poweredBy.setStyleName(RESOURCES.css().version());
poweredBy.add(new InlineHTML(M.poweredBy(vs)));
btmmenu.add(new InlineLabel(C.keyHelp()));
btmmenu.add(new InlineLabel(" | "));
btmmenu.add(new InlineHTML(M.poweredBy(vs)));
if (getConfig().getReportBugUrl() != null) {
poweredBy.add(new InlineLabel(" | "));
Anchor a = new Anchor(
C.reportBug(),
getConfig().getReportBugUrl());
a.setTarget("_blank");
a.setStyleName("");
poweredBy.add(a);
btmmenu.add(new InlineLabel(" | "));
btmmenu.add(a);
}
btmmenu.add(poweredBy);
}
private void onModuleLoad2(HostPageData hpd) {

View File

@@ -140,7 +140,6 @@ public interface GerritCss extends CssResource {
String infoBlock();
String infoTable();
String inputFieldTypeHint();
String keyhelp();
String labelList();
String leftMostCell();
String lineHeader();
@@ -230,6 +229,5 @@ public interface GerritCss extends CssResource {
String userInfoPopup();
String useridentity();
String usernameField();
String version();
String watchedProjectFilter();
}

View File

@@ -61,12 +61,11 @@ a:hover {
text-decoration: underline;
}
.version,
.keyhelp {
#gerrit_btmmenu {
clear: both;
color: #a0adcc;
right: 0;
padding-right: 10px;
text-align: right;
padding-right: 10px;
}
.version a,

View File

@@ -44,9 +44,9 @@
</noscript>
</div>
<div id="gerrit_body"></div>
<div style="clear: both; margin-top: 15px; padding-top: 2px; margin-bottom: 15px;">
<div style="clear: both">
<div id="gerrit_footer"></div>
<div id="gerrit_btmmenu" style="clear: both;"></div>
<div id="gerrit_btmmenu"></div>
</div>
<iframe src="javascript:''" id="__gwt_historyFrame" tabIndex='-1' style="position:absolute;width:0;height:0;border:0"></iframe>
<script id="gerrit_module"></script>