Commit 417f6d8f authored by Tristan Matthews's avatar Tristan Matthews
Browse files

gnome: cosmetics

parent 29464c21
...@@ -518,6 +518,9 @@ audiocodecs_box(const account_t *account) ...@@ -518,6 +518,9 @@ audiocodecs_box(const account_t *account)
// Create codec tree view with list store // Create codec tree view with list store
codecTreeView = gtk_tree_view_new_with_model(GTK_TREE_MODEL(codecStore)); codecTreeView = gtk_tree_view_new_with_model(GTK_TREE_MODEL(codecStore));
/* The list store model will be destroyed automatically with the view */
g_object_unref(G_OBJECT(codecStore));
// Get tree selection manager // Get tree selection manager
GtkTreeSelection *treeSelection = gtk_tree_view_get_selection(GTK_TREE_VIEW(codecTreeView)); GtkTreeSelection *treeSelection = gtk_tree_view_get_selection(GTK_TREE_VIEW(codecTreeView));
g_signal_connect(G_OBJECT(treeSelection), "changed", g_signal_connect(G_OBJECT(treeSelection), "changed",
...@@ -547,7 +550,6 @@ audiocodecs_box(const account_t *account) ...@@ -547,7 +550,6 @@ audiocodecs_box(const account_t *account)
treeViewColumn = gtk_tree_view_column_new_with_attributes(_("Bitrate"), renderer, "text", COLUMN_CODEC_BITRATE, NULL); treeViewColumn = gtk_tree_view_column_new_with_attributes(_("Bitrate"), renderer, "text", COLUMN_CODEC_BITRATE, NULL);
gtk_tree_view_append_column(GTK_TREE_VIEW(codecTreeView), treeViewColumn); gtk_tree_view_append_column(GTK_TREE_VIEW(codecTreeView), treeViewColumn);
g_object_unref(G_OBJECT(codecStore));
gtk_container_add(GTK_CONTAINER(scrolledWindow), codecTreeView); gtk_container_add(GTK_CONTAINER(scrolledWindow), codecTreeView);
// Create button box // Create button box
......
...@@ -424,6 +424,9 @@ videocodecs_box(account_t *acc) ...@@ -424,6 +424,9 @@ videocodecs_box(account_t *acc)
// Create codec tree view with list store // Create codec tree view with list store
codecTreeView = gtk_tree_view_new_with_model(GTK_TREE_MODEL(codecStore)); codecTreeView = gtk_tree_view_new_with_model(GTK_TREE_MODEL(codecStore));
/* The list store model will be destroyed automatically with the view */
g_object_unref(G_OBJECT(codecStore));
// Get tree selection manager // Get tree selection manager
GtkTreeSelection *treeSelection = gtk_tree_view_get_selection(GTK_TREE_VIEW(codecTreeView)); GtkTreeSelection *treeSelection = gtk_tree_view_get_selection(GTK_TREE_VIEW(codecTreeView));
g_signal_connect(G_OBJECT(treeSelection), "changed", g_signal_connect(G_OBJECT(treeSelection), "changed",
...@@ -450,7 +453,6 @@ videocodecs_box(account_t *acc) ...@@ -450,7 +453,6 @@ videocodecs_box(account_t *acc)
treeViewColumn = gtk_tree_view_column_new_with_attributes(_("Bitrate (kbps)"), renderer, "text", COLUMN_CODEC_BITRATE, NULL); treeViewColumn = gtk_tree_view_column_new_with_attributes(_("Bitrate (kbps)"), renderer, "text", COLUMN_CODEC_BITRATE, NULL);
gtk_tree_view_append_column(GTK_TREE_VIEW(codecTreeView), treeViewColumn); gtk_tree_view_append_column(GTK_TREE_VIEW(codecTreeView), treeViewColumn);
g_object_unref(G_OBJECT(codecStore));
gtk_container_add(GTK_CONTAINER(scrolledWindow), codecTreeView); gtk_container_add(GTK_CONTAINER(scrolledWindow), codecTreeView);
// Create button box // Create button box
...@@ -731,12 +733,10 @@ fill_devices() ...@@ -731,12 +733,10 @@ fill_devices()
gtk_widget_show_all(v4l2_hbox); gtk_widget_show_all(v4l2_hbox);
gtk_widget_hide(v4l2_nodev); gtk_widget_hide(v4l2_nodev);
gtk_widget_set_sensitive(preview_button, TRUE); gtk_widget_set_sensitive(preview_button, TRUE);
} else { } else if (GTK_IS_WIDGET(v4l2_hbox)) {
if (GTK_IS_WIDGET(v4l2_hbox)) { gtk_widget_hide(v4l2_hbox);
gtk_widget_hide(v4l2_hbox); gtk_widget_show(v4l2_nodev);
gtk_widget_show(v4l2_nodev); gtk_widget_set_sensitive(preview_button, FALSE);
gtk_widget_set_sensitive(preview_button, FALSE);
}
} }
} }
...@@ -750,7 +750,6 @@ video_device_event_cb(DBusGProxy *proxy UNUSED, void * foo UNUSED) ...@@ -750,7 +750,6 @@ video_device_event_cb(DBusGProxy *proxy UNUSED, void * foo UNUSED)
static GtkWidget * static GtkWidget *
v4l2_box() v4l2_box()
{ {
DEBUG("%s", __PRETTY_FUNCTION__);
GtkWidget *ret = gtk_box_new(GTK_ORIENTATION_VERTICAL, 0); GtkWidget *ret = gtk_box_new(GTK_ORIENTATION_VERTICAL, 0);
v4l2_nodev = gtk_label_new(_("No devices found")); v4l2_nodev = gtk_label_new(_("No devices found"));
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment