extensionsService: Fix setting prefs dialog parent
Between the GTK4 port and the latest GTK4 version, calling realize() on a newly created window to force its surface to be created stopped working. So instead, wait for the window to get realized regularly to set its parent. Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1574>
This commit is contained in:
parent
1a9478c740
commit
a32df6b7a3
@ -120,8 +120,7 @@ var ExtensionsService = class extends ServiceImplementation {
|
||||
const extension = ExtensionUtils.deserializeExtension(serialized);
|
||||
|
||||
const window = new ExtensionPrefsDialog(extension);
|
||||
window.realize();
|
||||
|
||||
window.connect('realize', () => {
|
||||
let externalWindow = null;
|
||||
|
||||
if (parentWindow)
|
||||
@ -129,6 +128,7 @@ var ExtensionsService = class extends ServiceImplementation {
|
||||
|
||||
if (externalWindow)
|
||||
externalWindow.set_parent_of(window.get_surface());
|
||||
});
|
||||
|
||||
if (options.modal)
|
||||
window.modal = options.modal.get_boolean();
|
||||
|
Loading…
Reference in New Issue
Block a user