From 26fec12cade6cf62a3e30b8d51fbb8c1b20c6018 Mon Sep 17 00:00:00 2001 From: Doug Kearns Date: Fri, 27 Mar 2009 13:31:31 +1100 Subject: [PATCH] Fix #204. Fixes #204 (statusbar should follow "site identification button" color codes). --- common/content/events.js | 11 +++++++---- common/content/style.js | 7 ++++--- common/content/ui.js | 4 +++- vimperator/locale/en-US/styling.txt | 1 + 4 files changed, 15 insertions(+), 8 deletions(-) diff --git a/common/content/events.js b/common/content/events.js index 3c58afc2..51d1ecb8 100644 --- a/common/content/events.js +++ b/common/content/events.js @@ -1684,13 +1684,16 @@ function Events() //{{{ } }, // for notifying the user about secure web pages - onSecurityChange: function (webProgress, aRequest, aState) + onSecurityChange: function (webProgress, request, state) { - if (aState & Ci.nsIWebProgressListener.STATE_IS_INSECURE) + // TODO: do something useful with STATE_SECURE_MED and STATE_SECURE_LOW + if (state & Ci.nsIWebProgressListener.STATE_IS_INSECURE) statusline.setClass("insecure"); - else if (aState & Ci.nsIWebProgressListener.STATE_IS_BROKEN) + else if (state & Ci.nsIWebProgressListener.STATE_IS_BROKEN) statusline.setClass("broken"); - else if (aState & Ci.nsIWebProgressListener.STATE_IS_SECURE) + else if (state & Ci.nsIWebProgressListener.STATE_IDENTITY_EV_TOPLEVEL) + statusline.setClass("extended"); + else if (state & Ci.nsIWebProgressListener.STATE_SECURE_HIGH) statusline.setClass("secure"); }, onStatusChange: function (webProgress, request, status, message) diff --git a/common/content/style.js b/common/content/style.js index d994dbd6..24a05657 100644 --- a/common/content/style.js +++ b/common/content/style.js @@ -71,9 +71,10 @@ Highlights.prototype.CSS =