problem with cleaning wors list after bookmarks closing fixed;
[mdictionary] / src / gui / src / ws_gui_callbacks.c
index 68a7aba..5f417d8 100644 (file)
@@ -2010,7 +2010,7 @@ void ws_gui_dictionary_close_bookmark(GtkMenuItem *menuitem, gpointer user_data)
        ws_gui_fill_html(" ", ws_gui_app);
        ws_gui_app->html_flag = TRUE;
        //g_strstrip(ws_gui_app->last_searched);
-       if (ws_gui_app->last_searched != NULL && ws_gui_app->first_run == FALSE) 
+       if (g_strstrip(ws_gui_app->last_searched) != NULL && ws_gui_app->first_run == FALSE) 
        {
        g_object_set(G_OBJECT(ws_gui_app->ws_gui_hildon_find_toolbar),
                                      "prefix",
@@ -2019,6 +2019,10 @@ void ws_gui_dictionary_close_bookmark(GtkMenuItem *menuitem, gpointer user_data)
        //ws_dbus_client_find_word(ws_gui_app->dbus_data, ws_gui_app->last_searched);
        ws_gui_search(NULL, ws_gui_app);
        }
+       else
+       {
+               gtk_list_store_clear(ws_gui_app->ws_gui_w_list->ws_gui_store);
+       }
 /*     else if (ws_gui_app->first_run == FALSE) 
        {
                g_object_set(G_OBJECT(ws_gui_app->ws_gui_hildon_find_toolbar),
@@ -2393,7 +2397,11 @@ void ws_refresh_search_results(gpointer user_data) {
                                "prefix",
                                &temp,
                                NULL);
-       ws_dbus_client_find_word (ws_gui_app->dbus_data, temp);
+       
+       if (ws_gui_app->first_run == FALSE)
+       {
+               ws_dbus_client_find_word (ws_gui_app->dbus_data, temp);
+       }
        //gtk_widget_hide(ws_gui_app->ws_gui_list_hbox);
        //-----------------------------------------------
 }