提交 2b3caaf1 编写于 作者: 璃白.'s avatar 璃白. 🌻

release0.0.4

上级 fe646862
{
"name": "Quicker",
"version": "0.0.3",
"version": "0.0.4",
"author": "libai",
"description": "An electron-vue project",
"license": null,
......@@ -17,7 +17,7 @@
"build": {
"asar": true,
"productName": "Quicker",
"appId": "com.muwoo.rubick",
"appId": "com.layyback.quicker",
"compression": "maximum",
"directories": {
"output": "build"
......
......@@ -20,7 +20,7 @@ module.exports = () => {
resizable: true,
width: 920,
frame: false,
backgroundColor: "#fff",
// backgroundColor: "#fff",
title: "拉比克",
show: true,
skipTaskbar: true,
......@@ -57,7 +57,7 @@ module.exports = () => {
});
win.on("blur", () => {
const childWindows = win.getChildWindows();
if (!childWindows.length) win.hide();
// if (!childWindows.length) win.hide();
});
};
......
......@@ -12,7 +12,7 @@ const defaultConfigForAnyPlatform = {
shortCut: {
showAndHidden: "Option+R",
separate: "Ctrl+D",
quit: "Shift+Escape"
quit: "Shift+Escape",
},
common: {
start: true,
......
......@@ -62,6 +62,7 @@ class Listener {
registerShortCut(mainWindow) {
const config = global.opConfig.get();
globalShortcut.unregisterAll();
this.registerQuitPluginShortCut(mainWindow)
// 注册偏好快捷键
globalShortcut.register(config.perf.shortCut.showAndHidden, () => {
const { x, y } = screen.getCursorScreenPoint();
......@@ -124,7 +125,8 @@ class Listener {
this.setAutoLogin();
this.colorPicker();
this.initPlugin();
this.initPlugin(mainWindow);
this.registerQuitPluginShortCut(mainWindow)
this.lockScreen();
this.separate();
this.initCapture();
......@@ -219,7 +221,7 @@ class Listener {
if (win === null || win === undefined) {
login.createWindow(mainWindow);
} else {
win.show()
win.show();
}
});
}
......@@ -305,12 +307,18 @@ class Listener {
});
}
initPlugin() {
initPlugin(mainWindow) {
ipcMain.on("optionPlugin", (e, args) => {
this.optionPlugin = args;
});
}
registerQuitPluginShortCut(mainWindow) {
globalShortcut.register("Esc", () => {
mainWindow.webContents.send("quitPlugin");
});
}
lockScreen() {
// 锁屏
ipcMain.on("lock-screen", () => {
......
......@@ -29,6 +29,7 @@ class initApp {
this.onReady();
this.onRunning();
this.onQuit();
// main.registerQuitPluginShortCut()
}
}
......
......@@ -186,10 +186,18 @@ export default {
pluginInfo: pluginInfo
});
};
// document.addEventListener("keydown", e => {
// console.log(e);
// if (e.keyCode === 27) {
// this.closeTag();
// this.changeMode("view");
// }
// });
},
mounted() {
ipcRenderer.on("init-rubick", this.closeTag);
ipcRenderer.on("new-window", this.newWindow);
ipcRenderer.on("quitPlugin", this.quitPlugin);
// 超级面板打开插件
ipcRenderer.on("superPanel-openPlugin", (e, args) => {
this.closeTag();
......@@ -367,11 +375,14 @@ export default {
return `<div>${result[0]}</div>`;
}
},
quitPlugin() {
this.closeTag();
this.changeMode("view");
},
checkNeedInit(e) {
// 如果搜索栏无内容,且按了删除键,则清空 tag
if (this.searchValue === "" && e.keyCode === 8) {
this.closeTag();
this.changeMode("view");
this.quitPlugin();
}
},
changePath({ key }) {
......
......@@ -39,7 +39,8 @@ export default {
};
},
mounted() {
this.setSubPlaceHolder("按 ⌫ 键退出插件");
this.setSubPlaceHolder("按 Esc 键退出插件");
// this.setSubPlaceHolder("按 ⌫ 键退出插件");
this.webview = document.querySelector("webview");
// if (!this.webview) return;
this.webview.addEventListener("dom-ready", () => {
......
......@@ -49,7 +49,8 @@ export default {
}
},
mounted() {
this.setSubPlaceHolder("按 ⌫ 键退出");
this.setSubPlaceHolder("按 Esc 键退出");
// this.setSubPlaceHolder("按 ⌫ 键退出");
},
computed: {
...mapState("main", [
......
......@@ -42,7 +42,7 @@
{{ config.perf.shortCut.showAndHidden }}
</div>
</div>
<div class="settings-item-li">
<!-- <div class="settings-item-li">
<div class="label">插件分离快捷键</div>
<div
class="value"
......@@ -51,8 +51,8 @@
>
{{ config.perf.shortCut.separate }}
</div>
</div>
<div class="settings-item-li">
</div> -->
<!-- <div class="settings-item-li">
<div class="label">返回主界面</div>
<div
class="value"
......@@ -61,7 +61,7 @@
>
{{ config.perf.shortCut.quit }}
</div>
</div>
</div> -->
</div>
<div class="setting-item">
<div class="title">通用</div>
......@@ -260,6 +260,9 @@ export default {
this.config.perf.shortCut[key] = compose;
change = true;
}
console.log(this.config.perf.shortCut.showAndHidden);
this.saveConfig();
},
addConfig() {
this.config.global.push({
......
......@@ -290,7 +290,7 @@ const actions = {
/**
* @param {Object} payload payload.filePath为配置文件的绝对路径。payload.value为搜索栏文字值。
*/
async onSearch({ commit }, payload) {
async onSearch({ commit, getters }, payload) {
if (state.selected && state.selected.key !== "plugin-container") {
commit("commonUpdate", { searchValue: "" });
return;
......
......@@ -62,7 +62,7 @@
text-decoration: none;
cursor: pointer;
position: relative;
border-bottom: 1px dashed;
border-bottom: 1px dashed #fc5531;
padding-bottom: 2px;
box-sizing: border-box;
color: inherit;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册