summaryrefslogtreecommitdiff
path: root/mate-about/mate-about.c
diff options
context:
space:
mode:
authorStefano Karapetsas <[email protected]>2013-07-30 16:52:51 +0200
committerStefano Karapetsas <[email protected]>2013-07-30 16:52:51 +0200
commit13c45a3626873c5e23422c41ccd0fa8531e9c2a5 (patch)
treeb45311bc1666e33f49a7fc48feccd41f5556bb8a /mate-about/mate-about.c
parent9c5b89dde212acf060bcff4945b0137a48e80ec1 (diff)
downloadmate-desktop-13c45a3626873c5e23422c41ccd0fa8531e9c2a5.tar.bz2
mate-desktop-13c45a3626873c5e23422c41ccd0fa8531e9c2a5.tar.xz
mate-about: Try to use 'mate' as icon, if available in icon theme
Deleted old code because now we require GTK 2.24
Diffstat (limited to 'mate-about/mate-about.c')
-rw-r--r--mate-about/mate-about.c24
1 files changed, 9 insertions, 15 deletions
diff --git a/mate-about/mate-about.c b/mate-about/mate-about.c
index 9a1a9ca..fa25be6 100644
--- a/mate-about/mate-about.c
+++ b/mate-about/mate-about.c
@@ -72,24 +72,18 @@
{
mate_about_dialog = (GtkAboutDialog*) gtk_about_dialog_new();
- gtk_window_set_default_icon_name(icon);
+ gtk_window_set_default_icon_name(desktop_icon);
- #if GTK_CHECK_VERSION(3, 0, 0) || GTK_CHECK_VERSION(2, 6, 0)
+ GtkIconTheme* icon_theme = gtk_icon_theme_get_default();
+ if (gtk_icon_theme_has_icon(icon_theme, icon))
+ {
gtk_about_dialog_set_logo_icon_name(mate_about_dialog, icon);
-
- #else
-
- GtkIconTheme* icon_theme = gtk_icon_theme_get_default();
-
- if (gtk_icon_theme_has_icon(icon_theme, icon))
- {
- GdkPixbuf* pixbuf = gtk_icon_theme_load_icon(icon_theme, icon, 64, 0, NULL);
- gtk_about_dialog_set_logo(mate_about_dialog, pixbuf);
- g_object_unref(pixbuf);
- }
-
- #endif
+ }
+ else
+ {
+ gtk_about_dialog_set_logo_icon_name(mate_about_dialog, desktop_icon);
+ }
// name
#if GTK_CHECK_VERSION(3, 0, 0) || GTK_CHECK_VERSION(2, 12, 0)