本文整理汇总了C++中TableView::AddTableViewItemEventListener方法的典型用法代码示例。如果您正苦于以下问题:C++ TableView::AddTableViewItemEventListener方法的具体用法?C++ TableView::AddTableViewItemEventListener怎么用?C++ TableView::AddTableViewItemEventListener使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类TableView
的用法示例。
在下文中一共展示了TableView::AddTableViewItemEventListener方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: Construct
result ConfigForm::Construct(IActionEventListener * mainListener)
{
VerticalBoxLayout layout;
layout.Construct(VERTICAL_DIRECTION_DOWNWARD);
Form::Construct(layout, FORM_STYLE_NORMAL | FORM_STYLE_FOOTER);
Label * label = new Label();
label->Construct(Rectangle(0, 0, 48, 50), L"Device model:");
AddControl(*label);
layout.SetHorizontalFitPolicy(*label, FIT_POLICY_PARENT);
layout.SetVerticalFitPolicy(*label, FIT_POLICY_FIXED);
__pModelEditField = new EditField;
__pModelEditField->Construct(Rectangle(0, 0, 150, 110), EDIT_FIELD_STYLE_NORMAL, INPUT_STYLE_FULLSCREEN);
__pModelEditField->SetText(L"GT-I8800");
AddControl(*__pModelEditField);
layout.SetHorizontalFitPolicy(*__pModelEditField, FIT_POLICY_PARENT);
layout.SetVerticalFitPolicy(*__pModelEditField, FIT_POLICY_FIXED);
label = new Label();
label->Construct(Rectangle(0, 0, 48, 50), L"MNC:");
AddControl(*label);
layout.SetHorizontalFitPolicy(*label, FIT_POLICY_PARENT);
layout.SetVerticalFitPolicy(*label, FIT_POLICY_FIXED);
__pMncEditField = new EditField;
__pMncEditField->Construct(Rectangle(0, 0, 150, 110), EDIT_FIELD_STYLE_NUMBER, INPUT_STYLE_FULLSCREEN);
AddControl(*__pMncEditField);
layout.SetHorizontalFitPolicy(*__pMncEditField, FIT_POLICY_PARENT);
layout.SetVerticalFitPolicy(*__pMncEditField, FIT_POLICY_FIXED);
__pMncEditField->SetText(L"01");
label = new Label();
label->Construct(Rectangle(0, 0, 48, 50), L"Developer flag:");
AddControl(*label);
layout.SetHorizontalFitPolicy(*label, FIT_POLICY_PARENT);
layout.SetVerticalFitPolicy(*label, FIT_POLICY_FIXED);
__pDevRadioGroup = new RadioGroup;
__pDevRadioGroup->Construct();
CheckButton * devbutton = new CheckButton;
devbutton->Construct(Rectangle(0, 0, 150, 110), CHECK_BUTTON_STYLE_RADIO, BACKGROUND_STYLE_DEFAULT, false, "Developer mode, always success");
devbutton->SetActionId(BuyConfigInfo::AlwaysSuccess, BuyConfigInfo::AlwaysSuccess);
devbutton->AddActionEventListener(*this);
AddControl(*devbutton);
__pDevRadioGroup->Add(*devbutton);
layout.SetHorizontalFitPolicy(*devbutton, FIT_POLICY_PARENT);
layout.SetVerticalFitPolicy(*devbutton, FIT_POLICY_FIXED);
AppLog("chkbtn %p", devbutton);
__pDevRadioGroup->SetSelectedItem(*devbutton);
devbutton = new CheckButton;
devbutton->Construct(Rectangle(0, 0, 150, 110), CHECK_BUTTON_STYLE_RADIO, BACKGROUND_STYLE_DEFAULT, false, "Normal");
devbutton->SetActionId(BuyConfigInfo::Normal, BuyConfigInfo::Normal);
devbutton->AddActionEventListener(*this);
AddControl(*devbutton);
__pDevRadioGroup->Add(*devbutton);
layout.SetHorizontalFitPolicy(*devbutton, FIT_POLICY_PARENT);
layout.SetVerticalFitPolicy(*devbutton, FIT_POLICY_FIXED);
AddControl(*__pDevRadioGroup);
AppLog("chkbtn %p", devbutton);
TableView * pTableView = new TableView();
pTableView->Construct( Rectangle(0, 0, GetWidth(), 600), false, TABLE_VIEW_SCROLL_BAR_STYLE_NONE);
AddControl(*pTableView);
m_pTableView = pTableView;
pTableView->SetItemProvider(this);
pTableView->AddTableViewItemEventListener(*this);
layout.SetHorizontalFitPolicy(*pTableView, FIT_POLICY_PARENT);
layout.SetVerticalFitPolicy(*pTableView, FIT_POLICY_FIXED);
GetFooter()->SetStyle(FOOTER_STYLE_BUTTON_TEXT);
GetFooter()->AddActionEventListener(*this);
__pMainListener = mainListener;
BuyConfigInfo info;
info.m_developerFlag = BuyConfigInfo::AlwaysSuccess;
info.m_model = "GT-I8800";
info.m_mcc = "000";
info.m_mnc = "00";
__pEngine = new BuyEngine(this, info);
result r = __pEngine->RequestCountryList(0);
if ( IsFailed(r) ) AppLog(GetErrorMessage(r));
UpdateConfirmButtonState();
return E_SUCCESS;
}