|
|
|
@ -111,7 +111,21 @@ function updateTrayMenu() {
|
|
|
|
|
|
|
|
|
|
|
|
const contextMenu = Menu.buildFromTemplate([
|
|
|
|
const contextMenu = Menu.buildFromTemplate([
|
|
|
|
{
|
|
|
|
{
|
|
|
|
label: "New Note",
|
|
|
|
label: "Show windows",
|
|
|
|
|
|
|
|
type: "checkbox",
|
|
|
|
|
|
|
|
checked: isVisible,
|
|
|
|
|
|
|
|
click: () => {
|
|
|
|
|
|
|
|
if (isVisible) {
|
|
|
|
|
|
|
|
mainWindow.hide();
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
mainWindow.show();
|
|
|
|
|
|
|
|
mainWindow.focus();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
{ type: "separator" },
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
label: "New note",
|
|
|
|
type: "normal",
|
|
|
|
type: "normal",
|
|
|
|
click: () => triggerKeyboardAction("createNoteIntoInbox")
|
|
|
|
click: () => triggerKeyboardAction("createNoteIntoInbox")
|
|
|
|
},
|
|
|
|
},
|
|
|
|
@ -132,20 +146,7 @@ function updateTrayMenu() {
|
|
|
|
},
|
|
|
|
},
|
|
|
|
{ type: "separator" },
|
|
|
|
{ type: "separator" },
|
|
|
|
{
|
|
|
|
{
|
|
|
|
label: isVisible ? "Hide" : "Show",
|
|
|
|
label: "Quit Trilium",
|
|
|
|
type: "normal",
|
|
|
|
|
|
|
|
click: () => {
|
|
|
|
|
|
|
|
if (isVisible) {
|
|
|
|
|
|
|
|
mainWindow.hide();
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
mainWindow.show();
|
|
|
|
|
|
|
|
mainWindow.focus();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
{ type: "separator" },
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
label: "Quit",
|
|
|
|
|
|
|
|
type: "normal",
|
|
|
|
type: "normal",
|
|
|
|
click: () => {
|
|
|
|
click: () => {
|
|
|
|
mainWindow.close();
|
|
|
|
mainWindow.close();
|
|
|
|
|