1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2026-01-04 22:44:12 +01:00

Add <S-Left>/<S-Right> (like H/L) mappings to Player mode.

Also the appropriate prefix to Player mode help tags.
This commit is contained in:
Doug Kearns
2009-03-30 00:32:11 +11:00
parent 24216eb7a4
commit 2d25c1f7c3
3 changed files with 30 additions and 30 deletions

View File

@@ -1,5 +1,3 @@
// Import Artist List as this can be huge
function Player() // {{{
{
////////////////////////////////////////////////////////////////////////////////
@@ -52,13 +50,12 @@ function Player() // {{{
}
// Get the artist names before hand.
let artists = getArtistsArray();
const pageService = Components.classes["@songbirdnest.com/Songbird/MediaPageManager;1"]
.getService(Components.interfaces.sbIMediaPageManager);
// Register Callbacks for searching.
// Register Callbacks for searching.
liberator.registerCallback("change", modes.SEARCH_VIEW_FORWARD, function (command) { player.searchView(command);});
liberator.registerCallback("submit", modes.SEARCH_VIEW_FORWARD, function (command) { player.searchView(command);});
//liberator.registerCallback("cancel", modes.SEARCH_VIEW_FORWARD, function (command) { player.searchView(command);});
@@ -175,12 +172,12 @@ function Player() // {{{
{ flags: Mappings.flags.COUNT });
mappings.add([modes.PLAYER],
["H"], "Seek -1m",
["H", "<S-Left>"], "Seek -1m",
function (count) { player.seekBackward(Math.max(1, count) * 60000); },
{ flags: Mappings.flags.COUNT });
mappings.add([modes.PLAYER],
["L"], "Seek +1m",
["L", "<S-Right>"], "Seek +1m",
function (count) { player.seekForward(Math.max(1, count) * 60000); },
{ flags: Mappings.flags.COUNT });
@@ -217,7 +214,7 @@ function Player() // {{{
////////////////////// COMMANDS ////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////{{{
// TODO: presumably this will eventually just filter the library view like cmus? --djk
// TODO: rename :Filter to :filter and move this functionality into :tqueue etc? --djk
commands.add(["f[ilter]"],
"Filter and play tracks",
function (args)
@@ -591,7 +588,7 @@ function Player() // {{{
}
else
{
liberator.echoerr("E486 Pattern not found: "+searchString, commandline.FORCE_SINGLELINE);
liberator.echoerr("E486 Pattern not found: " + searchString, commandline.FORCE_SINGLELINE);
}
},

View File

@@ -17,14 +17,17 @@ section:Player{nbsp}mode[player-index]
||[m]f[m]|| Filter and play tracks +
||[m]F[m]|| Filter and show the tracks as a view +
||[m]h[m]|| Seek -10s +
||[m]<Left>[m]|| Seek -10s +
||[m]l[m]|| Seek +10s +
||[m]<Right>[m]|| Seek -10s +
||[m]H[m]|| Seek -1m +
||[m]<S-Left>[m]|| Seek -10s +
||[m]L[m]|| Seek +1m +
||[m]<S-Right>[m]|| Seek -10s +
||[m]+[m]|| Increase volume by 10% +
||[m]-[m]|| Decrease volume by 10% +
||[m]/[m]|| Search forward for a track +
//||[m]?[m]|| Search backward for a track +
||[m]n[m]|| Find the next track +
||[m]N[m]|| Find the previous track +

View File

@@ -7,14 +7,14 @@ tab has focus.
section:Playing{nbsp}tracks[playing-tracks]
|x| |:playerp| |:playerplay|
|p_x| |:playerp| |:playerplay|
||:playerp[lay]|| +
||x||
________________________________________________________________________________
Play the current track.
________________________________________________________________________________
|z| |:playerpr| |:playerprev|
|p_z| |:playerpr| |:playerprev|
||:playerpr[ev]|| +
||z||
________________________________________________________________________________
@@ -22,7 +22,7 @@ Play the previous track.
________________________________________________________________________________
|b| |:playern| |:playernext|
|p_b| |:playern| |:playernext|
||:playern[ext]|| +
||b||
________________________________________________________________________________
@@ -30,7 +30,7 @@ Play the next track.
________________________________________________________________________________
|c| |:playerpa| |:playerpause|
|p_c| |:playerpa| |:playerpause|
||:playerpa[use]|| +
||c||
________________________________________________________________________________
@@ -38,7 +38,7 @@ Pause/unpause the current track.
________________________________________________________________________________
|v| |:players| |:playerstop|
|p_v| |:players| |:playerstop|
||:players[top]|| +
||v||
________________________________________________________________________________
@@ -46,21 +46,21 @@ Stop playing the current track.
________________________________________________________________________________
|x|
|p_x|
||x||
________________________________________________________________________________
Toggle shuffle mode.
________________________________________________________________________________
|r|
|p_r|
||r||
________________________________________________________________________________
Toggle repeat mode.
________________________________________________________________________________
|i|
|p_i|
||i||
________________________________________________________________________________
Select the currently playing track.
@@ -68,7 +68,7 @@ ________________________________________________________________________________
section:Filtering{nbsp}the{nbsp}library[filter,filtering]
|f| |:f| |:filter|
|p_f| |:f| |:filter|
||:f[ilter] {artist} [a][album][a] [a][track][a]|| +
||f||
________________________________________________________________________________
@@ -79,7 +79,7 @@ tracks for that album are played. A specific track can be specified with
________________________________________________________________________________
|F| |:F| |:Filter|
|p_F| |:F| |:Filter|
||:F[ilter] {keywords}|| +
||F||
________________________________________________________________________________
@@ -90,28 +90,28 @@ ________________________________________________________________________________
section:Seeking{nbsp}to{nbsp}a{nbsp}track{nbsp}position[seeking]
|<Left>| |h|
|p_<Left>| |p_h|
||[count]h||
________________________________________________________________________________
Seek +10s.
________________________________________________________________________________
|<Right>| |l|
|p_<Right>| |p_l|
||[count]l||
________________________________________________________________________________
Seek -10s.
________________________________________________________________________________
|H|
|p_<S-Left>| |p_H|
||[count]H||
________________________________________________________________________________
Seek +1m.
________________________________________________________________________________
|L|
|p_<S-Right>| |p_L|
||[count]L||
________________________________________________________________________________
Seek -1m.
@@ -132,7 +132,7 @@ ________________________________________________________________________________
section:Adjusting{nbsp}the{nbsp}volume[volume]
|+| |=|
|p_+| |p_=|
||+|| +
||=||
________________________________________________________________________________
@@ -140,7 +140,7 @@ Increase volume by 10%.
________________________________________________________________________________
|-|
|p_-|
||-|| +
________________________________________________________________________________
Decrease volume by 10%.
@@ -175,26 +175,26 @@ ________________________________________________________________________________
section:Search{nbsp}commands[search]
|/|
|p_/|
||/{pattern}<CR>|| +
________________________________________________________________________________
Search forward for a track matching {pattern} in the visible media view.
________________________________________________________________________________
//|?|
//|p_?|
//||?{pattern}<CR>|| +
//________________________________________________________________________________
//Search backwards for a track matching {pattern} in the visible media view.
//________________________________________________________________________________
|n|
|p_n|
||n|| +
________________________________________________________________________________
Find the next track. Repeats the last search. If the search hits BOTTOM of the
view, it continues from TOP.
________________________________________________________________________________
|N|
|p_N|
||N|| +
________________________________________________________________________________
Find the previous track. Repeats the last search in the opposite direction. If
@@ -203,7 +203,7 @@ ________________________________________________________________________________
section:Rating{nbsp}tracks[rating]
|<C-5>| |<C-4>| |<C-3>| |<C-2>| |<C-1>| |<C-0>|
|p_<C-5>| |p_<C-4>| |p_<C-3>| |p_<C-2>| |p_<C-1>| |p_<C-0>|
||<C-0>|| +
||<C-1>|| +
||<C-2>|| +