Unverified Commit 1c68380f authored by Julian Sparber's avatar Julian Sparber

Merge branch 'librem5' into pureos/sloppy

parents b2d0a275 c957c066
......@@ -30,6 +30,8 @@ public class Contacts.App : Gtk.Application {
private bool is_prepare_scheluded = false;
private bool is_quiescent_scheduled = false;
private HashTable<string, Value?> new_contact_data = null;
private const GLib.ActionEntry[] action_entries = {
{ "quit", quit },
{ "help", show_help },
......@@ -318,20 +320,28 @@ public class Contacts.App : Gtk.Application {
ulong id = 0;
uint id2 = 0;
id = contacts_store.quiescent.connect (() => {
Source.remove (id2);
contacts_store.disconnect (id);
debug ("callign set_list_pane from quiescent.connect");
window.set_list_pane ();
});
Source.remove (id2);
contacts_store.disconnect (id);
debug ("callign set_list_pane from quiescent.connect");
if (new_contact_data == null)
window.set_list_pane ();
else
window.new_contact (new_contact_data);
});
// Wait at most 0.5 seconds to show the window
id2 = Timeout.add (500, () => {
contacts_store.disconnect (id);
contacts_store.disconnect (id);
debug ("callign set_list_pane from 500.timeout");
window.set_list_pane ();
return false;
});
debug ("callign set_list_pane from 500.timeout");
if (new_contact_data == null)
window.set_list_pane ();
else
window.new_contact (new_contact_data);
return false;
});
is_quiescent_scheduled = true;
}
......@@ -413,8 +423,11 @@ public class Contacts.App : Gtk.Application {
if (param != null)
details = array_to_details (param);
if (window == null)
create_window ();
if (window == null) {
new_contact_data = details;
create_new_window ();
return;
}
window.present ();
window.new_contact (details);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment