summaryrefslogtreecommitdiff
path: root/common/modules
diff options
context:
space:
mode:
authorKris Maglione <maglione.k@gmail.com>2010-10-14 13:58:18 -0400
committerKris Maglione <maglione.k@gmail.com>2010-10-14 13:58:18 -0400
commite925a7db012144901eda875940e0d78554b8d686 (patch)
tree212e7d0372045f2ca57508543676e12037616249 /common/modules
parentfbb70c7093cd4377376ae96e7a48d13633aa3806 (diff)
downloadpentadactyl-e925a7db012144901eda875940e0d78554b8d686.tar.gz
Fix some stupid bugs in newer JägerMonkey. Closes issue #86.
Diffstat (limited to 'common/modules')
-rw-r--r--common/modules/highlight.jsm10
-rw-r--r--common/modules/storage.jsm2
2 files changed, 7 insertions, 5 deletions
diff --git a/common/modules/highlight.jsm b/common/modules/highlight.jsm
index 96a142e0..d5d7f711 100644
--- a/common/modules/highlight.jsm
+++ b/common/modules/highlight.jsm
@@ -147,11 +147,13 @@ const Highlights = Module("Highlight", {
*
* @param {string} class
*/
- selector: function (class_)
- class_.replace(/(^|\s)([A-Z]\w+)\b/g,
+ selector: function (class_) {
+ const self = this;
+ return class_.replace(/(^|\s)([A-Z]\w+)\b/g,
function (m, n1, hl) n1 +
- (this.highlight[hl] && this.highlight[hl].class != class_
- ? this.highlight[hl] : "[dactyl|highlight~=" + hl + "]")),
+ (self.highlight[hl] && self.highlight[hl].class != class_
+ ? self.highlight[hl] : "[dactyl|highlight~=" + hl + "]"));
+ },
/**
* Clears all highlighting rules. Rules with default values are
diff --git a/common/modules/storage.jsm b/common/modules/storage.jsm
index 0cd800e6..008fcedc 100644
--- a/common/modules/storage.jsm
+++ b/common/modules/storage.jsm
@@ -282,7 +282,7 @@ const File = Class("File", {
return null;
}
}
- let self = XPCSafeJSObjectWrapper(file);
+ let self = XPCNativeWrapper(file);
self.__proto__ = File.prototype;
return self;
},