Finalize logging
This commit is contained in:
parent
435f2890c4
commit
21e24cc226
@ -8,7 +8,8 @@
|
|||||||
<div class="button flex-noshrink button-header"
|
<div class="button flex-noshrink button-header"
|
||||||
@click="hidePopup()"
|
@click="hidePopup()"
|
||||||
>
|
>
|
||||||
Close
|
<template v-if="logStringified">Finish logging</template>
|
||||||
|
<template v-else>Hide popup</template>
|
||||||
</div>
|
</div>
|
||||||
<!-- <div class="button flex-noshrink button-header"
|
<!-- <div class="button flex-noshrink button-header"
|
||||||
@click="stopLogging()"
|
@click="stopLogging()"
|
||||||
@ -77,7 +78,7 @@
|
|||||||
<div class="button button-bar button-primary"
|
<div class="button button-bar button-primary"
|
||||||
@click="exportAndQuit()"
|
@click="exportAndQuit()"
|
||||||
>
|
>
|
||||||
Export & quit
|
Export & finish
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
@ -96,7 +96,6 @@ class Logger {
|
|||||||
this.temp_disable = false;
|
this.temp_disable = false;
|
||||||
this.stopTime = this.conf.timeout ? performance.now() + (this.conf.timeout * 1000) : undefined;
|
this.stopTime = this.conf.timeout ? performance.now() + (this.conf.timeout * 1000) : undefined;
|
||||||
|
|
||||||
const ths = this;
|
|
||||||
const br = currentBrowser.firefox ? browser : chrome;
|
const br = currentBrowser.firefox ? browser : chrome;
|
||||||
|
|
||||||
br.storage.onChanged.addListener( (changes, area) => {
|
br.storage.onChanged.addListener( (changes, area) => {
|
||||||
@ -107,7 +106,11 @@ class Logger {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (changes['uwLogger'] && changes['uwLogger'].newValue) {
|
if (changes['uwLogger'] && changes['uwLogger'].newValue) {
|
||||||
ths.conf = JSON.parse(changes.uwLogger.newValue);
|
const newConf = JSON.parse(changes.uwLogger.newValue);
|
||||||
|
if (this.isContentScript && this.conf.allowLogging && !newConf.allowLogging) {
|
||||||
|
this.saveToVuex();
|
||||||
|
}
|
||||||
|
this.conf = newConf;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user