mirror of https://github.com/gorhill/uBlock.git
Firefox: get the version number from the fragment
This commit is contained in:
parent
e9b816f585
commit
21b42304fe
|
@ -60,7 +60,7 @@ function startup(data, reason) {
|
||||||
);
|
);
|
||||||
bgProcess.setAttribute(
|
bgProcess.setAttribute(
|
||||||
'src',
|
'src',
|
||||||
'chrome://' + hostName + '/content/background.html'
|
'chrome://' + hostName + '/content/background.html#' + data.version
|
||||||
);
|
);
|
||||||
|
|
||||||
restartListener.messageManager.addMessageListener(
|
restartListener.messageManager.addMessageListener(
|
||||||
|
@ -104,13 +104,15 @@ function shutdown(data, reason) {
|
||||||
|
|
||||||
bgProcess.parentNode.removeChild(bgProcess);
|
bgProcess.parentNode.removeChild(bgProcess);
|
||||||
|
|
||||||
// Remove the restartObserver only when the extension is being disabled
|
if ( data === undefined ) {
|
||||||
if ( data !== undefined ) {
|
return;
|
||||||
restartListener.messageManager.removeMessageListener(
|
|
||||||
hostName + '-restart',
|
|
||||||
restartListener
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Remove the restartObserver only when the extension is being disabled
|
||||||
|
restartListener.messageManager.removeMessageListener(
|
||||||
|
hostName + '-restart',
|
||||||
|
restartListener
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
/******************************************************************************/
|
/******************************************************************************/
|
||||||
|
|
|
@ -19,7 +19,7 @@
|
||||||
<r:Description>
|
<r:Description>
|
||||||
<id>{{ec8030f7-c20a-464f-9b0e-13a3a9e97384}}</id>
|
<id>{{ec8030f7-c20a-464f-9b0e-13a3a9e97384}}</id>
|
||||||
<minVersion>24.0</minVersion>
|
<minVersion>24.0</minVersion>
|
||||||
<maxVersion>38.0</maxVersion>
|
<maxVersion>39.0</maxVersion>
|
||||||
</r:Description>
|
</r:Description>
|
||||||
</targetApplication>
|
</targetApplication>
|
||||||
|
|
||||||
|
@ -28,8 +28,17 @@
|
||||||
<r:Description>
|
<r:Description>
|
||||||
<id>{{92650c4d-4b8e-4d2a-b7eb-24ecf4f6b63a}}</id>
|
<id>{{92650c4d-4b8e-4d2a-b7eb-24ecf4f6b63a}}</id>
|
||||||
<minVersion>2.21</minVersion>
|
<minVersion>2.21</minVersion>
|
||||||
<maxVersion>2.35</maxVersion>
|
<maxVersion>2.36</maxVersion>
|
||||||
</r:Description>
|
</r:Description>
|
||||||
</targetApplication>
|
</targetApplication>
|
||||||
|
|
||||||
|
<!-- Thunderbird
|
||||||
|
<targetApplication>
|
||||||
|
<r:Description>
|
||||||
|
<id>{{3550f703-e582-4d05-9a08-453d09bdfdc6}}</id>
|
||||||
|
<minVersion>24.0</minVersion>
|
||||||
|
<maxVersion>39.0</maxVersion>
|
||||||
|
</r:Description>
|
||||||
|
</targetApplication> -->
|
||||||
</r:Description>
|
</r:Description>
|
||||||
</r:RDF>
|
</r:RDF>
|
||||||
|
|
|
@ -43,10 +43,9 @@ vAPI.firefox = true;
|
||||||
|
|
||||||
/******************************************************************************/
|
/******************************************************************************/
|
||||||
|
|
||||||
// TODO: read these data from somewhere...
|
|
||||||
vAPI.app = {
|
vAPI.app = {
|
||||||
name: 'µBlock',
|
name: 'µBlock',
|
||||||
version: '0.8.6.0'
|
version: location.hash.slice(1)
|
||||||
};
|
};
|
||||||
|
|
||||||
/******************************************************************************/
|
/******************************************************************************/
|
||||||
|
|
Loading…
Reference in New Issue