Code-style consistency improvement:
Apply clang-format-all.sh using the _clang-format file through all the cpp/.h files. make sure not to apply it to certain serialization structures, since some parser expects the * as part of the name, instead of type. This commit contains no other changes aside from adding and applying clang-format-all.sh
This commit is contained in:
@@ -6,58 +6,52 @@ using namespace Gwen;
|
||||
|
||||
class Properties2 : public GUnit
|
||||
{
|
||||
public:
|
||||
|
||||
GWEN_CONTROL_INLINE( Properties2, GUnit )
|
||||
public:
|
||||
GWEN_CONTROL_INLINE(Properties2, GUnit)
|
||||
{
|
||||
{
|
||||
Gwen::Controls::Properties* props = new Gwen::Controls::Properties( this );
|
||||
Gwen::Controls::Properties* props = new Gwen::Controls::Properties(this);
|
||||
|
||||
props->SetBounds( 10, 10, 150, 300 );
|
||||
props->SetBounds(10, 10, 150, 300);
|
||||
|
||||
{
|
||||
{
|
||||
Gwen::Controls::PropertyRow* pRow = props->Add( L"First Name" );
|
||||
pRow->onChange.Add( this, &Properties2::OnFirstNameChanged );
|
||||
Gwen::Controls::PropertyRow* pRow = props->Add(L"First Name");
|
||||
pRow->onChange.Add(this, &Properties2::OnFirstNameChanged);
|
||||
}
|
||||
|
||||
props->Add( L"Middle Name" );
|
||||
props->Add( L"Last Name" );
|
||||
props->Add(L"Middle Name");
|
||||
props->Add(L"Last Name");
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
{
|
||||
Gwen::Controls::PropertyTree* ptree = new Gwen::Controls::PropertyTree( this );
|
||||
ptree->SetBounds( 200, 10, 200, 200 );
|
||||
Gwen::Controls::PropertyTree* ptree = new Gwen::Controls::PropertyTree(this);
|
||||
ptree->SetBounds(200, 10, 200, 200);
|
||||
|
||||
{
|
||||
Gwen::Controls::Properties* props = ptree->Add( L"Item One" );
|
||||
props->Add( L"Middle Name" );
|
||||
props->Add( L"Last Name" );
|
||||
props->Add( L"Four" );
|
||||
Gwen::Controls::Properties* props = ptree->Add(L"Item One");
|
||||
props->Add(L"Middle Name");
|
||||
props->Add(L"Last Name");
|
||||
props->Add(L"Four");
|
||||
}
|
||||
|
||||
{
|
||||
Gwen::Controls::Properties* props = ptree->Add( L"Item Two" );
|
||||
props->Add( L"More Items" );
|
||||
props->Add( L"To Fill" );
|
||||
props->Add( L"Out Here" );
|
||||
Gwen::Controls::Properties* props = ptree->Add(L"Item Two");
|
||||
props->Add(L"More Items");
|
||||
props->Add(L"To Fill");
|
||||
props->Add(L"Out Here");
|
||||
}
|
||||
|
||||
ptree->ExpandAll();
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
void OnFirstNameChanged( Controls::Base* pControl )
|
||||
void OnFirstNameChanged(Controls::Base* pControl)
|
||||
{
|
||||
Gwen::Controls::PropertyRow* pRow = (Gwen::Controls::PropertyRow*) pControl;
|
||||
UnitPrint( Utility::Format( L"First Name Changed: %s", pRow->GetProperty()->GetPropertyValue().c_str() ) );
|
||||
Gwen::Controls::PropertyRow* pRow = (Gwen::Controls::PropertyRow*)pControl;
|
||||
UnitPrint(Utility::Format(L"First Name Changed: %s", pRow->GetProperty()->GetPropertyValue().c_str()));
|
||||
}
|
||||
|
||||
};
|
||||
|
||||
|
||||
|
||||
DEFINE_UNIT_TEST( Properties2, L"Properties" );
|
||||
DEFINE_UNIT_TEST(Properties2, L"Properties");
|
||||
Reference in New Issue
Block a user