mirror of
https://github.com/ultimatepp/ultimatepp.git
synced 2026-05-16 06:05:58 -06:00
30 lines
520 B
C++
30 lines
520 B
C++
#include "ValueCtrlTest.h"
|
|
|
|
ValueCtrlTest::ValueCtrlTest()
|
|
{
|
|
CtrlLayout(*this, "Window title");
|
|
clear <<= THISBACK(Clear);
|
|
|
|
Value v = ValueArray(Vector<Value>() << 123.8 << "Test");
|
|
vc.SetData(v);
|
|
vc <<= THISBACK(ActionCB);
|
|
Add(vc.HSizePos().BottomPos(0, 20));
|
|
}
|
|
|
|
void ValueCtrlTest::ActionCB()
|
|
{
|
|
Value v = vc.GetData();
|
|
|
|
String s = "# Value Type: ";
|
|
s << v.GetType() << "\n\t";
|
|
s << "data: ";
|
|
s << AsString(v);
|
|
ToInfo(s);
|
|
RLOG(s);
|
|
}
|
|
|
|
GUI_APP_MAIN
|
|
{
|
|
ValueCtrlTest().Run();
|
|
}
|
|
|