summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefano Karapetsas <[email protected]>2014-01-28 20:16:00 +0100
committerStefano Karapetsas <[email protected]>2014-01-28 20:16:00 +0100
commita3c69729467538e2821f0a27efbf0a8477d35791 (patch)
tree2f2add9b2477b400fef28613d6661ec2f6f8a414
parentee511ba9f042c64be34af0f7d8123391605a34c3 (diff)
parent38f7a4c66ec15897c05eb0f3577aaca4cb1b884d (diff)
downloadmate-control-center-a3c69729467538e2821f0a27efbf0a8477d35791.tar.bz2
mate-control-center-a3c69729467538e2821f0a27efbf0a8477d35791.tar.xz
Merge branch 'master' of github.com:mate-desktop/mate-control-center
-rw-r--r--capplets/about-me/fingerprint-strings.h26
-rw-r--r--capplets/about-me/mate-about-me.c2
-rw-r--r--capplets/appearance/appearance-style.c4
-rw-r--r--capplets/appearance/mate-wp-item.c21
-rw-r--r--capplets/appearance/mate-wp-item.h3
-rw-r--r--capplets/appearance/mate-wp-xml.c16
-rw-r--r--capplets/mouse/mate-mouse-properties.c6
-rw-r--r--capplets/windows/mate-window-properties.ui9
-rw-r--r--font-viewer/font-view.c2
-rw-r--r--libslab/tile.c2
10 files changed, 43 insertions, 48 deletions
diff --git a/capplets/about-me/fingerprint-strings.h b/capplets/about-me/fingerprint-strings.h
index d1b919e9..20446a0b 100644
--- a/capplets/about-me/fingerprint-strings.h
+++ b/capplets/about-me/fingerprint-strings.h
@@ -58,32 +58,6 @@ static const char *finger_str_to_msg(const char *finger_name, gboolean is_swipe)
}
/* Cases not handled:
- * verify-no-match
- * verify-match
- * verify-unknown-error
- */
-static const char *verify_result_str_to_msg(const char *result, gboolean is_swipe)
-{
- if (result == NULL)
- return NULL;
-
- if (strcmp (result, "verify-retry-scan") == 0) {
- if (is_swipe == FALSE)
- return N_("Place your finger on the reader again");
- else
- return N_("Swipe your finger again");
- }
- if (strcmp (result, "verify-swipe-too-short") == 0)
- return N_("Swipe was too short, try again");
- if (strcmp (result, "verify-finger-not-centered") == 0)
- return N_("Your finger was not centered, try swiping your finger again");
- if (strcmp (result, "verify-remove-and-retry") == 0)
- return N_("Remove your finger, and try swiping your finger again");
-
- return NULL;
-}
-
-/* Cases not handled:
* enroll-completed
* enroll-failed
* enroll-unknown-error
diff --git a/capplets/about-me/mate-about-me.c b/capplets/about-me/mate-about-me.c
index 6e125d3c..164408d5 100644
--- a/capplets/about-me/mate-about-me.c
+++ b/capplets/about-me/mate-about-me.c
@@ -41,8 +41,6 @@
#define MAX_HEIGHT 100
#define MAX_WIDTH 100
-#define EMAIL_SLOTS 4
-
typedef struct {
GtkBuilder *dialog;
diff --git a/capplets/appearance/appearance-style.c b/capplets/appearance/appearance-style.c
index 5ebd9523..ec9f916a 100644
--- a/capplets/appearance/appearance-style.c
+++ b/capplets/appearance/appearance-style.c
@@ -982,7 +982,7 @@ prepare_list (AppearanceData *data, GtkWidget *list, ThemeType type, GCallback c
/* select in treeview the theme set in gsettings */
GtkTreeModel *treemodel;
- treemodel = gtk_tree_view_get_model (list);
+ treemodel = gtk_tree_view_get_model (GTK_TREE_VIEW (list));
gchar *theme = g_settings_get_string (settings, key);
gchar *path = find_string_in_model (treemodel, theme, COL_NAME);
if (path)
@@ -990,7 +990,7 @@ prepare_list (AppearanceData *data, GtkWidget *list, ThemeType type, GCallback c
GtkTreeSelection *selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (list));
GtkTreePath *treepath = gtk_tree_path_new_from_string (path);
gtk_tree_selection_select_path (selection, treepath);
- gtk_tree_view_scroll_to_cell (list, treepath, NULL, FALSE, 0, 0);
+ gtk_tree_view_scroll_to_cell (GTK_TREE_VIEW (list), treepath, NULL, FALSE, 0, 0);
gtk_tree_path_free (treepath);
g_free (path);
}
diff --git a/capplets/appearance/mate-wp-item.c b/capplets/appearance/mate-wp-item.c
index d11fa896..96e7d67a 100644
--- a/capplets/appearance/mate-wp-item.c
+++ b/capplets/appearance/mate-wp-item.c
@@ -279,10 +279,16 @@ void mate_wp_item_update_description (MateWPItem * item) {
const gchar *description;
gchar *size;
gchar *dirname = g_path_get_dirname (item->filename);
+ gchar *artist;
description = NULL;
size = NULL;
+ if (!item->artist || item->artist[0] == 0 || !g_strcmp0(item->artist, "(none)"))
+ artist = g_strdup (_("unknown"));
+ else
+ artist = g_strdup (item->artist);
+
if (strcmp (item->fileinfo->mime_type, "application/xml") == 0)
{
if (mate_bg_changes_with_time (item->bg))
@@ -308,28 +314,35 @@ void mate_wp_item_update_description (MateWPItem * item) {
/* translators: <b>wallpaper name</b>
* mime type, size
* Folder: /path/to/file
+ * Artist: wallpaper author
*/
item->description = g_markup_printf_escaped (_("<b>%s</b>\n"
"%s, %s\n"
- "Folder: %s"),
+ "Folder: %s\n"
+ "Artist: %s"),
item->name,
description,
size,
- dirname);
+ dirname,
+ artist);
} else {
/* translators: <b>wallpaper name</b>
* Image missing
* Folder: /path/to/file
+ * Artist: wallpaper author
*/
item->description = g_markup_printf_escaped (_("<b>%s</b>\n"
"%s\n"
- "Folder: %s"),
+ "Folder: %s\n"
+ "Artist: %s"),
item->name,
_("Image missing"),
- dirname);
+ dirname,
+ artist);
}
g_free (size);
g_free (dirname);
+ g_free (artist);
}
}
diff --git a/capplets/appearance/mate-wp-item.h b/capplets/appearance/mate-wp-item.h
index a6e13f24..5e336d53 100644
--- a/capplets/appearance/mate-wp-item.h
+++ b/capplets/appearance/mate-wp-item.h
@@ -53,6 +53,9 @@ struct _MateWPItem {
/* Did the user remove us? */
gboolean deleted;
+ /* Wallpaper author, if present */
+ gchar *artist;
+
/* Width and Height of the original image */
gint width;
gint height;
diff --git a/capplets/appearance/mate-wp-xml.c b/capplets/appearance/mate-wp-xml.c
index d6b0c71d..11e19235 100644
--- a/capplets/appearance/mate-wp-xml.c
+++ b/capplets/appearance/mate-wp-xml.c
@@ -145,7 +145,7 @@ static void mate_wp_xml_load_xml(AppearanceData* data, const char* filename)
{
MateWPItem * wp;
char *pcolor = NULL, *scolor = NULL;
- gboolean have_scale = FALSE, have_shade = FALSE;
+ gboolean have_scale = FALSE, have_shade = FALSE, have_artist = FALSE;
wp = g_new0(MateWPItem, 1);
@@ -242,6 +242,14 @@ static void mate_wp_xml_load_xml(AppearanceData* data, const char* filename)
scolor = g_strdup(g_strstrip ((char *)wpa->last->content));
}
}
+ else if (!strcmp ((char*) wpa->name, "artist"))
+ {
+ if (wpa->last != NULL)
+ {
+ wp->artist = g_strdup (g_strstrip ((char *)wpa->last->content));
+ have_artist = TRUE;
+ }
+ }
else if (!strcmp ((char*) wpa->name, "text"))
{
/* Do nothing here, libxml2 is being weird */
@@ -283,6 +291,11 @@ static void mate_wp_xml_load_xml(AppearanceData* data, const char* filename)
scolor = g_settings_get_string (data->wp_settings, WP_SCOLOR_KEY);
}
+ if (!have_artist)
+ {
+ wp->artist = g_strdup ("(none)");
+ }
+
gdk_color_parse(pcolor, &color1);
gdk_color_parse(scolor, &color2);
g_free(pcolor);
@@ -541,6 +554,7 @@ void mate_wp_xml_save_list(AppearanceData* data)
xmlNewTextChild(wallpaper, NULL, (xmlChar*) "shade_type", (xmlChar*) shade);
xmlNewTextChild(wallpaper, NULL, (xmlChar*) "pcolor", (xmlChar*) pcolor);
xmlNewTextChild(wallpaper, NULL, (xmlChar*) "scolor", (xmlChar*) scolor);
+ xmlNewTextChild(wallpaper, NULL, (xmlChar*) "artist", (xmlChar*) wpitem->artist);
g_free(pcolor);
g_free(scolor);
diff --git a/capplets/mouse/mate-mouse-properties.c b/capplets/mouse/mate-mouse-properties.c
index cf5c9deb..38e17530 100644
--- a/capplets/mouse/mate-mouse-properties.c
+++ b/capplets/mouse/mate-mouse-properties.c
@@ -208,11 +208,11 @@ scrollmethod_gsettings_changed_event (GSettings *settings,
GtkBuilder *dialog)
{
int scroll_method = g_settings_get_int (touchpad_settings, "scroll-method");
- gtk_toggle_button_set_active (WID ("scroll_disabled_radio"),
+ gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (WID ("scroll_disabled_radio")),
scroll_method == 0);
- gtk_toggle_button_set_active (WID ("scroll_edge_radio"),
+ gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (WID ("scroll_edge_radio")),
scroll_method == 1);
- gtk_toggle_button_set_active (WID ("scroll_twofinger_radio"),
+ gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (WID ("scroll_twofinger_radio")),
scroll_method == 2);
gtk_widget_set_sensitive (WID ("horiz_scroll_toggle"),
scroll_method != 0);
diff --git a/capplets/windows/mate-window-properties.ui b/capplets/windows/mate-window-properties.ui
index 6a40b744..1029fed9 100644
--- a/capplets/windows/mate-window-properties.ui
+++ b/capplets/windows/mate-window-properties.ui
@@ -295,15 +295,8 @@
</packing>
</child>
<child>
- <object class="GtkComboBox" id="double-click-titlebar-optionmenu">
+ <object class="GtkComboBoxText" id="double-click-titlebar-optionmenu">
<property name="visible">True</property>
- <property name="model">liststore1</property>
- <child>
- <object class="GtkCellRendererText" id="cellrenderertext1"/>
- <attributes>
- <attribute name="text">0</attribute>
- </attributes>
- </child>
</object>
<packing>
<property name="expand">False</property>
diff --git a/font-viewer/font-view.c b/font-viewer/font-view.c
index 8ae289b8..634ac9ce 100644
--- a/font-viewer/font-view.c
+++ b/font-viewer/font-view.c
@@ -582,7 +582,7 @@ main(int argc, char **argv)
gtk_scrolled_window_add_with_viewport(GTK_SCROLLED_WINDOW(swin),
drawing_area);
#if !GTK_CHECK_VERSION (3, 0, 0)
- g_signal_connect (drawing_area, "realize", create_text_pixmap, face);
+ g_signal_connect (drawing_area, "realize", G_CALLBACK(create_text_pixmap), face);
#endif
/* set the minimum size on the scrolled window to prevent
diff --git a/libslab/tile.c b/libslab/tile.c
index aaa4203e..d91c571d 100644
--- a/libslab/tile.c
+++ b/libslab/tile.c
@@ -308,7 +308,7 @@ tile_enter (GtkButton * widget)
static void
tile_leave (GtkButton * widget)
{
- if (gtk_widget_has_focus (widget))
+ if (gtk_widget_has_focus (GTK_WIDGET (widget)))
gtk_widget_set_state (GTK_WIDGET (widget), TILE_STATE_FOCUSED);
else
gtk_widget_set_state (GTK_WIDGET (widget), GTK_STATE_NORMAL);