Esempio n. 1
0
	/* Read fields into Mod */
	void ModFrame::dump(Mod * mod)
	{
		int n = 1;
		// mode
		mod->mod.mode = getChecked(modeRadios, MOVIESOAP_MOD_MODE_COUNT);
		// times
		mod->mod.start = parseTime(startText);
		mod->mod.stop = parseTime(stopText);
		mod->mod.title = parseInt(titleText);
		// severity
		mod->mod.severity = getChecked(severityRadios, MOVIESOAP_TOLERANCE_COUNT-1) + 1;
		// category
		mod->mod.category = categoryBox->currentIndex();
		// description
		mod->description = descText->text().toAscii().data();
	}
Esempio n. 2
0
void CheckBox::updateView(float mouseData[2], int clickType, wchar_t keyChar, vector<string> eventCompList) {


	if ((Button::isMouseOver(mouseData) == true) && getMouseOverContainer() && (Button::getSentClickEvent())) {

		setChecked(!getChecked());

		for (unsigned int i = 0; i < eventCompList.size(); i++) {
			GUIEventData::sendToComp(new GUIEventData(O_CHECKBOX_CHANGED,this->getName(),getChecked()),eventCompList.at(i).c_str());
		}

	}

	//override mouseOver of Button, so that also if the mouse is over the label the whole checkbox is in mouseover state
	if (ButtonLabel::getLabel()->isMouseOver(mouseData))		
		Button::setMouseOverIsTrue(true);
	else Button::setMouseOverIsTrue(false);

	ButtonLabel::setAutoUpdatePosX(false);
	ButtonLabel::updateView(mouseData,clickType,keyChar,eventCompList);


}