1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2026-03-13 04:15:47 +01:00

Make last commit less sucky.

This commit is contained in:
Kris Maglione
2011-01-04 11:26:20 -05:00
parent e7ae04749c
commit c833f864d3
2 changed files with 12 additions and 15 deletions

View File

@@ -82,8 +82,8 @@ var StatusLine = Module("statusline", {
*
* @param {'extended'|'secure'|'broken'|'insecure'} type
*/
set class(type) {
this._class = type;
set security(type) {
this._security = type;
const highlightGroup = {
extended: "StatusLineExtended",
secure: "StatusLineSecure",
@@ -93,17 +93,7 @@ var StatusLine = Module("statusline", {
highlight.highlightNode(this.statusBar, this.baseGroup + highlightGroup[type]);
},
get class() this._class,
set security(state) {
if (state & Ci.nsIWebProgressListener.STATE_IS_BROKEN)
this.class = "broken";
else if (state & Ci.nsIWebProgressListener.STATE_IDENTITY_EV_TOPLEVEL)
this.class = "extended";
else if (state & Ci.nsIWebProgressListener.STATE_SECURE_HIGH)
this.class = "secure";
else // if (state & Ci.nsIWebProgressListener.STATE_IS_INSECURE)
this.class = "insecure";
},
get security() this._security,
// update all fields of the statusline
update: function update() {