コード例 #1
0
ファイル: controlpotmeter.cpp プロジェクト: AlbanBedel/mixxx
ControlPotmeter::ControlPotmeter(ConfigKey key, double dMinValue, double dMaxValue)
        : ControlObject(key),
          m_controls(key) {
    setRange(dMinValue, dMaxValue);
    setStep(m_dValueRange / 10.f);
    setSmallStep(m_dValueRange / 100.f);
}
コード例 #2
0
ファイル: CGUIScrollBar.cpp プロジェクト: jivibounty/irrlicht
//! Reads attributes of the element
void CGUIScrollBar::deserializeAttributes(io::IAttributes* in, io::SAttributeReadWriteOptions* options=0)
{
	IGUIScrollBar::deserializeAttributes(in,options);

	Horizontal = in->getAttributeAsBool("Horizontal");
	setMax(in->getAttributeAsInt("Max"));
	setPos(in->getAttributeAsInt("Value"));
	setSmallStep(in->getAttributeAsInt("SmallStep"));
	setLargeStep(in->getAttributeAsInt("LargeStep"));

	refreshControls();
}
コード例 #3
0
	//! Reads attributes of the element
	void CGUIScrollBar::deserializeAttributes(IAttributes* in, SAttributeReadWriteOptions* options = 0)
	{
		IGUIScrollBar::deserializeAttributes(in, options);

		Horizontal = in->getAttributeAsBool("Horizontal");
		setMin(in->getAttributeAsInt("Min"));
		setMax(in->getAttributeAsInt("Max"));
		setPos(in->getAttributeAsInt("Value"));
		setSmallStep(in->getAttributeAsInt("SmallStep"));
		setLargeStep(in->getAttributeAsInt("LargeStep"));
		// CurrentIconColor - not serialized as continuiously updated

		refreshControls();
	}