summaryrefslogtreecommitdiffstats
path: root/macosx
diff options
context:
space:
mode:
authorritsuka <[email protected]>2015-06-01 17:23:11 +0000
committerritsuka <[email protected]>2015-06-01 17:23:11 +0000
commited7212d81585b107b16db52abb6e0627712eb64f (patch)
tree8bc376df9157c1152bbc87de013a8580dd217e20 /macosx
parent29b0a01848dcff05c0ccf184ce1d8b99aec63507 (diff)
MacGui: fix the audio defaults to use the languages specified in the preferences.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@7258 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'macosx')
-rw-r--r--macosx/HBAudioDefaults.m14
1 files changed, 7 insertions, 7 deletions
diff --git a/macosx/HBAudioDefaults.m b/macosx/HBAudioDefaults.m
index acff4ceaa..f54bb8e77 100644
--- a/macosx/HBAudioDefaults.m
+++ b/macosx/HBAudioDefaults.m
@@ -95,22 +95,22 @@
if ([preset[@"Type"] intValue] == 0)
{
self.trackSelectionBehavior = HBAudioTrackSelectionBehaviorFirst;
- if (self.trackSelectionLanguages.count == 0)
+ if (self.trackSelectionLanguages.count == 0 || [self.trackSelectionLanguages.firstObject isEqualToString:@"und"])
{
- if ([[NSUserDefaults standardUserDefaults] stringForKey:@"DefaultLanguage"])
+ if ([[NSUserDefaults standardUserDefaults] stringForKey:@"AlternateLanguage"])
{
- NSString *lang = [self isoCodeForNativeLang:[[NSUserDefaults standardUserDefaults] stringForKey:@"DefaultLanguage"]];
+ NSString *lang = [self isoCodeForNativeLang:[[NSUserDefaults standardUserDefaults] stringForKey:@"AlternateLanguage"]];
if (lang)
{
- [self.trackSelectionLanguages addObject:lang];
+ [self.trackSelectionLanguages insertObject:lang atIndex:0];
}
}
- if ([[NSUserDefaults standardUserDefaults] stringForKey:@"AlternateLanguage"])
+ if ([[NSUserDefaults standardUserDefaults] stringForKey:@"DefaultLanguage"])
{
- NSString *lang = [self isoCodeForNativeLang:[[NSUserDefaults standardUserDefaults] stringForKey:@"AlternateLanguage"]];
+ NSString *lang = [self isoCodeForNativeLang:[[NSUserDefaults standardUserDefaults] stringForKey:@"DefaultLanguage"]];
if (lang)
{
- [self.trackSelectionLanguages addObject:lang];
+ [self.trackSelectionLanguages insertObject:lang atIndex:0];
}
}
}