gchar* text_editor;
browser = midori_browser_get_for_widget (GTK_WIDGET (addons->treeview));
- settings = katze_object_get_object (browser, "settings");
+ settings = midori_browser_get_settings (browser);
gtk_tree_model_get (model, &iter, 0, &element, -1);
MidoriWebSettings* settings;
MidoriBrowser* browser;
gint n;
-
browser = midori_browser_get_for_widget (GTK_WIDGET (panel));
n = midori_browser_add_item (browser, item);
-
- settings = katze_object_get_object (browser, "settings");
+ settings = midori_browser_get_settings (browser);
if (!katze_object_get_boolean (settings, "open-tabs-in-the-background"))
midori_browser_set_current_page (browser, n);
- g_object_unref (settings);
-
}
g_object_unref (item);
}
browser = midori_browser_get_for_widget (GTK_WIDGET (panel));
n = midori_browser_add_item (browser, item);
-
- settings = katze_object_get_object (browser, "settings");
+ settings = midori_browser_get_settings (browser);
if (!katze_object_get_boolean (settings, "open-tabs-in-the-background"))
midori_browser_set_current_page (browser, n);
- g_object_unref (settings);
}
}
browser = midori_browser_get_for_widget (GTK_WIDGET (panel));
n = midori_browser_add_item (browser, item);
- settings = katze_object_get_object (browser, "settings");
+ settings = midori_browser_get_settings (browser);
if (!katze_object_get_boolean (settings, "open-tabs-in-the-background"))
midori_browser_set_current_page (browser, n);
- g_object_unref (settings);
}
}
else
view = midori_view_new (NULL);
browser = midori_browser_get_for_widget (notebook);
- settings = katze_object_get_object (browser, "settings");
+ settings = midori_browser_get_settings (browser);
midori_view_set_settings (MIDORI_VIEW (view), settings);
- g_object_unref (settings);
gtk_widget_show (view);
label = midori_view_get_proxy_tab_label (MIDORI_VIEW (view));
return gtk_notebook_append_page (GTK_NOTEBOOK (notebook), view, label);
statusbar = katze_object_get_object (browser, "statusbar");
bbox = gtk_hbox_new (FALSE, 0);
- settings = katze_object_get_object (browser, "settings");
+ settings = midori_browser_get_settings (browser);
toolbar = katze_object_get_object (browser, "navigationbar");
button = katze_property_proxy (settings, "auto-load-images", "toggle");
g_object_set_data (G_OBJECT (button), "feature-label", _("Images"));
gtk_box_pack_start (GTK_BOX (bbox), button, FALSE, FALSE, 2);
gtk_widget_show_all (bbox);
gtk_box_pack_start (GTK_BOX (statusbar), bbox, FALSE, FALSE, 3);
- g_object_unref (settings);
g_object_unref (statusbar);
g_signal_connect (extension, "deactivate",
{
GtkWidget* notebook = katze_object_get_object (browser, "notebook");
gint page = gtk_notebook_page_num (GTK_NOTEBOOK (notebook), view);
- MidoriWebSettings* settings = katze_object_get_object (browser, "settings");
+ MidoriWebSettings* settings = midori_browser_get_settings (browser);
gboolean minimized = katze_object_get_boolean (view, "minimized");
GdkPixbuf* icon = midori_view_get_icon (MIDORI_VIEW (view));
const gchar* title = midori_view_get_display_title (MIDORI_VIEW (view));
}
g_object_unref (notebook);
- g_object_unref (settings);
}
static void
GSList *list = NULL;
MidoriWebSettings *settings;
- settings = katze_object_get_object(browser, "settings");
+ settings = midori_browser_get_settings(browser);
g_object_get(settings, "toolbar-items", &items, NULL);
- g_object_unref(settings);
names = g_strsplit(items ? items : "", ",", 0);
list = tb_editor_array_to_list((const gchar **) names);
gtk_tree_model_foreach(GTK_TREE_MODEL(tbw->store_used), tb_editor_foreach_used, str);
- settings = katze_object_get_object(tbw->browser, "settings");
+ settings = midori_browser_get_settings(tbw->browser);
g_object_set(settings, "toolbar-items", str->str, NULL);
- g_object_unref(settings);
g_string_free(str, TRUE);
}
GEnumClass* enum_class = G_ENUM_CLASS (
g_type_class_peek (pspec->value_type));
GEnumValue* enum_value;
-
str = g_key_file_get_string (key_file, "settings", property, NULL);
enum_value = g_enum_get_value_by_name (enum_class, str);
if (enum_value)
else
g_warning (_("Value '%s' is invalid for %s"),
str, property);
-
g_free (str);
- g_type_class_unref (enum_class);
}
else
g_warning (_("Invalid configuration value '%s'"), property);
else if (type == G_TYPE_PARAM_ENUM)
{
GEnumClass* enum_class = G_ENUM_CLASS (
- g_type_class_ref (pspec->value_type));
+ g_type_class_peek (pspec->value_type));
gint integer;
GEnumValue* enum_value;
g_object_get (settings, property, &integer, NULL);
}
else
{
- settings = katze_object_get_object (browser, "settings");
+ settings = g_object_ref (midori_browser_get_settings (browser));
g_object_set (settings,
"show-menubar", FALSE,
"show-navigationbar", FALSE,
GParamSpec* pspec,
MidoriBrowser* browser)
{
- gint page = katze_object_get_boolean (panel, "page");
+ gint page = midori_panel_get_current_page (panel);
if (page > -1)
g_object_set (browser->settings, "last-panel-page", page, NULL);
}