mirror of https://code.videolan.org/videolan/vlc
Applies part of patch from Tom Maguire. Adds controls for 1min/5min forward / backward, and add menu items for them in the control menu. It might make it a bit uinclear. Please make any comment.
This commit is contained in:
parent
136957ea77
commit
d48f97db9c
1
THANKS
1
THANKS
|
@ -87,3 +87,4 @@ Watanabe Go <go@dsl.gr.jp> - fix for non-ASCII filenames
|
|||
Xavier Maillard <zedek@fxgsproject.org> - audio converters
|
||||
Xavier Marchesini <xav@alarue.net> - Win32 fixes
|
||||
Yves Duret <yves@zarb.org> - RPM packages
|
||||
Bob Maguire <maguirer at rjmaguire dot com> - addition of some controls to the OSX interface
|
||||
|
|
|
@ -22,13 +22,18 @@
|
|||
{
|
||||
ACTIONS = {
|
||||
backward = id;
|
||||
backward1Min = id;
|
||||
backward5Min = id;
|
||||
faster = id;
|
||||
forward = id;
|
||||
forward1Min = id;
|
||||
forward5Min = id;
|
||||
loop = id;
|
||||
mute = id;
|
||||
next = id;
|
||||
pause = id;
|
||||
play = id;
|
||||
position = id;
|
||||
prev = id;
|
||||
random = id;
|
||||
repeat = id;
|
||||
|
@ -101,6 +106,8 @@
|
|||
"o_mi_audiotrack" = id;
|
||||
"o_mi_bring_atf" = id;
|
||||
"o_mi_bwd" = id;
|
||||
"o_mi_bwd1m" = id;
|
||||
"o_mi_bwd5m" = id;
|
||||
"o_mi_channels" = id;
|
||||
"o_mi_chapter" = id;
|
||||
"o_mi_clear" = id;
|
||||
|
@ -117,6 +124,8 @@
|
|||
"o_mi_floatontop" = id;
|
||||
"o_mi_fullscreen" = id;
|
||||
"o_mi_fwd" = id;
|
||||
"o_mi_fwd1m" = id;
|
||||
"o_mi_fwd5m" = id;
|
||||
"o_mi_half_window" = id;
|
||||
"o_mi_hide" = id;
|
||||
"o_mi_hide_others" = id;
|
||||
|
@ -137,6 +146,7 @@
|
|||
"o_mi_paste" = id;
|
||||
"o_mi_play" = id;
|
||||
"o_mi_playlist" = id;
|
||||
"o_mi_position" = id;
|
||||
"o_mi_prefs" = id;
|
||||
"o_mi_previous" = id;
|
||||
"o_mi_program" = id;
|
||||
|
|
|
@ -3,13 +3,13 @@
|
|||
<plist version="1.0">
|
||||
<dict>
|
||||
<key>IBDocumentLocation</key>
|
||||
<string>561 168 505 541 0 0 1024 746 </string>
|
||||
<string>494 131 505 541 0 0 1024 746 </string>
|
||||
<key>IBEditorPositions</key>
|
||||
<dict>
|
||||
<key>1617</key>
|
||||
<string>410 345 104 149 0 0 800 578 </string>
|
||||
<key>29</key>
|
||||
<string>73 518 419 44 0 0 800 578 </string>
|
||||
<string>17 579 419 44 0 0 1024 746 </string>
|
||||
<key>915</key>
|
||||
<string>212 486 103 130 0 0 1024 746 </string>
|
||||
</dict>
|
||||
|
@ -19,9 +19,8 @@
|
|||
<array/>
|
||||
<key>IBOpenObjects</key>
|
||||
<array>
|
||||
<integer>1530</integer>
|
||||
<integer>29</integer>
|
||||
<integer>21</integer>
|
||||
<integer>915</integer>
|
||||
</array>
|
||||
<key>IBSystem Version</key>
|
||||
<string>7D24</string>
|
||||
|
|
Binary file not shown.
|
@ -48,6 +48,10 @@
|
|||
|
||||
- (IBAction)forward:(id)sender;
|
||||
- (IBAction)backward:(id)sender;
|
||||
- (IBAction)forward1Min:(id)sender;
|
||||
- (IBAction)backward1Min:(id)sender;
|
||||
- (IBAction)forward5Min:(id)sender;
|
||||
- (IBAction)backward5Min:(id)sender;
|
||||
|
||||
- (IBAction)volumeUp:(id)sender;
|
||||
- (IBAction)volumeDown:(id)sender;
|
||||
|
|
|
@ -256,6 +256,37 @@
|
|||
vlc_value_t time;
|
||||
time.i_time = 10 * 1000000;
|
||||
var_Set( p_input, "time-offset", time );
|
||||
vout_OSDMessage( p_intf, _( "Jump +10 Seconds" ) );
|
||||
vlc_object_release( p_input );
|
||||
}
|
||||
}
|
||||
|
||||
- (IBAction)forward1Min:(id)sender
|
||||
{
|
||||
intf_thread_t * p_intf = [NSApp getIntf];
|
||||
input_thread_t * p_input = vlc_object_find( p_intf, VLC_OBJECT_INPUT,
|
||||
FIND_ANYWHERE );
|
||||
if( p_input != NULL )
|
||||
{
|
||||
vlc_value_t time;
|
||||
time.i_time = 60 * 1000000;
|
||||
var_Set( p_input, "time-offset", time );
|
||||
vout_OSDMessage( p_intf, _( "Jump +1 Minute" ) );
|
||||
vlc_object_release( p_input );
|
||||
}
|
||||
}
|
||||
|
||||
- (IBAction)forward5Min:(id)sender
|
||||
{
|
||||
intf_thread_t * p_intf = [NSApp getIntf];
|
||||
input_thread_t * p_input = vlc_object_find( p_intf, VLC_OBJECT_INPUT,
|
||||
FIND_ANYWHERE );
|
||||
if( p_input != NULL )
|
||||
{
|
||||
vlc_value_t time;
|
||||
time.i_time = 300 * 1000000;
|
||||
var_Set( p_input, "time-offset", time );
|
||||
vout_OSDMessage( p_intf, _( "Jump +5 Minutes" ) );
|
||||
vlc_object_release( p_input );
|
||||
}
|
||||
}
|
||||
|
@ -270,6 +301,37 @@
|
|||
vlc_value_t time;
|
||||
time.i_time = -10 * 1000000;
|
||||
var_Set( p_input, "time-offset", time );
|
||||
vout_OSDMessage( p_intf, _( "Jump -10 Seconds" ) );
|
||||
vlc_object_release( p_input );
|
||||
}
|
||||
}
|
||||
|
||||
- (IBAction)backward1Min:(id)sender
|
||||
{
|
||||
intf_thread_t * p_intf = [NSApp getIntf];
|
||||
input_thread_t * p_input = vlc_object_find( p_intf, VLC_OBJECT_INPUT,
|
||||
FIND_ANYWHERE );
|
||||
if( p_input != NULL )
|
||||
{
|
||||
vlc_value_t time;
|
||||
time.i_time = -60 * 1000000;
|
||||
var_Set( p_input, "time-offset", time );
|
||||
vout_OSDMessage( p_intf, _( "Jump -1 Minute" ) );
|
||||
vlc_object_release( p_input );
|
||||
}
|
||||
}
|
||||
|
||||
- (IBAction)backward5Min:(id)sender
|
||||
{
|
||||
intf_thread_t * p_intf = [NSApp getIntf];
|
||||
input_thread_t * p_input = vlc_object_find( p_intf, VLC_OBJECT_INPUT,
|
||||
FIND_ANYWHERE );
|
||||
if( p_input != NULL )
|
||||
{
|
||||
vlc_value_t time;
|
||||
time.i_time = -300 * 1000000;
|
||||
var_Set( p_input, "time-offset", time );
|
||||
vout_OSDMessage( p_intf, _( "Jump -5 Minutes" ) );
|
||||
vlc_object_release( p_input );
|
||||
}
|
||||
}
|
||||
|
|
|
@ -170,6 +170,10 @@ struct intf_sys_t
|
|||
IBOutlet id o_mi_loop;
|
||||
IBOutlet id o_mi_fwd;
|
||||
IBOutlet id o_mi_bwd;
|
||||
IBOutlet id o_mi_fwd1m;
|
||||
IBOutlet id o_mi_bwd1m;
|
||||
IBOutlet id o_mi_fwd5m;
|
||||
IBOutlet id o_mi_bwd5m;
|
||||
IBOutlet id o_mi_program;
|
||||
IBOutlet id o_mu_program;
|
||||
IBOutlet id o_mi_title;
|
||||
|
|
|
@ -411,6 +411,18 @@ unsigned int VLCModifiersToCocoa( unsigned int i_key )
|
|||
i_key = config_GetInt( p_intf, "key-jump-10sec" );
|
||||
[o_mi_bwd setKeyEquivalent: [NSString stringWithFormat:@"%C", VLCKeyToCocoa( i_key )]];
|
||||
[o_mi_bwd setKeyEquivalentModifierMask: VLCModifiersToCocoa(i_key)];
|
||||
i_key = config_GetInt( p_intf, "key-jump+1min" );
|
||||
[o_mi_fwd1m setKeyEquivalent: [NSString stringWithFormat:@"%C", VLCKeyToCocoa( i_key )]];
|
||||
[o_mi_fwd1m setKeyEquivalentModifierMask: VLCModifiersToCocoa(i_key)];
|
||||
i_key = config_GetInt( p_intf, "key-jump-1min" );
|
||||
[o_mi_bwd1m setKeyEquivalent: [NSString stringWithFormat:@"%C", VLCKeyToCocoa( i_key )]];
|
||||
[o_mi_bwd1m setKeyEquivalentModifierMask: VLCModifiersToCocoa(i_key)];
|
||||
i_key = config_GetInt( p_intf, "key-jump+5min" );
|
||||
[o_mi_fwd5m setKeyEquivalent: [NSString stringWithFormat:@"%C", VLCKeyToCocoa( i_key )]];
|
||||
[o_mi_fwd5m setKeyEquivalentModifierMask: VLCModifiersToCocoa(i_key)];
|
||||
i_key = config_GetInt( p_intf, "key-jump-5min" );
|
||||
[o_mi_bwd5m setKeyEquivalent: [NSString stringWithFormat:@"%C", VLCKeyToCocoa( i_key )]];
|
||||
[o_mi_bwd5m setKeyEquivalentModifierMask: VLCModifiersToCocoa(i_key)];
|
||||
i_key = config_GetInt( p_intf, "key-vol-up" );
|
||||
[o_mi_vol_up setKeyEquivalent: [NSString stringWithFormat:@"%C", VLCKeyToCocoa( i_key )]];
|
||||
[o_mi_vol_up setKeyEquivalentModifierMask: VLCModifiersToCocoa(i_key)];
|
||||
|
@ -488,8 +500,13 @@ unsigned int VLCModifiersToCocoa( unsigned int i_key )
|
|||
[o_mi_random setTitle: _NS("Random")];
|
||||
[o_mi_repeat setTitle: _NS("Repeat One")];
|
||||
[o_mi_loop setTitle: _NS("Repeat All")];
|
||||
[o_mi_fwd setTitle: _NS("Step Forward")];
|
||||
[o_mi_bwd setTitle: _NS("Step Backward")];
|
||||
[o_mi_fwd setTitle: _NS("Forward 10 Seconds")];
|
||||
[o_mi_bwd setTitle: _NS("Backward 10 Seconds")];
|
||||
[o_mi_fwd1m setTitle: _NS("Forward 1 Minute")];
|
||||
[o_mi_bwd1m setTitle: _NS("Backward 1 Minute")];
|
||||
[o_mi_fwd5m setTitle: _NS("Forward 5 Minutes")];
|
||||
[o_mi_bwd5m setTitle: _NS("Backward 5 Minutes")];
|
||||
|
||||
[o_mi_program setTitle: _NS("Program")];
|
||||
[o_mu_program setTitle: _NS("Program")];
|
||||
[o_mi_title setTitle: _NS("Title")];
|
||||
|
|
Loading…
Reference in New Issue