mirror of
https://github.com/gorhill/uBlock.git
synced 2024-10-06 09:37:12 +02:00
Remove unused code
This commit is contained in:
parent
f80fe365d3
commit
f20372cf73
@ -32,6 +32,15 @@
|
|||||||
</r:Description>
|
</r:Description>
|
||||||
</targetApplication>
|
</targetApplication>
|
||||||
|
|
||||||
|
<!-- Firefox for Android
|
||||||
|
<targetApplication>
|
||||||
|
<r:Description>
|
||||||
|
<id>{{aa3c5121-dab2-40e2-81ca-7ea25febc110}}</id>
|
||||||
|
<minVersion>24.0</minVersion>
|
||||||
|
<maxVersion>39.0</maxVersion>
|
||||||
|
</r:Description>
|
||||||
|
</targetApplication> -->
|
||||||
|
|
||||||
<!-- Thunderbird
|
<!-- Thunderbird
|
||||||
<targetApplication>
|
<targetApplication>
|
||||||
<r:Description>
|
<r:Description>
|
||||||
|
@ -792,17 +792,17 @@ vAPI.messaging.broadcast = function(message) {
|
|||||||
|
|
||||||
// This allows to avoid creating a closure for every single message which
|
// This allows to avoid creating a closure for every single message which
|
||||||
// expects an answer. Having a closure created each time a message is processed
|
// expects an answer. Having a closure created each time a message is processed
|
||||||
// has been always bothering me. Another benefit of the implementation here
|
// has been always bothering me. Another benefit of the implementation here
|
||||||
// is to reuse the callback proxy object, so less memory churning.
|
// is to reuse the callback proxy object, so less memory churning.
|
||||||
//
|
//
|
||||||
// https://developers.google.com/speed/articles/optimizing-javascript
|
// https://developers.google.com/speed/articles/optimizing-javascript
|
||||||
// "Creating a closure is significantly slower then creating an inner
|
// "Creating a closure is significantly slower then creating an inner
|
||||||
// function without a closure, and much slower than reusing a static
|
// function without a closure, and much slower than reusing a static
|
||||||
// function"
|
// function"
|
||||||
//
|
//
|
||||||
// http://hacksoflife.blogspot.ca/2015/01/the-four-horsemen-of-performance.html
|
// http://hacksoflife.blogspot.ca/2015/01/the-four-horsemen-of-performance.html
|
||||||
// "the dreaded 'uniformly slow code' case where every function takes 1%
|
// "the dreaded 'uniformly slow code' case where every function takes 1%
|
||||||
// of CPU and you have to make one hundred separate performance optimizations
|
// of CPU and you have to make one hundred separate performance optimizations
|
||||||
// to improve performance at all"
|
// to improve performance at all"
|
||||||
//
|
//
|
||||||
// http://jsperf.com/closure-no-closure/2
|
// http://jsperf.com/closure-no-closure/2
|
||||||
@ -844,9 +844,9 @@ CallbackWrapper.prototype.proxy = function(response) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Mark for reuse
|
// Mark for reuse
|
||||||
this.messageManager =
|
this.messageManager =
|
||||||
this.channelName =
|
this.channelName =
|
||||||
this.requestId =
|
this.requestId =
|
||||||
this.listenerId = null;
|
this.listenerId = null;
|
||||||
CallbackWrapper.junkyard.push(this);
|
CallbackWrapper.junkyard.push(this);
|
||||||
};
|
};
|
||||||
@ -1556,19 +1556,6 @@ vAPI.contextMenu.create = function(details, callback) {
|
|||||||
|
|
||||||
/******************************************************************************/
|
/******************************************************************************/
|
||||||
|
|
||||||
vAPI.contextMenu.remove = function() {
|
|
||||||
for ( var win of vAPI.tabs.getWindows() ) {
|
|
||||||
this.unregister(win.document);
|
|
||||||
}
|
|
||||||
|
|
||||||
this.menuItemId = null;
|
|
||||||
this.menuLabel = null;
|
|
||||||
this.contexts = null;
|
|
||||||
this.onCommand = null;
|
|
||||||
};
|
|
||||||
|
|
||||||
/******************************************************************************/
|
|
||||||
|
|
||||||
vAPI.lastError = function() {
|
vAPI.lastError = function() {
|
||||||
return null;
|
return null;
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user