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

Add support for the http proxy password setting to the simple prefs and make...

Add support for the http proxy password setting to the simple prefs and make sure that the last.fm password isn't displayed as plain text
parent 1de30292
...@@ -4,6 +4,14 @@ ...@@ -4,6 +4,14 @@
<dict> <dict>
<key>IBClasses</key> <key>IBClasses</key>
<array> <array>
<dict>
<key>CLASS</key>
<string>NSApplication</string>
<key>LANGUAGE</key>
<string>ObjC</string>
<key>SUPERCLASS</key>
<string>NSResponder</string>
</dict>
<dict> <dict>
<key>CLASS</key> <key>CLASS</key>
<string>VLCHotkeyChangeWindow</string> <string>VLCHotkeyChangeWindow</string>
...@@ -56,7 +64,7 @@ ...@@ -56,7 +64,7 @@
<string>id</string> <string>id</string>
<key>o_audio_last_ckb</key> <key>o_audio_last_ckb</key>
<string>id</string> <string>id</string>
<key>o_audio_lastpwd_fld</key> <key>o_audio_lastpwd_sfld</key>
<string>id</string> <string>id</string>
<key>o_audio_lastpwd_txt</key> <key>o_audio_lastpwd_txt</key>
<string>id</string> <string>id</string>
...@@ -128,6 +136,10 @@ ...@@ -128,6 +136,10 @@
<string>id</string> <string>id</string>
<key>o_input_httpproxy_txt</key> <key>o_input_httpproxy_txt</key>
<string>id</string> <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> <key>o_input_mux_box</key>
<string>id</string> <string>id</string>
<key>o_input_net_box</key> <key>o_input_net_box</key>
...@@ -262,11 +274,9 @@ ...@@ -262,11 +274,9 @@
</dict> </dict>
<dict> <dict>
<key>CLASS</key> <key>CLASS</key>
<string>NSApplication</string> <string>NSObject</string>
<key>LANGUAGE</key> <key>LANGUAGE</key>
<string>ObjC</string> <string>ObjC</string>
<key>SUPERCLASS</key>
<string>NSResponder</string>
</dict> </dict>
<dict> <dict>
<key>CLASS</key> <key>CLASS</key>
...@@ -276,12 +286,6 @@ ...@@ -276,12 +286,6 @@
<key>SUPERCLASS</key> <key>SUPERCLASS</key>
<string>NSObject</string> <string>NSObject</string>
</dict> </dict>
<dict>
<key>CLASS</key>
<string>NSObject</string>
<key>LANGUAGE</key>
<string>ObjC</string>
</dict>
<dict> <dict>
<key>ACTIONS</key> <key>ACTIONS</key>
<dict> <dict>
......
...@@ -3,24 +3,24 @@ ...@@ -3,24 +3,24 @@
<plist version="1.0"> <plist version="1.0">
<dict> <dict>
<key>IBFramework Version</key> <key>IBFramework Version</key>
<string>648</string> <string>667</string>
<key>IBLastKnownRelativeProjectPath</key> <key>IBLastKnownRelativeProjectPath</key>
<string>../../vlc.xcodeproj</string> <string>../../vlc.xcodeproj</string>
<key>IBOldestOS</key> <key>IBOldestOS</key>
<integer>5</integer> <integer>5</integer>
<key>IBOpenObjects</key> <key>IBOpenObjects</key>
<array> <array>
<integer>2668</integer>
<integer>2678</integer>
<integer>2562</integer>
<integer>2311</integer> <integer>2311</integer>
<integer>2330</integer>
<integer>2523</integer>
<integer>2410</integer> <integer>2410</integer>
<integer>2678</integer>
<integer>2523</integer>
<integer>2668</integer>
<integer>2330</integer>
<integer>2563</integer>
<integer>2440</integer> <integer>2440</integer>
</array> </array>
<key>IBSystem Version</key> <key>IBSystem Version</key>
<string>9C7010</string> <string>9D34</string>
<key>targetFramework</key> <key>targetFramework</key>
<string>IBCocoaFramework</string> <string>IBCocoaFramework</string>
</dict> </dict>
......
...@@ -37,7 +37,7 @@ ...@@ -37,7 +37,7 @@
IBOutlet id o_audio_lang_txt; IBOutlet id o_audio_lang_txt;
IBOutlet id o_audio_last_box; IBOutlet id o_audio_last_box;
IBOutlet id o_audio_last_ckb; IBOutlet id o_audio_last_ckb;
IBOutlet id o_audio_lastpwd_fld; IBOutlet id o_audio_lastpwd_sfld;
IBOutlet id o_audio_lastpwd_txt; IBOutlet id o_audio_lastpwd_txt;
IBOutlet id o_audio_lastuser_fld; IBOutlet id o_audio_lastuser_fld;
IBOutlet id o_audio_lastuser_txt; IBOutlet id o_audio_lastuser_txt;
...@@ -74,6 +74,8 @@ ...@@ -74,6 +74,8 @@
IBOutlet id o_input_dump_ckb; IBOutlet id o_input_dump_ckb;
IBOutlet id o_input_httpproxy_fld; IBOutlet id o_input_httpproxy_fld;
IBOutlet id o_input_httpproxy_txt; IBOutlet id o_input_httpproxy_txt;
IBOutlet id o_input_httpproxypwd_sfld;
IBOutlet id o_input_httpproxypwd_txt;
IBOutlet id o_input_mux_box; IBOutlet id o_input_mux_box;
IBOutlet id o_input_net_box; IBOutlet id o_input_net_box;
IBOutlet id o_input_postproc_fld; IBOutlet id o_input_postproc_fld;
......
...@@ -244,6 +244,7 @@ static VLCSimplePrefs *_o_sharedInstance = nil; ...@@ -244,6 +244,7 @@ static VLCSimplePrefs *_o_sharedInstance = nil;
[o_input_cachelevel_custom_txt setStringValue: _NS("Use the complete preferences to configure custom caching values for each access module.")]; [o_input_cachelevel_custom_txt setStringValue: _NS("Use the complete preferences to configure custom caching values for each access module.")];
[o_input_dump_ckb setTitle: _NS("Dump")]; [o_input_dump_ckb setTitle: _NS("Dump")];
[o_input_httpproxy_txt setStringValue: _NS("HTTP Proxy")]; [o_input_httpproxy_txt setStringValue: _NS("HTTP Proxy")];
[o_input_httpproxypwd_txt setStringValue: _NS("Password for HTTP Proxy")];
[o_input_mux_box setTitle: _NS("Codecs / Muxers")]; [o_input_mux_box setTitle: _NS("Codecs / Muxers")];
[o_input_net_box setTitle: _NS("Network")]; [o_input_net_box setTitle: _NS("Network")];
[o_input_postproc_txt setStringValue: _NS("Post-Processing Quality")]; [o_input_postproc_txt setStringValue: _NS("Post-Processing Quality")];
...@@ -391,19 +392,19 @@ static VLCSimplePrefs *_o_sharedInstance = nil; ...@@ -391,19 +392,19 @@ static VLCSimplePrefs *_o_sharedInstance = nil;
if( module_Exists( p_intf, "audioscrobbler" ) ) if( module_Exists( p_intf, "audioscrobbler" ) )
{ {
[o_audio_lastuser_fld setStringValue: [NSString stringWithUTF8String: config_GetPsz( p_intf, "lastfm-username" )]]; [o_audio_lastuser_fld setStringValue: [NSString stringWithUTF8String: config_GetPsz( p_intf, "lastfm-username" )]];
[o_audio_lastpwd_fld setStringValue: [NSString stringWithUTF8String: config_GetPsz( p_intf, "lastfm-password" )]]; [o_audio_lastpwd_sfld setStringValue: [NSString stringWithUTF8String: config_GetPsz( p_intf, "lastfm-password" )]];
if( config_ExistIntf( VLC_OBJECT( p_intf ), "audioscrobbler" ) ) if( config_ExistIntf( VLC_OBJECT( p_intf ), "audioscrobbler" ) )
{ {
[o_audio_last_ckb setState: NSOnState]; [o_audio_last_ckb setState: NSOnState];
[o_audio_lastuser_fld setEnabled: YES]; [o_audio_lastuser_fld setEnabled: YES];
[o_audio_lastpwd_fld setEnabled: YES]; [o_audio_lastpwd_sfld setEnabled: YES];
} }
else else
{ {
[o_audio_last_ckb setState: NSOffState]; [o_audio_last_ckb setState: NSOffState];
[o_audio_lastuser_fld setEnabled: NO]; [o_audio_lastuser_fld setEnabled: NO];
[o_audio_lastpwd_fld setEnabled: NO]; [o_audio_lastpwd_sfld setEnabled: NO];
} }
} }
else else
...@@ -457,6 +458,8 @@ static VLCSimplePrefs *_o_sharedInstance = nil; ...@@ -457,6 +458,8 @@ static VLCSimplePrefs *_o_sharedInstance = nil;
[o_input_serverport_fld setIntValue: config_GetInt( p_intf, "server-port" )]; [o_input_serverport_fld setIntValue: config_GetInt( p_intf, "server-port" )];
if( config_GetPsz( p_intf, "http-proxy" ) != NULL ) if( config_GetPsz( p_intf, "http-proxy" ) != NULL )
[o_input_httpproxy_fld setStringValue: [NSString stringWithUTF8String: config_GetPsz( p_intf, "http-proxy" )]]; [o_input_httpproxy_fld setStringValue: [NSString stringWithUTF8String: config_GetPsz( p_intf, "http-proxy" )]];
if( config_GetPsz( p_intf, "http-proxy" ) != NULL )
[o_input_httpproxypwd_sfld setStringValue: [NSString stringWithUTF8String: config_GetPsz( p_intf, "http-proxy-pwd" )]];
[o_input_postproc_fld setIntValue: config_GetInt( p_intf, "ffmpeg-pp-q" )]; [o_input_postproc_fld setIntValue: config_GetInt( p_intf, "ffmpeg-pp-q" )];
SetupIntList( o_input_avi_pop, "avi-index" ); SetupIntList( o_input_avi_pop, "avi-index" );
...@@ -738,7 +741,7 @@ static VLCSimplePrefs *_o_sharedInstance = nil; ...@@ -738,7 +741,7 @@ static VLCSimplePrefs *_o_sharedInstance = nil;
config_RemoveIntf( VLC_OBJECT( p_intf ), "audioscrobbler" ); config_RemoveIntf( VLC_OBJECT( p_intf ), "audioscrobbler" );
config_PutPsz( p_intf, "lastfm-username", [[o_audio_lastuser_fld stringValue] UTF8String] ); config_PutPsz( p_intf, "lastfm-username", [[o_audio_lastuser_fld stringValue] UTF8String] );
config_PutPsz( p_intf, "lastfm-password", [[o_audio_lastpwd_fld stringValue] UTF8String] ); config_PutPsz( p_intf, "lastfm-password", [[o_audio_lastpwd_sfld stringValue] UTF8String] );
} }
else else
[o_audio_last_ckb setEnabled: NO]; [o_audio_last_ckb setEnabled: NO];
...@@ -795,6 +798,7 @@ static VLCSimplePrefs *_o_sharedInstance = nil; ...@@ -795,6 +798,7 @@ static VLCSimplePrefs *_o_sharedInstance = nil;
{ {
config_PutInt( p_intf, "server-port", [o_input_serverport_fld intValue] ); config_PutInt( p_intf, "server-port", [o_input_serverport_fld intValue] );
config_PutPsz( p_intf, "http-proxy", [[o_input_httpproxy_fld stringValue] UTF8String] ); config_PutPsz( p_intf, "http-proxy", [[o_input_httpproxy_fld stringValue] UTF8String] );
config_PutPsz( p_intf, "http-proxy-pwd", [[o_input_httpproxypwd_sfld stringValue] UTF8String] );
config_PutInt( p_intf, "ffmpeg-pp-q", [o_input_postproc_fld intValue] ); config_PutInt( p_intf, "ffmpeg-pp-q", [o_input_postproc_fld intValue] );
SaveIntList( o_input_avi_pop, "avi-index" ); SaveIntList( o_input_avi_pop, "avi-index" );
...@@ -979,12 +983,12 @@ static VLCSimplePrefs *_o_sharedInstance = nil; ...@@ -979,12 +983,12 @@ static VLCSimplePrefs *_o_sharedInstance = nil;
{ {
if( [o_audio_last_ckb state] == NSOnState ) if( [o_audio_last_ckb state] == NSOnState )
{ {
[o_audio_lastpwd_fld setEnabled: YES]; [o_audio_lastpwd_sfld setEnabled: YES];
[o_audio_lastuser_fld setEnabled: YES]; [o_audio_lastuser_fld setEnabled: YES];
} }
else else
{ {
[o_audio_lastpwd_fld setEnabled: NO]; [o_audio_lastpwd_sfld setEnabled: NO];
[o_audio_lastuser_fld setEnabled: NO]; [o_audio_lastuser_fld setEnabled: NO];
} }
} }
......
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