[gnome-photos] Add photos_utils_alpha_gtk_widget



commit 1ae5bf395f0fe908081dc3d9da36c736aa013c61
Author: Debarshi Ray <debarshir gnome org>
Date:   Wed Apr 25 15:17:56 2012 +0200

    Add photos_utils_alpha_gtk_widget

 src/Makefile.am    |    2 ++
 src/photos-utils.c |   32 ++++++++++++++++++++++++++++++++
 src/photos-utils.h |   32 ++++++++++++++++++++++++++++++++
 3 files changed, 66 insertions(+), 0 deletions(-)
---
diff --git a/src/Makefile.am b/src/Makefile.am
index dd0e25f..998a110 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -25,6 +25,8 @@ gnome_photos_SOURCES = \
 	photos-mode-controller.h \
 	photos-selection-controller.c \
 	photos-selection-controller.h \
+	photos-utils.c \
+	photos-utils.h \
 	photos-main.c \
 	$(NULL)
 
diff --git a/src/photos-utils.c b/src/photos-utils.c
new file mode 100644
index 0000000..54a09e0
--- /dev/null
+++ b/src/photos-utils.c
@@ -0,0 +1,32 @@
+/*
+ * Photos - access, organize and share your photos on GNOME
+ * Copyright  2012 Red Hat, Inc.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301, USA.
+ */
+
+
+#include "config.h"
+
+#include "photos-utils.h"
+
+
+void
+photos_utils_alpha_gtk_widget (GtkWidget *widget)
+{
+  GdkRGBA color = {0.0, 0.0, 0.0, 0.0};
+  gtk_widget_override_background_color (widget, GTK_STATE_FLAG_NORMAL, &color);
+}
diff --git a/src/photos-utils.h b/src/photos-utils.h
new file mode 100644
index 0000000..a15e885
--- /dev/null
+++ b/src/photos-utils.h
@@ -0,0 +1,32 @@
+/*
+ * Photos - access, organize and share your photos on GNOME
+ * Copyright  2012 Red Hat, Inc.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301, USA.
+ */
+
+#ifndef PHOTOS_UTILS_H
+#define PHOTOS_UTILS_H
+
+#include <gtk/gtk.h>
+
+G_BEGIN_DECLS
+
+void             photos_utils_alpha_gtk_widget            (GtkWidget *widget);
+
+G_END_DECLS
+
+#endif /* PHOTOS_UTILS_H */



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]