Rockbox.org home
release
dev builds
extras
themes manual
wiki
device status forums
mailing lists
IRC bugs
patches
dev guide



Rockbox mail archive

Subject: assistance with patch that isn't working.

assistance with patch that isn't working.

From: alex wallis <alexwallis646_at_googlemail.com>
Date: Thu, 6 Aug 2009 18:44:44 +0100

Hi list.

I would really appreciate it if someone could please take a look at a patch
for me and advise me why it isn't working?

the patch appears to apply fine with an offset of five lines in tree.c, but
I always got that offset even when the patch didn't cause problems. However
when I try to build rockbox with this patch applied, I get messages about
syntax errors in tree.c I am not sure why this is as I haven't had any
problems til now, I am assuming its something to do with changes to the wps
that has resulted in this issue, but I don't know what.

If someone could please take a look I would appreciate it.

I have pasted the full patch file below as I guess it all needs to be read.

Index: apps/action.h
===================================================================
--- apps/action.h.orig 2009-08-04 13:26:25.000000000 +0100
+++ apps/action.h 2009-08-04 13:28:39.760784000 +0100
@@ -100,7 +100,9 @@
     ACTION_STD_QUICKSCREEN,
     ACTION_STD_KEYLOCK,
     ACTION_STD_REC,
-
+#if CONFIG_TUNER
+ ACTION_STD_RADIO,
+#endif
     ACTION_F3, /* just so everything works again, possibly change me */
     /* code context actions */

@@ -122,6 +124,11 @@
     ACTION_WPS_MENU, /*this should be the same as ACTION_STD_MENU */
     ACTION_WPS_VIEW_PLAYLIST,
     ACTION_WPS_REC,
+#if CONFIG_TUNER
+ ACTION_WPS_RADIO,
+#endif
+ ACTION_WPS_PLAYINGTIME,
+
 #if 0
     ACTION_WPSAB_SINGLE, /* This needs to be #defined in
                             the config-<target>.h to one of the ACTION_WPS_
actions
Index: apps/keymaps/keymap-h1x0_h3x0.c
===================================================================
--- apps/keymaps/keymap-h1x0_h3x0.c.orig 2009-08-04 13:26:25.000000000 +0100
+++ apps/keymaps/keymap-h1x0_h3x0.c 2009-08-04 13:28:39.790827200 +0100
@@ -64,6 +64,7 @@
     { ACTION_STD_OK, BUTTON_RIGHT, BUTTON_NONE },
     { ACTION_STD_OK, BUTTON_ON|BUTTON_REL, BUTTON_NONE },
     { ACTION_STD_REC, BUTTON_REC|BUTTON_REPEAT,
BUTTON_NONE },
+ { ACTION_STD_RADIO, BUTTON_REC|BUTTON_REL,
       BUTTON_NONE },

     LAST_ITEM_IN_LIST
 }; /* button_context_standard */
Index: apps/menu.c
===================================================================
--- apps/menu.c.orig 2009-08-04 12:41:16.000000000 +0100
+++ apps/menu.c 2009-08-04 13:28:39.850913600 +0100
@@ -427,6 +427,13 @@
             done = true;
         }
 #endif
+#if CONFIG_TUNER
+ else if (action == ACTION_STD_RADIO)
+ {
+ ret = GO_TO_FM;
+ done =true;
+ }
+#endif
         else if (action == ACTION_TREE_WPS)
         {
             ret = GO_TO_PREVIOUS_MUSIC;
Index: apps/tree.c
===================================================================
--- apps/tree.c.orig 2009-08-04 12:37:10.000000000 +0100
+++ apps/tree.c 2009-08-04 14:11:40.171232000 +0100
@@ -723,7 +723,8 @@
              return GO_TO_FM;
 #endif

- case ACTION_TREE_WPS:
+
+case ACTION_TREE_WPS:
                 return GO_TO_PREVIOUS_MUSIC;
                 break;
 #ifdef HAVE_QUICKSCREEN
@@ -910,7 +911,9 @@
         static struct tree_context backup;
         char current[MAX_PATH];
         int last_context;
-
+ else /* reset current[] */
+ current[0] = '\0';
+
         backup = tc;
         tc.selected_item = 0;
         tc.dirlevel = 0;

-------------------------------------------------------------------
Unsubscribe: http://cool.haxx.se/cgi-bin/mailman/listinfo/rockbox
FAQ: http://www.rockbox.org/twiki/bin/view/Main/GeneralFAQ
Etiquette: http://www.rockbox.org/mail/etiquette.html
Received on 2009-08-06


Page was last modified "Jan 10 2012" The Rockbox Crew
aaa