Commit 61751385 authored by Felix Paul Kühne's avatar Felix Paul Kühne

Implement the full/basic switch correctly and completely. Additionally, fixed...

Implement the full/basic switch correctly and completely. Additionally, fixed a rare sprefs init failure.
parent ca0d8dc7
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>IBClasses</key>
<array>
<dict>
<key>CLASS</key>
<string>NSApplication</string>
<key>LANGUAGE</key>
<string>ObjC</string>
<key>SUPERCLASS</key>
<string>NSResponder</string>
</dict>
<dict>
<key>CLASS</key>
<string>VLCHotkeyChangeWindow</string>
<key>LANGUAGE</key>
<string>ObjC</string>
<key>SUPERCLASS</key>
<string>NSWindow</string>
</dict>
<dict>
<key>ACTIONS</key>
<dict>
<key>audioSettingChanged</key>
<string>id</string>
<key>buttonAction</key>
<string>id</string>
<key>hotkeySettingChanged</key>
<string>id</string>
<key>inputSettingChanged</key>
<string>id</string>
<key>interfaceSettingChanged</key>
<string>id</string>
<key>osdSettingChanged</key>
<string>id</string>
<key>videoSettingChanged</key>
<string>id</string>
</dict>
<key>CLASS</key>
<string>VLCSimplePrefs</string>
<key>LANGUAGE</key>
<string>ObjC</string>
<key>OUTLETS</key>
<dict>
<key>o_audio_dolby_pop</key>
<string>id</string>
<key>o_audio_dolby_txt</key>
<string>id</string>
<key>o_audio_effects_box</key>
<string>id</string>
<key>o_audio_enable_ckb</key>
<string>id</string>
<key>o_audio_general_box</key>
<string>id</string>
<key>o_audio_headphone_ckb</key>
<string>id</string>
<key>o_audio_lang_fld</key>
<string>id</string>
<key>o_audio_lang_txt</key>
<string>id</string>
<key>o_audio_last_box</key>
<string>id</string>
<key>o_audio_last_ckb</key>
<string>id</string>
<key>o_audio_lastpwd_sfld</key>
<string>id</string>
<key>o_audio_lastpwd_txt</key>
<string>id</string>
<key>o_audio_lastuser_fld</key>
<string>id</string>
<key>o_audio_lastuser_txt</key>
<string>id</string>
<key>o_audio_norm_ckb</key>
<string>id</string>
<key>o_audio_norm_fld</key>
<string>id</string>
<key>o_audio_spdif_ckb</key>
<string>id</string>
<key>o_audio_view</key>
<string>id</string>
<key>o_audio_visual_pop</key>
<string>id</string>
<key>o_audio_visual_txt</key>
<string>id</string>
<key>o_audio_vol_fld</key>
<string>id</string>
<key>o_audio_vol_sld</key>
<string>id</string>
<key>o_audio_vol_txt</key>
<string>id</string>
<key>o_currentlyShownCategoryView</key>
<string>id</string>
<key>o_hotkeys_change_btn</key>
<string>id</string>
<key>o_hotkeys_change_cancel_btn</key>
<string>id</string>
<key>o_hotkeys_change_keys_lbl</key>
<string>id</string>
<key>o_hotkeys_change_lbl</key>
<string>id</string>
<key>o_hotkeys_change_ok_btn</key>
<string>id</string>
<key>o_hotkeys_change_taken_lbl</key>
<string>id</string>
<key>o_hotkeys_change_win</key>
<string>id</string>
<key>o_hotkeys_clear_btn</key>
<string>id</string>
<key>o_hotkeys_lbl</key>
<string>id</string>
<key>o_hotkeys_listbox</key>
<string>id</string>
<key>o_hotkeys_view</key>
<string>id</string>
<key>o_input_access_box</key>
<string>id</string>
<key>o_input_avi_pop</key>
<string>id</string>
<key>o_input_avi_txt</key>
<string>id</string>
<key>o_input_bandwidth_ckb</key>
<string>id</string>
<key>o_input_cachelevel_custom_txt</key>
<string>id</string>
<key>o_input_cachelevel_pop</key>
<string>id</string>
<key>o_input_cachelevel_txt</key>
<string>id</string>
<key>o_input_caching_box</key>
<string>id</string>
<key>o_input_dump_ckb</key>
<string>id</string>
<key>o_input_httpproxy_fld</key>
<string>id</string>
<key>o_input_httpproxy_txt</key>
<string>id</string>
<key>o_input_httpproxypwd_sfld</key>
<string>id</string>
<key>o_input_httpproxypwd_txt</key>
<string>id</string>
<key>o_input_mux_box</key>
<string>id</string>
<key>o_input_net_box</key>
<string>id</string>
<key>o_input_postproc_fld</key>
<string>id</string>
<key>o_input_postproc_txt</key>
<string>id</string>
<key>o_input_record_ckb</key>
<string>id</string>
<key>o_input_rtsp_ckb</key>
<string>id</string>
<key>o_input_serverport_fld</key>
<string>id</string>
<key>o_input_serverport_txt</key>
<string>id</string>
<key>o_input_timeshift_ckb</key>
<string>id</string>
<key>o_input_view</key>
<string>id</string>
<key>o_intf_art_pop</key>
<string>id</string>
<key>o_intf_art_txt</key>
<string>id</string>
<key>o_intf_embedded_ckb</key>
<string>id</string>
<key>o_intf_fspanel_ckb</key>
<string>id</string>
<key>o_intf_lang_pop</key>
<string>id</string>
<key>o_intf_lang_txt</key>
<string>id</string>
<key>o_intf_meta_ckb</key>
<string>id</string>
<key>o_intf_network_box</key>
<string>id</string>
<key>o_intf_view</key>
<string>id</string>
<key>o_osd_encoding_pop</key>
<string>id</string>
<key>o_osd_encoding_txt</key>
<string>id</string>
<key>o_osd_font_box</key>
<string>id</string>
<key>o_osd_font_btn</key>
<string>id</string>
<key>o_osd_font_color_pop</key>
<string>id</string>
<key>o_osd_font_color_txt</key>
<string>id</string>
<key>o_osd_font_effect_pop</key>
<string>id</string>
<key>o_osd_font_effect_txt</key>
<string>id</string>
<key>o_osd_font_fld</key>
<string>id</string>
<key>o_osd_font_size_pop</key>
<string>id</string>
<key>o_osd_font_size_txt</key>
<string>id</string>
<key>o_osd_font_txt</key>
<string>id</string>
<key>o_osd_lang_box</key>
<string>id</string>
<key>o_osd_lang_fld</key>
<string>id</string>
<key>o_osd_lang_txt</key>
<string>id</string>
<key>o_osd_osd_box</key>
<string>id</string>
<key>o_osd_osd_ckb</key>
<string>id</string>
<key>o_osd_view</key>
<string>id</string>
<key>o_sprefs_basicFull_matrix</key>
<string>id</string>
<key>o_sprefs_basic_box</key>
<string>id</string>
<key>o_sprefs_cancel_btn</key>
<string>id</string>
<key>o_sprefs_controls_box</key>
<string>id</string>
<key>o_sprefs_reset_btn</key>
<string>id</string>
<key>o_sprefs_save_btn</key>
<string>id</string>
<key>o_sprefs_win</key>
<string>id</string>
<key>o_video_black_ckb</key>
<string>id</string>
<key>o_video_device_pop</key>
<string>id</string>
<key>o_video_device_txt</key>
<string>id</string>
<key>o_video_display_box</key>
<string>id</string>
<key>o_video_enable_ckb</key>
<string>id</string>
<key>o_video_fullscreen_ckb</key>
<string>id</string>
<key>o_video_onTop_ckb</key>
<string>id</string>
<key>o_video_output_pop</key>
<string>id</string>
<key>o_video_output_txt</key>
<string>id</string>
<key>o_video_skipFrames_ckb</key>
<string>id</string>
<key>o_video_snap_box</key>
<string>id</string>
<key>o_video_snap_folder_btn</key>
<string>id</string>
<key>o_video_snap_folder_fld</key>
<string>id</string>
<key>o_video_snap_folder_txt</key>
<string>id</string>
<key>o_video_snap_format_pop</key>
<string>id</string>
<key>o_video_snap_format_txt</key>
<string>id</string>
<key>o_video_snap_prefix_fld</key>
<string>id</string>
<key>o_video_snap_prefix_txt</key>
<string>id</string>
<key>o_video_snap_seqnum_ckb</key>
<string>id</string>
<key>o_video_view</key>
<string>id</string>
</dict>
<key>SUPERCLASS</key>
<string>NSObject</string>
</dict>
<dict>
<key>CLASS</key>
<string>NSObject</string>
<key>LANGUAGE</key>
<string>ObjC</string>
</dict>
<dict>
<key>CLASS</key>
<string>FirstResponder</string>
<key>LANGUAGE</key>
<string>ObjC</string>
<key>SUPERCLASS</key>
<string>NSObject</string>
</dict>
<dict>
<key>ACTIONS</key>
<dict>
<key>advancedToggle</key>
<string>id</string>
<key>closePrefs</key>
<string>id</string>
<key>resetAll</key>
<string>id</string>
<key>savePrefs</key>
<string>id</string>
</dict>
<key>CLASS</key>
<string>VLCPrefs</string>
<key>LANGUAGE</key>
<string>ObjC</string>
<key>OUTLETS</key>
<dict>
<key>o_advanced_ckb</key>
<string>id</string>
<key>o_cancel_btn</key>
<string>id</string>
<key>o_prefs_view</key>
<string>id</string>
<key>o_prefs_window</key>
<string>id</string>
<key>o_reset_btn</key>
<string>id</string>
<key>o_save_btn</key>
<string>id</string>
<key>o_title</key>
<string>id</string>
<key>o_tree</key>
<string>id</string>
</dict>
<key>SUPERCLASS</key>
<string>NSObject</string>
</dict>
</array>
<key>IBVersion</key>
<string>1</string>
</dict>
</plist>
{
IBClasses = (
{
CLASS = FirstResponder;
LANGUAGE = ObjC;
SUPERCLASS = NSObject;
},
{
CLASS = NSApplication;
LANGUAGE = ObjC;
SUPERCLASS = NSResponder;
},
{
CLASS = NSObject;
LANGUAGE = ObjC;
},
{
CLASS = VLCHotkeyChangeWindow;
LANGUAGE = ObjC;
SUPERCLASS = NSWindow;
},
{
ACTIONS = {
advancedToggle = id;
buttonAction = id;
closePrefs = id;
resetAll = id;
savePrefs = id;
};
CLASS = VLCPrefs;
LANGUAGE = ObjC;
OUTLETS = {
"o_advanced_ckb" = id;
"o_basicFull_matrix" = id;
"o_cancel_btn" = id;
"o_prefs_view" = id;
"o_prefs_window" = id;
"o_reset_btn" = id;
"o_save_btn" = id;
"o_title" = id;
"o_tree" = id;
};
SUPERCLASS = NSObject;
},
{
ACTIONS = {
audioSettingChanged = id;
buttonAction = id;
hotkeySettingChanged = id;
inputSettingChanged = id;
interfaceSettingChanged = id;
osdSettingChanged = id;
videoSettingChanged = id;
};
CLASS = VLCSimplePrefs;
LANGUAGE = ObjC;
OUTLETS = {
"o_audio_dolby_pop" = id;
"o_audio_dolby_txt" = id;
"o_audio_effects_box" = id;
"o_audio_enable_ckb" = id;
"o_audio_general_box" = id;
"o_audio_headphone_ckb" = id;
"o_audio_lang_fld" = id;
"o_audio_lang_txt" = id;
"o_audio_last_box" = id;
"o_audio_last_ckb" = id;
"o_audio_lastpwd_sfld" = id;
"o_audio_lastpwd_txt" = id;
"o_audio_lastuser_fld" = id;
"o_audio_lastuser_txt" = id;
"o_audio_norm_ckb" = id;
"o_audio_norm_fld" = id;
"o_audio_spdif_ckb" = id;
"o_audio_view" = id;
"o_audio_visual_pop" = id;
"o_audio_visual_txt" = id;
"o_audio_vol_fld" = id;
"o_audio_vol_sld" = id;
"o_audio_vol_txt" = id;
"o_hotkeys_change_btn" = id;
"o_hotkeys_change_cancel_btn" = id;
"o_hotkeys_change_keys_lbl" = id;
"o_hotkeys_change_lbl" = id;
"o_hotkeys_change_ok_btn" = id;
"o_hotkeys_change_taken_lbl" = id;
"o_hotkeys_change_win" = id;
"o_hotkeys_clear_btn" = id;
"o_hotkeys_lbl" = id;
"o_hotkeys_listbox" = id;
"o_hotkeys_view" = id;
"o_input_access_box" = id;
"o_input_avi_pop" = id;
"o_input_avi_txt" = id;
"o_input_bandwidth_ckb" = id;
"o_input_cachelevel_custom_txt" = id;
"o_input_cachelevel_pop" = id;
"o_input_cachelevel_txt" = id;
"o_input_caching_box" = id;
"o_input_dump_ckb" = id;
"o_input_httpproxy_fld" = id;
"o_input_httpproxy_txt" = id;
"o_input_httpproxypwd_sfld" = id;
"o_input_httpproxypwd_txt" = id;
"o_input_mux_box" = id;
"o_input_net_box" = id;
"o_input_postproc_fld" = id;
"o_input_postproc_txt" = id;
"o_input_record_ckb" = id;
"o_input_rtsp_ckb" = id;
"o_input_serverport_fld" = id;
"o_input_serverport_txt" = id;
"o_input_timeshift_ckb" = id;
"o_input_view" = id;
"o_intf_art_pop" = id;
"o_intf_art_txt" = id;
"o_intf_embedded_ckb" = id;
"o_intf_fspanel_ckb" = id;
"o_intf_lang_pop" = id;
"o_intf_lang_txt" = id;
"o_intf_meta_ckb" = id;
"o_intf_network_box" = id;
"o_intf_view" = id;
"o_osd_encoding_pop" = id;
"o_osd_encoding_txt" = id;
"o_osd_font_box" = id;
"o_osd_font_btn" = id;
"o_osd_font_color_pop" = id;
"o_osd_font_color_txt" = id;
"o_osd_font_effect_pop" = id;
"o_osd_font_effect_txt" = id;
"o_osd_font_fld" = id;
"o_osd_font_size_pop" = id;
"o_osd_font_size_txt" = id;
"o_osd_font_txt" = id;
"o_osd_lang_box" = id;
"o_osd_lang_fld" = id;
"o_osd_lang_txt" = id;
"o_osd_osd_box" = id;
"o_osd_osd_ckb" = id;
"o_osd_view" = id;
"o_sprefs_basicFull_matrix" = id;
"o_sprefs_basic_box" = id;
"o_sprefs_cancel_btn" = id;
"o_sprefs_controls_box" = id;
"o_sprefs_reset_btn" = id;
"o_sprefs_save_btn" = id;
"o_sprefs_win" = id;
"o_video_black_ckb" = id;
"o_video_device_pop" = id;
"o_video_device_txt" = id;
"o_video_display_box" = id;
"o_video_enable_ckb" = id;
"o_video_fullscreen_ckb" = id;
"o_video_onTop_ckb" = id;
"o_video_output_pop" = id;
"o_video_output_txt" = id;
"o_video_skipFrames_ckb" = id;
"o_video_snap_box" = id;
"o_video_snap_folder_btn" = id;
"o_video_snap_folder_fld" = id;
"o_video_snap_folder_txt" = id;
"o_video_snap_format_pop" = id;
"o_video_snap_format_txt" = id;
"o_video_snap_prefix_fld" = id;
"o_video_snap_prefix_txt" = id;
"o_video_snap_seqnum_ckb" = id;
"o_video_view" = id;
};
SUPERCLASS = NSObject;
}
);
IBVersion = 1;
}
\ No newline at end of file
......@@ -2,22 +2,39 @@
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>IBDocumentLocation</key>
<string>48 424 356 240 0 0 1280 778 </string>
<key>IBEditorPositions</key>
<dict>
<key>2311</key>
<string>345 402 590 264 0 0 1280 778 </string>
<key>2330</key>
<string>345 223 590 502 0 0 1280 778 </string>
<key>2440</key>
<string>345 308 590 389 0 0 1280 778 </string>
<key>2523</key>
<string>345 320 590 373 0 0 1280 778 </string>
<key>2562</key>
<string>345 221 590 505 0 0 1280 778 </string>
<key>2668</key>
<string>345 257 590 457 0 0 1280 778 </string>
</dict>
<key>IBFramework Version</key>
<string>667</string>
<string>489.0</string>
<key>IBLastKnownRelativeProjectPath</key>
<string>../../vlc.xcodeproj</string>
<key>IBOldestOS</key>
<integer>5</integer>
<key>IBOpenObjects</key>
<array>
<integer>2265</integer>
<integer>2311</integer>
<integer>2410</integer>
<integer>2678</integer>
<integer>2523</integer>
<integer>2668</integer>
<integer>2330</integer>
<integer>2563</integer>
<integer>2440</integer>
<integer>2562</integer>
<integer>2330</integer>
<integer>2523</integer>
<integer>1530</integer>
</array>
<key>IBSystem Version</key>
<string>9D34</string>
......
......@@ -423,7 +423,7 @@ static VLCMain *_o_sharedMainInstance = nil;
_o_sharedMainInstance = [super init];
o_about = [[VLAboutBox alloc] init];
o_prefs = [[VLCPrefs alloc] init];
o_prefs = nil;
o_open = [[VLCOpen alloc] init];
o_wizard = [[VLCWizard alloc] init];
o_extended = nil;
......@@ -1801,22 +1801,25 @@ static VLCMain *_o_sharedMainInstance = nil;
/* release some other objects here, because it isn't sure whether dealloc
* will be called later on */
if( nib_about_loaded )
[o_about release];
if( nib_prefs_loaded )
{
[o_sprefs release];
[o_prefs release];
}
if( nib_open_loaded )
[o_open release];
if( nib_extended_loaded )
{
[o_extended collapsAll];
[o_extended release];
}
if( nib_bookmarks_loaded )
[o_bookmarks release];
......@@ -2003,11 +2006,14 @@ static VLCMain *_o_sharedMainInstance = nil;
- (IBAction)viewPreferences:(id)sender
{
if( !nib_prefs_loaded )
{
nib_prefs_loaded = [NSBundle loadNibNamed:@"Preferences" owner: self];
o_sprefs = [[VLCSimplePrefs alloc] init];
o_prefs= [[VLCPrefs alloc] init];
}
if( sender == o_mi_sprefs )
{
o_sprefs = [[VLCSimplePrefs alloc] init];
[o_sprefs showSimplePrefs];
}
else
......
......@@ -66,6 +66,7 @@
IBOutlet id o_cancel_btn;
IBOutlet id o_reset_btn;
IBOutlet id o_advanced_ckb;
IBOutlet id o_basicFull_matrix;
}
+ (VLCPrefs *)sharedInstance;
......@@ -77,6 +78,7 @@
- (IBAction)closePrefs: (id)sender;
- (IBAction)resetAll: (id)sender;
- (IBAction)advancedToggle: (id)sender;
- (IBAction)buttonAction: (id)sender;
@end
......
......@@ -53,10 +53,11 @@
#include <vlc_common.h>
#include <vlc_config_cat.h>
#include "intf.h"
#include "prefs.h"
#include "prefs_widgets.h"
#include "vlc_keys.h"
#import "intf.h"
#import "prefs.h"
#import "simple_prefs.h"
#import "prefs_widgets.h"
#import "vlc_keys.h"
/*****************************************************************************
* VLCPrefs implementation
......@@ -112,6 +113,9 @@ static VLCPrefs *_o_sharedMainInstance = nil;
- (void)showPrefs
{
[[o_basicFull_matrix cellAtRow:0 column:0] setState: NSOffState];
[[o_basicFull_matrix cellAtRow:0 column:1] setState: NSOnState];
[o_prefs_window center];
[o_prefs_window makeKeyAndOrderFront:self];
}
......@@ -123,6 +127,8 @@ static VLCPrefs *_o_sharedMainInstance = nil;
[o_cancel_btn setTitle: _NS("Cancel")];
[o_reset_btn setTitle: _NS("Reset All")];
[o_advanced_ckb setTitle: _NS("Advanced")];
[[o_basicFull_matrix cellAtRow: 0 column: 0] setStringValue: _NS("Basic")];
[[o_basicFull_matrix cellAtRow: 0 column: 1] setStringValue: _NS("All")];
}
- (IBAction)savePrefs: (id)sender
......@@ -170,6 +176,14 @@ static VLCPrefs *_o_sharedMainInstance = nil;
( [o_advanced_ckb state] == NSOnState ) ? true : false];
}
- (IBAction)buttonAction: (id)sender
{
[o_prefs_window orderOut: self];
[[o_basicFull_matrix cellAtRow:0 column:0] setState: NSOnState];
[[o_basicFull_matrix cellAtRow:0 column:1] setState: NSOffState];
[[[VLCMain sharedInstance] getSimplePreferences] showSimplePrefs];
}
- (void)loadConfigTree
{
}
......
......@@ -48,10 +48,10 @@ static VLCSimplePrefs *_o_sharedInstance = nil;
if (_o_sharedInstance) {
[self dealloc];
} else {
p_intf = VLCIntf;
_o_sharedInstance = [super init];
p_intf = VLCIntf;
}
return _o_sharedInstance;
}
......@@ -274,14 +274,6 @@ static VLCSimplePrefs *_o_sharedInstance = nil;
[o_osd_osd_box setTitle: _NS("On Screen Display")];
[o_osd_osd_ckb setTitle: _NS("Enable OSD")];
/* generic stuff */
[[o_sprefs_basicFull_matrix cellAtRow: 0 column: 0] setStringValue: _NS("Basic")];
[[o_sprefs_basicFull_matrix cellAtRow: 0 column: 1] setStringValue: _NS("All")];
[o_sprefs_cancel_btn setTitle: _NS("Cancel")];
[o_sprefs_reset_btn setTitle: _NS("Reset Preferences")];
[o_sprefs_save_btn setTitle: _NS("Save")];
[o_sprefs_win setTitle: _NS("Preferences")];
/* video */
[o_video_black_ckb setTitle: _NS("Black screens in Fullscreen mode")];
[o_video_device_txt setStringValue: _NS("Display device")];
......@@ -297,6 +289,14 @@ static VLCSimplePrefs *_o_sharedInstance = nil;
[o_video_snap_format_txt setStringValue: _NS("Format")];
[o_video_snap_prefix_txt setStringValue: _NS("Prefix")];
[o_video_snap_seqnum_ckb setTitle: _NS("Sequential numbering")];
/* generic stuff */
[[o_sprefs_basicFull_matrix cellAtRow: 0 column: 0] setStringValue: _NS("Basic")];
[[o_sprefs_basicFull_matrix cellAtRow: 0 column: 1] setStringValue: _NS("All")];
[o_sprefs_cancel_btn setTitle: _NS("Cancel")];
[o_sprefs_reset_btn setTitle: _NS("Reset Preferences")];
[o_sprefs_save_btn setTitle: _NS("Save")];
[o_sprefs_win setTitle: _NS("Preferences")];
}
- (void)resetControls
......@@ -356,6 +356,9 @@ static VLCSimplePrefs *_o_sharedInstance = nil;
vlc_list_release( p_list ); \
[object setToolTip: _NS(p_item->psz_longtext)]
[[o_sprefs_basicFull_matrix cellAtRow:0 column:0] setState: NSOnState];
[[o_sprefs_basicFull_matrix cellAtRow:0 column:1] setState: NSOffState];
/**********************
* interface settings *
**********************/
......@@ -610,8 +613,9 @@ static VLCSimplePrefs *_o_sharedInstance = nil;
else if( sender == o_sprefs_basicFull_matrix )
{
[o_sprefs_win orderOut: self];
[[o_sprefs_basicFull_matrix cellAtRow:0 column:0] setState: NSOffState];
[[o_sprefs_basicFull_matrix cellAtRow:0 column:1] setState: NSOnState];
[[[VLCMain sharedInstance] getPreferences] showPrefs];
[self resetControls];
}
else
msg_Err( p_intf, "unknown buttonAction sender" );
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment