| OLD | NEW |
| 1 /* | 1 /* |
| 2 * This file is part of Adblock Plus <http://adblockplus.org/>, | 2 * This file is part of Adblock Plus <http://adblockplus.org/>, |
| 3 * Copyright (C) 2006-2014 Eyeo GmbH | 3 * Copyright (C) 2006-2014 Eyeo GmbH |
| 4 * | 4 * |
| 5 * Adblock Plus is free software: you can redistribute it and/or modify | 5 * Adblock Plus is free software: you can redistribute it and/or modify |
| 6 * it under the terms of the GNU General Public License version 3 as | 6 * it under the terms of the GNU General Public License version 3 as |
| 7 * published by the Free Software Foundation. | 7 * published by the Free Software Foundation. |
| 8 * | 8 * |
| 9 * Adblock Plus is distributed in the hope that it will be useful, | 9 * Adblock Plus is distributed in the hope that it will be useful, |
| 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| (...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 44 | 44 |
| 45 let ioService = Cc["@mozilla.org/network/io-service;1"].getService(Ci.nsIIOSer
vice); | 45 let ioService = Cc["@mozilla.org/network/io-service;1"].getService(Ci.nsIIOSer
vice); |
| 46 try | 46 try |
| 47 { | 47 { |
| 48 let suggestions = [""]; | 48 let suggestions = [""]; |
| 49 | 49 |
| 50 let url = ioService.newURI(item.location, null, null) | 50 let url = ioService.newURI(item.location, null, null) |
| 51 .QueryInterface(Ci.nsIURL); | 51 .QueryInterface(Ci.nsIURL); |
| 52 let suffix = (url.query ? "?*" : ""); | 52 let suffix = (url.query ? "?*" : ""); |
| 53 url.query = ""; | 53 url.query = ""; |
| 54 url.ref = ""; |
| 54 suggestions[1] = addSuggestion(url.spec + suffix); | 55 suggestions[1] = addSuggestion(url.spec + suffix); |
| 55 | 56 |
| 56 let parentURL = ioService.newURI(url.fileName == "" ? ".." : ".", null, url)
; | 57 let parentURL = ioService.newURI(url.fileName == "" ? ".." : ".", null, url)
; |
| 57 if (!parentURL.equals(url)) | 58 if (!parentURL.equals(url)) |
| 58 suggestions[2] = addSuggestion(parentURL.spec + "*"); | 59 suggestions[2] = addSuggestion(parentURL.spec + "*"); |
| 59 else | 60 else |
| 60 suggestions[2] = suggestions[1]; | 61 suggestions[2] = suggestions[1]; |
| 61 | 62 |
| 62 let rootURL = ioService.newURI("/", null, url); | 63 let rootURL = ioService.newURI("/", null, url); |
| 63 if (!rootURL.equals(parentURL) && !rootURL.equals(url)) | 64 if (!rootURL.equals(parentURL) && !rootURL.equals(url)) |
| (...skipping 338 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 402 * Selects or unselects all type checkboxes except those | 403 * Selects or unselects all type checkboxes except those |
| 403 * that are disabled. | 404 * that are disabled. |
| 404 */ | 405 */ |
| 405 function selectAllTypes(/**Boolean*/ select) | 406 function selectAllTypes(/**Boolean*/ select) |
| 406 { | 407 { |
| 407 for (let typeNode = E("typeGroup").firstChild; typeNode; typeNode = typeNode.n
extSibling) | 408 for (let typeNode = E("typeGroup").firstChild; typeNode; typeNode = typeNode.n
extSibling) |
| 408 if (typeNode.getAttribute("disabled") != "true") | 409 if (typeNode.getAttribute("disabled") != "true") |
| 409 typeNode.checked = select; | 410 typeNode.checked = select; |
| 410 updateFilter(); | 411 updateFilter(); |
| 411 } | 412 } |
| OLD | NEW |