From 28dfb54eeb77b1c99972b3b5fa9f1d1fd97e04e4 Mon Sep 17 00:00:00 2001 From: Jonathan Gordon Date: Sun, 11 Nov 2007 04:48:33 +0000 Subject: change the SCREEN_ROTATE define to be more meaningful, and set the mr500 orientation to landscape by default git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15567 a1c6a512-1295-4272-9138-f99709370657 --- firmware/export/config-mrobe500.h | 8 ++++++-- firmware/export/config.h | 15 +++++++++++++++ 2 files changed, 21 insertions(+), 2 deletions(-) (limited to 'firmware/export') diff --git a/firmware/export/config-mrobe500.h b/firmware/export/config-mrobe500.h index 850a2e83a1..3156b87060 100644 --- a/firmware/export/config-mrobe500.h +++ b/firmware/export/config-mrobe500.h @@ -49,8 +49,12 @@ /* LCD dimensions */ #define CONFIG_LCD LCD_MROBE500 -#define SCREEN_ROTATE -#if defined(SCREEN_ROTATE) + +/* choose the lcd orientation. both work */ +/* #define CONFIG_ORIENTATION SCREEN_PORTAIT */ +#define CONFIG_ORIENTATION SCREEN_LANDSCAPE + +#if CONFIG_ORIENTATION == SCREEN_PORTAIT #define LCD_WIDTH 480 #define LCD_HEIGHT 640 #else diff --git a/firmware/export/config.h b/firmware/export/config.h index 538c75d08a..48dc3f5693 100644 --- a/firmware/export/config.h +++ b/firmware/export/config.h @@ -118,6 +118,11 @@ #define RGB565 565 #define RGB565SWAPPED 3553 +/* CONFIG_ORIENTATION */ +#define SCREEN_PORTAIT 0 +#define SCREEN_LANDSCAPE 1 +#define SCREEN_SQUARE 2 + /* CONFIG_I2C */ #define I2C_PLAYREC 1 /* Archos Player/Recorder style */ #define I2C_ONDIO 2 /* Ondio style */ @@ -251,6 +256,16 @@ #define CONFIG_RTC 0 #endif +#ifndef CONFIG_ORIENTATION +#if LCD_HEIGHT > LCD_WIDTH +#define CONFIG_ORIENTATION SCREEN_PORTAIT +#elif LCD_HEIGHT < LCD_WIDTH +#define CONFIG_ORIENTATION SCREEN_LANDSCAPE +#else +#define CONFIG_ORIENTATION SCREEN_SQUARE +#endif +#endif + /* define this in the target config.h to use a different size */ #ifndef CONFIG_DEFAULT_ICON_HEIGHT #define CONFIG_DEFAULT_ICON_HEIGHT 8 -- cgit v1.2.3