|
List Info
Thread: Re: Re-using components
|
|
| Re: Re-using components |
  United States |
2007-05-21 13:21:40 |
|
On May 19, 2007, at 2:50 AM, Dave Silvia wrote:
> You say what your platform is and the DialogBlocks version, but you
> don't
> mention the wxWidgets version or your build system.;)
Sorry. I'm using wxPython 2.8.3.0; I would assume that that would
use the same wxWidgets version.
> Create a top level Null element (wxFrame, wxDialog, wxPanel,
> whatever). I used a
> wxDialog. Within that dialog I created a wxPanel and subclassed it as
> "DataPanel", I then specified not external implementation with
> separate files
> for the subclass.
>
> Then create the "real" top level elements. I have a wxFrame,
> MainFrame, a
> wxWizard, TheWiz, and a wxDialog, DataDialog. TheWiz and DataDialog
> each have an
> instance of DataPanel, this of course requires hand coding the
> include for
> DataPanel, DataPanel.h. MainFrame creates an instance of TheWiz,
> theWiz, in its
> Init(). The entered data is then placed in the variables (specified
> in DB in the
> Variables tab) in MainFrame. Under File in the MainFrame menubar is
> an Update
> Data menuitem. This creates an instance of DataDialog, theDlg, in
> its event
> handler. theDlg is populated with the stored values from MainFrame
> and theDlg is
> shown modal. On return, the variables in MainFrame are updated.
>
> I'm attaching a zip of the .pjd and sources. If you're not using
> Visual Studio,
> you'll need to make the necessary changes in Build>Configurations... .
I'm simply outputting XRC, which is then run through a converter
program to create the class definitions, along with the code to
import the XRC information. When I do that with your files, I still
get the same error; looking at the generated Python code, I don't see
the DataPanel class defined anywhere, so perhaps the fault is in the
program that generates the Python code. This is for a project I just
stepped into the middle of, so I have lots of new stuff to deal with,
and figure out it all works together.
Thanks for your help!
-- Ed Leafe
-- http://leafe.com
-- http://dabodev.com
__._,_.___
.
__,_._,___
|
| Re: Re-using components |
  United States |
2007-05-21 17:06:17 |
|
>-- On Mon, 21 May 2007 14:21:40 -0400 Ed Leafe wrote --
> On May 19, 2007, at 2:50 AM, Dave Silvia wrote:
>
>> You say what your platform is and the DialogBlocks version, but
>> you don't
>> mention the wxWidgets version or your build system.;)
>>
> Sorry. I'm using wxPython 2.8.3.0; I would assume that that would
> use the same wxWidgets version.
>
>> Create a top level Null element (wxFrame, wxDialog, wxPanel,
>> whatever). I used a
>> wxDialog. Within that dialog I created a wxPanel and subclassed
>> it as "DataPanel", I then specified not external implementation
>> with separate files for the subclass.
>>
>> Then create the "real" top level elements. I have a wxFrame,
>> MainFrame, a
>> wxWizard, TheWiz, and a wxDialog, DataDialog. TheWiz and
>> DataDialog each have an
>> instance of DataPanel, this of course requires hand coding the
>> include for
>> DataPanel, DataPanel.h. MainFrame creates an instance of TheWiz,
>> theWiz, in its
>> Init(). The entered data is then placed in the variables
>> (specified in DB in the
>> Variables tab) in MainFrame. Under File in the MainFrame menubar
>> is an Update
>> Data menuitem. This creates an instance of DataDialog, theDlg, in
>> its event
>> handler. theDlg is populated with the stored values from
>> MainFrame and theDlg is
>> shown modal. On return, the variables in MainFrame are updated.
>>
>> I'm attaching a zip of the .pjd and sources. If you're not using
>> Visual Studio,
>> you'll need to make the necessary changes in
>> Build>Configurations... .
>>
> I'm simply outputting XRC, which is then run through a converter
> program to create the class definitions, along with the code to
> import the XRC information. When I do that with your files, I still
> get the same error; looking at the generated Python code, I don't
> see the DataPanel class defined anywhere, so perhaps the fault is
> in the program that generates the Python code. This is for a
> project I just stepped into the middle of, so I have lots of new
> stuff to deal with, and figure out it all works together.
>
> Thanks for your help!
>
> -- Ed Leafe
Two questions: 1) is the DataPanel in the XRC file? 2) If it is, then, yes, it's
a fault of the Python code generator.
Could you attach a zip of the modifications you made to my example to generate
XRC? All the sources, too? Send it to the group:
anthemion-devtools%40yahoogroups.com">anthemion-devtools yahoogroups.com
in your email client, anyone receiving email will get the attachment, but the
attachment won't be saved at the group.
thx,
Dave S.
Which came first, the chicken or the egg. As every good biologist knows:
"A chicken is an egg's way of making another egg!"
wxMS_developers - Development with wxWidgets on MSWindows
http://tech.groups.yahoo.com/group/wxMS_developers/
wxWidgets Code Exchange
http://www.wxCodex.net/
__._,_.___
.
__,_._,___
|
[1-2]
|
|