1
0
mirror of git://projects.qi-hardware.com/gmenu2x.git synced 2025-04-21 12:27:27 +03:00

Rewrite of how the events are handled by the menusetting* objects.

This commit is contained in:
Ayla
2011-09-15 20:20:35 +02:00
parent fdee206d93
commit 7f2c7db8e2
12 changed files with 60 additions and 77 deletions

View File

@@ -82,29 +82,30 @@ void MenuSettingRGBA::handleTS() {
MenuSetting::handleTS();
}
void MenuSettingRGBA::manageInput(bevent_t *event) {
switch(event->button) {
case MANUAL:
inc();
break;
case CLEAR:
dec();
break;
bool MenuSettingRGBA::manageInput(bevent_t *event) {
switch(event->button) {
case MANUAL:
inc();
break;
case CLEAR:
dec();
break;
case ALTLEFT:
update_value(-10);
break;
case ALTRIGHT:
update_value(10);
break;
case LEFT:
leftComponent();
break;
case RIGHT:
rightComponent();
break;
default:
break;
}
case LEFT:
leftComponent();
break;
case RIGHT:
rightComponent();
break;
default:
return false;
}
return true;
}
void MenuSettingRGBA::update_value(int value)