mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-08-29 08:21:07 +02:00
CTestMenu: add tests for CComponentsText
Origin commit data
------------------
Branch: ni/coolstream
Commit: 98b1e38dfa
Author: Thilo Graf <dbt@novatux.de>
Date: 2012-10-27 (Sat, 27 Oct 2012)
------------------
No further description and justification available within origin commit message!
------------------
This commit was generated by Migit
This commit is contained in:
@@ -67,6 +67,7 @@ CTestMenu::CTestMenu()
|
|||||||
pic= NULL;
|
pic= NULL;
|
||||||
pip = NULL;
|
pip = NULL;
|
||||||
form = NULL;
|
form = NULL;
|
||||||
|
txt = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
CTestMenu::~CTestMenu()
|
CTestMenu::~CTestMenu()
|
||||||
@@ -76,6 +77,7 @@ CTestMenu::~CTestMenu()
|
|||||||
delete pic;
|
delete pic;
|
||||||
delete pip;
|
delete pip;
|
||||||
delete form;
|
delete form;
|
||||||
|
delete txt;
|
||||||
}
|
}
|
||||||
|
|
||||||
int CTestMenu::exec(CMenuTarget* parent, const std::string &actionKey)
|
int CTestMenu::exec(CMenuTarget* parent, const std::string &actionKey)
|
||||||
@@ -375,6 +377,18 @@ int CTestMenu::exec(CMenuTarget* parent, const std::string &actionKey)
|
|||||||
form->paint();
|
form->paint();
|
||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
|
else if (actionKey == "text"){
|
||||||
|
if (txt == NULL)
|
||||||
|
txt = new CComponentsText();
|
||||||
|
txt->setDimensionsAll(100, 100, 250, 100);
|
||||||
|
txt->setText("This is a text for testing textbox", CTextBox::NO_AUTO_LINEBREAK);
|
||||||
|
|
||||||
|
if (txt->isPainted())
|
||||||
|
txt->hide();
|
||||||
|
else
|
||||||
|
txt->paint();
|
||||||
|
return res;
|
||||||
|
}
|
||||||
|
|
||||||
showTestMenu();
|
showTestMenu();
|
||||||
|
|
||||||
@@ -419,6 +433,7 @@ void CTestMenu::showCCTests(CMenuWidget *widget)
|
|||||||
widget->addItem(new CMenuForwarderNonLocalized("Picture", true, NULL, this, "picture"));
|
widget->addItem(new CMenuForwarderNonLocalized("Picture", true, NULL, this, "picture"));
|
||||||
widget->addItem(new CMenuForwarderNonLocalized("PiP", true, NULL, this, "pip"));
|
widget->addItem(new CMenuForwarderNonLocalized("PiP", true, NULL, this, "pip"));
|
||||||
widget->addItem(new CMenuForwarderNonLocalized("Form", true, NULL, this, "form"));
|
widget->addItem(new CMenuForwarderNonLocalized("Form", true, NULL, this, "form"));
|
||||||
|
widget->addItem(new CMenuForwarderNonLocalized("Text", true, NULL, this, "text"));
|
||||||
}
|
}
|
||||||
|
|
||||||
void CTestMenu::showHWTests(CMenuWidget *widget)
|
void CTestMenu::showHWTests(CMenuWidget *widget)
|
||||||
|
@@ -44,6 +44,7 @@ class CTestMenu : public CMenuTarget
|
|||||||
CComponentsPicture* pic;
|
CComponentsPicture* pic;
|
||||||
CComponentsPIP* pip;
|
CComponentsPIP* pip;
|
||||||
CComponentsForm *form;
|
CComponentsForm *form;
|
||||||
|
CComponentsText *txt;
|
||||||
int width, selected;
|
int width, selected;
|
||||||
|
|
||||||
void showTestMenu();
|
void showTestMenu();
|
||||||
|
Reference in New Issue
Block a user