From: Conrado P. <con...@us...> - 2006-07-09 03:42:07
|
Update of /cvsroot/smartwin/SmartWin/tests/PocketPC/SmartWinDevicesUnitTests/AddressBook In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv32732/tests/PocketPC/SmartWinDevicesUnitTests/AddressBook Modified Files: TabWidget.cpp TabWidget.h Log Message: MingW and WinCE issues fixed, WidgetLoadFile changes, setSmallIcon improvement, updateWidget new parameter, replaced the WC_* constants (they're not defined in WinCE) Index: TabWidget.h =================================================================== RCS file: /cvsroot/smartwin/SmartWin/tests/PocketPC/SmartWinDevicesUnitTests/AddressBook/TabWidget.h,v retrieving revision 1.5 retrieving revision 1.6 diff -u -d -r1.5 -r1.6 --- TabWidget.h 5 May 2006 17:14:39 -0000 1.5 +++ TabWidget.h 9 Jul 2006 03:42:01 -0000 1.6 @@ -18,8 +18,8 @@ void createChildWidgets(); void layout(); WidgetStatic * createStaticHelper( WidgetChildWindow * parent, const SmartUtil::tstring & txt ); - WidgetTextBox * createTextBoxHelper( WidgetChildWindow * parent, SmartWin::CreationalStruct & cs ); - WidgetCheckBox * createCheckBoxHelper( WidgetChildWindow * parent, SmartWin::CreationalStruct & cs, const SmartUtil::tstring & txt ); + WidgetTextBox * createTextBoxHelper( WidgetChildWindow * parent, WidgetTextBox::Seed & cs ); + WidgetCheckBox * createCheckBoxHelper( WidgetChildWindow * parent, WidgetCheckBox::Seed & cs, const SmartUtil::tstring & txt ); // Event handlers void selectedChanged( WidgetTabSheetPtr This ); Index: TabWidget.cpp =================================================================== RCS file: /cvsroot/smartwin/SmartWin/tests/PocketPC/SmartWinDevicesUnitTests/AddressBook/TabWidget.cpp,v retrieving revision 1.9 retrieving revision 1.10 diff -u -d -r1.9 -r1.10 --- TabWidget.cpp 5 May 2006 17:21:43 -0000 1.9 +++ TabWidget.cpp 9 Jul 2006 03:42:01 -0000 1.10 @@ -34,14 +34,14 @@ return tmp; } -ABTabWidget::WidgetTextBoxPtr ABTabWidget::createTextBoxHelper( WidgetChildWindowPtr parent, SmartWin::CreationalStruct & cs ) +ABTabWidget::WidgetTextBoxPtr ABTabWidget::createTextBoxHelper( WidgetChildWindowPtr parent, WidgetTextBox::Seed & cs ) { WidgetTextBoxPtr tmp = parent->createTextBox( cs ); tmp->setBorder(); return tmp; } -ABTabWidget::WidgetCheckBoxPtr ABTabWidget::createCheckBoxHelper( WidgetChildWindowPtr parent, SmartWin::CreationalStruct & cs, const SmartUtil::tstring & txt ) +ABTabWidget::WidgetCheckBoxPtr ABTabWidget::createCheckBoxHelper( WidgetChildWindowPtr parent, WidgetCheckBox::Seed & cs, const SmartUtil::tstring & txt ) { WidgetCheckBoxPtr tmp = parent->createCheckBox( cs ); tmp->setText( txt ); @@ -50,33 +50,33 @@ void ABTabWidget::createChildWidgets() { - SmartWin::CreationalStruct cs = SmartWin::defaultCreationalStruct; - cs.style |= WS_TABSTOP | ES_AUTOHSCROLL; - cs.exStyle |= WS_EX_CLIENTEDGE; + WidgetTextBox::Seed textSeed; + textSeed.style |= WS_TABSTOP | ES_AUTOHSCROLL; + textSeed.exStyle |= WS_EX_CLIENTEDGE; // First the Add/Change Entry addChange = createWidgetChildWindow(); firstName = createStaticHelper( addChange, _T( "First Name" ) ); - txtFirstName = createTextBoxHelper( addChange, cs ); + txtFirstName = createTextBoxHelper( addChange, textSeed ); txtFirstName->setFocus(); lastName = createStaticHelper( addChange, _T( "Last Name" ) ); - txtLastName = createTextBoxHelper( addChange, cs ); + txtLastName = createTextBoxHelper( addChange, textSeed ); address = createStaticHelper( addChange, _T( "Adr" ) ); - txtAddress = createTextBoxHelper( addChange, cs ); + txtAddress = createTextBoxHelper( addChange, textSeed ); email = createStaticHelper( addChange, _T( "E-Mail" ) ); - txtEmail = createTextBoxHelper( addChange, cs ); + txtEmail = createTextBoxHelper( addChange, textSeed ); explanation = createStaticHelper( addChange, _T( "Add new entry" ) ); - cs = SmartWin::defaultCreationalStruct; - cs.style |= WS_TABSTOP; - cs.exStyle |= WS_EX_STATICEDGE; + WidgetButton::Seed buttonSeed; + buttonSeed.style |= WS_TABSTOP; + buttonSeed.exStyle |= WS_EX_STATICEDGE; - btnAdd = addChange->createButton( cs ); + btnAdd = addChange->createButton( buttonSeed ); btnAdd->setText( _T( "&Add" ) ); btnAdd->onClicked( & ABTabWidget::addFunc ); @@ -88,30 +88,22 @@ // Then the Search search = createWidgetChildWindow(); - cs = SmartWin::defaultCreationalStruct; - cs.style |= WS_TABSTOP | ES_AUTOHSCROLL; - cs.exStyle |= WS_EX_CLIENTEDGE; - - SmartWin::CreationalStruct csChk = SmartWin::defaultCreationalStruct; - csChk.style |= WS_TABSTOP; - - chkFirstName = createCheckBoxHelper( search, csChk, _T( "First Name" ) ); - txtSearchFirstName = createTextBoxHelper( search, cs ); + WidgetCheckBox::Seed checkSeed; + checkSeed.style |= WS_TABSTOP; - chkLastName = createCheckBoxHelper( search, csChk, _T( "Last Name" ) ); - txtSearchLastName = createTextBoxHelper( search, cs ); + chkFirstName = createCheckBoxHelper( search, checkSeed, _T( "First Name" ) ); + txtSearchFirstName = createTextBoxHelper( search, textSeed ); - chkAddress = createCheckBoxHelper( search, csChk, _T( "Adr" ) ); - txtSearchAddress = createTextBoxHelper( search, cs ); + chkLastName = createCheckBoxHelper( search, checkSeed, _T( "Last Name" ) ); + txtSearchLastName = createTextBoxHelper( search, textSeed ); - chkEmail = createCheckBoxHelper( search, csChk, _T( "Mail" ) ); - txtSearchEmail = createTextBoxHelper( search, cs ); + chkAddress = createCheckBoxHelper( search, checkSeed, _T( "Adr" ) ); + txtSearchAddress = createTextBoxHelper( search, textSeed ); - cs = SmartWin::defaultCreationalStruct; - cs.style |= WS_TABSTOP; - cs.exStyle |= WS_EX_STATICEDGE; + chkEmail = createCheckBoxHelper( search, checkSeed, _T( "Mail" ) ); + txtSearchEmail = createTextBoxHelper( search, textSeed ); - btnSearch = search->createButton( cs ); + btnSearch = search->createButton( buttonSeed ); btnSearch->setText( _T( "&Search" ) ); btnSearch->onClicked( & ABTabWidget::searchFunc ); |