comparison src/bluetooth/gui.c @ 2885:7a1bc6c600e0

Disable rescan/connect while scanning / when no device is selected
author Paula Stanciu <paula.stanciu@gmail.com>
date Sat, 09 Aug 2008 21:00:39 +0300
parents 455e6e37feae
children
comparison
equal deleted inserted replaced
2884:4128ae5633e4 2885:7a1bc6c600e0
184 gtk_tree_path_free (path); 184 gtk_tree_path_free (path);
185 g_free(temp); 185 g_free(temp);
186 }else 186 }else
187 gtk_label_set_text(GTK_LABEL(label_prod),status); 187 gtk_label_set_text(GTK_LABEL(label_prod),status);
188 g_free(status); 188 g_free(status);
189 189 gtk_widget_set_sensitive(connect_button,TRUE);
190 } 190 }
191 } 191 }
192 192
193 void refresh_resultsui(){ 193 void refresh_resultsui(){
194 gtk_widget_destroy (window); 194 gtk_widget_destroy (window);
195 window = NULL; 195 window = NULL;
196 selected_dev = NULL; 196 selected_dev = NULL;
197 refresh_call(); 197 refresh_call();
198 } 198 }
199 199
200 200
201 void results_ui() 201 void results_ui()
229 gtk_container_add(GTK_CONTAINER(hbox_bottom),refresh); 229 gtk_container_add(GTK_CONTAINER(hbox_bottom),refresh);
230 230
231 connect_button = gtk_button_new_with_mnemonic(_("_Connect")); 231 connect_button = gtk_button_new_with_mnemonic(_("_Connect"));
232 g_signal_connect(connect_button,"clicked",G_CALLBACK (connect_call), NULL); 232 g_signal_connect(connect_button,"clicked",G_CALLBACK (connect_call), NULL);
233 gtk_container_add(GTK_CONTAINER(hbox_bottom),connect_button); 233 gtk_container_add(GTK_CONTAINER(hbox_bottom),connect_button);
234 gtk_widget_set_sensitive(connect_button,FALSE);
235
234 236
235 close_button = gtk_button_new_with_mnemonic(_("_Close")); 237 close_button = gtk_button_new_with_mnemonic(_("_Close"));
236 g_signal_connect(close_button,"clicked",G_CALLBACK (close_call),NULL); 238 g_signal_connect(close_button,"clicked",G_CALLBACK (close_call),NULL);
237 gtk_container_add(GTK_CONTAINER(hbox_bottom),close_button); 239 gtk_container_add(GTK_CONTAINER(hbox_bottom),close_button);
238 /* create tree model */ 240 /* create tree model */