示例#1
0
	/**
	 * Create layout that contains:
	 * - a Label widget.
	 * - a EditBox widget that will be used to get a file path for the
	 * pressed image.
	 */
	void PressedImageScreen::createEditBoxLayout()
	{
		NativeUI::HorizontalLayout* layout = new NativeUI::HorizontalLayout();
		layout->fillSpaceHorizontally();
		layout->wrapContentVertically();
		mMainLayout->addChild(layout);

		NativeUI::Label* label = new NativeUI::Label();
		label->wrapContentHorizontally();
		label->wrapContentVertically();
		label->setText(SET_PATH_LABEL_TEXT);
		layout->addChild(label);

		mPathEditBox = new NativeUI::EditBox();
		mPathEditBox->wrapContentVertically();
		mPathEditBox->fillSpaceHorizontally();
		layout->addChild(mPathEditBox);
	}