Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"Open file" dialog closes by itself after a few seconds #1007

Closed
Oberonc opened this issue Mar 29, 2023 · 1 comment
Closed

"Open file" dialog closes by itself after a few seconds #1007

Oberonc opened this issue Mar 29, 2023 · 1 comment
Labels
bug Something isn't working

Comments

@Oberonc
Copy link

Oberonc commented Mar 29, 2023

I've cloned the GTK4 branch and tested it a bit.
When I try to open a book by clicking the "Open.." in the menu to to open the "Open file" dialog, said dialog closes by itself after 10 seconds (doesn't matter if I interacted with it or not)

  • Foliate version: gtk4 branch
  • OS/Distribution and version: Linux from scratch
  • Desktop environment: GNOME 43
  • Installation method: cloned, installed into a folder under home directory and manually run using "GSETTINGS_SCHEMA_DIR=share/glib-2.0/schemas ./bin/foliate".
    I also tried running in place with same results.
@Oberonc Oberonc added the bug Something isn't working label Mar 29, 2023
@johnfactotum
Copy link
Owner

Yeah, I think it's probably a GJS bug. It can be reproduced with the following script:

#!/usr/bin/gjs
imports.gi.versions.Gtk = '4.0'
const { Gtk } = imports.gi

const app = new Gtk.Application({ application_id: 'org.gtk.Example' })
app.connect('activate', () => {
    const win = new Gtk.ApplicationWindow({ application: app })
    win.present()
    const dialog = new Gtk.FileChooserNative({ transient_for: win })
    dialog.show()
})
app.run([])

It doesn't seem to happen with Gtk.FileDialog, though. And since Gtk.FileChooserNative is deprecated, anyway, it should probably just switch to Gtk.FileDialog (which would require GTK 4.10).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants