Skip to content

Commit

Permalink
Merge tag '1.12.5rc0' into safari
Browse files Browse the repository at this point in the history
# Conflicts:
#	dist/README.md
#	src/_locales/gl/messages.json
#	src/_locales/sq/messages.json
  • Loading branch information
el1t committed Jun 4, 2017
2 parents 0c4ed01 + 4ea6138 commit 19b8144
Show file tree
Hide file tree
Showing 99 changed files with 4,171 additions and 3,183 deletions.
20 changes: 10 additions & 10 deletions assets/assets.json
Original file line number Diff line number Diff line change
Expand Up @@ -78,10 +78,10 @@
"content": "filters",
"group": "ads",
"off": true,
"title": "Adblock Protector List",
"contentURL": "https://raw.githubusercontent.com/jspenguin2017/AdBlockProtector/master/AdBlockProtectorList.txt",
"supportURL": "https://github.com/jspenguin2017/AdBlockProtector",
"instructionURL": "https://jspenguin2017.github.io/AdBlockProtector/"
"title": "uBlock Protector List",
"contentURL": "https://raw.githubusercontent.com/jspenguin2017/uBlockProtector/master/uBlockProtectorList.txt",
"supportURL": "https://github.com/jspenguin2017/uBlockProtector/blob/master/CONTRIBUTING.MD",
"instructionURL": "https://jspenguin2017.github.io/uBlockProtector/"
},
"awrl-0": {
"content": "filters",
Expand Down Expand Up @@ -175,7 +175,7 @@
"assets/thirdparties/mirror1.malwaredomains.com/files/justdomains.txt",
"assets/thirdparties/mirror1.malwaredomains.com/files/justdomains"
],
"supportURL": "http://www.malwaredomains.com/"
"supportURL": "https://www.malwaredomains.com/"
},
"malware-2": {
"content": "filters",
Expand All @@ -186,7 +186,7 @@
"https://mirror1.malwaredomains.com/files/immortal_domains.txt",
"https://mirror.cedia.org.ec/malwaredomains/immortal_domains.txt"
],
"supportURL": "http://www.malwaredomains.com/"
"supportURL": "https://www.malwaredomains.com/"
},
"disconnect-malware": {
"content": "filters",
Expand Down Expand Up @@ -379,14 +379,14 @@
"title": "FIN: Finnish Addition to Easylist",
"lang": "fi",
"contentURL": "https://adb.juvander.net/Finland_adb.txt",
"supportURL": "http://www.juvander.fi/AdblockFinland"
"supportURL": "https://www.juvander.fi/AdblockFinland"
},
"FRA-0": {
"content": "filters",
"group": "regions",
"off": true,
"title": "FRA: EasyList Liste FR",
"lang": "fr",
"lang": "ar fr",
"contentURL": "https://easylist-downloads.adblockplus.org/liste_fr.txt",
"supportURL": "https://forums.lanik.us/viewforum.php?f=91"
},
Expand Down Expand Up @@ -435,8 +435,8 @@
"off": true,
"title": "ISL: Icelandic ABP List",
"lang": "is",
"contentURL": "http://adblock.gardar.net/is.abp.txt",
"supportURL": "http://adblock.gardar.net/"
"contentURL": "https://adblock.gardar.net/is.abp.txt",
"supportURL": "https://adblock.gardar.net/"
},
"ISR-0": {
"content": "filters",
Expand Down
49 changes: 49 additions & 0 deletions dist/description/description-ka.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
An efficient blocker: easy on memory and CPU footprint, and yet can load and enforce thousands more filters than other popular blockers out there.

Illustrated overview of its efficiency: https://github.com/gorhill/uBlock/wiki/uBlock-vs.-ABP:-efficiency-compared

Usage: The big power button in the popup is to permanently disable/enable uBlock for the current web site. It applies to the current web site only, it is not a global power button.

***

Flexible, it's more than an "ad blocker": it can also read and create filters from hosts files.

Out of the box, these lists of filters are loaded and enforced:

- EasyList
- Peter Lowe’s Ad server list
- EasyPrivacy
- Malware domains

More lists are available for you to select if you wish:

- Fanboy’s Enhanced Tracking List
- Dan Pollock’s hosts file
- hpHosts’s Ad and tracking servers
- MVPS HOSTS
- Spam404
- And many others

Of course, the more filters enabled, the higher the memory footprint. Yet, even after adding Fanboy's two extra lists, hpHosts’s Ad and tracking servers, uBlock still has a lower memory footprint than other very popular blockers out there.

Also, be aware that selecting some of these extra lists may lead to higher likelihood of web site breakage -- especially those lists which are normally used as hosts file.

***

Without the preset lists of filters, this extension is nothing. So if ever you really do want to contribute something, think about the people working hard to maintain the filter lists you are using, which were made available to use by all for free.

***

Free.
Open source with public license (GPLv3)
For users by users.

Contributors @ Github: https://github.com/gorhill/uBlock/graphs/contributors
Contributors @ Crowdin: https://crowdin.net/project/ublock

***

It's quite an early version, keep this in mind when you review.

Project change log:
https://github.com/gorhill/uBlock/releases
14 changes: 7 additions & 7 deletions dist/description/description-ms.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,20 @@ Kecekapan yang digambarkan:
https://github.com/gorhill/uBlock/wiki/uBlock-vs.-ABP:-efficiency-compared
(Bahasa English)

Cara menguna: Butang besar di dalam popup adalah untuk mengaktifkan/menyahaktifkan uBlock bagi laman web yang terkini. It applies to the current web site only, it is not a global power button.
Cara menguna: Butang besar di dalam popup adalah untuk mengaktifkan/menyahaktifkan uBlock bagi laman web yang terkini. Ini hanya boleh diggunakan dalam laman web ini sahaja, ini bukan satu butang kuasa global.

***

Flexible, it's more than an "ad blocker": it can also read and create filters from hosts files.
Fleksibel, ini lebih daripada satu "penghalang": ia boleh membaca dan menghasilkan penapis daripada fail hosts.

Senarai penapis yang telah dimuatkan and dikuatkuasakan adalah yang berikutnya:
Senarai penapis yang telah dimuatkan dan dikuatkuasakan adalah seperti berikut:

- EasyList
- Peter Lowe’s Ad server list
- EasyPrivacy
- Malware domains
- Domain mengandungi malware

Banyak lagi senarai penapis yang boleh anda pilih seperti:
Banyak lagi senarai penapis yang boleh anda pilih jika anda ingin seperti:

- Fanboy’s Enhanced Tracking List
- Dan Pollock’s hosts file
Expand All @@ -26,9 +26,9 @@ Banyak lagi senarai penapis yang boleh anda pilih seperti:
- Spam404
- dan banyak lagi

Of course, the more filters enabled, the higher the memory footprint. Yet, even after adding Fanboy's two extra lists, hpHostss Ad and tracking servers, uBlock still has a lower memory footprint than other very popular blockers out there.
Sudah tentu, dengan lebih banyak penapis yang diaktifkan, jejakan memori lebih tinggi. Lagi, walaupun sudah menambah dua senarai tambahan Fanboy, hpHosts's Ad and tracking servers, uBlock masih kekal mempunyai jejakan memori yang rendah berbanding dengan penghalang yang terkenal di luar sana.

Also, be aware that selecting some of these extra lists may lead to higher likelihood of web site breakage -- especially those lists which are normally used as hosts file.
Juga, berhati-hati memilih sesetengah senarai tambahan yang kemungkinan besar membawa kepada kerosakan laman web -- terutamanya senarai yang biasanya digunakan sebagai fail hosts.

***

Expand Down
22 changes: 21 additions & 1 deletion platform/chromium/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,28 @@
"manifest_version": 2,

"name": "uBlock Origin",
"version": "1.12.3.1",
"version": "1.12.5.100",

"commands": {
"launch-element-zapper": {
"suggested_key": {
"default": "Alt+Z"
},
"description": "__MSG_popupTipZapper__"
},
"launch-element-picker": {
"suggested_key": {
"default": "Alt+X"
},
"description": "__MSG_popupTipPicker__"
},
"launch-logger": {
"suggested_key": {
"default": "Alt+L"
},
"description": "__MSG_popupTipLog__"
}
},
"default_locale": "en",
"description": "__MSG_extShortDesc__",
"icons": {
Expand Down
158 changes: 1 addition & 157 deletions platform/chromium/polyfill.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*******************************************************************************
uBlock Origin - a browser extension to block requests.
Copyright (C) 2014-2016 The uBlock Origin authors
Copyright (C) 2014-2017 The uBlock Origin authors
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
Expand Down Expand Up @@ -72,159 +72,3 @@ var objectAssign = Object.assign || function(target, source) {
};

/******************************************************************************/

// https://github.com/gorhill/uBlock/issues/1070
// https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Set#Browser_compatibility
// This polyfill is designed to fulfill *only* what uBlock Origin needs -- this
// is not an accurate API of the real Set() type.

if ( self.Set instanceof Function === false ) {
self.Set = function(iter) {
this.clear();
if ( Array.isArray(iter) ) {
for ( var i = 0, n = iter.length; i < n; i++ ) {
this.add(iter[i]);
}
return;
}
};

self.Set.polyfill = true;

self.Set.prototype.clear = function() {
this._set = Object.create(null);
this.size = 0;
// Iterator stuff
this._values = undefined;
this._i = undefined;
this.value = undefined;
this.done = true;
};

self.Set.prototype.add = function(k) {
if ( this._set[k] === undefined ) {
this._set[k] = true;
this.size += 1;
}
return this;
};

self.Set.prototype.delete = function(k) {
if ( this._set[k] !== undefined ) {
delete this._set[k];
this.size -= 1;
return true;
}
return false;
};

self.Set.prototype.has = function(k) {
return this._set[k] !== undefined;
};

self.Set.prototype.next = function() {
if ( this._i < this.size ) {
this.value = this._values[this._i++];
} else {
this._values = undefined;
this.value = undefined;
this.done = true;
}
return this;
};

self.Set.prototype.values = function() {
this._values = Object.keys(this._set);
this._i = 0;
this.value = undefined;
this.done = false;
return this;
};
}

/******************************************************************************/

// https://github.com/gorhill/uBlock/issues/1070
// https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Set#Browser_compatibility
// This polyfill is designed to fulfill *only* what uBlock Origin needs -- this
// is not an accurate API of the real Map() type.

if ( self.Map instanceof Function === false ) {
self.Map = function(iter) {
this.clear();
if ( Array.isArray(iter) ) {
for ( var i = 0, n = iter.length, entry; i < n; i++ ) {
entry = iter[i];
this.set(entry[0], entry[1]);
}
return;
}
};

self.Map.polyfill = true;

self.Map.prototype.clear = function() {
this._map = Object.create(null);
this.size = 0;
// Iterator stuff
this._keys = undefined;
this._i = undefined;
this.value = undefined;
this.done = true;
};

self.Map.prototype.delete = function(k) {
if ( this._map[k] !== undefined ) {
delete this._map[k];
this.size -= 1;
return true;
}
return false;
};

self.Map.prototype.entries = function() {
this._keys = Object.keys(this._map);
this._i = 0;
this.value = [ undefined, undefined ];
this.done = false;
return this;
};

self.Map.prototype.get = function(k) {
return this._map[k];
};

self.Map.prototype.has = function(k) {
return this._map[k] !== undefined;
};

self.Map.prototype.next = function() {
if ( this._i < this.size ) {
var key = this._keys[this._i++];
this.value[0] = key;
this.value[1] = this._map[key];
} else {
this._keys = undefined;
this.value = undefined;
this.done = true;
}
return this;
};

self.Map.prototype.set = function(k, v) {
if ( v !== undefined ) {
if ( this._map[k] === undefined ) {
this.size += 1;
}
this._map[k] = v;
} else {
if ( this._map[k] !== undefined ) {
this.size -= 1;
}
delete this._map[k];
}
return this;
};
}

/******************************************************************************/
13 changes: 12 additions & 1 deletion platform/chromium/vapi-background.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,13 @@ var chrome = self.chrome;
var manifest = chrome.runtime.getManifest();

vAPI.chrome = true;
vAPI.cantWebsocket = true;
vAPI.chromiumVersion = (function(){
var matches = /\bChrom(?:e|ium)\/(\d+)\b/.exec(navigator.userAgent);
return matches !== null ? parseInt(matches[1], 10) : NaN;
})();
vAPI.cantWebsocket =
chrome.webRequest.ResourceType instanceof Object === false ||
chrome.webRequest.ResourceType.WEBSOCKET !== 'websocket';

var noopFunc = function(){};

Expand Down Expand Up @@ -1186,6 +1192,11 @@ vAPI.contextMenu = {
/******************************************************************************/
/******************************************************************************/

vAPI.commands = chrome.commands;

/******************************************************************************/
/******************************************************************************/

vAPI.lastError = function() {
return chrome.runtime.lastError;
};
Expand Down
Loading

2 comments on commit 19b8144

@ruchernchong
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would the official Safari Extension gallery gets updated frequently?

@el1t
Copy link
Owner Author

@el1t el1t commented on 19b8144 Jun 21, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, I will try to upload every release—however, Apple hasn't updated the listed extension yet. I'll post in the issue when they do.

Please sign in to comment.