[Pkg-mozext-commits] [tabmixplus] 08/10: Remove Array.filter generics usage, follow up bug 1228975

David Prévot taffit at moszumanska.debian.org
Tue Dec 29 19:03:20 UTC 2015


This is an automated email from the git hooks/post-receive script.

taffit pushed a commit to tag 0.4.2.1pre.151226a1
in repository tabmixplus.

commit be1ae681a6529bb54881e58ec0cfb2e4c41273eb
Author: onemen <tabmix.onemen at gmail.com>
Date:   Thu Dec 24 15:33:03 2015 +0200

    Remove Array.filter generics usage, follow up bug 1228975
---
 chrome/content/flst/lasttab.js          | 2 +-
 chrome/content/minit/minit.js           | 4 ++--
 chrome/content/minit/tablib.js          | 2 +-
 chrome/content/preferences/menu.js      | 2 +-
 chrome/content/preferences/shortcuts.js | 2 +-
 chrome/content/tab/scrollbox.xml        | 2 +-
 6 files changed, 7 insertions(+), 7 deletions(-)

diff --git a/chrome/content/flst/lasttab.js b/chrome/content/flst/lasttab.js
index 4f44aaf..1039a42 100644
--- a/chrome/content/flst/lasttab.js
+++ b/chrome/content/flst/lasttab.js
@@ -172,7 +172,7 @@ var TMP_LastTab = {
     if (this._tabs)
       return this._tabs;
     let list = this.handleCtrlTab ? this.TabHistory : gBrowser.tabs;
-    this._tabs = Array.filter(list, function(tab) {
+    this._tabs = Array.prototype.filter.call(list, function(tab) {
       return !tab.hidden && !tab.closing;
     });
     return this._tabs;
diff --git a/chrome/content/minit/minit.js b/chrome/content/minit/minit.js
index 98069de..0f216b0 100644
--- a/chrome/content/minit/minit.js
+++ b/chrome/content/minit/minit.js
@@ -945,13 +945,13 @@ var TMP_TabView = {
 
   // includung _removingTabs
   currentGroup: function() {
-    return Array.filter(gBrowser.tabs, tab => !tab.hidden);
+    return Array.prototype.filter.call(gBrowser.tabs, tab => !tab.hidden);
   },
 
   // visibleTabs don't include  _removingTabs
   getTabPosInCurrentGroup: function(aTab) {
     if (aTab) {
-      let tabs = Array.filter(gBrowser.tabs, tab => !tab.hidden);
+      let tabs = Array.prototype.filter.call(gBrowser.tabs, tab => !tab.hidden);
       return tabs.indexOf(aTab);
     }
     return -1;
diff --git a/chrome/content/minit/tablib.js b/chrome/content/minit/tablib.js
index 8904b86..6d9882d 100644
--- a/chrome/content/minit/tablib.js
+++ b/chrome/content/minit/tablib.js
@@ -1385,7 +1385,7 @@ var tablib = { // eslint-disable-line
     gBrowser.previousTabIndex = function _previousTabIndex(aTab, aTabs) {
       var temp_id, tempIndex = -1, max_id = 0;
       var tabs = aTabs || this.visibleTabs;
-      var items = Array.filter(this.tabContainer.getElementsByAttribute("tabmix_selectedID", "*"),
+      var items = Array.prototype.filter.call(this.tabContainer.getElementsByAttribute("tabmix_selectedID", "*"),
           tab => !tab.hidden && !tab.closing);
       for (var i = 0; i < items.length; ++i) {
         if (aTab && items[i] == aTab)
diff --git a/chrome/content/preferences/menu.js b/chrome/content/preferences/menu.js
index b3110ad..4c92045 100644
--- a/chrome/content/preferences/menu.js
+++ b/chrome/content/preferences/menu.js
@@ -72,7 +72,7 @@ var gMenuPane = { // jshint ignore:line
 
   _slideShow: "",
   updateShortcuts: function(aShortcuts, aCallBack) {
-    let boxes = Array.filter(aShortcuts.childNodes, aCallBack);
+    let boxes = Array.prototype.filter.call(aShortcuts.childNodes, aCallBack);
     $("shortcuts-panel").setAttribute("usedKeys", boxes.length > 0);
     if (this._slideShow != $("shortcut-group").keys.slideShow) {
       this._slideShow = $("shortcut-group").keys.slideShow;
diff --git a/chrome/content/preferences/shortcuts.js b/chrome/content/preferences/shortcuts.js
index 561c773..c612bcc 100644
--- a/chrome/content/preferences/shortcuts.js
+++ b/chrome/content/preferences/shortcuts.js
@@ -21,7 +21,7 @@ function getKeysForShortcut(shortcut, id, win) {
 
   let dots = "…";
   let keys = win.document.getElementsByTagName("key");
-  let usedKeys = Array.filter(keys, function(key) {
+  let usedKeys = Array.prototype.filter.call(keys, function(key) {
     if (ourKey == key)
       return false;
     if (isDisabled(key) || isDisabled($(key.getAttribute("command"))))
diff --git a/chrome/content/tab/scrollbox.xml b/chrome/content/tab/scrollbox.xml
index 1893f0a..286f77b 100644
--- a/chrome/content/tab/scrollbox.xml
+++ b/chrome/content/tab/scrollbox.xml
@@ -115,7 +115,7 @@
            inherited from the binding parent -->
       <method name="_getScrollableElements">
         <body><![CDATA[
-          return Array.filter(document.getBindingParent(this).childNodes,
+          return Array.prototype.filter.call(document.getBindingParent(this).childNodes,
                               this._canScrollToElement, this);
         ]]></body>
       </method>

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-mozext/tabmixplus.git



More information about the Pkg-mozext-commits mailing list