Hello!

Before using WWidget::find, you should set object name to descendant
widget using WWidget::setObjectName. By default, object name is empty.
Passing the object name to find() method of ancestor widget, you get a
pointer to descendant widget.

To convert the pointer to needed type, use boost::polymorphic_downcast
( http://www.boost.org/doc/libs/1_52_0/boost/cast.hpp ). If particular
type is unknown (i.e., WContainerWidget or WTabWidget), use operator
dynamic_cast: it returns 0 if a pointer can not be converted.

On Wed, Jan 2, 2013 at 2:25 PM, Rashad M <mohammedrasha...@gmail.com> wrote:
> How to use find for getting a widget inside a WContainerWidget or WTabWidget
> which may be on a child or WContainerWidget
>
> --
> Regards,
>    Rashad
>
> ------------------------------------------------------------------------------
> Master Java SE, Java EE, Eclipse, Spring, Hibernate, JavaScript, jQuery
> and much more. Keep your Java skills current with LearnJavaNow -
> 200+ hours of step-by-step video tutorials by Java experts.
> SALE $49.99 this month only -- learn more at:
> http://p.sf.net/sfu/learnmore_122612
> _______________________________________________
> witty-interest mailing list
> witty-interest@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/witty-interest
>

------------------------------------------------------------------------------
Master Java SE, Java EE, Eclipse, Spring, Hibernate, JavaScript, jQuery
and much more. Keep your Java skills current with LearnJavaNow -
200+ hours of step-by-step video tutorials by Java experts.
SALE $49.99 this month only -- learn more at:
http://p.sf.net/sfu/learnmore_122612 
_______________________________________________
witty-interest mailing list
witty-interest@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/witty-interest

Reply via email to