[mutter/configurable-shadows: 6/13] Export meta_frame_type_to_string()
- From: Owen Taylor <otaylor src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter/configurable-shadows: 6/13] Export meta_frame_type_to_string()
- Date: Sat, 13 Nov 2010 16:51:58 +0000 (UTC)
commit a0a0fc14d7e264d8bdad8b516006d78f0f745242
Author: Owen W. Taylor <otaylor fishsoup net>
Date: Thu Nov 11 16:14:07 2010 -0500
Export meta_frame_type_to_string()
Frame types will form the bases of shadow classes, which are strings,
so export the to-string function so that we can do the conversion
uniformly.
https://bugzilla.gnome.org/show_bug.cgi?id=592382
src/include/util.h | 3 +++
src/ui/theme-private.h | 1 -
src/ui/theme.c | 8 ++++++++
3 files changed, 11 insertions(+), 1 deletions(-)
---
diff --git a/src/include/util.h b/src/include/util.h
index 595dc30..f9176f4 100644
--- a/src/include/util.h
+++ b/src/include/util.h
@@ -28,6 +28,8 @@
#include <glib.h>
#include <glib-object.h>
+#include "common.h"
+
gboolean meta_is_verbose (void);
void meta_set_verbose (gboolean setting);
gboolean meta_is_debugging (void);
@@ -91,6 +93,7 @@ guint meta_unsigned_long_hash (gconstpointer v);
void meta_print_backtrace (void);
+const char* meta_frame_type_to_string (MetaFrameType type);
const char* meta_gravity_to_string (int gravity);
#include <libintl.h>
diff --git a/src/ui/theme-private.h b/src/ui/theme-private.h
index 9c5f7d7..ba5f64d 100644
--- a/src/ui/theme-private.h
+++ b/src/ui/theme-private.h
@@ -1189,7 +1189,6 @@ const char* meta_frame_resize_to_string (MetaFrameResize r
MetaFrameFocus meta_frame_focus_from_string (const char *str);
const char* meta_frame_focus_to_string (MetaFrameFocus focus);
MetaFrameType meta_frame_type_from_string (const char *str);
-const char* meta_frame_type_to_string (MetaFrameType type);
MetaGradientType meta_gradient_type_from_string (const char *str);
const char* meta_gradient_type_to_string (MetaGradientType type);
GtkStateType meta_gtk_state_from_string (const char *str);
diff --git a/src/ui/theme.c b/src/ui/theme.c
index 577ab62..f7ac4aa 100644
--- a/src/ui/theme.c
+++ b/src/ui/theme.c
@@ -6017,6 +6017,14 @@ meta_frame_type_from_string (const char *str)
return META_FRAME_TYPE_LAST;
}
+/**
+ * meta_frame_type_to_string:
+ *
+ * Converts a frame type enum value to the name string that would
+ * appear in the theme definition file.
+ *
+ * Return value: the string value
+ */
const char*
meta_frame_type_to_string (MetaFrameType type)
{
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]