Results 1 to 6 of 6
  1. jrfougere's Avatar
    Posts
    20 Posts
    Global Posts
    21 Global Posts
       #1  
    I wish the pre made better use of it's keyboard. For example, in the browser, I wish we could assign keys to scroll and page up/down, refresh, open bookmarks, etc.

    Also, for the media player, it would be great if you could press a hard key to pause the track, next/previous, etc.

    Same with e-mail, with r for reply, f for forward, c new message.

    I doubt palm will ever come up with an update for this, but does anyone thing this is possible via an app/rooting?
  2. #2  
    Quote Originally Posted by jrfougere View Post
    I wish the pre made better use of it's keyboard. For example, in the browser, I wish we could assign keys to scroll and page up/down, refresh, open bookmarks, etc.

    Also, for the media player, it would be great if you could press a hard key to pause the track, next/previous, etc.

    Same with e-mail, with r for reply, f for forward, c new message.

    I doubt palm will ever come up with an update for this, but does anyone thing this is possible via an app/rooting?
    I don't know how to do it but my guess is that it would be VERY easy to do with a rooted pre and someone who knows what they're doing.
  3. jrfougere's Avatar
    Posts
    20 Posts
    Global Posts
    21 Global Posts
       #3  
    That would be awesome. If anybody has any suggestions for how it might be accomplished, I would be very grateful.
  4. #4  
    Quote Originally Posted by jrfougere View Post
    That would be awesome. If anybody has any suggestions for how it might be accomplished, I would be very grateful.
    I know in the camera app the spacebar is mapped to take a pic, maybe if we dig into that we can see how to assign keyboard shortcuts and move on from there...
  5. jrfougere's Avatar
    Posts
    20 Posts
    Global Posts
    21 Global Posts
       #5  
    Thanks for the tip. I know very little linux, but I was able to find what appears to be the space bar shortcut code in the camera settings.

    If you view /usr/palm/applications/com.palm.app.camera/app/controllers/capture-assistant.jsjsjs $you$'$ll$ $find$ $the$ $following$ $code$:

    onKeyPress: function(event) {
    // Space bar also takes a picture.
    if (Mojo.Char.spaceBar == event.originalEvent.keyCode){
    this.cameraControl.capture();
    }
    },

    Now let me look for a similar file in for example the media player to see if I can remap the pause button.
  6. jrfougere's Avatar
    Posts
    20 Posts
    Global Posts
    21 Global Posts
       #6  
    Ok I think I have a general idea about how to use the keyboard in the music player.

    The following will let you pause/play a song by pressing the space bar:

    You need to make two changes to the file /usr/palm/applications/com.palm.app.musicplayer/app/controllers/localnowplaying-assistant.jsjsjs

    First, add these two lines someone in the main function:

    this.onKeyPressHandler = this.onKeyPress.bindAsEventListener(this);
    Mojo.listen(this.controller.sceneElement, Mojo.Event.keypress, this.onKeyPressHandler);

    Then add the following function:

    onKeyPress: function(event) {
    // Space bar to pause
    if (Mojo.Char.spaceBar == event.originalEvent.keyCode){
    this.togglePausePlay();
    }
    },

    I tried to add "next" and "previous" using n and p, but I haven't been able to get them to work. Any ideas? Here's the function I tried:

    onKeyPress: function(event) {
    // Space bar to pause
    if (Mojo.Char.spaceBar == event.originalEvent.keyCode){
    this.togglePausePlay();
    }

    // n for next song
    else if (Mojo.Char.n == event.originalEvent.keyCode){
    this.nextSong();
    }

    // p for previous song
    else if (Mojo.Char.p == event.originalEvent.keyCode){
    this.prevSong();
    }
    },
    Last edited by jrfougere; 07/07/2009 at 10:39 PM.

Posting Permissions