crimx / ext-saladict

🥗 All-in-one professional pop-up dictionary and page translator which supports multiple search modes, page translations, new word notebook and PDF selection searching.
https://saladict.crimx.com/
MIT License
11.8k stars 715 forks source link

[已解决]在独立窗口中搜索剪贴板内容 快捷键不生效 #2133

Open freemedom opened 7 months ago

freemedom commented 7 months ago

设备信息

描述问题

在独立窗口中搜索剪贴板内容 快捷键不生效

复现步骤

按设置好的快捷键,不弹出独立窗口

期待的正常行为

截图

额外信息

LY-must-win commented 7 months ago

换Edge吧老弟

captainwayland commented 7 months ago

换Edge吧老弟

系统win1122h2,edge浏览器版本 119.0.2151.72 (正式版本) (64 位) ,怎么设置无法在独立窗口中搜索剪贴板内容

LY-must-win commented 7 months ago

换Edge吧老弟

系统win1122h2,edge浏览器版本 119.0.2151.72 (正式版本) (64 位) ,怎么设置无法在独立窗口中搜索剪贴板内容

你在chrome怎么设置的,在Edge就怎么设置

freemedom commented 7 months ago

https://github.com/crimx/ext-saladict/issues/2089

freemedom commented 7 months ago

https://github.com/crimx/ext-saladict/issues/2067

freemedom commented 7 months ago

https://github.com/crimx/ext-saladict/issues/2075

WB-MKT commented 6 months ago

同样的bug

LY-must-win commented 6 months ago

同样的bug

查看之前设置的全局快捷键、独立窗口划词设置是不是还原了,一切设置完毕再重启电脑看一下。

WB-MKT commented 6 months ago

同样的bug

查看之前设置的全局快捷键、独立窗口划词设置是不是还原了,一切设置完毕再重启电脑看一下。

重新设置重启了还是不行。其他功能用快捷键没问题

WB-MKT commented 6 months ago

卸载重装后解决了问题

LY-must-win commented 6 months ago

同样的bug

查看之前设置的全局快捷键、独立窗口划词设置是不是还原了,一切设置完毕再重启电脑看一下。

重新设置重启了还是不行。其他功能用快捷键没问题

image image 终极办法,,重新安装一下chrome浏览器

卸载重装后解决了问题

还是浏览器本身的问题

freemedom commented 6 months ago

{ "height": 28, "left": -25600, "top": -25592, "width": 160 }

Invalid value for bounds. Bounds must be at least 50% within visible screen space.

这个left和top看起来有点奇怪

const a = window.appConfig.qssaSidebar是空字符串 ? await this.getSidebarRect(window.appConfig.qssaSidebar) : window.appConfig.qssaRectMemo && await this.getStorageRect() || this.getDefaultRect();

window.appConfig.qssaRectMemo是true && await this.getStorageRect()这个函数获取的值 || this.getDefaultRect();

const {qssaRect: e} = await o.c.local.get("qssaRect");

chrome.storage.local.get(function(result){console.log(result)}) 输出 { "lastCheckUpdate": 1703571510231, "qssaRect": { "height": 28, "left": -25600, "top": -25600, "width": 160 }, "titlebarOffset": { "main": -8, "panel": -8 } } 问题是这个qssaRect是怎么得到的

终于懂了。。。我猜是我曾经接过第二个屏幕导致的,然后把qssaRect的不太正常的值“记住了” image 然后 记住位置与大小


其实另外一个原因是 try { qsPanelWin = await browser.windows.create({ ...qsPanelRect, type: 'popup', url: browser.runtime.getURL( quick-search.html?sidebar=${window.appConfig.qssaSidebar}${wordString}${lastTabString} ) }) } catch (err) { browser.notifications.create({ type: 'basic', iconUrl: browser.runtime.getURL(assets/icon-128.png), title: Saladict, message: err.message, priority: 2, eventTime: Date.now() + 5000 }) }

browser.notifications 我的chrome不知道为什么notifications不能弹出windows右下的通知了(win设置里我关了忘了)。然后就没显示报错,还得让我找了一下逻辑