Changeset 9b21679c04e34024ed9e83c7f40670f715d8d471
- Timestamp:
- 02/06/02 14:16:31
(6 years ago)
- Author:
- Christophe Massiot <massiot@videolan.org>
- git-committer:
- Christophe Massiot <massiot@videolan.org> 1023020191 +0000
- git-parent:
[b73f6722b19f7e553f7516d7533eeed6074b6ea3]
- git-author:
- Christophe Massiot <massiot@videolan.org> 1023020191 +0000
- Message:
* New Loop menu item in OS X interface.
-
Files:
-
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
| r91eb944 |
r9b21679 |
|
| 7 | 7 | faster = id; |
|---|
| 8 | 8 | fullscreen = id; |
|---|
| | 9 | loop = id; |
|---|
| 9 | 10 | maxvolume = id; |
|---|
| 10 | 11 | mute = id; |
|---|
| r91eb944 |
r9b21679 |
|
| 20 | 20 | <key>IBOpenObjects</key> |
|---|
| 21 | 21 | <array> |
|---|
| | 22 | <integer>528</integer> |
|---|
| 22 | 23 | <integer>29</integer> |
|---|
| 23 | | <integer>528</integer> |
|---|
| 24 | | <integer>21</integer> |
|---|
| 25 | 24 | </array> |
|---|
| 26 | 25 | <key>IBSystem Version</key> |
|---|
| r91eb944 |
r9b21679 |
|
| 3 | 3 | ***************************************************************************** |
|---|
| 4 | 4 | * Copyright (C) 2001 VideoLAN |
|---|
| 5 | | * $Id: intf_controller.h,v 1.9 2002/06/02 01:20:52 massiot Exp $ |
|---|
| | 5 | * $Id: intf_controller.h,v 1.10 2002/06/02 12:16:31 massiot Exp $ |
|---|
| 6 | 6 | * |
|---|
| 7 | 7 | * Authors: Florian G. Pflug <fgp@phlo.org> |
|---|
| … | … | |
| 69 | 69 | - (BOOL)application:(NSApplication *)o_app openFile:(NSString *)o_filename; |
|---|
| 70 | 70 | |
|---|
| 71 | | /* Functions atteched to user interface */ |
|---|
| | 71 | /* Functions attached to user interface */ |
|---|
| 72 | 72 | - (IBAction)pause:(id)sender; |
|---|
| 73 | 73 | - (IBAction)play:(id)sender; |
|---|
| … | … | |
| 79 | 79 | - (IBAction)prevChannel:(id)sender; |
|---|
| 80 | 80 | - (IBAction)nextChannel:(id)sender; |
|---|
| | 81 | - (IBAction)loop:(id)sender; |
|---|
| 81 | 82 | - (IBAction)mute:(id)sender; |
|---|
| 82 | 83 | - (IBAction)fullscreen:(id)fullscreen; |
|---|
| … | … | |
| 86 | 87 | - (IBAction)quit:(id)sender; |
|---|
| 87 | 88 | |
|---|
| | 89 | - (BOOL)validateMenuItem:(id)sender; |
|---|
| | 90 | |
|---|
| 88 | 91 | @end |
|---|
| r91eb944 |
r9b21679 |
|
| 3 | 3 | ***************************************************************************** |
|---|
| 4 | 4 | * Copyright (C) 2001 VideoLAN |
|---|
| 5 | | * $Id: intf_controller.m,v 1.6 2002/06/02 01:20:52 massiot Exp $ |
|---|
| | 5 | * $Id: intf_controller.m,v 1.7 2002/06/02 12:16:31 massiot Exp $ |
|---|
| 6 | 6 | * |
|---|
| 7 | 7 | * Authors: Florian G. Pflug <fgp@phlo.org> |
|---|
| … | … | |
| 176 | 176 | } |
|---|
| 177 | 177 | |
|---|
| | 178 | - (IBAction)loop:(id)sender |
|---|
| | 179 | { |
|---|
| | 180 | NSMenuItem * item = (NSMenuItem *)sender; |
|---|
| | 181 | |
|---|
| | 182 | [o_intf loop]; |
|---|
| | 183 | |
|---|
| | 184 | if( p_main->p_intf->p_sys->b_loop ) |
|---|
| | 185 | { |
|---|
| | 186 | [item setState:NSOnState]; |
|---|
| | 187 | } |
|---|
| | 188 | else |
|---|
| | 189 | { |
|---|
| | 190 | [item setState:NSOffState]; |
|---|
| | 191 | } |
|---|
| | 192 | } |
|---|
| | 193 | |
|---|
| 178 | 194 | - (IBAction)mute:(id)sender |
|---|
| 179 | 195 | { |
|---|
| … | … | |
| 230 | 246 | } |
|---|
| 231 | 247 | |
|---|
| | 248 | - (BOOL)validateMenuItem:(id)sender |
|---|
| | 249 | { |
|---|
| | 250 | NSMenuItem * o_item = (NSMenuItem *)sender; |
|---|
| | 251 | |
|---|
| | 252 | if ( [o_item tag] == 12 || [o_item tag] == 13 ) |
|---|
| | 253 | { |
|---|
| | 254 | if( !config_GetIntVariable( "network-channel" ) ) |
|---|
| | 255 | { |
|---|
| | 256 | return NO; |
|---|
| | 257 | } |
|---|
| | 258 | } |
|---|
| | 259 | |
|---|
| | 260 | return YES; |
|---|
| | 261 | } |
|---|
| | 262 | |
|---|
| 232 | 263 | @end |
|---|
| 233 | 264 | |
|---|
| r91eb944 |
r9b21679 |
|
| 3 | 3 | ***************************************************************************** |
|---|
| 4 | 4 | * Copyright (C) 2001 VideoLAN |
|---|
| 5 | | * $Id: intf_macosx.m,v 1.3 2002/06/02 01:20:52 massiot Exp $ |
|---|
| | 5 | * $Id: intf_macosx.m,v 1.4 2002/06/02 12:16:31 massiot Exp $ |
|---|
| 6 | 6 | * |
|---|
| 7 | 7 | * Authors: Colin Delacroix <colin@zoy.org> |
|---|
| … | … | |
| 70 | 70 | p_intf->p_sys->i_part = 0; |
|---|
| 71 | 71 | p_intf->p_sys->b_disabled_menus = 0; |
|---|
| | 72 | p_intf->p_sys->b_loop = 0; |
|---|
| 72 | 73 | p_intf->p_sys->>i_channel = 0; |
|---|
| 73 | 74 | |
|---|
| r91eb944 |
r9b21679 |
|
| 3 | 3 | ***************************************************************************** |
|---|
| 4 | 4 | * Copyright (C) 2001 VideoLAN |
|---|
| 5 | | * $Id: intf_vlc_wrapper.h,v 1.9 2002/06/02 01:20:52 massiot Exp $ |
|---|
| | 5 | * $Id: intf_vlc_wrapper.h,v 1.10 2002/06/02 12:16:31 massiot Exp $ |
|---|
| 6 | 6 | * |
|---|
| 7 | 7 | * Authors: Florian G. Pflug <fgp@phlo.org> |
|---|
| … | … | |
| 45 | 45 | - (void)channelNext; |
|---|
| 46 | 46 | - (void)channelPrev; |
|---|
| | 47 | - (void)loop; |
|---|
| 47 | 48 | |
|---|
| 48 | 49 | - (void)playSlower; |
|---|
| r91eb944 |
r9b21679 |
|
| 3 | 3 | ***************************************************************************** |
|---|
| 4 | 4 | * Copyright (C) 2001 VideoLAN |
|---|
| 5 | | * $Id: intf_vlc_wrapper.m,v 1.10 2002/06/02 01:20:52 massiot Exp $ |
|---|
| | 5 | * $Id: intf_vlc_wrapper.m,v 1.11 2002/06/02 12:16:31 massiot Exp $ |
|---|
| 6 | 6 | * |
|---|
| 7 | 7 | * Authors: Florian G. Pflug <fgp@phlo.org> |
|---|
| … | … | |
| 276 | 276 | } |
|---|
| 277 | 277 | |
|---|
| | 278 | - (void)loop |
|---|
| | 279 | { |
|---|
| | 280 | intf_thread_t * p_intf = p_main->p_intf; |
|---|
| | 281 | |
|---|
| | 282 | if ( p_intf->p_sys->b_loop ) |
|---|
| | 283 | { |
|---|
| | 284 | intf_PlaylistDelete( p_main->p_playlist, |
|---|
| | 285 | p_main->p_playlist->i_size - 1 ); |
|---|
| | 286 | } |
|---|
| | 287 | else |
|---|
| | 288 | { |
|---|
| | 289 | intf_PlaylistAdd( p_main->p_playlist, PLAYLIST_END, |
|---|
| | 290 | "vlc:loop" ); |
|---|
| | 291 | } |
|---|
| | 292 | p_intf->p_sys->b_loop = !p_intf->p_sys->b_loop; |
|---|
| | 293 | } |
|---|
| | 294 | |
|---|
| 278 | 295 | - (void)playSlower |
|---|
| 279 | 296 | { |
|---|
| … | … | |
| 500 | 517 | int i_end = p_main->p_playlist->i_size; |
|---|
| 501 | 518 | NSEnumerator *o_enum = [o_files objectEnumerator]; |
|---|
| | 519 | intf_thread_t * p_intf = p_main->p_intf; |
|---|
| | 520 | |
|---|
| | 521 | if ( p_intf->p_sys->b_loop ) |
|---|
| | 522 | { |
|---|
| | 523 | intf_PlaylistDelete( p_main->p_playlist, |
|---|
| | 524 | p_main->p_playlist->i_size - 1 ); |
|---|
| | 525 | } |
|---|
| 502 | 526 | |
|---|
| 503 | 527 | while( ( o_file = (NSString *)[o_enum nextObject] ) ) |
|---|
| … | … | |
| 514 | 538 | |
|---|
| 515 | 539 | intf_PlaylistJumpto( p_main->p_playlist, i_end - 1 ); |
|---|
| | 540 | |
|---|
| | 541 | if ( p_intf->p_sys->b_loop ) |
|---|
| | 542 | { |
|---|
| | 543 | intf_PlaylistAdd( p_main->p_playlist, PLAYLIST_END, |
|---|
| | 544 | "vlc:loop" ); |
|---|
| | 545 | } |
|---|
| 516 | 546 | } |
|---|
| 517 | 547 | |
|---|
| … | … | |
| 520 | 550 | NSString *o_source; |
|---|
| 521 | 551 | int i_end = p_main->p_playlist->i_size; |
|---|
| | 552 | intf_thread_t * p_intf = p_main->p_intf; |
|---|
| 522 | 553 | |
|---|
| 523 | 554 | o_source = [NSString stringWithFormat: @"%@:%@@%d,%d", |
|---|
| 524 | 555 | o_type, o_device, i_title, i_chapter]; |
|---|
| 525 | 556 | |
|---|
| | 557 | if ( p_intf->p_sys->b_loop ) |
|---|
| | 558 | { |
|---|
| | 559 | intf_PlaylistDelete( p_main->p_playlist, |
|---|
| | 560 | p_main->p_playlist->i_size - 1 ); |
|---|
| | 561 | } |
|---|
| | 562 | |
|---|
| 526 | 563 | intf_PlaylistAdd( p_main->p_playlist, PLAYLIST_END, |
|---|
| 527 | 564 | [o_source fileSystemRepresentation] ); |
|---|
| … | … | |
| 534 | 571 | |
|---|
| 535 | 572 | intf_PlaylistJumpto( p_main->p_playlist, i_end - 1 ); |
|---|
| | 573 | |
|---|
| | 574 | if ( p_intf->p_sys->b_loop ) |
|---|
| | 575 | { |
|---|
| | 576 | intf_PlaylistAdd( p_main->p_playlist, PLAYLIST_END, |
|---|
| | 577 | "vlc:loop" ); |
|---|
| | 578 | } |
|---|
| 536 | 579 | } |
|---|
| 537 | 580 | |
|---|
| … | … | |
| 540 | 583 | NSString *o_source; |
|---|
| 541 | 584 | int i_end = p_main->p_playlist->i_size; |
|---|
| | 585 | intf_thread_t * p_intf = p_main->p_intf; |
|---|
| 542 | 586 | |
|---|
| 543 | 587 | if( p_input_bank->pp_input[0] != NULL ) |
|---|
| … | … | |
| 559 | 603 | } |
|---|
| 560 | 604 | |
|---|
| | 605 | if ( p_intf->p_sys->b_loop ) |
|---|
| | 606 | { |
|---|
| | 607 | intf_PlaylistDelete( p_main->p_playlist, |
|---|
| | 608 | p_main->p_playlist->i_size - 1 ); |
|---|
| | 609 | } |
|---|
| | 610 | |
|---|
| 561 | 611 | intf_PlaylistAdd( p_main->p_playlist, PLAYLIST_END, |
|---|
| 562 | 612 | [o_source fileSystemRepresentation] ); |
|---|
| 563 | 613 | |
|---|
| 564 | 614 | intf_PlaylistJumpto( p_main->p_playlist, i_end - 1 ); |
|---|
| | 615 | |
|---|
| | 616 | if ( p_intf->p_sys->b_loop ) |
|---|
| | 617 | { |
|---|
| | 618 | intf_PlaylistAdd( p_main->p_playlist, PLAYLIST_END, |
|---|
| | 619 | "vlc:loop" ); |
|---|
| | 620 | } |
|---|
| 565 | 621 | } |
|---|
| 566 | 622 | |
|---|
| … | … | |
| 738 | 794 | o_language_item = [[o_controls_item submenu] itemWithTitle: @"Language"]; |
|---|
| 739 | 795 | o_subtitle_item = [[o_controls_item submenu] itemWithTitle: @"Subtitles"]; |
|---|
| 740 | | o_next_channel_item = [[o_controls_item submenu] itemWithTag: 2]; |
|---|
| 741 | | o_prev_channel_item = [[o_controls_item submenu] itemWithTag: 1]; |
|---|
| | 796 | o_next_channel_item = [[o_controls_item submenu] itemWithTag: 13]; |
|---|
| | 797 | o_prev_channel_item = [[o_controls_item submenu] itemWithTag: 12]; |
|---|
| 742 | 798 | |
|---|
| 743 | 799 | if( p_input == NULL ) |
|---|
| … | … | |
| 1008 | 1064 | p_input->stream.b_changed = 0; |
|---|
| 1009 | 1065 | } |
|---|
| 1010 | | |
|---|
| 1011 | | if( config_GetIntVariable( "network-channel" ) ) |
|---|
| 1012 | | { |
|---|
| 1013 | | [o_next_channel_item setEnabled: 1]; |
|---|
| 1014 | | [o_prev_channel_item setEnabled: 1]; |
|---|
| 1015 | | } |
|---|
| 1016 | | else |
|---|
| 1017 | | { |
|---|
| 1018 | | [o_next_channel_item setEnabled: 0]; |
|---|
| 1019 | | [o_prev_channel_item setEnabled: 0]; |
|---|
| 1020 | | } |
|---|
| 1021 | 1066 | } |
|---|
| 1022 | 1067 | |
|---|
| r91eb944 |
r9b21679 |
|
| 3 | 3 | ***************************************************************************** |
|---|
| 4 | 4 | * Copyright (C) 2001 VideoLAN |
|---|
| 5 | | * $Id: macosx.h,v 1.11 2002/06/02 01:20:52 massiot Exp $ |
|---|
| | 5 | * $Id: macosx.h,v 1.12 2002/06/02 12:16:31 massiot Exp $ |
|---|
| 6 | 6 | * |
|---|
| 7 | 7 | * Authors: Colin Delacroix <colin@zoy.org> |
|---|
| … | … | |
| 44 | 44 | int i_part; |
|---|
| 45 | 45 | vlc_bool_t b_disabled_menus; |
|---|
| | 46 | vlc_bool_t b_loop; |
|---|
| 46 | 47 | int i_channel; |
|---|
| 47 | 48 | }; |
|---|