Reload the history view when repository changes

This commit is contained in:
Techlive Zheng 2013-06-03 14:59:16 +08:00
parent 471a604309
commit 869479c31f

View file

@ -51,6 +51,18 @@ namespace GitgHistory
get { return d_stack_panel; }
}
[Notify]
public Gitg.Repository repository
{
set
{
if (value != null)
{
reload();
}
}
}
public void foreach_selected(GitgExt.ForeachObjectSelectionFunc func)
{
bool breakit = false;
@ -85,6 +97,7 @@ namespace GitgHistory
application.bind_property("repository", d_navigation_model, "repository", BindingFlags.DEFAULT);
application.bind_property("repository", d_commit_list_model, "repository", BindingFlags.DEFAULT);
application.bind_property("repository", this, "repository", BindingFlags.DEFAULT);
application.notify["repository"].connect((a, r) => {
notify_property("available");