~ubuntu-branches/ubuntu/quantal/epiphany-extensions/quantal

« back to all changes in this revision

Viewing changes to extensions/tab-states/ephy-tab-states-extension.c

  • Committer: Bazaar Package Importer
  • Author(s): Frederic Peters
  • Date: 2011-04-14 19:04:24 UTC
  • mfrom: (1.1.43 upstream) (2.3.16 experimental)
  • Revision ID: james.westby@ubuntu.com-20110414190424-df2o8wz2pei97hbd
Tags: 3.0.0-2
debian/control.in: bump build-dep on epiphany.

Show diffs side-by-side

added added

removed removed

Lines of Context:
25
25
 
26
26
#include <epiphany/epiphany.h>
27
27
 
28
 
#include "eel-gconf-extensions.h"
29
28
#include "ephy-debug.h"
30
29
 
31
30
#include <gmodule.h>
46
45
        PangoFontDescription *bold_font_desc;
47
46
};
48
47
 
49
 
#define CONF_TABS_LOADING_COLOUR        "/apps/galeon/UI/Tabs/tabbed_loading_color"
50
 
#define CONF_TABS_UNREAD_COLOUR         "/apps/galeon/UI/Tabs/tabbed_new_color"
51
 
 
52
48
static void ephy_tab_states_extension_class_init        (EphyTabStatesExtensionClass *klass);
53
49
static void ephy_tab_states_extension_iface_init        (EphyExtensionIface *iface);
54
50
static void ephy_tab_states_extension_init              (EphyTabStatesExtension *extension);
105
101
        EphyTabStatesExtensionPrivate *priv;
106
102
#ifdef ENABLE_COLOURS
107
103
        char *colour;
 
104
        GSettings *settings;
108
105
#endif
109
106
 
110
107
        priv = extension->priv = EPHY_TAB_STATES_EXTENSION_GET_PRIVATE (extension);
112
109
        LOG ("EphyTabStatesExtension initialising");
113
110
 
114
111
#ifdef ENABLE_COLOURS
 
112
        settings = g_settings_new ("org.gnome.EpiphanyExtensions.tab-states");
 
113
 
115
114
        /* FIXME handle NULL and "" */
116
 
        colour = eel_gconf_get_string (CONF_TABS_LOADING_COLOUR);
 
115
        colour = g_settings_get_string ("loading-color");
117
116
        gdk_color_parse (colour, &priv->tab_loading_colour);
118
117
        g_free (colour);
119
118
 
120
 
        colour = eel_gconf_get_string (CONF_TABS_UNREAD_COLOUR);
 
119
        colour = g_settings_get_string ("unread-color");
121
120
        gdk_color_parse (colour, &priv->tab_unread_colour);
122
121
        g_free (colour);
 
122
 
 
123
        g_object_unref (settings);
123
124
#endif
124
125
 
125
126
        priv->bold_font_desc = pango_font_description_new ();