Ticket #688: gui-tweak-Ticket-688.patch

File gui-tweak-Ticket-688.patch, 1.1 KB (added by sleske, 11 years ago)

patch to gtk/destination.c

  • navit/gui/gtk/destination.c

     
    245245        if (widget == search->entry_street) {
    246246                dbg(0,"street\n");
    247247                search->attr.type=attr_street_name;
     248                // Searching for a street by just its first letter generates too many hits to be useful,
     249                // plus it causes the GUI to become unresponsive because the search is single-threaded.
     250                // So we only start searching once we have two letters.
     251                if (strlen(search->attr.u.str) < 2)
     252                        return;
    248253                set_columns(search, 2);
    249254        }
    250255
    251 
    252256        search_list_search(search->sl, &search->attr, search->partial);
    253257        gtk_list_store_clear(search->liststore);
    254258        while((res=search_list_get_result(search->sl))) {
     
    466470        window2 = gtk_window_new(GTK_WINDOW_TOPLEVEL);
    467471        gtk_window_set_title(GTK_WINDOW(window2),_("Enter Destination"));
    468472        gtk_window_set_wmclass (GTK_WINDOW (window2), "navit", "Navit");
     473        gtk_window_set_default_size (GTK_WINDOW (window2),0,500);
    469474        vbox = gtk_vbox_new(FALSE, 0);
    470475        table = gtk_table_new(3, 8, FALSE);
    471476