backing out larry again, just for now, since we should have enough data by now

This commit is contained in:
mconnor@steelgryphon.com 2007-09-26 23:55:04 -07:00
Родитель 40b83c69d8
Коммит 06caf23005
11 изменённых файлов: 124 добавлений и 294 удалений

Просмотреть файл

@ -3679,8 +3679,9 @@ nsBrowserStatusHandler.prototype =
var securityUI = gBrowser.securityUI; var securityUI = gBrowser.securityUI;
this.securityButton.setAttribute("tooltiptext", securityUI.tooltipText); this.securityButton.setAttribute("tooltiptext", securityUI.tooltipText);
var lockIcon = document.getElementById("lock-icon");
getIdentityHandler().checkIdentity(aState); if (lockIcon)
lockIcon.setAttribute("tooltiptext", securityUI.tooltipText);
}, },
// simulate all change notifications after switching tabs // simulate all change notifications after switching tabs
@ -5662,11 +5663,8 @@ IdentityHandler.prototype = {
*/ */
checkIdentity : function(state) { checkIdentity : function(state) {
var currentURI = gBrowser.currentURI; var currentURI = gBrowser.currentURI;
if (currentURI.schemeIs("http")) { if (currentURI.schemeIs("http") && this._lastURI.schemeIs("http"))
if (!this._lastURI.schemeIs("http"))
this.setMode(this.IDENTITY_MODE_UNKNOWN);
return; return;
}
var currentStatus = gBrowser.securityUI var currentStatus = gBrowser.securityUI
.QueryInterface(Components.interfaces.nsISSLStatusProvider) .QueryInterface(Components.interfaces.nsISSLStatusProvider)

Просмотреть файл

@ -28,7 +28,6 @@
# Joe Hewitt <hewitt@netscape.com> # Joe Hewitt <hewitt@netscape.com>
# Pierre Chanial <chanial@noos.fr> # Pierre Chanial <chanial@noos.fr>
# Dean Tessman <dean_tessman@hotmail.com> # Dean Tessman <dean_tessman@hotmail.com>
# Johnathan Nightingale <johnath@mozilla.com>
# #
# Alternatively, the contents of this file may be used under the terms of # Alternatively, the contents of this file may be used under the terms of
# either the GNU General Public License Version 2 or later (the "GPL"), or # either the GNU General Public License Version 2 or later (the "GPL"), or
@ -137,34 +136,6 @@
<popup id="placesContext"/> <popup id="placesContext"/>
<!-- Popup for site identity information -->
<panel id="identity-popup" position="after_start" hidden="true" noautofocus="true">
<hbox id="identity-popup-container" align="top">
<image id="identity-popup-icon"/>
<vbox id="identity-popup-content-box">
<!-- Title Bar -->
<label id="identity-popup-title"/>
<!-- Content area -->
<description id="identity-popup-content"/>
<description id="identity-popup-content-supplemental"/>
<description id="identity-popup-content-verifier"/>
<hbox id="identity-popup-encryption" flex="1">
<vbox>
<image id="identity-popup-encryption-icon"/>
<spacer flex="1"/>
</vbox>
<description id="identity-popup-encryption-label" flex="1"/>
</hbox>
<spacer flex="1"/>
<!-- Footer link to page info -->
<label id="identity-popup-more-info-link"
class="text-link plain"
value="&identity.moreInfoLinkText;"
onclick="getIdentityHandler().handleMoreInfoClick(event);"/>
</vbox>
</hbox>
</panel>
<tooltip id="urlTooltip"> <tooltip id="urlTooltip">
<label crop="center" flex="1"/> <label crop="center" flex="1"/>
</tooltip> </tooltip>
@ -260,25 +231,19 @@
oninput="gBrowser.userTypedValue = this.value" oninput="gBrowser.userTypedValue = this.value"
ontextentered="return handleURLBarCommand(param);" ontextentered="return handleURLBarCommand(param);"
ontextreverted="return handleURLBarRevert();"> ontextreverted="return handleURLBarRevert();">
<!-- Use onclick instead of normal popup= syntax since the popup <deck id="page-proxy-deck" onclick="PageProxyClickHandler(event);">
code fires onmousedown, and hence eats our favicon drag events --> <image id="page-proxy-button"
<box id="identity-box" align="center" ondraggesture="PageProxyDragGesture(event);"
onclick="getIdentityHandler().handleIdentityClick(event);"> tooltiptext="&proxyIcon.tooltip;"/>
<deck id="page-proxy-deck" onclick="PageProxyClickHandler(event);"> <image id="page-proxy-favicon" validate="never"
<image id="page-proxy-button" ondraggesture="PageProxyDragGesture(event);"
ondraggesture="PageProxyDragGesture(event);" onload="this.parentNode.selectedIndex = 1;
tooltiptext="&proxyIcon.tooltip;"/> event.stopPropagation();"
<image id="page-proxy-favicon" validate="never" onerror="gBrowser.addToMissedIconCache(this.src);
ondraggesture="PageProxyDragGesture(event);" this.removeAttribute('src');
onload="this.parentNode.selectedIndex = 1; this.parentNode.selectedIndex = 0;"
event.stopPropagation();" tooltiptext="&proxyIcon.tooltip;"/>
onerror="gBrowser.addToMissedIconCache(this.src); </deck>
this.removeAttribute('src');
this.parentNode.selectedIndex = 0;"
tooltiptext="&proxyIcon.tooltip;"/>
</deck>
<label id="identity-icon-label"/>
</box>
<hbox id="urlbar-icons"> <hbox id="urlbar-icons">
<button type="menu" <button type="menu"
style="-moz-user-focus: none" style="-moz-user-focus: none"
@ -291,6 +256,7 @@
oncommand="return FeedHandler.subscribeToFeed(null, event);" oncommand="return FeedHandler.subscribeToFeed(null, event);"
onclick="checkForMiddleClick(this, event);"/> onclick="checkForMiddleClick(this, event);"/>
</button> </button>
<image id="lock-icon" onclick="if (event.button == 0) displaySecurityInfo(); event.stopPropagation();"/>
#ifdef MOZ_SAFE_BROWSING #ifdef MOZ_SAFE_BROWSING
<image id="safebrowsing-urlbar-icon" tooltiptext="&safeb.urlbaricon.tooltip;" <image id="safebrowsing-urlbar-icon" tooltiptext="&safeb.urlbaricon.tooltip;"
level="safe" level="safe"

Просмотреть файл

@ -46,7 +46,7 @@
<binding id="urlbar" extends="chrome://global/content/bindings/autocomplete.xml#autocomplete"> <binding id="urlbar" extends="chrome://global/content/bindings/autocomplete.xml#autocomplete">
<content sizetopopup="pref"> <content sizetopopup="pref">
<xul:hbox class="autocomplete-textbox-container" flex="1"> <xul:hbox class="autocomplete-textbox-container" flex="1">
<children includes="image|deck|stack|box"> <children includes="image|deck|stack">
<xul:image class="autocomplete-icon" allowevents="true"/> <xul:image class="autocomplete-icon" allowevents="true"/>
</children> </children>

Просмотреть файл

@ -208,6 +208,7 @@ PROT_PhishMsgDisplayerBase.prototype.browserSelected = function() {
this.messageShouldShow_ = true; this.messageShouldShow_ = true;
} }
this.hideLockIcon_(); // Comes back when we are unselected or unloaded
this.addWarningInUrlbar_(); // Goes away when we are unselected or unloaded this.addWarningInUrlbar_(); // Goes away when we are unselected or unloaded
// messageShouldShow might be false if the user dismissed the warning, // messageShouldShow might be false if the user dismissed the warning,
@ -233,6 +234,7 @@ PROT_PhishMsgDisplayerBase.prototype.explicitShow = function() {
*/ */
PROT_PhishMsgDisplayerBase.prototype.browserUnselected = function() { PROT_PhishMsgDisplayerBase.prototype.browserUnselected = function() {
this.removeWarningInUrlbar_(); this.removeWarningInUrlbar_();
this.unhideLockIcon_();
if (this.messageShowing_) if (this.messageShowing_)
this.hideMessage_(); this.hideMessage_();
} }
@ -288,6 +290,7 @@ PROT_PhishMsgDisplayerBase.prototype.done = function() {
// If we were started, we must be the current problem, so these things // If we were started, we must be the current problem, so these things
// must be showing // must be showing
this.removeWarningInUrlbar_(); this.removeWarningInUrlbar_();
this.unhideLockIcon_();
// Could be though that they've closed the warning dialog // Could be though that they've closed the warning dialog
if (this.messageShowing_) if (this.messageShowing_)
@ -324,6 +327,28 @@ PROT_PhishMsgDisplayerBase.prototype.removeIfExists_ = function(orig,
return orig; return orig;
} }
/**
* We don't want to confuse users if they land on a phishy page that uses
* SSL, so ensure that the lock icon never shows when we're showing our
* warning.
*/
PROT_PhishMsgDisplayerBase.prototype.hideLockIcon_ = function() {
var lockIcon = this.doc_.getElementById("lock-icon");
if (!lockIcon)
return;
lockIcon.hidden = true;
}
/**
* Ensure they can see it after our warning is finished.
*/
PROT_PhishMsgDisplayerBase.prototype.unhideLockIcon_ = function() {
var lockIcon = this.doc_.getElementById("lock-icon");
if (!lockIcon)
return;
lockIcon.hidden = false;
}
/** /**
* This method makes our warning icon visible in the location bar. It will * This method makes our warning icon visible in the location bar. It will
* be removed only when the problematic document is navigated awy from * be removed only when the problematic document is navigated awy from

Просмотреть файл

@ -350,5 +350,3 @@
<!ENTITY editBookmark.done.label "Done"> <!ENTITY editBookmark.done.label "Done">
<!ENTITY editBookmark.delete.label "Delete"> <!ENTITY editBookmark.delete.label "Delete">
<!ENTITY identity.moreInfoLinkText "Tell me more about this web site...">

Просмотреть файл

@ -101,20 +101,3 @@ chromelessWindow.accessKey=S
# Star button # Star button
starButtonOn.tooltip=Edit this bookmark starButtonOn.tooltip=Edit this bookmark
starButtonOff.tooltip=Bookmark this page starButtonOff.tooltip=Bookmark this page
# Identity information
identity.domainverified.title=Location Verified
identity.domainverified.body=You are currently visiting:
identity.domainverified.supplemental=Information identifying the owner of this web site may not have been validated.
identity.identified.title=Identity Verified
identity.identified.body=This web site is owned by:
identity.identified.verifier=Verified by: %S
identity.identified.state_and_country=%S, %S
identity.identified.title_with_country=%S (%S)
identity.unknown.title=Identity Unknown
identity.unknown.body=This web site does not supply identity information.
identity.encrypted=Your connection to this web site is encrypted to prevent eavesdropping.
identity.unencrypted=Your connection to this web site is not encrypted.

Просмотреть файл

@ -112,7 +112,7 @@
<!ENTITY securityView.identity.verifier "Verified by: "> <!ENTITY securityView.identity.verifier "Verified by: ">
<!ENTITY securityView.privacy.header "Privacy &amp; History"> <!ENTITY securityView.privacy.header "Privacy &amp; History">
<!ENTITY securityView.privacy.history "Have I visited this web site before today?"> <!ENTITY securityView.privacy.history "Have I visited this website before today?">
<!ENTITY securityView.privacy.cookies "Is this web site storing information (cookies) on my computer?"> <!ENTITY securityView.privacy.cookies "Is this web site storing information (cookies) on my computer?">
<!ENTITY securityView.privacy.viewCookies "View Cookies"> <!ENTITY securityView.privacy.viewCookies "View Cookies">
<!ENTITY securityView.privacy.viewCookies.accessKey "k"> <!ENTITY securityView.privacy.viewCookies.accessKey "k">

Просмотреть файл

@ -827,7 +827,7 @@ toolbar[iconsize="small"] #paste-button:hover:active {
#urlbar { #urlbar {
margin-top: 5px; margin-top: 5px;
margin-bottom: 5px; margin-bottom: 5px;
-moz-margin-start: 0px; -moz-margin-start: 4px;
-moz-margin-end: 0px; -moz-margin-end: 0px;
width: 7em; width: 7em;
min-width: 7em; min-width: 7em;
@ -879,6 +879,46 @@ toolbar[iconsize="small"] #paste-button:hover:active {
background: url("chrome://browser/skin/Secure-background.gif") #FFFED8 repeat-x; background: url("chrome://browser/skin/Secure-background.gif") #FFFED8 repeat-x;
} }
#urlbar #lock-icon {
height: 18px;
margin: -1px;
}
#urlbar[level="high"] #lock-icon {
list-style-image: url("chrome://browser/skin/Secure.png");
-moz-image-region: rect(0px, 18px, 18px, 0px);
}
#urlbar[level="high"] #lock-icon:hover {
-moz-image-region: rect(18px, 18px, 36px, 0px);
}
#urlbar[level="high"] #lock-icon:active {
-moz-image-region: rect(36px, 18px, 54px, 0px);
}
#urlbar[level="low"] #lock-icon {
list-style-image: url("chrome://browser/skin/Secure.png");
-moz-image-region: rect(0px, 18px, 18px, 0px);
}
#urlbar[level="low"] #lock-icon:hover {
-moz-image-region: rect(18px, 18px, 36px, 0px);
}
#urlbar[level="low"] #lock-icon:active {
-moz-image-region: rect(36px, 18px, 54px, 0px);
}
#urlbar[level="broken"] #lock-icon {
list-style-image: url("chrome://browser/skin/Security-broken.png");
-moz-image-region: rect(0px, 18px, 18px, 0px);
}
#urlbar[level="broken"] #lock-icon:hover {
-moz-image-region: rect(18px, 18px, 36px, 0px);
}
#urlbar[level="broken"] #lock-icon:active {
-moz-image-region: rect(36px, 18px, 54px, 0px);
}
#urlbar-container { #urlbar-container {
-moz-padding-end: 5px; -moz-padding-end: 5px;
} }
@ -1663,116 +1703,3 @@ toolbarbutton.bookmark-item[dragover="true"][open="true"] {
-moz-border-left-colors: ThreeDLightShadow ThreeDHighlight !important; -moz-border-left-colors: ThreeDLightShadow ThreeDHighlight !important;
} }
/* ::::: Identity Indicator Styling ::::: */
/* Location bar visuals*/
#identity-box {
/* Extend our margins out so that our highlight/separator bar covers the
location bar properly */
margin: -1px 0 -2px;
padding: 1px 2px 2px 0;
border-right: 1px solid #888;
background-color: white;
opacity: 0.9;
}
#identity-box:hover {
opacity: 1.0;
}
#identity-box.verifiedIdentity {
background-color: #BFA;
}
#urlbar[level="high"] > #identity-box,
#urlbar[level="low"] > #identity-box {
/* urlbar adds padding when security level is set, which we need to
counteract here so that we still fill the background. */
margin: -2px;
padding: 1px 2px 2px;
}
#identity-icon-label {
padding: 2px 2px 1px;
margin: 0;
color: black;
vertical-align: middle;
}
.unknownIdentity > #identity-icon-label {
display: none;
}
/* Popup Icons */
#identity-popup-icon {
height: 64px;
width: 64px;
padding: 0;
margin: 10px 0 0;
list-style-image: url("chrome://browser/skin/identity.png");
-moz-image-region: rect(0px, 64px, 64px, 0px);
}
.verifiedDomain > #identity-popup-container > #identity-popup-icon {
-moz-image-region: rect(64px, 64px, 128px, 0px);
}
.verifiedIdentity > #identity-popup-container > #identity-popup-icon {
-moz-image-region: rect(128px, 64px, 192px, 0px);
}
/* Popup Title */
#identity-popup-title {
font-size: 120%;
font-weight: bold;
}
.verifiedIdentity > #identity-popup-title {
color: #6A6;
}
.unknownIdentity > #identity-popup-title {
color: #999;
}
.verifiedDomain > #identity-popup-title {
color: black;
}
/* Popup Body Text */
#identity-popup-content-box > description,
#identity-popup-encryption-label {
white-space: -moz-pre-wrap;
color: black;
padding-left: 10px;
}
#identity-popup-content {
padding-top: 5px;
margin-bottom: 0;
max-width: 200px;
}
.verifiedIdentity > #identity-popup-content,
.verifiedDomain > #identity-popup-content {
font-size: 140%;
font-weight: bold;
max-width: 300px;
}
#identity-popup-encryption {
margin: 10px 0;
}
.verifiedIdentity > #identity-popup-encryption > * > #identity-popup-encryption-icon,
.verifiedDomain > #identity-popup-encryption > * >#identity-popup-encryption-icon {
list-style-image: url("chrome://browser/skin/Secure.png");
-moz-image-region: rect(0px, 18px, 18px, 0px);
}
/* Popup Bounding Box */
#identity-popup-container {
background-image: none;
background-color: white;
min-width: 280px;
padding: 10px;
}

Просмотреть файл

@ -10,7 +10,6 @@ classic.jar:
skin/classic/browser/find.png skin/classic/browser/find.png
skin/classic/browser/find-bar-background.png skin/classic/browser/find-bar-background.png
skin/classic/browser/Go.png skin/classic/browser/Go.png
skin/classic/browser/identity.png
skin/classic/browser/Info.png skin/classic/browser/Info.png
skin/classic/browser/page-livemarks.png skin/classic/browser/page-livemarks.png
skin/classic/browser/livemark-item.png skin/classic/browser/livemark-item.png

Просмотреть файл

@ -850,7 +850,7 @@ toolbar[iconsize="small"] #paste-button:not([disabled="true"]):hover:active {
margin-bottom: 2px; margin-bottom: 2px;
margin-top: 2px; margin-top: 2px;
-moz-margin-end: 0px; -moz-margin-end: 0px;
-moz-margin-start: 0px; -moz-margin-start: 3px;
width: 7em; width: 7em;
min-width: 7em; min-width: 7em;
@ -1735,6 +1735,43 @@ toolbar[mode="text"] > #window-controls > toolbarbutton > .toolbarbutton-text {
color: #000000; color: #000000;
} }
#urlbar[level="high"] #lock-icon {
-moz-image-region: rect(0px, 18px, 18px, 0px);
list-style-image: url("chrome://browser/skin/Secure.png");
}
#urlbar[level="high"] #lock-icon:hover {
-moz-image-region: rect(18px, 18px, 36px, 0px);
list-style-image: url("chrome://browser/skin/Secure.png");
}
#urlbar[level="high"] #lock-icon:active {
-moz-image-region: rect(36px, 18px, 54px, 0px);
list-style-image: url("chrome://browser/skin/Secure.png");
}
#urlbar[level="low"] #lock-icon {
-moz-image-region: rect(0px, 18px, 18px, 0px);
list-style-image: url("chrome://browser/skin/Secure.png");
}
#urlbar[level="low"] #lock-icon:hover {
-moz-image-region: rect(18px, 18px, 36px, 0px);
list-style-image: url("chrome://browser/skin/Secure.png");
}
#urlbar[level="low"] #lock-icon:active {
-moz-image-region: rect(36px, 18px, 54px, 0px);
list-style-image: url("chrome://browser/skin/Secure.png");
}
#urlbar[level="broken"] #lock-icon {
-moz-image-region: rect(0px, 18px, 18px, 0px);
list-style-image: url("chrome://browser/skin/Security-broken.png");
}
#urlbar[level="broken"] #lock-icon:hover {
-moz-image-region: rect(18px, 18px, 36px, 0px);
list-style-image: url("chrome://browser/skin/Security-broken.png");
}
#urlbar[level="broken"] #lock-icon:active {
-moz-image-region: rect(36px, 18px, 54px, 0px);
list-style-image: url("chrome://browser/skin/Security-broken.png");
}
%ifdef MOZ_WIDGET_GTK2 %ifdef MOZ_WIDGET_GTK2
#urlbar > .autocomplete-textbox-container { #urlbar > .autocomplete-textbox-container {
-moz-binding: url(chrome://browser/skin/browser.xml#autocomplete-security-wrapper); -moz-binding: url(chrome://browser/skin/browser.xml#autocomplete-security-wrapper);
@ -1847,105 +1884,3 @@ toolbarbutton.bookmark-item[dragover="true"][open="true"] {
.bookmark-item[dragover-bottom="true"] { .bookmark-item[dragover-bottom="true"] {
-moz-border-bottom-colors: #000000; -moz-border-bottom-colors: #000000;
} }
/* ::::: Identity Indicator Styling ::::: */
/* Location bar visuals*/
#identity-box {
border-right: 1px solid #888;
background-color: white;
opacity: 0.9;
}
#identity-box:hover {
opacity: 1.0;
}
#identity-box.verifiedIdentity {
background-color: #BFA;
}
#identity-icon-label {
padding: 1px 2px 2px;
margin: 0;
color: black;
vertical-align: middle;
}
.unknownIdentity > #identity-icon-label {
display: none;
}
/* Popup Icons */
#identity-popup-icon {
height: 64px;
width: 64px;
padding: 0;
margin: 10px 0 0;
list-style-image: url("chrome://browser/skin/identity.png");
-moz-image-region: rect(0px, 64px, 64px, 0px);
}
.verifiedDomain > #identity-popup-container > #identity-popup-icon {
-moz-image-region: rect(64px, 64px, 128px, 0px);
}
.verifiedIdentity > #identity-popup-container > #identity-popup-icon {
-moz-image-region: rect(128px, 64px, 192px, 0px);
}
/* Popup Title */
#identity-popup-title {
font-size: 120%;
font-weight: bold;
}
.verifiedIdentity > #identity-popup-title {
color: #6A6;
}
.unknownIdentity > #identity-popup-title {
color: #999;
}
.verifiedDomain > #identity-popup-title {
color: black;
}
/* Popup Body Text */
#identity-popup-content-box > description,
#identity-popup-encryption-label {
white-space: -moz-pre-wrap;
color: black;
padding-left: 10px;
}
#identity-popup-content {
padding-top: 5px;
margin-bottom: 0;
max-width: 200px;
}
.verifiedIdentity > #identity-popup-content,
.verifiedDomain > #identity-popup-content {
font-size: 140%;
font-weight: bold;
max-width: 300px;
}
#identity-popup-encryption {
margin: 10px 0;
}
.verifiedIdentity > #identity-popup-encryption > * > #identity-popup-encryption-icon,
.verifiedDomain > #identity-popup-encryption > * >#identity-popup-encryption-icon {
list-style-image: url("chrome://browser/skin/Secure.png");
-moz-image-region: rect(0px, 18px, 18px, 0px);
}
/* Popup Bounding Box */
#identity-popup-container {
background-image: none;
background-color: white;
min-width: 280px;
padding: 10px;
}

Просмотреть файл

@ -6,7 +6,6 @@ classic.jar:
skin/classic/browser/endcap-bkgnd-hover.png skin/classic/browser/endcap-bkgnd-hover.png
* skin/classic/browser/engineManager.css (engineManager.css) * skin/classic/browser/engineManager.css (engineManager.css)
skin/classic/browser/Info.png skin/classic/browser/Info.png
skin/classic/browser/identity.png
skin/classic/browser/pageInfo.css skin/classic/browser/pageInfo.css
skin/classic/browser/pageInfo.png skin/classic/browser/pageInfo.png
skin/classic/browser/page-livemarks.png skin/classic/browser/page-livemarks.png