Revision: 3959
http://skim-app.svn.sourceforge.net/skim-app/?rev=3959&view=rev
Author: hofman
Date: 2008-06-04 04:11:41 -0700 (Wed, 04 Jun 2008)
Log Message:
-----------
Don't send string method when we determined it's not a string. Small changes to
initializing a new note.
Modified Paths:
--------------
trunk/PDFAnnotation_SKExtensions.m
Modified: trunk/PDFAnnotation_SKExtensions.m
===================================================================
--- trunk/PDFAnnotation_SKExtensions.m 2008-06-04 10:51:57 UTC (rev 3958)
+++ trunk/PDFAnnotation_SKExtensions.m 2008-06-04 11:11:41 UTC (rev 3959)
@@ -141,14 +141,15 @@
- (id)initNoteWithProperties:(NSDictionary *)dict{
Class stringClass = [NSString class];
- if ([self class] == [PDFAnnotation class]) {
+ if ([self isMemberOfClass:[PDFAnnotation class]]) {
// generic, initalize the class for the type in the dictionary
NSString *type = [dict objectForKey:SKPDFAnnotationTypeKey];
Class annotationClass = NULL;
+ NSZone *zone = [self zone];
if ([type isKindOfClass:stringClass] == NO)
annotationClass = Nil;
- if ([type isEqualToString:SKNoteString] || [type
isEqualToString:SKTextString])
+ else if ([type isEqualToString:SKNoteString] || [type
isEqualToString:SKTextString])
annotationClass = [SKPDFAnnotationNote class];
else if ([type isEqualToString:SKFreeTextString])
annotationClass = [PDFAnnotationFreeText class];
@@ -162,7 +163,7 @@
annotationClass = [PDFAnnotationLine class];
[[self initWithBounds:NSZeroRect] release];
- self = [[annotationClass alloc] initNoteWithProperties:dict];
+ self = [[annotationClass allocWithZone:zone]
initNoteWithProperties:dict];
} else {
// called from the initialization of a subclass
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php
_______________________________________________
Skim-app-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/skim-app-commit