summaryrefslogtreecommitdiffstats
path: root/macosx/HBLanguagesSelection.m
diff options
context:
space:
mode:
authorritsuka <[email protected]>2014-08-16 16:05:26 +0000
committerritsuka <[email protected]>2014-08-16 16:05:26 +0000
commit66590157361bb0b7e7cf2a4622feee77fd38fe1c (patch)
tree4507e5e08cd5ab17789071d1698f80eaf961e7a1 /macosx/HBLanguagesSelection.m
parentb6084716cf4dbfc50596fa8126eb0fa1c0101dfa (diff)
MacGui: Fixed the languages selection in the built in presets for languages with a native name.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@6300 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'macosx/HBLanguagesSelection.m')
-rw-r--r--macosx/HBLanguagesSelection.m22
1 files changed, 22 insertions, 0 deletions
diff --git a/macosx/HBLanguagesSelection.m b/macosx/HBLanguagesSelection.m
index 3bdb8ec61..bdc6ed7ae 100644
--- a/macosx/HBLanguagesSelection.m
+++ b/macosx/HBLanguagesSelection.m
@@ -20,6 +20,17 @@
return self;
}
+- (instancetype)copyWithZone:(NSZone *)zone
+{
+ HBLang *lang = [[self class] allocWithZone:zone];
+
+ lang->_isSelected = self.isSelected;
+ lang->_language = [self.language retain];
+ lang->_iso639_2 = [self.iso639_2 retain];
+
+ return lang;
+}
+
- (void)dealloc
{
[_language release];
@@ -28,10 +39,21 @@
[super dealloc];
}
+- (NSString *)description
+{
+ return self.language;
+}
+
@end
@implementation HBLanguagesSelection
+- (instancetype)init
+{
+ self = [self initWithLanguages:nil];
+ return self;
+}
+
- (instancetype)initWithLanguages:(NSArray *)languages
{
self = [super init];