本文整理汇总了C++中cegui::FrameWindow::isVisible方法的典型用法代码示例。如果您正苦于以下问题:C++ FrameWindow::isVisible方法的具体用法?C++ FrameWindow::isVisible怎么用?C++ FrameWindow::isVisible使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类cegui::FrameWindow
的用法示例。
在下文中一共展示了FrameWindow::isVisible方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1:
/***********************************************************
destructor
***********************************************************/
CommunityBox::~CommunityBox()
{
try
{
CEGUI::FrameWindow * frw = static_cast<CEGUI::FrameWindow *> (
CEGUI::WindowManager::getSingleton().getWindow("CommunityFrame"));
CEGUI::UVector2 vec = frw->getPosition();
ConfigurationManager::GetInstance()->SetFloat("Gui.Communitybox.PosX", vec.d_x.d_scale);
ConfigurationManager::GetInstance()->SetFloat("Gui.Communitybox.PosY", vec.d_y.d_scale);
ConfigurationManager::GetInstance()->SetFloat("Gui.Communitybox.SizeX", frw->getWidth().d_scale);
ConfigurationManager::GetInstance()->SetFloat("Gui.Communitybox.SizeY", frw->getHeight().d_scale);
ConfigurationManager::GetInstance()->SetFloat("Gui.Communitybox.OffsetPosX", vec.d_x.d_offset);
ConfigurationManager::GetInstance()->SetFloat("Gui.Communitybox.OffsetPosY", vec.d_y.d_offset);
ConfigurationManager::GetInstance()->SetFloat("Gui.Communitybox.OffsetSizeX", frw->getWidth().d_offset);
ConfigurationManager::GetInstance()->SetFloat("Gui.Communitybox.OffsetSizeY", frw->getHeight().d_offset);
ConfigurationManager::GetInstance()->SetBool("Gui.Communitybox.Visible", frw->isVisible());
}
catch(CEGUI::Exception &ex)
{
LogHandler::getInstance()->LogToFile(std::string("Exception destructor community box: ") + ex.getMessage().c_str());
}
}
示例2:
/***********************************************************
destructor
***********************************************************/
JournalBox::~JournalBox()
{
try
{
CEGUI::FrameWindow * frw = static_cast<CEGUI::FrameWindow *> (
CEGUI::WindowManager::getSingleton().getWindow("JournalFrame"));
int resX, resY;
bool fullscreen;
OsgHandler::getInstance()->GetScreenAttributes(resX, resY, fullscreen);
CEGUI::UVector2 vec = frw->getPosition();
ConfigurationManager::GetInstance()->SetValue("Gui.JournalBox.PosX", vec.d_x.asRelative((float)resX));
ConfigurationManager::GetInstance()->SetValue("Gui.JournalBox.PosY", vec.d_y.asRelative((float)resY));
ConfigurationManager::GetInstance()->SetValue("Gui.JournalBox.SizeX", frw->getWidth().asRelative((float)resX));
ConfigurationManager::GetInstance()->SetValue("Gui.JournalBox.SizeY", frw->getHeight().asRelative((float)resY));
ConfigurationManager::GetInstance()->SetValue("Gui.JournalBox.Visible", frw->isVisible());
{
std::string qtreedown;
std::string selected;
std::map<std::string, CEGUI::TreeItem *>::iterator itm = _mapquestarea.begin();
std::map<std::string, CEGUI::TreeItem *>::iterator endm = _mapquestarea.end();
for(; itm != endm; ++itm)
{
if(itm->second->getIsOpen())
{
qtreedown += "##" + itm->first;
}
std::vector<CEGUI::TreeItem*> items = itm->second->getItemList();
for(size_t i=0; i<items.size(); ++i)
{
if(items[i]->isSelected())
selected = items[i]->getText().c_str();
}
}
ConfigurationManager::GetInstance()->SetValue("Gui.JournalBox.QuestTreeOpen", qtreedown);
ConfigurationManager::GetInstance()->SetValue("Gui.JournalBox.QuestTreeSelected", selected);
}
{
std::string qtreedown;
std::string selected;
std::map<std::string, CEGUI::TreeItem *>::iterator itm = _mapquestdonearea.begin();
std::map<std::string, CEGUI::TreeItem *>::iterator endm = _mapquestdonearea.end();
for(; itm != endm; ++itm)
{
if(itm->second->getIsOpen())
{
qtreedown += "##" + itm->first;
}
std::vector<CEGUI::TreeItem*> items = itm->second->getItemList();
for(size_t i=0; i<items.size(); ++i)
{
if(items[i]->isSelected())
selected = items[i]->getText().c_str();
}
}
ConfigurationManager::GetInstance()->SetValue("Gui.JournalBox.QuestDoneTreeOpen", qtreedown);
ConfigurationManager::GetInstance()->SetValue("Gui.JournalBox.QuestDoneTreeSelected", selected);
}
}
catch(CEGUI::Exception &ex)
{
LogHandler::getInstance()->LogToFile(std::string("Exception destructor Inventorybox: ") + ex.getMessage().c_str());
}
}