Re: type casts (FindWindow)

[email protected] (Robert Roebling)
Newsgroups gmane.comp.lib.wxwindows.wxnet
Message-ID <[email protected]>
Bryan Bulten wrote:

> > currently wx.Window.FindWindow() returns a "Window".
> > If I know it is a "ListBox", how do I convert the
> > return value?
> 
> This goes back to when I was asking about RTTI and
> wxWindows.
> 
> The method, Object::CreateFromObject is used to look up
> the wxWindow object type using a typemap 

So what can I do?

  Window win = FindWindow( ID_MY_WIN );
  ListBox lb = win.CreateFromObject();

> since the typemap is unaware of sub-classed controls.

What do we actually need the typemap for? Cannot
we query the RTTI system at run-time?

  Robert

-- 
Robert Roebling, MD <[email protected]>


-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.