ultimatepp/upptst/Ctrl_GetAscendant/main.cpp
cxl 7a9686af98 .upptst
git-svn-id: svn://ultimatepp.org/upp/trunk@13755 f0d560ea-af0d-0410-9eb7-867de7ffcac7
2019-12-12 13:07:49 +00:00

19 lines
310 B
C++

#include <CtrlLib/CtrlLib.h>
using namespace Upp;
struct TestCtrl : Ctrl {
virtual void LeftDown(Point p, dword keyflags) {
TopWindow *w = GetAscendant<TopWindow>();
if(w)
w->Title(AsString(p));
}
};
GUI_APP_MAIN
{
TopWindow win;
TestCtrl h;
win << h.SizePos();
win.Run();
}