[gtk+] app chooser: Avoid duplicates
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] app chooser: Avoid duplicates
- Date: Tue, 22 Sep 2015 19:17:39 +0000 (UTC)
commit 08e25b9ef7fee78b97dae4831323d950bdb10be9
Author: Matthias Clasen <mclasen redhat com>
Date: Tue Sep 22 15:14:00 2015 -0400
app chooser: Avoid duplicates
At the time we populate the model "initially" in constructed(),
it has already been filled and cleared a couple of times (we do
that every time one of the construct properties gets set). So
we can't assume that the model is empty, and have to clear it
first. Otherwise, we add duplicates to the list.
https://bugzilla.gnome.org/show_bug.cgi?id=748080
gtk/gtkappchooserwidget.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/gtk/gtkappchooserwidget.c b/gtk/gtkappchooserwidget.c
index aa6b0df..7e2117c 100644
--- a/gtk/gtkappchooserwidget.c
+++ b/gtk/gtkappchooserwidget.c
@@ -813,7 +813,7 @@ gtk_app_chooser_widget_initialize_items (GtkAppChooserWidget *self)
NULL);
/* populate the widget */
- gtk_app_chooser_widget_real_add_items (self);
+ gtk_app_chooser_refresh (GTK_APP_CHOOSER (self));
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]