summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorSimon <simon@hardwired.org.uk>2010-12-30 10:04:20 (GMT)
committer Simon <simon@hardwired.org.uk>2010-12-30 10:04:20 (GMT)
commite8c6b37550620f959b4686789b09df9ceca3d987 (patch)
treed40b6598956231dbeaa82a59341b8985707e1801 /src
parentb92e6b391fd41b03002eca8b1c212c22b42bb707 (diff)
downloadpowder-e8c6b37550620f959b4686789b09df9ceca3d987.zip
powder-e8c6b37550620f959b4686789b09df9ceca3d987.tar.gz
Bit of readability
Diffstat (limited to 'src')
-rw-r--r--src/main.c15
1 files changed, 9 insertions, 6 deletions
diff --git a/src/main.c b/src/main.c
index de000ee..7c24475 100644
--- a/src/main.c
+++ b/src/main.c
@@ -2074,13 +2074,16 @@ int main(int argc, char *argv[])
}
if(x>=(XRES+BARSIZE-(510-476)) && x<=(XRES+BARSIZE-(510-491)) && !bq)
{
- if(b & SDL_BUTTON_LMASK)
+ if(b & SDL_BUTTON_LMASK){
set_cmode((cmode+1) % CM_COUNT);
- if(b & SDL_BUTTON_RMASK)
- if((cmode+(CM_COUNT-1)) % CM_COUNT == CM_LIFE)
- set_cmode(CM_GRAD);
- else
- set_cmode((cmode+(CM_COUNT-1)) % CM_COUNT);
+ }
+ if(b & SDL_BUTTON_RMASK){
+ if((cmode+(CM_COUNT-1)) % CM_COUNT == CM_LIFE) {
+ set_cmode(CM_GRAD);
+ } else {
+ set_cmode((cmode+(CM_COUNT-1)) % CM_COUNT);
+ }
+ }
save_presets(0);
}
if(x>=(XRES+BARSIZE-(510-494)) && x<=(XRES+BARSIZE-(510-509)) && !bq)