summaryrefslogtreecommitdiff
path: root/apps
diff options
context:
space:
mode:
Diffstat (limited to 'apps')
-rw-r--r--apps/plugins/chessclock.c2
-rw-r--r--apps/plugins/pong.c10
-rw-r--r--apps/plugins/sudoku/sudoku.c10
3 files changed, 13 insertions, 9 deletions
diff --git a/apps/plugins/chessclock.c b/apps/plugins/chessclock.c
index 1bd6c80940..39b28628f0 100644
--- a/apps/plugins/chessclock.c
+++ b/apps/plugins/chessclock.c
@@ -242,7 +242,7 @@ PLUGIN_HEADER
242#define CHC_SETTINGS_INC BUTTON_NEXT 242#define CHC_SETTINGS_INC BUTTON_NEXT
243#define CHC_SETTINGS_DEC BUTTON_PREV 243#define CHC_SETTINGS_DEC BUTTON_PREV
244#define CHC_SETTINGS_OK BUTTON_PLAY 244#define CHC_SETTINGS_OK BUTTON_PLAY
245#define CHC_SETTINGS_CANEL BUTTON_POWER 245#define CHC_SETTINGS_CANCEL BUTTON_POWER
246 246
247#elif CONFIG_KEYPAD == ONDAVX747_PAD 247#elif CONFIG_KEYPAD == ONDAVX747_PAD
248#define CHC_QUIT BUTTON_POWER 248#define CHC_QUIT BUTTON_POWER
diff --git a/apps/plugins/pong.c b/apps/plugins/pong.c
index 13c5012770..73fb48356b 100644
--- a/apps/plugins/pong.c
+++ b/apps/plugins/pong.c
@@ -370,7 +370,7 @@ void score(struct pong *p, int pad)
370 /* avoid hitting the pad with the new ball */ 370 /* avoid hitting the pad with the new ball */
371 p->ballx = (p->ballx < 0) ? 371 p->ballx = (p->ballx < 0) ?
372 (RES * PAD_WIDTH) : (RES * (LCD_WIDTH - PAD_WIDTH - BALL_WIDTH)); 372 (RES * PAD_WIDTH) : (RES * (LCD_WIDTH - PAD_WIDTH - BALL_WIDTH));
373 373
374 /* restore Y-speed to default */ 374 /* restore Y-speed to default */
375 p->ballspeedy = (p->ballspeedy > 0) ? SPEEDY : -SPEEDY; 375 p->ballspeedy = (p->ballspeedy > 0) ? SPEEDY : -SPEEDY;
376 376
@@ -460,7 +460,7 @@ int keys(struct pong *p)
460 460
461 while(TIME_BEFORE(*rb->current_tick, end)) { 461 while(TIME_BEFORE(*rb->current_tick, end)) {
462 key = rb->button_get_w_tmo(end - *rb->current_tick); 462 key = rb->button_get_w_tmo(end - *rb->current_tick);
463 463
464#ifdef HAVE_TOUCHSCREEN 464#ifdef HAVE_TOUCHSCREEN
465 short touch_x, touch_y; 465 short touch_x, touch_y;
466 if(key & BUTTON_TOUCHSCREEN) 466 if(key & BUTTON_TOUCHSCREEN)
@@ -469,7 +469,7 @@ int keys(struct pong *p)
469 touch_y = rb->button_get_data() & 0xFFFF; 469 touch_y = rb->button_get_data() & 0xFFFF;
470 if(touch_x >= xpos[0] && touch_x <= xpos[0]+(PAD_WIDTH*4)) 470 if(touch_x >= xpos[0] && touch_x <= xpos[0]+(PAD_WIDTH*4))
471 padmove(&p->w_pad[0], touch_y-(p->e_pad[0]*2+PAD_HEIGHT)/2); 471 padmove(&p->w_pad[0], touch_y-(p->e_pad[0]*2+PAD_HEIGHT)/2);
472 472
473 if(touch_x >= xpos[1]-(PAD_WIDTH*4) && touch_x <= xpos[1]) 473 if(touch_x >= xpos[1]-(PAD_WIDTH*4) && touch_x <= xpos[1])
474 padmove(&p->w_pad[1], touch_y-(p->e_pad[1]*2+PAD_HEIGHT)/2); 474 padmove(&p->w_pad[1], touch_y-(p->e_pad[1]*2+PAD_HEIGHT)/2);
475 } 475 }
@@ -507,7 +507,7 @@ int keys(struct pong *p)
507 507
508 if(key & PONG_RIGHT_UP) /* player right goes up */ 508 if(key & PONG_RIGHT_UP) /* player right goes up */
509 padmove(&p->w_pad[1], -MOVE_STEP); 509 padmove(&p->w_pad[1], -MOVE_STEP);
510 510
511 if(rb->default_event_handler(key) == SYS_USB_CONNECTED) 511 if(rb->default_event_handler(key) == SYS_USB_CONNECTED)
512 return -1; /* exit game because of USB */ 512 return -1; /* exit game because of USB */
513 } 513 }
@@ -548,7 +548,7 @@ enum plugin_status plugin_start(const void* parameter)
548 /* if you don't use the parameter, you can do like 548 /* if you don't use the parameter, you can do like
549 this to avoid the compiler warning about it */ 549 this to avoid the compiler warning about it */
550 (void)parameter; 550 (void)parameter;
551 551
552 /* Clear screen */ 552 /* Clear screen */
553 rb->lcd_clear_display(); 553 rb->lcd_clear_display();
554 554
diff --git a/apps/plugins/sudoku/sudoku.c b/apps/plugins/sudoku/sudoku.c
index acd6065fbc..99b08f21a9 100644
--- a/apps/plugins/sudoku/sudoku.c
+++ b/apps/plugins/sudoku/sudoku.c
@@ -122,11 +122,9 @@ static const char default_game[9][9] =
122#define MARK_SIZE 1 /* Mark width and height */ 122#define MARK_SIZE 1 /* Mark width and height */
123 123
124#elif (LCD_HEIGHT==110) && (LCD_WIDTH==138) \ 124#elif (LCD_HEIGHT==110) && (LCD_WIDTH==138) \
125 || (LCD_HEIGHT==128) && (LCD_WIDTH==128) \ 125 || (LCD_HEIGHT==128) && (LCD_WIDTH==128)
126 || (LCD_HEIGHT==160) && (LCD_WIDTH==128)
127/* iPod Mini - 138x110, 9 cells @ 10x10 with 14 border lines */ 126/* iPod Mini - 138x110, 9 cells @ 10x10 with 14 border lines */
128/* iriver H10 5-6GB - 128x128, 9 cells @ 10x10 with 14 border lines */ 127/* iriver H10 5-6GB - 128x128, 9 cells @ 10x10 with 14 border lines */
129/* Philips GoGear SA9200 - 128x160, 9 cells @ 10x10 with 14 border tiles */
130#define MARK_OFFS 1 /* Pixels between border and mark */ 128#define MARK_OFFS 1 /* Pixels between border and mark */
131#define MARK_SPACE 1 /* Pixels between two marks */ 129#define MARK_SPACE 1 /* Pixels between two marks */
132#define MARK_SIZE 2 /* Mark width and height */ 130#define MARK_SIZE 2 /* Mark width and height */
@@ -176,6 +174,12 @@ static const char default_game[9][9] =
176#define MARK_SPACE 2 /* Pixels between two marks */ 174#define MARK_SPACE 2 /* Pixels between two marks */
177#define MARK_SIZE 6 /* Mark width and height */ 175#define MARK_SIZE 6 /* Mark width and height */
178 176
177#elif ((LCD_HEIGHT==160) && (LCD_WIDTH==128))
178/* Philips GoGear SA9200 - 128x160, 9 cells @ 10x10 with 14 border tiles */
179#define MARK_OFFS 1 /* Pixels between border and mark */
180#define MARK_SPACE 1 /* Pixels between two marks */
181#define MARK_SIZE 2 /* Mark width and height */
182
179#else 183#else
180 #error SUDOKU: Unsupported LCD size 184 #error SUDOKU: Unsupported LCD size
181#endif 185#endif