1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-11-27 22:49:25 +02:00

End of buttons refactoring:

- cleanup of slider API
- documentation fixes
This commit is contained in:
Ivan Savenko
2014-08-03 17:31:56 +03:00
parent 0882201b17
commit 7390647cd5
8 changed files with 136 additions and 76 deletions

View File

@@ -295,9 +295,9 @@ void CTextBox::setText(const std::string &text)
label->setText(text);
OBJ_CONSTRUCTION_CAPTURING_ALL;
slider = new CSlider(pos.w - 32, 0, pos.h, boost::bind(&CTextBox::sliderMoved, this, _1),
label->pos.h, label->textSize.y, 0, false, sliderStyle);
slider->scrollStep = graphics->fonts[label->font]->getLineHeight();
slider = new CSlider(Point(pos.w - 32, 0), pos.h, boost::bind(&CTextBox::sliderMoved, this, _1),
label->pos.h, label->textSize.y, 0, false, CSlider::EStyle(sliderStyle));
slider->setScrollStep(graphics->fonts[label->font]->getLineHeight());
}
}