usercss install: reuse current tab for editor when possible
This commit is contained in:
parent
cbe90272b9
commit
b762f48135
|
@ -198,10 +198,13 @@
|
||||||
|
|
||||||
updateMeta(style);
|
updateMeta(style);
|
||||||
|
|
||||||
sendMessage({method: 'openEditor', id: style.id});
|
if (!liveReload && !prefs.get('openEditInWindow')) {
|
||||||
|
chrome.tabs.update({url: '/edit.html?id=' + style.id});
|
||||||
|
} else {
|
||||||
|
BG.openEditor(style.id);
|
||||||
if (!liveReload) {
|
if (!liveReload) {
|
||||||
chrome.runtime.sendMessage({method: 'closeTab'});
|
closeCurrentTab();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
window.dispatchEvent(new CustomEvent('installed'));
|
window.dispatchEvent(new CustomEvent('installed'));
|
||||||
|
|
Loading…
Reference in New Issue
Block a user