~ted/pidgin/11_buddy_list_really_show.patch

« back to all changes in this revision

Viewing changes to finch/libgnt/gntentry.c

  • Committer: Bazaar Package Importer
  • Date: 2008-10-13 20:37:35 UTC
  • Revision ID: jamesw@ubuntu.com-20081013203735-pi5e6u963tydsu0r
Tags: upstream-ubuntu-2.4.2
ImportĀ upstreamĀ versionĀ 2.4.2

Show diffs side-by-side

added added

removed removed

Lines of Context:
238
238
                destroy_suggest(entry);
239
239
                return FALSE;
240
240
        } else if (count == 1) {
 
241
                char *store = g_strndup(entry->start, entry->end - entry->start);
 
242
                gboolean ret;
 
243
 
241
244
                destroy_suggest(entry);
242
 
                return complete_suggest(entry, sgst);
 
245
                complete_suggest(entry, sgst);
 
246
 
 
247
                ret = (strncmp(store, entry->start, entry->end - entry->start) != 0);
 
248
                g_free(store);
 
249
                return ret;
243
250
        } else {
244
251
                if (max > 0) {
245
252
                        GntWidget *ddown = entry->ddown;
832
839
        entry_redraw(widget);
833
840
}
834
841
 
 
842
static gboolean
 
843
gnt_entry_clicked(GntWidget *widget, GntMouseEvent event, int x, int y)
 
844
{
 
845
        if (event == GNT_MIDDLE_MOUSE_DOWN) {
 
846
                clipboard_paste(GNT_BINDABLE(widget), NULL);
 
847
                return TRUE;
 
848
        }
 
849
        return FALSE;
 
850
 
 
851
}
 
852
 
835
853
static void
836
854
gnt_entry_class_init(GntEntryClass *klass)
837
855
{
839
857
        char s[2] = {erasechar(), 0};
840
858
 
841
859
        parent_class = GNT_WIDGET_CLASS(klass);
 
860
        parent_class->clicked = gnt_entry_clicked;
842
861
        parent_class->destroy = gnt_entry_destroy;
843
862
        parent_class->draw = gnt_entry_draw;
844
863
        parent_class->map = gnt_entry_map;