Open files via native file chooser

This commit is contained in:
Rafostar
2020-10-26 21:25:13 +01:00
parent 556809c1f4
commit ac06e84851
6 changed files with 81 additions and 4 deletions

View File

@@ -1,8 +1,10 @@
const { GObject, Gst, Gtk } = imports.gi;
const Misc = imports.clapper_src.misc;
const Prefs = imports.clapper_src.prefs;
const { FileChooser } = imports.clapper_src.filechooser;
var actions = [
openLocal,
prefs,
about,
];
@@ -11,6 +13,12 @@ var accels = [
['app.quit', ['q']],
];
function openLocal(window, appName)
{
let fileChooser = new FileChooser(window);
fileChooser.present();
}
function prefs(window, appName)
{
let prefsWidget = Prefs.buildPrefsWidget();