summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: a36eddd)
raw | patch | inline | side by side (parent: a36eddd)
author | Jon A. Cruz <jon@joncruz.org> | |
Sat, 3 Apr 2010 09:28:11 +0000 (02:28 -0700) | ||
committer | Jon A. Cruz <jon@joncruz.org> | |
Sat, 3 Apr 2010 09:28:11 +0000 (02:28 -0700) |
src/ui/dialog/glyphs.cpp | patch | blob | history |
index 8677bcda2c4a1169a008f0230f2fc0eafa6eb1c3..133cf01ea856e7b4c2471735415e786ee1302607 100644 (file)
--- a/src/ui/dialog/glyphs.cpp
+++ b/src/ui/dialog/glyphs.cpp
}
#endif // GLIB_CHECK_VERSION(2,14,0)
+ // Disconnect the model while we update it. Simple work-around for 5x+ performance boost.
+ Glib::RefPtr<Gtk::ListStore> tmp = Gtk::ListStore::create(*getColumns());
+ iconView->set_model(tmp);
+
std::vector<gunichar> present;
for (gunichar ch = 1; ch < 65535; ch++) {
int glyphId = font->MapUnicodeChar(ch);
(*row)[columns->code] = *it;
(*row)[columns->name] = tmp;
}
+
+ // Reconnect the model once it has been updated:
+ iconView->set_model(store);
}
}