[at-spi2-core] Revert "Clean up enums"



commit e5198adbcc277c6dc22ecf022b4b7504292b7ce0
Author: Mike Gorse <mgorse novell com>
Date:   Sun May 29 17:27:02 2011 -0500

    Revert "Clean up enums"
    
    This reverts commit a12d7458110c57e183916255d701b1e0d7c070e1.
    
    Conflicts:
    
    	atspi/atspi-constants.h
    
    Reverting these enum clean-ups for now, since they require pygobject 2.28.0
    for pyatspi, at least one user is pulling git while using pygobject 2.26.0,
    upgrading pygobject is likely to be a complicated process that may break
    things, and these changes are only code clean-ups that will not really benefit
    users.  Will reinstate in a separate branch and merge some time in the future.

 atspi/Makefile.am                 |   15 +-------------
 atspi/atspi-accessible.c          |    2 +-
 atspi/atspi-constants.h           |    4 +-
 atspi/atspi-enum-types.c.template |   39 -------------------------------------
 atspi/atspi-enum-types.h.template |   27 -------------------------
 atspi/atspi-registry.c            |    3 +-
 atspi/atspi-registry.h            |    3 +-
 atspi/atspi-types.h               |    6 ++--
 configure.ac                      |    2 -
 9 files changed, 9 insertions(+), 92 deletions(-)
---
diff --git a/atspi/Makefile.am b/atspi/Makefile.am
index 4d38ee4..8a26430 100644
--- a/atspi/Makefile.am
+++ b/atspi/Makefile.am
@@ -48,7 +48,6 @@ atspi-gmain.h \
 	atspi-value.h
 
 libatspi_la_SOURCES =		\
-	$(BUILT_SOURCES) \
 	$(libatspiinclude_HEADERS) \
 	atspi.h	\
 	atspi-accessible.c \
@@ -103,25 +102,13 @@ libatspi_la_SOURCES =		\
 	atspi-value.c \
 	atspi-value.h
 
-BUILT_SOURCES = \
-	atspi-enum-types.c \
-	atspi-enum-types.h
+#BUILT_SOURCES = atspi-constants.h
 
 #CLEANFILES = atspi-constants.h
 
 #atspi-constants.h: $(top_srcdir)/xml/spec.xml $(top_srcdir)/tools/c-constants-gen.py
 #	python $(top_srcdir)/tools/c-constants-gen.py Atspi $(top_srcdir)/xml/spec.xml atspi-constants
 
-ENUM_TYPES = \
-	atspi-constants.h \
-	atspi-types.h
-
-atspi-enum-types.h: atspi-enum-types.h.template $(ENUM_TYPES) $(GLIB_MKENUMS)
-	$(AM_V_GEN) (cd $(srcdir) && $(GLIB_MKENUMS) --template atspi-enum-types.h.template $(ENUM_TYPES)) > $@
-
-atspi-enum-types.c: atspi-enum-types.c.template $(ENUM_TYPES) $(GLIB_MKENUMS)
-	$(AM_V_GEN) (cd $(srcdir) && $(GLIB_MKENUMS) --template atspi-enum-types.c.template $(ENUM_TYPES)) > $@
-
 if HAVE_INTROSPECTION
 INTROSPECTION_FILES = $(libatspi_la_SOURCES)
 
diff --git a/atspi/atspi-accessible.c b/atspi/atspi-accessible.c
index eb8a103..50b5845 100644
--- a/atspi/atspi-accessible.c
+++ b/atspi/atspi-accessible.c
@@ -1415,7 +1415,7 @@ atspi_accessible_new (AtspiApplication *app, const gchar *path)
  *
  * @accessible: The #AtspiAccessible to operate on.  Must be the desktop or
  *             the root of an application.
- * @mask: An #AtspiCache specifying a bit mask of the types of data to cache.
+ * @mask: (type int): An #AtspiCache specifying a bit mask of the types of data to cache.
  *
  * Sets the type of data to cache for accessibles.
  * If this is not set for an application or is reset to ATSPI_CACHE_UNDEFINED,
diff --git a/atspi/atspi-constants.h b/atspi/atspi-constants.h
index 3632854..073102c 100644
--- a/atspi/atspi-constants.h
+++ b/atspi/atspi-constants.h
@@ -761,8 +761,8 @@ typedef enum {
 
 typedef enum
 {
-     ATSPI_CACHE_NONE     = 0,
-     ATSPI_CACHE_PARENT   = 1 << 0,
+  ATSPI_CACHE_NONE     = 0,
+  ATSPI_CACHE_PARENT   = 1 << 0,
   ATSPI_CACHE_CHILDREN    = 1 << 1,
   ATSPI_CACHE_NAME        = 1 << 2,
   ATSPI_CACHE_DESCRIPTION = 1 << 3,
diff --git a/atspi/atspi-registry.c b/atspi/atspi-registry.c
index 51392d0..9856be3 100644
--- a/atspi/atspi-registry.c
+++ b/atspi/atspi-registry.c
@@ -119,8 +119,7 @@ atspi_register_keystroke_listener (AtspiDeviceListener  *listener,
 					 GArray             *key_set,
 					 AtspiKeyMaskType         modmask,
 					 AtspiKeyEventMask        event_types,
-					 AtspiKeyListenerSyncType sync_type,
-                                         GError **error)
+					 gint sync_type, GError **error)
 {
   GArray *d_key_set;
   gchar *path = _atspi_device_listener_get_path (listener);
diff --git a/atspi/atspi-registry.h b/atspi/atspi-registry.h
index f8bf42f..03086dc 100644
--- a/atspi/atspi-registry.h
+++ b/atspi/atspi-registry.h
@@ -42,8 +42,7 @@ atspi_register_keystroke_listener (AtspiDeviceListener  *listener,
 					 GArray *key_set,
 					 AtspiKeyMaskType         modmask,
 					 AtspiKeyEventMask        event_types,
-					 AtspiKeyListenerSyncType sync_type,
-                                         GError **error);
+					 gint sync_type, GError **error);
 
 gboolean
 atspi_deregister_keystroke_listener (AtspiDeviceListener *listener,
diff --git a/atspi/atspi-types.h b/atspi/atspi-types.h
index 4e8dc1a..e56f93f 100644
--- a/atspi/atspi-types.h
+++ b/atspi/atspi-types.h
@@ -143,8 +143,8 @@ typedef struct _AtspiKeySet
  **/
 typedef enum {
   ATSPI_KEYLISTENER_NOSYNC = 0,
-  ATSPI_KEYLISTENER_SYNCHRONOUS = 1 << 0,
-  ATSPI_KEYLISTENER_CANCONSUME = 1 << 1,
-  ATSPI_KEYLISTENER_ALL_WINDOWS = 1 << 2
+  ATSPI_KEYLISTENER_SYNCHRONOUS = 1,
+  ATSPI_KEYLISTENER_CANCONSUME = 2,
+  ATSPI_KEYLISTENER_ALL_WINDOWS = 4
 } AtspiKeyListenerSyncType;
 #endif	/* _ATSPI_TYPES_H_ */
diff --git a/configure.ac b/configure.ac
index fc0c93d..b3374be 100644
--- a/configure.ac
+++ b/configure.ac
@@ -171,8 +171,6 @@ else
 fi
 AC_SUBST(DBUS_SERVICES_DIR)
 
-AC_PATH_PROG(GLIB_MKENUMS, glib-mkenums)
-
 GOBJECT_INTROSPECTION_CHECK([0.9.6])
 
 AC_SUBST(LIBTOOL_EXPORT_OPTIONS)



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