mirror of
https://github.com/Rafostar/clapper.git
synced 2025-08-30 07:42:23 +02:00
Add support for keyboard shortcuts for menu items. Additionally enable a common Ctrl+O for opening new file(s) and Ctrl+U for opening an URI. Closes #45
20 lines
468 B
JavaScript
20 lines
468 B
JavaScript
const { GObject, Gtk } = imports.gi;
|
|
const Dialogs = imports.src.dialogs;
|
|
|
|
var actions = {
|
|
openLocal: {
|
|
run: (window) => new Dialogs.FileChooser(window),
|
|
accels: ['<Ctrl>O'],
|
|
},
|
|
openUri: {
|
|
run: (window) => new Dialogs.UriDialog(window),
|
|
accels: ['<Ctrl>U'],
|
|
},
|
|
prefs: {
|
|
run: (window) => new Dialogs.PrefsDialog(window),
|
|
},
|
|
about: {
|
|
run: (window) => new Dialogs.AboutDialog(window),
|
|
},
|
|
};
|