almost finishing theming support
This commit is contained in:
parent
5cbb13cf4b
commit
3932589790
8 changed files with 181 additions and 61 deletions
|
|
@ -187,7 +187,7 @@ namespace enginend{
|
|||
}
|
||||
};
|
||||
struct button :virtual public tinted{
|
||||
void(*func)();
|
||||
std::function<void()> func;
|
||||
bool pressed;
|
||||
bool hover;
|
||||
const bool isboolean;
|
||||
|
|
@ -214,14 +214,14 @@ namespace enginend{
|
|||
}else{
|
||||
pressed=false;
|
||||
c=isboolean?boolean?
|
||||
this->theme->booleanbutton[4]:this->theme->button[1]:
|
||||
this->theme->booleanbutton[4]:this->theme->booleanbutton[1]:
|
||||
this->theme->button[1];
|
||||
}
|
||||
}else{
|
||||
hover=false;
|
||||
pressed=false;
|
||||
c=isboolean?boolean?
|
||||
this->theme->booleanbutton[3]:this->theme->button[0]:
|
||||
this->theme->booleanbutton[3]:this->theme->booleanbutton[0]:
|
||||
this->theme->button[0];
|
||||
}
|
||||
}
|
||||
|
|
@ -270,13 +270,13 @@ namespace enginend{
|
|||
this->theme->buttontext[2];
|
||||
}else {
|
||||
txc=isboolean?boolean?
|
||||
this->theme->booleantext[4]:this->theme->buttontext[1]:
|
||||
this->theme->button[1];
|
||||
this->theme->booleantext[4]:this->theme->booleantext[1]:
|
||||
this->theme->buttontext[1];
|
||||
}
|
||||
}else {
|
||||
txc=isboolean?boolean?
|
||||
this->theme->booleantext[3]:this->theme->button[0]:
|
||||
this->theme->button[0];
|
||||
this->theme->booleantext[3]:this->theme->booleantext[0]:
|
||||
this->theme->buttontext[0];
|
||||
}
|
||||
DrawTextEx(this->theme->font,label.c_str(),tpos,fs,1,txc);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue