~ubuntu-branches/ubuntu/wily/sflphone/wily

« back to all changes in this revision

Viewing changes to gnome/src/contacts/searchbar.c

  • Committer: Package Import Robot
  • Author(s): Mark Purcell
  • Date: 2014-01-28 18:23:36 UTC
  • mfrom: (1.1.11)
  • mto: This revision was merged to the branch mainline in revision 24.
  • Revision ID: package-import@ubuntu.com-20140128182336-3xenud1kbnwmf3mz
* New upstream release 
  - Fixes "New Upstream Release" (Closes: #735846)
  - Fixes "Ringtone does not stop" (Closes: #727164)
  - Fixes "[sflphone-kde] crash on startup" (Closes: #718178)
  - Fixes "sflphone GUI crashes when call is hung up" (Closes: #736583)
* Build-Depends: ensure GnuTLS 2.6
  - libucommon-dev (>= 6.0.7-1.1), libccrtp-dev (>= 2.0.6-3)
  - Fixes "FTBFS Build-Depends libgnutls{26,28}-dev" (Closes: #722040)
* Fix "boost 1.49 is going away" unversioned Build-Depends: (Closes: #736746)
* Add Build-Depends: libsndfile-dev, nepomuk-core-dev

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/*
2
 
 *  Copyright (C) 2004-2012 Savoir-Faire Linux Inc.
 
2
 *  Copyright (C) 2004-2013 Savoir-Faire Linux Inc.
3
3
 *
4
4
 *  Author: Antoine Reversat <antoine.reversat@savoirfairelinux.com>
5
5
 *  Author: Emmanuel Milou <emmanuel.milou@savoirfairelinux.com>
252
252
}
253
253
 
254
254
static void
255
 
icon_press_cb(GtkEntry *entry, gint position, GdkEventButton *event, G_GNUC_UNUSED gpointer data)
 
255
icon_press_cb(GtkEntry *entry, gint position, GdkEventButton *event, gpointer data)
256
256
{
257
257
    g_debug("Searchbar: Icon pressed");
258
258
 
261
261
           gtk_menu_popup(GTK_MENU(menu), NULL, NULL, NULL,
262
262
                          NULL, event->button, event->time);
263
263
       else if (calltab_has_name(active_calltree_tab, CONTACTS))
264
 
           gtk_menu_popup(GTK_MENU(addressbook_menu_new()), NULL, NULL, NULL,
 
264
           gtk_menu_popup(GTK_MENU(addressbook_menu_new(data)), NULL, NULL, NULL,
265
265
                          NULL, event->button, event->time);
266
266
       else
267
267
           gtk_entry_set_text(entry, "");
304
304
 
305
305
 
306
306
GtkWidget*
307
 
history_searchbar_new()
 
307
history_searchbar_new(GSettings *settings)
308
308
{
309
309
    GtkWidget *ret = gtk_box_new(GTK_ORIENTATION_HORIZONTAL, 0);
310
310
 
318
318
    // Set the clean insensitive
319
319
    text_changed_cb(GTK_ENTRY(searchbox), NULL);
320
320
 
321
 
    g_signal_connect(searchbox, "icon-press", G_CALLBACK(icon_press_cb), NULL);
 
321
    g_signal_connect(searchbox, "icon-press", G_CALLBACK(icon_press_cb), settings);
322
322
    g_signal_connect(searchbox, "notify::text", G_CALLBACK(text_changed_cb), NULL);
323
323
 
324
324
    // Set up the search icon
436
436
    text_changed_cb(GTK_ENTRY(addressbookentry), NULL);
437
437
 
438
438
    g_signal_connect(addressbookentry, "notify::text", G_CALLBACK(text_changed_cb), NULL);
439
 
    g_signal_connect(addressbookentry, "icon-press", G_CALLBACK(icon_press_cb), NULL);
 
439
    g_signal_connect(addressbookentry, "icon-press", G_CALLBACK(icon_press_cb), settings);
440
440
 
441
441
    gtk_entry_set_activates_default(GTK_ENTRY(addressbookentry), TRUE);
442
442
    g_signal_connect_after(GTK_ENTRY(addressbookentry), "activate",