1
0
mirror of git://projects.qi-hardware.com/gmenu2x.git synced 2024-06-30 21:13:51 +03:00

Rearrange calls to GMenu2X::drawButton from left to right

This breaks up large reversed call chains in a few places.
This commit is contained in:
Nebuleon Fumika 2014-08-15 22:23:57 +00:00 committed by Maarten ter Huurne
parent fe0db484ec
commit 9b583f9b38
3 changed files with 17 additions and 14 deletions

View File

@ -471,10 +471,11 @@ void LinkApp::showManual() {
pngman->blit(s, -page*320, 0); pngman->blit(s, -page*320, 0);
gmenu2x->drawBottomBar(s); gmenu2x->drawBottomBar(s);
gmenu2x->drawButton(s, "start", gmenu2x->tr["Exit"], int x = 5;
gmenu2x->drawButton(s, "cancel", "", x = gmenu2x->drawButton(s, "left", "", x);
gmenu2x->drawButton(s, "right", gmenu2x->tr["Change page"], x = gmenu2x->drawButton(s, "right", gmenu2x->tr["Change page"], x);
gmenu2x->drawButton(s, "left", "", 5)))); x = gmenu2x->drawButton(s, "cancel", "", x);
x = gmenu2x->drawButton(s, "start", gmenu2x->tr["Exit"], x);
ss.clear(); ss.clear();
ss << page+1; ss << page+1;

View File

@ -70,10 +70,11 @@ void TextDialog::exec() {
writeTitle(bg, title); writeTitle(bg, title);
writeSubTitle(bg, description); writeSubTitle(bg, description);
gmenu2x->drawButton(bg, "start", gmenu2x->tr["Exit"], int x = 5;
gmenu2x->drawButton(bg, "cancel", "", x = gmenu2x->drawButton(bg, "up", "", x);
gmenu2x->drawButton(bg, "down", gmenu2x->tr["Scroll"], x = gmenu2x->drawButton(bg, "down", gmenu2x->tr["Scroll"], x);
gmenu2x->drawButton(bg, "up", "", 5)))); x = gmenu2x->drawButton(bg, "cancel", "", x);
x = gmenu2x->drawButton(bg, "start", gmenu2x->tr["Exit"], x);
bg.convertToDisplayFormat(); bg.convertToDisplayFormat();

View File

@ -77,12 +77,13 @@ void TextManualDialog::exec() {
drawTitleIcon(bg, icon, false); drawTitleIcon(bg, icon, false);
writeTitle(bg, title+(description.empty() ? "" : ": "+description)); writeTitle(bg, title+(description.empty() ? "" : ": "+description));
gmenu2x->drawButton(bg, "start", gmenu2x->tr["Exit"], int x = 5;
gmenu2x->drawButton(bg, "cancel", "", x = gmenu2x->drawButton(bg, "up", "", x);
gmenu2x->drawButton(bg, "right", gmenu2x->tr["Change page"], x = gmenu2x->drawButton(bg, "down", gmenu2x->tr["Scroll"], x);
gmenu2x->drawButton(bg, "left", "", x = gmenu2x->drawButton(bg, "left", "", x);
gmenu2x->drawButton(bg, "down", gmenu2x->tr["Scroll"], x = gmenu2x->drawButton(bg, "right", gmenu2x->tr["Change page"], x);
gmenu2x->drawButton(bg, "up", "", 5)))))); x = gmenu2x->drawButton(bg, "cancel", "", x);
x = gmenu2x->drawButton(bg, "start", gmenu2x->tr["Exit"], x);
bg.convertToDisplayFormat(); bg.convertToDisplayFormat();