summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJonathan Gordon <rockbox@jdgordon.info>2006-08-16 13:25:45 +0000
committerJonathan Gordon <rockbox@jdgordon.info>2006-08-16 13:25:45 +0000
commit5e5bfabf6731758302a8ec15dc4f93109bf91d84 (patch)
treec539ebce3ac1aef9081201dcc52956704458216e
parent75765df6df134c718189125073806bfb4a1512b1 (diff)
downloadrockbox-5e5bfabf6731758302a8ec15dc4f93109bf91d84.tar.gz
rockbox-5e5bfabf6731758302a8ec15dc4f93109bf91d84.zip
* fixed the pitch screen key mappings for all targets, targets require a
mapping to access the screen from the wps git-svn-id: svn://svn.rockbox.org/rockbox/trunk@10611 a1c6a512-1295-4272-9138-f99709370657
-rw-r--r--apps/action.h23
-rw-r--r--apps/gui/gwps.c31
-rw-r--r--apps/keymaps/keymap-h1x0_h3x0.c30
-rw-r--r--apps/keymaps/keymap-ipod.c17
-rw-r--r--apps/keymaps/keymap-ondio.c18
-rw-r--r--apps/keymaps/keymap-recorder.c17
-rw-r--r--apps/keymaps/keymap-x5.c17
-rw-r--r--apps/onplay.c2
-rw-r--r--apps/screens.c36
-rw-r--r--apps/screens.h2
-rw-r--r--firmware/export/config-fmrecorder.h2
-rw-r--r--firmware/export/config-h100.h2
-rw-r--r--firmware/export/config-h120.h2
-rw-r--r--firmware/export/config-h300.h2
-rw-r--r--firmware/export/config-iaudiox5.h2
-rw-r--r--firmware/export/config-ipod3g.h2
-rw-r--r--firmware/export/config-ipod4g.h2
-rw-r--r--firmware/export/config-ipodcolor.h2
-rw-r--r--firmware/export/config-ipodmini.h2
-rwxr-xr-xfirmware/export/config-ipodmini2g.h2
-rw-r--r--firmware/export/config-ipodnano.h2
-rw-r--r--firmware/export/config-ipodvideo.h2
-rw-r--r--firmware/export/config-ondiofm.h3
-rw-r--r--firmware/export/config-ondiosp.h3
24 files changed, 170 insertions, 53 deletions
diff --git a/apps/action.h b/apps/action.h
index 2210bda176..c73a9e4867 100644
--- a/apps/action.h
+++ b/apps/action.h
@@ -46,6 +46,7 @@ enum {
46 CONTEXT_YESNOSCREEN, /*NOTE: make sure your target has this and ACTION_YESNO_ACCEPT */ 46 CONTEXT_YESNOSCREEN, /*NOTE: make sure your target has this and ACTION_YESNO_ACCEPT */
47 CONTEXT_BOOKMARKSCREEN, /*NOTE: requires the action_setting_* mappings also */ 47 CONTEXT_BOOKMARKSCREEN, /*NOTE: requires the action_setting_* mappings also */
48 CONTEXT_QUICKSCREEN, /* uses ACTION_QS_ defines below */ 48 CONTEXT_QUICKSCREEN, /* uses ACTION_QS_ defines below */
49 CONTEXT_PITCHSCREEN, /* uses ACTION_PS_ defines below */
49}; 50};
50 51
51 52
@@ -82,18 +83,14 @@ enum {
82 ACTION_WPS_STOP, 83 ACTION_WPS_STOP,
83 ACTION_WPS_VOLDOWN, 84 ACTION_WPS_VOLDOWN,
84 ACTION_WPS_VOLUP, 85 ACTION_WPS_VOLUP,
85 ACTION_WPS_NEXTDIR,/* optional */
86 ACTION_WPS_PREVDIR,/* optional */
87 ACTION_WPS_PITCHSCREEN,/* optional */ 86 ACTION_WPS_PITCHSCREEN,/* optional */
88 ACTION_WPS_ID3SCREEN,/* optional */ 87 ACTION_WPS_ID3SCREEN,/* optional */
89 ACTION_WPS_CONTEXT, 88 ACTION_WPS_CONTEXT,
90 ACTION_WPS_QUICKSCREEN,/* optional */ 89 ACTION_WPS_QUICKSCREEN,/* optional */
91 ACTION_WPS_MENU, /*this should be the same as ACTION_STD_MENU */ 90 ACTION_WPS_MENU, /*this should be the same as ACTION_STD_MENU */
92 /* following code are for AB mode in wps,
93 only needed if defined(AB_REPEAT_ENABLE) */
94 ACTION_WPSAB_SINGLE, /* No targets use this, but leave n just-in-case! */ 91 ACTION_WPSAB_SINGLE, /* No targets use this, but leave n just-in-case! */
95 ACTION_WPSAB_SETA, /* either #define WPS_AB_SHARE_DIR_BUTTONS */ 92 ACTION_WPS_ABSETA_PREVDIR, /* these should be safe to put together seen as */
96 ACTION_WPSAB_SETB, /* OR implement ACTION_WPSAB_SET[AB] */ 93 ACTION_WPS_ABSETB_NEXTDIR, /* you shouldnt want to change dir in ab-mode */
97 ACTION_WPSAB_RESET, 94 ACTION_WPSAB_RESET,
98 95
99 /* list and tree page up/down */ 96 /* list and tree page up/down */
@@ -134,6 +131,20 @@ enum {
134 ACTION_QS_DOWN, 131 ACTION_QS_DOWN,
135 ACTION_QS_DOWNINV, /* why is this not called up?? :p */ 132 ACTION_QS_DOWNINV, /* why is this not called up?? :p */
136 133
134 /* pitchscreen */
135 /* obviously ignore if you dont have thise screen */
136 ACTION_PS_INC_SMALL,
137 ACTION_PS_INC_BIG,
138 ACTION_PS_DEC_SMALL,
139 ACTION_PS_DEC_BIG,
140 ACTION_PS_NUDGE_LEFT,
141 ACTION_PS_NUDGE_RIGHT,
142 ACTION_PS_NUDGE_LEFTOFF,
143 ACTION_PS_NUDGE_RIGHTOFF,
144 ACTION_PS_RESET,
145 ACTION_PS_EXIT, /* _STD_* isnt going to work here */
146
147
137}; 148};
138 149
139struct button_mapping { 150struct button_mapping {
diff --git a/apps/gui/gwps.c b/apps/gui/gwps.c
index 2b80172ad4..12e120f7d4 100644
--- a/apps/gui/gwps.c
+++ b/apps/gui/gwps.c
@@ -19,6 +19,7 @@
19#include <stdio.h> 19#include <stdio.h>
20#include <string.h> 20#include <string.h>
21#include <stdlib.h> 21#include <stdlib.h>
22#include "config.h"
22 23
23#include "system.h" 24#include "system.h"
24#include "file.h" 25#include "file.h"
@@ -373,10 +374,11 @@ long gui_wps_show(void)
373 audio_next(); 374 audio_next();
374 break; 375 break;
375 /* next / prev directories */ 376 /* next / prev directories */
376 case ACTION_WPS_NEXTDIR: 377 /* and set A-B markers if in a-b mode */
378 case ACTION_WPS_ABSETB_NEXTDIR:
377 if (global_settings.party_mode) 379 if (global_settings.party_mode)
378 break; 380 break;
379#if defined(AB_REPEAT_ENABLE) && defined(WPS_AB_SHARE_DIR_BUTTONS) 381#if defined(AB_REPEAT_ENABLE)
380 if (ab_repeat_mode_enabled()) 382 if (ab_repeat_mode_enabled())
381 { 383 {
382 ab_set_B_marker(wps_state.id3->elapsed); 384 ab_set_B_marker(wps_state.id3->elapsed);
@@ -389,10 +391,10 @@ long gui_wps_show(void)
389 audio_next_dir(); 391 audio_next_dir();
390 } 392 }
391 break; 393 break;
392 case ACTION_WPS_PREVDIR: 394 case ACTION_WPS_ABSETA_PREVDIR:
393 if (global_settings.party_mode) 395 if (global_settings.party_mode)
394 break; 396 break;
395#if defined(AB_REPEAT_ENABLE) && defined(WPS_AB_SHARE_DIR_BUTTONS) 397#if defined(AB_REPEAT_ENABLE)
396 if (ab_repeat_mode_enabled()) 398 if (ab_repeat_mode_enabled())
397 ab_set_A_marker(wps_state.id3->elapsed); 399 ab_set_A_marker(wps_state.id3->elapsed);
398 else 400 else
@@ -465,10 +467,10 @@ long gui_wps_show(void)
465 { 467 {
466 gui_wps_set_margin(&gui_wps[i]); 468 gui_wps_set_margin(&gui_wps[i]);
467 } 469 }
468#endif /* BUTTON_F3 */ 470#endif
469 restore = true; 471 restore = true;
470 break; 472 break;
471#endif 473#endif /* BUTTON_F3 */
472 474
473 /* pitch screen */ 475 /* pitch screen */
474#ifdef HAVE_PITCHSCREEN 476#ifdef HAVE_PITCHSCREEN
@@ -476,6 +478,7 @@ long gui_wps_show(void)
476#ifdef HAVE_LCD_COLOR 478#ifdef HAVE_LCD_COLOR
477 show_main_backdrop(); 479 show_main_backdrop();
478#endif 480#endif
481 action_signalscreenchange();
479 if (1 == pitch_screen()) 482 if (1 == pitch_screen())
480 return SYS_USB_CONNECTED; 483 return SYS_USB_CONNECTED;
481#ifdef HAVE_LCD_COLOR 484#ifdef HAVE_LCD_COLOR
@@ -505,22 +508,6 @@ long gui_wps_show(void)
505 } 508 }
506 ab_set_A_marker(wps_state.id3->elapsed); 509 ab_set_A_marker(wps_state.id3->elapsed);
507 break; 510 break;
508
509
510 /* set A marker for A-B repeat */
511 case ACTION_WPSAB_SETA:
512 if (ab_repeat_mode_enabled())
513 ab_set_A_marker(wps_state.id3->elapsed);
514 break;
515 /* set B marker for A-B repeat and jump to A */
516 case ACTION_WPSAB_SETB:
517 if (ab_repeat_mode_enabled())
518 {
519 ab_set_B_marker(wps_state.id3->elapsed);
520 ab_jump_to_A_marker();
521 update_track = true;
522 }
523 break;
524 /* reset A&B markers */ 511 /* reset A&B markers */
525 case ACTION_WPSAB_RESET: 512 case ACTION_WPSAB_RESET:
526 if (ab_repeat_mode_enabled()) 513 if (ab_repeat_mode_enabled())
diff --git a/apps/keymaps/keymap-h1x0_h3x0.c b/apps/keymaps/keymap-h1x0_h3x0.c
index 557feea3ff..a087ea6c55 100644
--- a/apps/keymaps/keymap-h1x0_h3x0.c
+++ b/apps/keymaps/keymap-h1x0_h3x0.c
@@ -5,6 +5,7 @@
5 * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < < 5 * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
6 * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \ 6 * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
7 * \/ \/ \/ \/ \/ 7 * \/ \/ \/ \/ \/
8 * $Id $
8 * 9 *
9 * Copyright (C) 2006 Jonathan Gordon 10 * Copyright (C) 2006 Jonathan Gordon
10 * 11 *
@@ -61,6 +62,7 @@ const struct button_mapping button_context_standard[] = {
61 62
62 63
63const struct button_mapping button_context_wps[] = { 64const struct button_mapping button_context_wps[] = {
65 { ACTION_NONE, BUTTON_ON, BUTTON_NONE },
64 { ACTION_WPS_PLAY, BUTTON_ON|BUTTON_REL, BUTTON_ON }, 66 { ACTION_WPS_PLAY, BUTTON_ON|BUTTON_REL, BUTTON_ON },
65 { ACTION_WPS_SKIPNEXT, BUTTON_RIGHT|BUTTON_REL, BUTTON_RIGHT }, 67 { ACTION_WPS_SKIPNEXT, BUTTON_RIGHT|BUTTON_REL, BUTTON_RIGHT },
66 { ACTION_WPS_SKIPPREV, BUTTON_LEFT|BUTTON_REL, BUTTON_LEFT }, 68 { ACTION_WPS_SKIPPREV, BUTTON_LEFT|BUTTON_REL, BUTTON_LEFT },
@@ -68,14 +70,15 @@ const struct button_mapping button_context_wps[] = {
68 { ACTION_WPS_SEEKFWD, BUTTON_RIGHT|BUTTON_REPEAT, BUTTON_NONE }, 70 { ACTION_WPS_SEEKFWD, BUTTON_RIGHT|BUTTON_REPEAT, BUTTON_NONE },
69 { ACTION_WPS_STOPSEEK, BUTTON_LEFT|BUTTON_REL, BUTTON_LEFT|BUTTON_REPEAT }, 71 { ACTION_WPS_STOPSEEK, BUTTON_LEFT|BUTTON_REL, BUTTON_LEFT|BUTTON_REPEAT },
70 { ACTION_WPS_STOPSEEK, BUTTON_RIGHT|BUTTON_REL, BUTTON_RIGHT|BUTTON_REPEAT }, 72 { ACTION_WPS_STOPSEEK, BUTTON_RIGHT|BUTTON_REL, BUTTON_RIGHT|BUTTON_REPEAT },
71 { ACTION_WPS_NEXTDIR, BUTTON_ON|BUTTON_RIGHT, BUTTON_ON }, 73 { ACTION_WPS_ABSETB_NEXTDIR, BUTTON_ON|BUTTON_RIGHT, BUTTON_ON },
72 { ACTION_WPS_PREVDIR, BUTTON_ON|BUTTON_LEFT, BUTTON_ON }, 74 { ACTION_WPS_ABSETA_PREVDIR, BUTTON_ON|BUTTON_LEFT, BUTTON_ON },
73 { ACTION_WPS_STOP, BUTTON_OFF, BUTTON_NONE }, 75 { ACTION_WPS_STOP, BUTTON_OFF, BUTTON_NONE },
74 { ACTION_WPS_VOLDOWN, BUTTON_DOWN|BUTTON_REL, BUTTON_DOWN }, 76 { ACTION_WPS_VOLDOWN, BUTTON_DOWN|BUTTON_REL, BUTTON_DOWN },
75 { ACTION_WPS_VOLDOWN, BUTTON_DOWN|BUTTON_REPEAT, BUTTON_NONE }, 77 { ACTION_WPS_VOLDOWN, BUTTON_DOWN|BUTTON_REPEAT, BUTTON_NONE },
76 { ACTION_WPS_VOLUP, BUTTON_UP|BUTTON_REL, BUTTON_UP }, 78 { ACTION_WPS_VOLUP, BUTTON_UP|BUTTON_REL, BUTTON_UP },
77 { ACTION_WPS_VOLUP, BUTTON_UP|BUTTON_REPEAT, BUTTON_NONE }, 79 { ACTION_WPS_VOLUP, BUTTON_UP|BUTTON_REPEAT, BUTTON_NONE },
78 { ACTION_WPS_PITCHSCREEN, BUTTON_ON|BUTTON_REPEAT, BUTTON_ON }, 80 { ACTION_WPS_PITCHSCREEN, BUTTON_ON|BUTTON_UP, BUTTON_ON },
81 { ACTION_WPS_PITCHSCREEN, BUTTON_ON|BUTTON_DOWN, BUTTON_ON },
79 { ACTION_WPS_QUICKSCREEN, BUTTON_MODE|BUTTON_REPEAT, BUTTON_MODE }, 82 { ACTION_WPS_QUICKSCREEN, BUTTON_MODE|BUTTON_REPEAT, BUTTON_MODE },
80 { ACTION_WPS_MENU, BUTTON_MODE|BUTTON_REL, BUTTON_MODE }, 83 { ACTION_WPS_MENU, BUTTON_MODE|BUTTON_REL, BUTTON_MODE },
81 { ACTION_WPS_CONTEXT, BUTTON_SELECT|BUTTON_REPEAT, BUTTON_SELECT }, 84 { ACTION_WPS_CONTEXT, BUTTON_SELECT|BUTTON_REPEAT, BUTTON_SELECT },
@@ -176,6 +179,21 @@ const struct button_mapping button_context_quickscreen[] = {
176 179
177 LAST_ITEM_IN_LIST 180 LAST_ITEM_IN_LIST
178}; /* button_context_quickscreen */ 181}; /* button_context_quickscreen */
182
183const struct button_mapping button_context_pitchscreen[] = {
184 { ACTION_PS_INC_SMALL, BUTTON_UP, BUTTON_NONE },
185 { ACTION_PS_INC_BIG, BUTTON_UP|BUTTON_REPEAT, BUTTON_UP },
186 { ACTION_PS_DEC_SMALL, BUTTON_DOWN, BUTTON_NONE },
187 { ACTION_PS_DEC_BIG, BUTTON_DOWN|BUTTON_REPEAT, BUTTON_DOWN },
188 { ACTION_PS_NUDGE_LEFT, BUTTON_LEFT, BUTTON_NONE },
189 { ACTION_PS_NUDGE_LEFTOFF, BUTTON_LEFT|BUTTON_REL, BUTTON_NONE },
190 { ACTION_PS_NUDGE_RIGHT, BUTTON_RIGHT, BUTTON_NONE },
191 { ACTION_PS_NUDGE_RIGHTOFF, BUTTON_RIGHT|BUTTON_REL, BUTTON_NONE },
192 { ACTION_PS_RESET, BUTTON_ON, BUTTON_NONE },
193 { ACTION_PS_EXIT, BUTTON_OFF, BUTTON_NONE },
194
195 LAST_ITEM_IN_LIST
196}; /* button_context_pitchcreen */
179/***************************************************************************** 197/*****************************************************************************
180 * Remote control mappings 198 * Remote control mappings
181 *****************************************************************************/ 199 *****************************************************************************/
@@ -209,8 +227,8 @@ const struct button_mapping button_context_wps_h100lcdremote[] = {
209 { ACTION_WPS_VOLDOWN, BUTTON_RC_VOL_DOWN|BUTTON_REPEAT, BUTTON_NONE }, 227 { ACTION_WPS_VOLDOWN, BUTTON_RC_VOL_DOWN|BUTTON_REPEAT, BUTTON_NONE },
210 { ACTION_WPS_VOLUP, BUTTON_RC_VOL_UP, BUTTON_NONE }, 228 { ACTION_WPS_VOLUP, BUTTON_RC_VOL_UP, BUTTON_NONE },
211 { ACTION_WPS_VOLUP, BUTTON_RC_VOL_UP|BUTTON_REPEAT, BUTTON_NONE }, 229 { ACTION_WPS_VOLUP, BUTTON_RC_VOL_UP|BUTTON_REPEAT, BUTTON_NONE },
212 { ACTION_WPS_NEXTDIR, BUTTON_RC_BITRATE, BUTTON_NONE }, 230 { ACTION_WPS_ABSETB_NEXTDIR, BUTTON_RC_BITRATE, BUTTON_NONE },
213 { ACTION_WPS_PREVDIR, BUTTON_RC_SOURCE, BUTTON_NONE }, 231 { ACTION_WPS_ABSETA_PREVDIR, BUTTON_RC_SOURCE, BUTTON_NONE },
214 { ACTION_WPS_PITCHSCREEN, BUTTON_RC_ON|BUTTON_REPEAT, BUTTON_RC_ON }, 232 { ACTION_WPS_PITCHSCREEN, BUTTON_RC_ON|BUTTON_REPEAT, BUTTON_RC_ON },
215 { ACTION_WPS_QUICKSCREEN, BUTTON_RC_MODE|BUTTON_REPEAT, BUTTON_RC_MODE }, 233 { ACTION_WPS_QUICKSCREEN, BUTTON_RC_MODE|BUTTON_REPEAT, BUTTON_RC_MODE },
216 { ACTION_WPS_MENU, BUTTON_RC_MODE|BUTTON_REL, BUTTON_RC_MODE }, 234 { ACTION_WPS_MENU, BUTTON_RC_MODE|BUTTON_REL, BUTTON_RC_MODE },
@@ -383,6 +401,8 @@ const struct button_mapping* get_context_mapping(int context)
383 return button_context_bmark; 401 return button_context_bmark;
384 case CONTEXT_QUICKSCREEN: 402 case CONTEXT_QUICKSCREEN:
385 return button_context_quickscreen; 403 return button_context_quickscreen;
404 case CONTEXT_PITCHSCREEN:
405 return button_context_pitchscreen;
386 } 406 }
387 return button_context_standard; 407 return button_context_standard;
388} 408}
diff --git a/apps/keymaps/keymap-ipod.c b/apps/keymaps/keymap-ipod.c
index 2beb428b6b..96e2f20e9e 100644
--- a/apps/keymaps/keymap-ipod.c
+++ b/apps/keymaps/keymap-ipod.c
@@ -129,6 +129,21 @@ const struct button_mapping button_context_quickscreen[] = {
129 LAST_ITEM_IN_LIST 129 LAST_ITEM_IN_LIST
130}; /* button_context_quickscreen */ 130}; /* button_context_quickscreen */
131 131
132const struct button_mapping button_context_pitchscreen[] = {
133 { ACTION_PS_INC_SMALL, BUTTON_SCROLL_FWD, BUTTON_NONE },
134 { ACTION_PS_INC_BIG, BUTTON_SCROLL_FWD|BUTTON_REPEAT, BUTTON_SCROLL_FWD },
135 { ACTION_PS_DEC_SMALL, BUTTON_SCROLL_BACK, BUTTON_NONE },
136 { ACTION_PS_DEC_BIG, BUTTON_SCROLL_BACK|BUTTON_REPEAT, BUTTON_SCROLL_BACK },
137 { ACTION_PS_NUDGE_LEFT, BUTTON_LEFT, BUTTON_NONE },
138 { ACTION_PS_NUDGE_LEFTOFF, BUTTON_LEFT|BUTTON_REL, BUTTON_NONE },
139 { ACTION_PS_NUDGE_RIGHT, BUTTON_RIGHT, BUTTON_NONE },
140 { ACTION_PS_NUDGE_RIGHTOFF, BUTTON_RIGHT|BUTTON_REL, BUTTON_NONE },
141 { ACTION_PS_RESET, BUTTON_MENU, BUTTON_NONE },
142 { ACTION_PS_EXIT, BUTTON_SELECT, BUTTON_NONE },
143
144 LAST_ITEM_IN_LIST
145}; /* button_context_pitchscreen */
146
132/* get_context_mapping returns a pointer to one of the above defined arrays depending on the context */ 147/* get_context_mapping returns a pointer to one of the above defined arrays depending on the context */
133const struct button_mapping* get_context_mapping(int context) 148const struct button_mapping* get_context_mapping(int context)
134{ 149{
@@ -158,6 +173,8 @@ const struct button_mapping* get_context_mapping(int context)
158 return button_context_bmark; 173 return button_context_bmark;
159 case CONTEXT_QUICKSCREEN: 174 case CONTEXT_QUICKSCREEN:
160 return button_context_quickscreen; 175 return button_context_quickscreen;
176 case CONTEXT_PITCHSCREEN:
177 return button_context_pitchscreen;
161 default: 178 default:
162 return button_context_standard; 179 return button_context_standard;
163 } 180 }
diff --git a/apps/keymaps/keymap-ondio.c b/apps/keymaps/keymap-ondio.c
index a82d6eb5fa..7ca7d20c83 100644
--- a/apps/keymaps/keymap-ondio.c
+++ b/apps/keymaps/keymap-ondio.c
@@ -111,6 +111,21 @@ struct button_mapping button_context_bmark[] = {
111 LAST_ITEM_IN_LIST__NEXTLIST(CONTEXT_SETTINGS), 111 LAST_ITEM_IN_LIST__NEXTLIST(CONTEXT_SETTINGS),
112}; /* button_context_settings_bmark */ 112}; /* button_context_settings_bmark */
113 113
114const struct button_mapping button_context_pitchscreen[] = {
115 { ACTION_PS_INC_SMALL, BUTTON_UP, BUTTON_NONE },
116 { ACTION_PS_INC_BIG, BUTTON_UP|BUTTON_REPEAT, BUTTON_UP },
117 { ACTION_PS_DEC_SMALL, BUTTON_DOWN, BUTTON_NONE },
118 { ACTION_PS_DEC_BIG, BUTTON_DOWN|BUTTON_REPEAT, BUTTON_DOWN },
119 { ACTION_PS_NUDGE_LEFT, BUTTON_LEFT, BUTTON_NONE },
120 { ACTION_PS_NUDGE_LEFTOFF, BUTTON_LEFT|BUTTON_REL, BUTTON_NONE },
121 { ACTION_PS_NUDGE_RIGHT, BUTTON_RIGHT, BUTTON_NONE },
122 { ACTION_PS_NUDGE_RIGHTOFF, BUTTON_RIGHT|BUTTON_REL, BUTTON_NONE },
123 { ACTION_PS_RESET, BUTTON_MENU, BUTTON_NONE },
124 { ACTION_PS_EXIT, BUTTON_OFF, BUTTON_NONE },
125
126 LAST_ITEM_IN_LIST
127}; /* button_context_quickscreen */
128
114const struct button_mapping* get_context_mapping( int context ) 129const struct button_mapping* get_context_mapping( int context )
115{ 130{
116 switch( context ) 131 switch( context )
@@ -129,7 +144,8 @@ const struct button_mapping* get_context_mapping( int context )
129 144
130 case CONTEXT_BOOKMARKSCREEN: 145 case CONTEXT_BOOKMARKSCREEN:
131 return button_context_bmark; 146 return button_context_bmark;
132 147 case CONTEXT_PITCHSCREEN:
148 return button_context_pitchscreen;
133 case CONTEXT_TREE: 149 case CONTEXT_TREE:
134 if (global_settings.hold_lr_for_scroll_in_list) 150 if (global_settings.hold_lr_for_scroll_in_list)
135 return button_context_tree_scroll_lr; 151 return button_context_tree_scroll_lr;
diff --git a/apps/keymaps/keymap-recorder.c b/apps/keymaps/keymap-recorder.c
index a28286936e..a0a0426d32 100644
--- a/apps/keymaps/keymap-recorder.c
+++ b/apps/keymaps/keymap-recorder.c
@@ -125,6 +125,21 @@ const struct button_mapping button_context_quickscreen[] = {
125 LAST_ITEM_IN_LIST 125 LAST_ITEM_IN_LIST
126}; /* button_context_quickscreen */ 126}; /* button_context_quickscreen */
127 127
128const struct button_mapping button_context_pitchscreen[] = {
129 { ACTION_PS_INC_SMALL, BUTTON_UP, BUTTON_NONE },
130 { ACTION_PS_INC_BIG, BUTTON_UP|BUTTON_REPEAT, BUTTON_UP },
131 { ACTION_PS_DEC_SMALL, BUTTON_DOWN, BUTTON_NONE },
132 { ACTION_PS_DEC_BIG, BUTTON_DOWN|BUTTON_REPEAT, BUTTON_DOWN },
133 { ACTION_PS_NUDGE_LEFT, BUTTON_LEFT, BUTTON_NONE },
134 { ACTION_PS_NUDGE_LEFTOFF, BUTTON_LEFT|BUTTON_REL, BUTTON_NONE },
135 { ACTION_PS_NUDGE_RIGHT, BUTTON_RIGHT, BUTTON_NONE },
136 { ACTION_PS_NUDGE_RIGHTOFF, BUTTON_RIGHT|BUTTON_REL, BUTTON_NONE },
137 { ACTION_PS_RESET, BUTTON_ON, BUTTON_NONE },
138 { ACTION_PS_EXIT, BUTTON_OFF, BUTTON_NONE },
139
140 LAST_ITEM_IN_LIST
141}; /* button_context_pitchcreen */
142
128const struct button_mapping* get_context_mapping( int context ) 143const struct button_mapping* get_context_mapping( int context )
129{ 144{
130 switch( context ) 145 switch( context )
@@ -137,6 +152,8 @@ const struct button_mapping* get_context_mapping( int context )
137 152
138 case CONTEXT_YESNOSCREEN: 153 case CONTEXT_YESNOSCREEN:
139 return button_context_yesno; 154 return button_context_yesno;
155 case CONTEXT_PITCHSCREEN:
156 return button_context_pitchscreen;
140 157
141 case CONTEXT_TREE: 158 case CONTEXT_TREE:
142 if (global_settings.hold_lr_for_scroll_in_list) 159 if (global_settings.hold_lr_for_scroll_in_list)
diff --git a/apps/keymaps/keymap-x5.c b/apps/keymaps/keymap-x5.c
index 61e20f9d46..d428de0e27 100644
--- a/apps/keymaps/keymap-x5.c
+++ b/apps/keymaps/keymap-x5.c
@@ -124,6 +124,21 @@ const struct button_mapping button_context_quickscreen[] = {
124 LAST_ITEM_IN_LIST 124 LAST_ITEM_IN_LIST
125}; /* button_context_quickscreen */ 125}; /* button_context_quickscreen */
126 126
127const struct button_mapping button_context_pitchscreen[] = {
128 { ACTION_PS_INC_SMALL, BUTTON_UP, BUTTON_NONE },
129 { ACTION_PS_INC_BIG, BUTTON_UP|BUTTON_REPEAT, BUTTON_UP },
130 { ACTION_PS_DEC_SMALL, BUTTON_DOWN, BUTTON_NONE },
131 { ACTION_PS_DEC_BIG, BUTTON_DOWN|BUTTON_REPEAT, BUTTON_DOWN },
132 { ACTION_PS_NUDGE_LEFT, BUTTON_LEFT, BUTTON_NONE },
133 { ACTION_PS_NUDGE_LEFTOFF, BUTTON_LEFT|BUTTON_REL, BUTTON_NONE },
134 { ACTION_PS_NUDGE_RIGHT, BUTTON_RIGHT, BUTTON_NONE },
135 { ACTION_PS_NUDGE_RIGHTOFF, BUTTON_RIGHT|BUTTON_REL, BUTTON_NONE },
136 { ACTION_PS_RESET, BUTTON_POWER, BUTTON_NONE },
137 { ACTION_PS_EXIT, BUTTON_PLAY, BUTTON_NONE },
138
139 LAST_ITEM_IN_LIST
140}; /* button_context_pitchscreen */
141
127const struct button_mapping* get_context_mapping( int context ) 142const struct button_mapping* get_context_mapping( int context )
128{ 143{
129 switch( context ) 144 switch( context )
@@ -148,6 +163,8 @@ const struct button_mapping* get_context_mapping( int context )
148 return button_context_tree; 163 return button_context_tree;
149 case CONTEXT_QUICKSCREEN: 164 case CONTEXT_QUICKSCREEN:
150 return button_context_quickscreen; 165 return button_context_quickscreen;
166 case CONTEXT_PITCHSCREEN:
167 return button_context_pitchscreen;
151 case CONTEXT_LIST: 168 case CONTEXT_LIST:
152 case CONTEXT_MAINMENU: 169 case CONTEXT_MAINMENU:
153 default: 170 default:
diff --git a/apps/onplay.c b/apps/onplay.c
index 231e658ed9..106c433d60 100644
--- a/apps/onplay.c
+++ b/apps/onplay.c
@@ -961,7 +961,7 @@ int onplay(char* file, int attr, int from)
961 } 961 }
962 if (context == CONTEXT_WPS) 962 if (context == CONTEXT_WPS)
963 { 963 {
964#if (CONFIG_KEYPAD != PLAYER_PAD) 964#ifdef HAVE_PITCHSCREEN
965 /* Pitch screen access */ 965 /* Pitch screen access */
966 items[i].desc = ID2P(LANG_PITCH); 966 items[i].desc = ID2P(LANG_PITCH);
967 items[i].function = pitch_screen; 967 items[i].function = pitch_screen;
diff --git a/apps/screens.c b/apps/screens.c
index 43680e5564..42faac4cfa 100644
--- a/apps/screens.c
+++ b/apps/screens.c
@@ -351,7 +351,7 @@ int charging_screen(void)
351} 351}
352#endif /* CONFIG_CHARGING && !HAVE_POWEROFF_WHILE_CHARGING */ 352#endif /* CONFIG_CHARGING && !HAVE_POWEROFF_WHILE_CHARGING */
353 353
354#if (CONFIG_KEYPAD != PLAYER_PAD) 354#ifdef HAVE_PITCHSCREEN
355/* returns: 355/* returns:
356 0 if no key was pressed 356 0 if no key was pressed
357 1 if USB was connected */ 357 1 if USB was connected */
@@ -416,19 +416,20 @@ bool pitch_screen(void)
416 pcmbuf_set_low_latency(true); 416 pcmbuf_set_low_latency(true);
417#endif 417#endif
418 418
419 action_signalscreenchange();
419 while (!exit) 420 while (!exit)
420 { 421 {
421 pitch_screen_draw(pitch); 422 pitch_screen_draw(pitch);
422 423
423 button = get_action(CONTEXT_SETTINGS,TIMEOUT_BLOCK); 424 button = get_action(CONTEXT_PITCHSCREEN,TIMEOUT_BLOCK);
424 switch (button) { 425 switch (button) {
425 case ACTION_SETTINGS_INC: 426 case ACTION_PS_DEC_SMALL:
426 if ( pitch < 2000 ) 427 if ( pitch < 2000 )
427 pitch++; 428 pitch++;
428 sound_set_pitch(pitch); 429 sound_set_pitch(pitch);
429 break; 430 break;
430 431
431 case ACTION_SETTINGS_INCREPEAT: 432 case ACTION_PS_DEC_BIG:
432 if ( pitch < 1990 ) 433 if ( pitch < 1990 )
433 pitch += 10; 434 pitch += 10;
434 else 435 else
@@ -436,13 +437,13 @@ bool pitch_screen(void)
436 sound_set_pitch(pitch); 437 sound_set_pitch(pitch);
437 break; 438 break;
438 439
439 case ACTION_SETTINGS_DEC: 440 case ACTION_PS_INC_SMALL:
440 if ( pitch > 500 ) 441 if ( pitch > 500 )
441 pitch--; 442 pitch--;
442 sound_set_pitch(pitch); 443 sound_set_pitch(pitch);
443 break; 444 break;
444 445
445 case ACTION_SETTINGS_DECREPEAT: 446 case ACTION_PS_INC_BIG:
446 if ( pitch > 510 ) 447 if ( pitch > 510 )
447 pitch -= 10; 448 pitch -= 10;
448 else 449 else
@@ -450,33 +451,32 @@ bool pitch_screen(void)
450 sound_set_pitch(pitch); 451 sound_set_pitch(pitch);
451 break; 452 break;
452 453
453 case ACTION_STD_NEXT: 454 case ACTION_PS_NUDGE_RIGHT:
454 if ( pitch < 1980 ) 455 if ( pitch < 1980 )
455 { 456 {
456 pitch += 20; 457 pitch += 20;
457 sound_set_pitch(pitch); 458 sound_set_pitch(pitch);
458
459 pitch_screen_draw(pitch); 459 pitch_screen_draw(pitch);
460
461 pitch -= 20;
462 sound_set_pitch(pitch);
463 } 460 }
464 break; 461 break;
462 case ACTION_PS_NUDGE_RIGHTOFF:
463 pitch -= 20;
464 sound_set_pitch(pitch);
465 break;
465 466
466 case ACTION_STD_PREV: 467 case ACTION_PS_NUDGE_LEFT:
467 if ( pitch > 520 ) 468 if ( pitch > 520 )
468 { 469 {
469 pitch -= 20; 470 pitch -= 20;
470 sound_set_pitch(pitch); 471 sound_set_pitch(pitch);
471
472 pitch_screen_draw(pitch); 472 pitch_screen_draw(pitch);
473
474 pitch += 20;
475 sound_set_pitch(pitch);
476 } 473 }
474 case ACTION_PS_NUDGE_LEFTOFF:
475 pitch += 20;
476 sound_set_pitch(pitch);
477 break; 477 break;
478 478
479 case ACTION_STD_OK: 479 case ACTION_PS_RESET:
480 pitch = 1000; 480 pitch = 1000;
481 sound_set_pitch( pitch ); 481 sound_set_pitch( pitch );
482 break; 482 break;
@@ -498,7 +498,7 @@ bool pitch_screen(void)
498 action_signalscreenchange(); 498 action_signalscreenchange();
499 return 0; 499 return 0;
500} 500}
501#endif 501#endif /* HAVE_PITCHSCREEN */
502 502
503#ifdef HAVE_QUICKSCREEN 503#ifdef HAVE_QUICKSCREEN
504 504
diff --git a/apps/screens.h b/apps/screens.h
index deece8784d..c34f612ded 100644
--- a/apps/screens.h
+++ b/apps/screens.h
@@ -33,7 +33,9 @@ void charging_splash(void);
33int mmc_remove_request(void); 33int mmc_remove_request(void);
34#endif 34#endif
35 35
36#ifdef HAVE_PITCHSCREEN
36bool pitch_screen(void); 37bool pitch_screen(void);
38#endif
37 39
38#if CONFIG_KEYPAD == RECORDER_PAD 40#if CONFIG_KEYPAD == RECORDER_PAD
39extern bool quick_screen_f3(int button_enter); 41extern bool quick_screen_f3(int button_enter);
diff --git a/firmware/export/config-fmrecorder.h b/firmware/export/config-fmrecorder.h
index 7a78d48822..4009d334ab 100644
--- a/firmware/export/config-fmrecorder.h
+++ b/firmware/export/config-fmrecorder.h
@@ -9,6 +9,8 @@
9 9
10/* define this if you have access to the quickscreen */ 10/* define this if you have access to the quickscreen */
11#define HAVE_QUICKSCREEN 11#define HAVE_QUICKSCREEN
12/* define this if you have access to the pitchscreen */
13#define HAVE_PITCHSCREEN
12 14
13/* LCD dimensions */ 15/* LCD dimensions */
14#define LCD_WIDTH 112 16#define LCD_WIDTH 112
diff --git a/firmware/export/config-h100.h b/firmware/export/config-h100.h
index 38f26c104b..52f7625760 100644
--- a/firmware/export/config-h100.h
+++ b/firmware/export/config-h100.h
@@ -18,6 +18,8 @@
18 18
19/* define this if you have access to the quickscreen */ 19/* define this if you have access to the quickscreen */
20#define HAVE_QUICKSCREEN 20#define HAVE_QUICKSCREEN
21/* define this if you have access to the pitchscreen */
22#define HAVE_PITCHSCREEN
21 23
22/* LCD dimensions */ 24/* LCD dimensions */
23#define LCD_WIDTH 160 25#define LCD_WIDTH 160
diff --git a/firmware/export/config-h120.h b/firmware/export/config-h120.h
index a9b0ed3039..69fd565c23 100644
--- a/firmware/export/config-h120.h
+++ b/firmware/export/config-h120.h
@@ -14,6 +14,8 @@
14 14
15/* define this if you have access to the quickscreen */ 15/* define this if you have access to the quickscreen */
16#define HAVE_QUICKSCREEN 16#define HAVE_QUICKSCREEN
17/* define this if you have access to the pitchscreen */
18#define HAVE_PITCHSCREEN
17 19
18/* LCD dimensions */ 20/* LCD dimensions */
19#define LCD_WIDTH 160 21#define LCD_WIDTH 160
diff --git a/firmware/export/config-h300.h b/firmware/export/config-h300.h
index 2a174bc4e5..a310a4eef3 100644
--- a/firmware/export/config-h300.h
+++ b/firmware/export/config-h300.h
@@ -17,6 +17,8 @@
17 17
18/* define this if you have access to the quickscreen */ 18/* define this if you have access to the quickscreen */
19#define HAVE_QUICKSCREEN 19#define HAVE_QUICKSCREEN
20/* define this if you have access to the pitchscreen */
21#define HAVE_PITCHSCREEN
20 22
21/* LCD dimensions */ 23/* LCD dimensions */
22#define LCD_WIDTH 220 24#define LCD_WIDTH 220
diff --git a/firmware/export/config-iaudiox5.h b/firmware/export/config-iaudiox5.h
index 40772f7ffa..8a2ed7a29d 100644
--- a/firmware/export/config-iaudiox5.h
+++ b/firmware/export/config-iaudiox5.h
@@ -17,6 +17,8 @@
17 17
18/* define this if you have access to the quickscreen */ 18/* define this if you have access to the quickscreen */
19#define HAVE_QUICKSCREEN 19#define HAVE_QUICKSCREEN
20/* define this if you have access to the pitchscreen */
21#define HAVE_PITCHSCREEN
20 22
21/* LCD dimensions */ 23/* LCD dimensions */
22#define LCD_WIDTH 160 24#define LCD_WIDTH 160
diff --git a/firmware/export/config-ipod3g.h b/firmware/export/config-ipod3g.h
index 831ff40c1d..7a7000c080 100644
--- a/firmware/export/config-ipod3g.h
+++ b/firmware/export/config-ipod3g.h
@@ -14,6 +14,8 @@
14 14
15/* define this if you have access to the quickscreen */ 15/* define this if you have access to the quickscreen */
16#define HAVE_QUICKSCREEN 16#define HAVE_QUICKSCREEN
17/* define this if you have access to the pitchscreen */
18#define HAVE_PITCHSCREEN
17 19
18/* LCD dimensions */ 20/* LCD dimensions */
19#define LCD_WIDTH 160 21#define LCD_WIDTH 160
diff --git a/firmware/export/config-ipod4g.h b/firmware/export/config-ipod4g.h
index 46abbdf72b..163d91c3db 100644
--- a/firmware/export/config-ipod4g.h
+++ b/firmware/export/config-ipod4g.h
@@ -14,6 +14,8 @@
14 14
15/* define this if you have access to the quickscreen */ 15/* define this if you have access to the quickscreen */
16#define HAVE_QUICKSCREEN 16#define HAVE_QUICKSCREEN
17/* define this if you have access to the pitchscreen */
18#define HAVE_PITCHSCREEN
17 19
18/* LCD dimensions */ 20/* LCD dimensions */
19#define LCD_WIDTH 160 21#define LCD_WIDTH 160
diff --git a/firmware/export/config-ipodcolor.h b/firmware/export/config-ipodcolor.h
index e063e93737..3366baa8ea 100644
--- a/firmware/export/config-ipodcolor.h
+++ b/firmware/export/config-ipodcolor.h
@@ -17,6 +17,8 @@
17 17
18/* define this if you have access to the quickscreen */ 18/* define this if you have access to the quickscreen */
19#define HAVE_QUICKSCREEN 19#define HAVE_QUICKSCREEN
20/* define this if you have access to the pitchscreen */
21#define HAVE_PITCHSCREEN
20 22
21/* LCD dimensions */ 23/* LCD dimensions */
22#define LCD_WIDTH 220 24#define LCD_WIDTH 220
diff --git a/firmware/export/config-ipodmini.h b/firmware/export/config-ipodmini.h
index c842de4001..12bc658610 100644
--- a/firmware/export/config-ipodmini.h
+++ b/firmware/export/config-ipodmini.h
@@ -14,6 +14,8 @@
14 14
15/* define this if you have access to the quickscreen */ 15/* define this if you have access to the quickscreen */
16#define HAVE_QUICKSCREEN 16#define HAVE_QUICKSCREEN
17/* define this if you have access to the pitchscreen */
18#define HAVE_PITCHSCREEN
17 19
18/* LCD dimensions */ 20/* LCD dimensions */
19#define LCD_WIDTH 138 21#define LCD_WIDTH 138
diff --git a/firmware/export/config-ipodmini2g.h b/firmware/export/config-ipodmini2g.h
index ea19f5c985..2b2e967599 100755
--- a/firmware/export/config-ipodmini2g.h
+++ b/firmware/export/config-ipodmini2g.h
@@ -14,6 +14,8 @@
14 14
15/* define this if you have access to the quickscreen */ 15/* define this if you have access to the quickscreen */
16#define HAVE_QUICKSCREEN 16#define HAVE_QUICKSCREEN
17/* define this if you have access to the pitchscreen */
18#define HAVE_PITCHSCREEN
17 19
18/* LCD dimensions */ 20/* LCD dimensions */
19#define LCD_WIDTH 138 21#define LCD_WIDTH 138
diff --git a/firmware/export/config-ipodnano.h b/firmware/export/config-ipodnano.h
index 3d4deb3abd..c077c381f8 100644
--- a/firmware/export/config-ipodnano.h
+++ b/firmware/export/config-ipodnano.h
@@ -17,6 +17,8 @@
17 17
18/* define this if you have access to the quickscreen */ 18/* define this if you have access to the quickscreen */
19#define HAVE_QUICKSCREEN 19#define HAVE_QUICKSCREEN
20/* define this if you have access to the pitchscreen */
21#define HAVE_PITCHSCREEN
20 22
21/* LCD dimensions */ 23/* LCD dimensions */
22#define LCD_WIDTH 176 24#define LCD_WIDTH 176
diff --git a/firmware/export/config-ipodvideo.h b/firmware/export/config-ipodvideo.h
index 79ef1a85ac..5cea64deb4 100644
--- a/firmware/export/config-ipodvideo.h
+++ b/firmware/export/config-ipodvideo.h
@@ -17,6 +17,8 @@
17 17
18/* define this if you have access to the quickscreen */ 18/* define this if you have access to the quickscreen */
19#define HAVE_QUICKSCREEN 19#define HAVE_QUICKSCREEN
20/* define this if you have access to the pitchscreen */
21#define HAVE_PITCHSCREEN
20 22
21/* LCD dimensions */ 23/* LCD dimensions */
22#define LCD_WIDTH 320 24#define LCD_WIDTH 320
diff --git a/firmware/export/config-ondiofm.h b/firmware/export/config-ondiofm.h
index 3e6ca50877..ec20929b62 100644
--- a/firmware/export/config-ondiofm.h
+++ b/firmware/export/config-ondiofm.h
@@ -15,6 +15,9 @@
15/* define this if you have an Ondio style 6-key keyboard */ 15/* define this if you have an Ondio style 6-key keyboard */
16#define CONFIG_KEYPAD ONDIO_PAD 16#define CONFIG_KEYPAD ONDIO_PAD
17 17
18/* define this if you have access to the pitchscreen */
19#define HAVE_PITCHSCREEN
20
18/* Define this if you have a software controlled poweroff */ 21/* Define this if you have a software controlled poweroff */
19#define HAVE_SW_POWEROFF 22#define HAVE_SW_POWEROFF
20 23
diff --git a/firmware/export/config-ondiosp.h b/firmware/export/config-ondiosp.h
index 67de4db45c..c6b70e3685 100644
--- a/firmware/export/config-ondiosp.h
+++ b/firmware/export/config-ondiosp.h
@@ -12,6 +12,9 @@
12/* define this if you have an Ondio style 6-key keyboard */ 12/* define this if you have an Ondio style 6-key keyboard */
13#define CONFIG_KEYPAD ONDIO_PAD 13#define CONFIG_KEYPAD ONDIO_PAD
14 14
15/* define this if you have access to the pitchscreen */
16#define HAVE_PITCHSCREEN
17
15/* Define this if you have a software controlled poweroff */ 18/* Define this if you have a software controlled poweroff */
16#define HAVE_SW_POWEROFF 19#define HAVE_SW_POWEROFF
17 20