[gitg] Do not trigger 'on_ref_activated' signal during reloading
- From: Ignacio Casal Quinteiro <icq src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gitg] Do not trigger 'on_ref_activated' signal during reloading
- Date: Mon, 3 Jun 2013 06:48:17 +0000 (UTC)
commit ef329ed44cac575e267f2af157634a69c6131589
Author: Techlive Zheng <techlivezheng gmail com>
Date: Sat Jun 1 03:04:11 2013 +0800
Do not trigger 'on_ref_activated' signal during reloading
Detach the model from the tree view first, then do the reloading of the
model. Otherwise, as the 'on_ref_activated' signal has been connected,
each time the model changes, the signal will be emitted, cause
unnecessary rendering of the commit list view.
plugins/history/gitg-history.vala | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
---
diff --git a/plugins/history/gitg-history.vala b/plugins/history/gitg-history.vala
index 64f2b98..6ea25ca 100644
--- a/plugins/history/gitg-history.vala
+++ b/plugins/history/gitg-history.vala
@@ -186,7 +186,9 @@ namespace GitgHistory
public void reload()
{
+ d_navigation.set_model(null);
d_navigation_model.reload();
+ d_navigation.set_model(d_navigation_model);
d_navigation.expand_all();
d_navigation.select_first();
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]