Commit 4be138f8 authored by Michael Gratton's avatar Michael Gratton 🤞

Merge branch 'wip/347-folks-loading-slow' into 'master'

Init Folks in backgroud to prevent blocking UI on startup

Closes #347

See merge request !185
parents 598a1d02 8ee768fb
Pipeline #71790 passed with stages
in 30 minutes and 19 seconds
......@@ -263,11 +263,16 @@ public class GearyController : Geary.BaseObject {
Folks.IndividualAggregator individuals =
Folks.IndividualAggregator.dup();
if (!individuals.is_prepared) {
// Do this in the background since it can take a long time
// on some systems and the GUI shouldn't be blocked by it
individuals.prepare.begin((obj, res) => {
try {
yield individuals.prepare();
individuals.prepare.end(res);
} catch (GLib.Error err) {
error("Error preparing Folks: %s", err.message);
warning("Error preparing Folks: %s", err.message);
}
});
}
this.avatar_store = new Application.AvatarStore(individuals);
......
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