Merge with mc

This commit is contained in:
Doug Turner 2010-09-15 18:11:09 -07:00
commit fdae655a09
8 changed files with 217 additions and 49 deletions

View File

@ -140,6 +140,10 @@ toolbar[mode="icons"] > #reload-button[displaystop] {
-moz-binding: url(chrome://browser/content/urlbarBindings.xml#urlbar);
}
#urlbar-progress {
-moz-binding: url("chrome://global/content/bindings/progressmeter.xml#progressmeter");
}
/* Some child nodes want to be ordered based on the locale's direction, while
everything else should be ltr. */
.urlbar-input-box:-moz-locale-dir(rtl) {

View File

@ -4026,7 +4026,7 @@ var XULBrowserWindow = {
get statusMeter () {
delete this.statusMeter;
return this.statusMeter = document.getElementById("statusbar-icon");
return this.statusMeter = document.getElementById("urlbar-progress");
},
get stopCommand () {
delete this.stopCommand;
@ -4162,7 +4162,7 @@ var XULBrowserWindow = {
this._progressCollapseTimer = 0;
}
else
this.statusMeter.parentNode.collapsed = false;
this.statusMeter.collapsed = false;
// XXX: This needs to be based on window activity...
this.stopCommand.removeAttribute("disabled");
@ -4226,7 +4226,7 @@ var XULBrowserWindow = {
// Turn the progress meter and throbber off.
this._progressCollapseTimer = setTimeout(function (self) {
self.statusMeter.parentNode.collapsed = true;
self.statusMeter.collapsed = true;
self._progressCollapseTimer = 0;
}, 100, this);

View File

@ -953,6 +953,7 @@
tooltiptext="&goEndCap.tooltip;"
onclick="gURLBar.handleCommand(event);"/>
</hbox>
<progressmeter id="urlbar-progress" mode="normal"/>
<toolbarbutton id="urlbar-go-button"
onclick="gURLBar.handleCommand(event);"
tooltiptext="&goEndCap.tooltip;"/>
@ -1287,9 +1288,6 @@
#endif
>
<statusbarpanel id="statusbar-display" label="" flex="1"/>
<statusbarpanel class="statusbarpanel-progress" collapsed="true" id="statusbar-progresspanel">
<progressmeter class="progressmeter-statusbar" id="statusbar-icon" mode="normal" value="0"/>
</statusbarpanel>
<statusbarpanel id="download-monitor" class="statusbarpanel-iconic-text"
tooltiptext="&downloadMonitor2.tooltip;" hidden="true"
command="Tools:Downloads"/>

View File

@ -47,6 +47,7 @@
<binding id="urlbar" extends="chrome://global/content/bindings/autocomplete.xml#autocomplete">
<content sizetopopup="pref">
<xul:vbox class="urlbar-contents" flex="1">
<xul:hbox class="urlbar-frontcap-and-textbox" flex="1">
<xul:hbox class="urlbar-frontcap">
<children includes="image|deck|stack|box">
@ -87,13 +88,17 @@
</xul:hbox>
</xul:hbox>
</xul:stack>
</xul:hbox>
<xul:dropmarker anonid="historydropmarker"
class="autocomplete-history-dropmarker urlbar-history-dropmarker"
allowevents="true"
xbl:inherits="open,enablehistory,parentfocused=focused"/>
<xul:popupset anonid="popupset"
class="autocomplete-result-popupset"/>
</xul:hbox>
<xul:vbox class="urlbar-progress-container" flex="1" pack="end">
<children includes="progressmeter"/>
</xul:vbox>
</xul:vbox>
<children includes="toolbarbutton"/>
</content>

View File

@ -953,6 +953,56 @@ toolbar[iconsize="small"] #sync-button[status="active"] {
margin: 0;
}
/* urlbar progress */
#urlbar-progress {
-moz-appearance: none;
min-height: 0px;
height: 3px;
border: 0;
margin: -2px 0 -1px;
background-color: transparent;
}
#urlbar-progress[busy][stalled][value="0"] {
/* TODO: add connecting state (bug 596812) */
}
#urlbar-progress > .progress-bar {
-moz-appearance: none;
min-width: 3px;
border-top: 1px solid rgba(100,100,100,.1);
border-bottom: 1px solid rgba(0,0,0,.2);
background-color: Highlight;
background-image: -moz-linear-gradient(left, rgba(255,255,255,.1) 50%,
rgba(255,255,255,.4) 90%,
rgba(255,255,255,.8));
}
#urlbar-progress > .progress-bar:-moz-locale-dir(rtl) {
background-image: -moz-linear-gradient(right, rgba(255,255,255,.1) 50%,
rgba(255,255,255,.4) 90%,
rgba(255,255,255,.8));
}
#urlbar-progress > .progress-remainder {
border-top: 1px solid rgba(100,100,100,.1);
border-bottom: 1px solid rgba(0,0,0,.2);
background-image: -moz-linear-gradient(right, ThreeDShadow 80%, ThreeDLightShadow);
}
#urlbar-progress > .progress-remainder:-moz-locale-dir(rtl) {
background-image: -moz-linear-gradient(left, ThreeDShadow 80%, ThreeDLightShadow);
}
.urlbar-contents {
-moz-margin-end: -2px;
}
.urlbar-history-dropmarker {
-moz-margin-end: 2px;
}
/* Favicon */
#page-proxy-favicon,
#urlbar-throbber {

View File

@ -912,6 +912,55 @@ statusbarpanel#statusbar-display {
margin: 0;
}
/* urlbar progress */
#urlbar-progress {
-moz-appearance: none;
height: 3px;
margin: -2px 0 -1px;
}
#urlbar-progress[busy][stalled][value="0"] {
/* TODO: add connecting state (bug 596812) */
}
#urlbar-progress > .progress-bar {
-moz-appearance: none;
border: 0;
border-top: 1px solid rgba(0,0,0,.4);
border-bottom: 1px solid rgba(0,0,0,.3);
-moz-background-origin: border;
background-image: -moz-linear-gradient(left, rgb(107,160,193), rgb(169,223,251));
}
#urlbar-progress > .progress-bar:-moz-window-inactive {
border-top: 1px solid rgba(0,0,0,.2);
border-bottom: 1px solid rgba(0,0,0,.1);
background-image: -moz-linear-gradient(left, rgb(150,150,150), rgb(210,210,210));
}
#urlbar-progress > .progress-bar:-moz-locale-dir(rtl) {
background-image: -moz-linear-gradient(right, rgb(107,160,193), rgb(169,223,251));
}
#urlbar-progress > .progress-bar:-moz-window-inactive:-moz-locale-dir(rtl) {
background-image: -moz-linear-gradient(right, rgb(150,150,150), rgb(210,210,210));
}
#urlbar-progress > .progress-remainder {
border-top: 1px solid rgba(0,0,0,.1);
border-bottom: 1px solid rgba(0,0,0,.1);
background-color: rgba(0,0,0,.3);
}
.urlbar-contents {
-moz-margin-end: -2px;
}
.urlbar-history-dropmarker {
-moz-margin-end: 2px;
}
/* ----- AUTOCOMPLETE ----- */
#treecolAutoCompleteImage {

View File

@ -1090,6 +1090,56 @@ html|*.urlbar-input:-moz-lwtheme:-moz-placeholder,
margin: 0;
}
/* urlbar progress */
#urlbar-progress {
-moz-appearance: none;
min-height: 0px;
height: 3px;
border: 0;
margin: -2px 0 -1px;
background-color: transparent;
}
#urlbar-progress[busy][stalled][value="0"] {
/* TODO: add connecting state (bug 596812) */
}
#urlbar-progress > .progress-bar {
-moz-appearance: none;
min-width: 3px;
border-top: 1px solid rgba(100,100,100,.1);
border-bottom: 1px solid rgba(0,0,0,.2);
background-color: Highlight;
background-image: -moz-linear-gradient(left, rgba(255,255,255,.1) 50%,
rgba(255,255,255,.4) 90%,
rgba(255,255,255,.8));
}
#urlbar-progress > .progress-bar:-moz-locale-dir(rtl) {
background-image: -moz-linear-gradient(right, rgba(255,255,255,.1) 50%,
rgba(255,255,255,.4) 90%,
rgba(255,255,255,.8));
}
#urlbar-progress > .progress-remainder {
border-top: 1px solid rgba(100,100,100,.1);
border-bottom: 1px solid rgba(0,0,0,.2);
background-image: -moz-linear-gradient(right, ThreeDShadow 80%, ThreeDLightShadow);
}
#urlbar-progress > .progress-remainder:-moz-locale-dir(rtl) {
background-image: -moz-linear-gradient(left, ThreeDShadow 80%, ThreeDLightShadow);
}
.urlbar-contents {
-moz-margin-end: -2px;
}
.urlbar-history-dropmarker {
-moz-margin-end: 2px;
}
/* identity box */
#identity-box {

View File

@ -2746,11 +2746,23 @@ nsWindow::MakeFullScreen(PRBool aFullScreen)
UpdateNonClientMargins();
// Prevent window updates during the transition.
DWORD style;
if (nsUXThemeData::CheckForCompositor()) {
style = GetWindowLong(mWnd, GWL_STYLE);
SetWindowLong(mWnd, GWL_STYLE, style & ~WS_VISIBLE);
}
// Will call hide chrome, reposition window. Note this will
// also cache dimensions for restoration, so it should only
// be called once per fullscreen request.
nsresult rv = nsBaseWidget::MakeFullScreen(aFullScreen);
if (nsUXThemeData::CheckForCompositor()) {
style = GetWindowLong(mWnd, GWL_STYLE);
SetWindowLong(mWnd, GWL_STYLE, style | WS_VISIBLE);
}
// Let the dom know via web shell window
nsSizeModeEvent event(PR_TRUE, NS_SIZEMODE, this);
event.mSizeMode = mSizeMode;