diff options
author | Matthias Clasen <mclasen@redhat.com> | 2019-02-16 23:59:39 -0500 |
---|---|---|
committer | Matthias Clasen <mclasen@redhat.com> | 2019-02-19 00:25:59 -0500 |
commit | a0454e40253aff0a7a05d6ae3c2d806c27fd4c3e (patch) | |
tree | 111fe9c4a58bd8c362c2ec18564715f9b3ecefe9 /demos | |
parent | b8c981fb2b5c8fe26b282b47ef1436312470e624 (diff) | |
download | gtk+-a0454e40253aff0a7a05d6ae3c2d806c27fd4c3e.tar.gz |
gtk-demo: Make the delayed search demo work
Make this demo work with the new search entry.
Diffstat (limited to 'demos')
-rw-r--r-- | demos/gtk-demo/search_entry2.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/demos/gtk-demo/search_entry2.c b/demos/gtk-demo/search_entry2.c index 1b0aa15395..ea4bb62151 100644 --- a/demos/gtk-demo/search_entry2.c +++ b/demos/gtk-demo/search_entry2.c @@ -13,7 +13,7 @@ search_changed_cb (GtkSearchEntry *entry, GtkLabel *result_label) { const char *text; - text = gtk_entry_get_text (GTK_ENTRY (entry)); + text = gtk_editable_get_text (GTK_EDITABLE (entry)); g_message ("search changed: %s", text); gtk_label_set_text (result_label, text ? text : ""); } @@ -22,7 +22,7 @@ static void changed_cb (GtkEditable *editable) { const char *text; - text = gtk_entry_get_text (GTK_ENTRY (editable)); + text = gtk_editable_get_text (GTK_EDITABLE (editable)); g_message ("changed: %s", text); } @@ -85,7 +85,7 @@ do_search_entry2 (GtkWidget *do_widget) gtk_widget_set_halign (container, GTK_ALIGN_CENTER); gtk_container_add (GTK_CONTAINER (container), entry); searchbar = gtk_search_bar_new (); - gtk_search_bar_connect_entry (GTK_SEARCH_BAR (searchbar), GTK_ENTRY (entry)); + gtk_search_bar_connect_entry (GTK_SEARCH_BAR (searchbar), GTK_EDITABLE (entry)); gtk_search_bar_set_show_close_button (GTK_SEARCH_BAR (searchbar), FALSE); gtk_container_add (GTK_CONTAINER (searchbar), container); gtk_container_add (GTK_CONTAINER (vbox), searchbar); |