예제 #1
0
파일: TuiManager.cpp 프로젝트: Kudoo/Tui-x
CWidgetWindow *TuiManager::createPanel(float tag, float x, float y, int w, int h,float rotation){
	CWidgetWindow *pPanel = CWidgetWindow::create();
	pPanel->setContentSize(Size(w, h));
	pPanel->setPosition(Point(x,y));
	pPanel->setRotation(rotation);
	pPanel->setTag(tag);
	return pPanel;
}
예제 #2
0
void TuiManager::doAdapterResolution(Node* pScene){
	for (auto node : pScene->getChildren()) {
		CWidgetWindow *pWindow = dynamic_cast<CWidgetWindow*>(node);
		if (pWindow != nullptr){
			pWindow->setPosition(Arp(pWindow->getPosition()));
			for (auto child : pWindow->getChildren()) {
				child->setPosition(Arp(child->getPosition()));
			}
		}
	}
}