Skip to content

Commit

Permalink
added a keyword to save as functions for the search and run tool
Browse files Browse the repository at this point in the history
  • Loading branch information
M-Wicenec committed Nov 8, 2024
1 parent 24e3a05 commit dfb5d24
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/KeyboardShortcut.ts
Original file line number Diff line number Diff line change
Expand Up @@ -256,7 +256,7 @@ export class KeyboardShortcut {
new KeyboardShortcut("add_graph_nodes_to_palette", "Add graph nodes to palette", [new Key("a")], "keydown", true, false, ['template','canvas'], KeyboardShortcut.true, KeyboardShortcut.allowPaletteEditing, KeyboardShortcut.allowPaletteEditing, (eagle): void => {eagle.addGraphNodesToPalette();}),
new KeyboardShortcut("insert_graph_from_local_disk", "Insert graph from local disk", [new Key("i")], "keydown", true, false, ['canvas','subGraph','upload'], KeyboardShortcut.true, KeyboardShortcut.allowGraphEditing, KeyboardShortcut.allowGraphEditing, (eagle): void => {eagle.getGraphFileToInsert();}),
new KeyboardShortcut("save_graph", "Save Graph", [new Key("s")], "keydown", true, false, ['canvas','commit','github','repository','gitlab'], KeyboardShortcut.true, KeyboardShortcut.allowGraphEditing, KeyboardShortcut.allowGraphEditing, (eagle): void => {eagle.saveGraph();}),
new KeyboardShortcut("save_as_graph", "Save Graph As", [new Key("s", KeyboardShortcut.Modifier.Shift)], "keydown", true, false, ['download','canvas'], KeyboardShortcut.true, KeyboardShortcut.allowGraphEditing, KeyboardShortcut.allowGraphEditing, (eagle): void => {eagle.saveGraphAs()}),
new KeyboardShortcut("save_as_graph", "Save Graph As", [new Key("s", KeyboardShortcut.Modifier.Shift)], "keydown", true, false, ['download','canvas','save as '], KeyboardShortcut.true, KeyboardShortcut.allowGraphEditing, KeyboardShortcut.allowGraphEditing, (eagle): void => {eagle.saveGraphAs()}),
new KeyboardShortcut("deploy_translator", "Generate PGT Using Default Algorithm", [new Key("d", KeyboardShortcut.Modifier.Shift)], "keydown", true, false, ['deploy','translate','translator'], KeyboardShortcut.true, KeyboardShortcut.true, KeyboardShortcut.true, (eagle): void => { eagle.deployDefaultTranslationAlgorithm(); }),
new KeyboardShortcut("delete_selection", "Delete Selection", [new Key("Delete"), new Key("Backspace")], "keydown", true, false, ['remove'], KeyboardShortcut.true, KeyboardShortcut.allowGraphEditing, KeyboardShortcut.allowGraphEditing, (eagle): void => {eagle.deleteSelection(false, false, true);}),
new KeyboardShortcut("delete_selection_except_children", "Delete Without Children", [new Key("Backspace", KeyboardShortcut.Modifier.Shift), new Key("Delete", KeyboardShortcut.Modifier.Shift)], "keydown", true, false, ['remove'], KeyboardShortcut.true, KeyboardShortcut.allowGraphEditing, KeyboardShortcut.allowGraphEditing, (eagle): void => {eagle.deleteSelection(false, false, false);}),
Expand All @@ -272,7 +272,7 @@ export class KeyboardShortcut {
new KeyboardShortcut("toggle_left_window", "Toggle left window", [new Key("ArrowLeft")], "keydown", true, false, ['close','open'], KeyboardShortcut.true, KeyboardShortcut.allowPaletteEditing, function(){return Setting.findValue(Setting.ALLOW_PALETTE_EDITING) || Setting.findValue(Setting.ALLOW_GRAPH_EDITING)}, (eagle): void => {SideWindow.toggleShown('left')}),
new KeyboardShortcut("toggle_right_window", "Toggle right window", [new Key("ArrowRight")], "keydown", true, false, ['close','open'], KeyboardShortcut.true, KeyboardShortcut.true, KeyboardShortcut.true, (eagle): void => {SideWindow.toggleShown('right')}),
new KeyboardShortcut("toggle_bottom_window", "Toggle bottom window", [new Key("ArrowDown")], "keydown", true, false, ['close','open'], KeyboardShortcut.true, KeyboardShortcut.true, KeyboardShortcut.true, (eagle): void => {SideWindow.toggleShown('bottom')}),
new KeyboardShortcut("toggle_both_window", "Toggle both windows", [new Key("ArrowUp")], "keydown", true, false, ['close','open'], KeyboardShortcut.true, function(){return Setting.findValue(Setting.ALLOW_PALETTE_EDITING) || Setting.findValue(Setting.ALLOW_GRAPH_EDITING)}, function(){return Setting.findValue(Setting.ALLOW_PALETTE_EDITING) || Setting.findValue(Setting.ALLOW_GRAPH_EDITING)}, (eagle): void => {eagle.toggleWindows();}),
new KeyboardShortcut("toggle_all_window", "Toggle all windows", [new Key("ArrowUp")], "keydown", true, false, ['close','open'], KeyboardShortcut.true, function(){return Setting.findValue(Setting.ALLOW_PALETTE_EDITING) || Setting.findValue(Setting.ALLOW_GRAPH_EDITING)}, function(){return Setting.findValue(Setting.ALLOW_PALETTE_EDITING) || Setting.findValue(Setting.ALLOW_GRAPH_EDITING)}, (eagle): void => {eagle.toggleWindows();}),
new KeyboardShortcut("open_settings", "Open setting", [new Key("o")], "keydown", true, false, ['menu','options'], KeyboardShortcut.true, KeyboardShortcut.true, KeyboardShortcut.true, (eagle): void => {eagle.smartToggleModal('settingsModal');}),
new KeyboardShortcut("open_help", "Open Online Documentation", [new Key("h")], "keydown", true, false, ['read me','guide','documentation'], KeyboardShortcut.true, KeyboardShortcut.true, KeyboardShortcut.true, (eagle): void => {eagle.onlineDocs();}),
new KeyboardShortcut("open_keyboard_shortcut_modal", "Open Keyboard Shortcut Modal", [new Key("k")], "keydown", true, false, ['shortcuts'], KeyboardShortcut.true, KeyboardShortcut.true, KeyboardShortcut.true, (eagle): void => {eagle.smartToggleModal('shortcutsModal')}),
Expand Down Expand Up @@ -307,7 +307,7 @@ export class KeyboardShortcut {
KeyboardShortcut.QUICK_ACTION("graphConfigTut", "Start Graph Configuration Tutorial", [], (eagle): void => {TutorialSystem.initiateTutorial('Graph Configurations');}),
KeyboardShortcut.QUICK_ACTION("savePaletteLocally", "Save Palette Locally", [], (eagle): void => {eagle.saveFileToLocal(Eagle.FileType.Palette);}),
KeyboardShortcut.QUICK_ACTION("createNewPaletteFromJson", "Create New Palette From Json", [], (eagle): void => {eagle.newPaletteFromJson();}),
KeyboardShortcut.QUICK_ACTION("savePaletteAs", "Save Palette To Git", [], (eagle): void => {eagle.commitToGitAs(Eagle.FileType.Palette);}),
KeyboardShortcut.QUICK_ACTION("savePaletteAs", "Save Palette To Git", ['save as '], (eagle): void => {eagle.commitToGitAs(Eagle.FileType.Palette);}),
KeyboardShortcut.QUICK_ACTION("loadFromRepository", "Load From Repository", [], (eagle): void => {SideWindow.setShown('right',true);eagle.changeRightWindowMode(Eagle.RightWindowMode.Repository);}),
KeyboardShortcut.QUICK_ACTION("createNewGraphFromJson", "Create New Graph From Json", [], (eagle): void => {eagle.newLogicalGraphFromJson();}),
KeyboardShortcut.QUICK_ACTION("addToGraphFromJson", "Add To Graph From Json", [], (eagle): void => {eagle.addToGraphFromJson();}),
Expand Down

0 comments on commit dfb5d24

Please sign in to comment.