fileModel: Use GFile with URI as key
Part-of: <https://gitlab.gnome.org/Incubator/loupe/-/merge_requests/174>
This commit is contained in:
parent
3b0c32ecee
commit
032707a210
10 changed files with 164 additions and 188 deletions
|
|
@ -72,10 +72,8 @@ mod imp {
|
|||
fn open(&self, files: &[gio::File], _hint: &str) {
|
||||
let application = self.obj();
|
||||
for file in files {
|
||||
let Some(path) = file.path() else { log::error!("File has no path {}", file.uri()); return; };
|
||||
|
||||
let win = LpWindow::new(&*application);
|
||||
win.set_image_from_path(&path);
|
||||
win.set_image_from_file(&file);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue