mirror of
git://projects.qi-hardware.com/gmenu2x.git
synced 2024-11-22 12:57:31 +02:00
On the skin menu, the ALTLEFT/ALTRIGHT buttons will now respectively decrease/increase the ARGB values by 10.
This commit is contained in:
parent
c22cc4d663
commit
38a83dd385
@ -90,6 +90,12 @@ void MenuSettingRGBA::manageInput(bevent_t *event) {
|
||||
case CLEAR:
|
||||
dec();
|
||||
break;
|
||||
case ALTLEFT:
|
||||
update_value(-10);
|
||||
break;
|
||||
case ALTRIGHT:
|
||||
update_value(10);
|
||||
break;
|
||||
case LEFT:
|
||||
leftComponent();
|
||||
break;
|
||||
@ -101,14 +107,19 @@ void MenuSettingRGBA::manageInput(bevent_t *event) {
|
||||
}
|
||||
}
|
||||
|
||||
void MenuSettingRGBA::update_value(int value)
|
||||
{
|
||||
setSelPart(constrain(getSelPart() + value, 0, 255));
|
||||
}
|
||||
|
||||
void MenuSettingRGBA::dec()
|
||||
{
|
||||
setSelPart(constrain(getSelPart()-1,0,255));
|
||||
update_value(-1);
|
||||
}
|
||||
|
||||
void MenuSettingRGBA::inc()
|
||||
{
|
||||
setSelPart(constrain(getSelPart()+1,0,255));
|
||||
update_value(+1);
|
||||
}
|
||||
|
||||
void MenuSettingRGBA::leftComponent()
|
||||
|
@ -34,6 +34,7 @@ private:
|
||||
RGBAColor originalValue;
|
||||
RGBAColor *_value;
|
||||
|
||||
void update_value(int value);
|
||||
void dec();
|
||||
void inc();
|
||||
void leftComponent();
|
||||
|
Loading…
Reference in New Issue
Block a user