Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependents: TouchScreenGUIDemo
Widgets/SpinnerWidget.cpp
- Committer:
- duncanFrance
- Date:
- 2016-04-22
- Revision:
- 11:b485561aa112
- Child:
- 12:63db16fea709
File content as of revision 11:b485561aa112:
#include "SpinnerWidget.h"
#include"resources/spinner-upArrow.bmp"
#include"resources/spinner-downArrow.bmp"
SpinnerWidget::SpinnerWidget(GUI* gui) : ContainerWidget(gui),
_upArrow(gui), _downArrow(gui), _text(gui), _min(0), _max(0), _increment(1), _value(0)
{
_upArrow.setBitmap(spinner_upArrow_bmp);
_upArrow.setSize(10,10);
_downArrow.setBitmap(spinner_downArrow_bmp);
_downArrow.setSize(10,10);
_text.setSize(gui->defaultFont()->width() * 4, gui->defaultFont()->height());
append(_upArrow);
append(_downArrow);
append(_text);
}
void SpinnerWidget::setMin(float min)
{
}
void SpinnerWidget::setMax(float max)
{
}
void SpinnerWidget::setIncrement(float increment)
{
}
void SpinnerWidget::setValue(float value)
{
}
void SpinnerWidget::getValue()
{
}
template<typename T>
void SpinnerWidget::onChange(T* tptr, void (T::*mptr)(SpinnerWidget*))
{
_onChange.attach(tptr, mptr);
}
void SpinnerWidget::_onUpClick() {
}
void SpinnerWidget::_onDownClick() {
}