Skip to content

Commit

Permalink
修复,锁定组的情况下,开启“打开标签并将其从标签列表中删除”会被删除的情况,锁定了就不能删了,除非解锁
Browse files Browse the repository at this point in the history
  • Loading branch information
scoful committed Jan 6, 2024
1 parent 5fa78da commit 0af2cab
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions js/workbench.js
Original file line number Diff line number Diff line change
Expand Up @@ -1943,12 +1943,18 @@ https://www.google.com | Google
}, group.tabs().map(function (tab, ii) {
return m('li.li-hover.li-standard', [m('span' + deleteLinkClass, {
onclick: function () {
tabs.vm.rmTab(i, ii);
if (isLock) {
showAlert(`${chrome.i18n.getMessage("showError")}`, `${chrome.i18n.getMessage("cannotDelete")}`)
} else {
tabs.vm.rmTab(i, ii);
}
}
}), m('span.link', {
title: tab.title + "\n" + tab.url, onclick: function () {
if (opts.deleteTabOnOpen === 'yes') {
tabs.vm.rmTab(i, ii);
if (!isLock) {
tabs.vm.rmTab(i, ii);
}
}
chrome.tabs.create({
url: tab.url, active: false
Expand Down

0 comments on commit 0af2cab

Please sign in to comment.