From 4e072013945fb6f0659bec62c7655327f0fc5f40 Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Sat, 17 Sep 2011 19:06:27 +0000 Subject: [PATCH] Move dataformat to dataobj git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@69120 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- etg/_core.py | 2 +- etg/{dataformat.py => dataobj.py} | 13 ++++++++++--- 2 files changed, 11 insertions(+), 4 deletions(-) rename etg/{dataformat.py => dataobj.py} (76%) diff --git a/etg/_core.py b/etg/_core.py index fe75e606..d43f34a8 100644 --- a/etg/_core.py +++ b/etg/_core.py @@ -113,7 +113,7 @@ INCLUDES = [ 'defs', 'listbox', 'gauge', 'headercol', - 'dataformat', + 'dataobj', 'filedlg', 'dirdlg', 'config', diff --git a/etg/dataformat.py b/etg/dataobj.py similarity index 76% rename from etg/dataformat.py rename to etg/dataobj.py index 63f60d7e..7b798045 100644 --- a/etg/dataformat.py +++ b/etg/dataobj.py @@ -1,5 +1,5 @@ #--------------------------------------------------------------------------- -# Name: etg/choice.py +# Name: etg/dataobj.py # Author: Kevin Ollivier # # Created: 10-Sept-2011 @@ -12,12 +12,14 @@ import etgtools.tweaker_tools as tools PACKAGE = "wx" MODULE = "_core" -NAME = "dataformat" # Base name of the file to generate to for this script +NAME = "dataobj" # Base name of the file to generate to for this script DOCSTRING = "" # The classes and/or the basename of the Doxygen XML files to be processed by # this script. -ITEMS = [ 'wxDataFormat' ] +ITEMS = [ 'wxDataFormat', + # TODO: specify the rest of the classes in dataobj.h here + ] #--------------------------------------------------------------------------- @@ -30,6 +32,11 @@ def run(): # Tweak the parsed meta objects in the module object as needed for # customizing the generated code and docstrings. + c = module.find('wxDataFormat') + assert isinstance(c, etgtools.ClassDef) + + c.find('GetType').setCppCode("sipRes = static_cast(sipCpp->GetType());") + #----------------------------------------------------------------- tools.doCommonTweaks(module) tools.addGetterSetterProps(module)