|
@@ -726,6 +726,19 @@
|
|
|
|
|
|
- (void)drawWithBox:(CPDFDisplayBox)box inContext:(CGContextRef)context
|
|
- (void)drawWithBox:(CPDFDisplayBox)box inContext:(CGContextRef)context
|
|
{
|
|
{
|
|
|
|
+ if (self.annotationShouldDisplay == false && self.shouldDisplay == false) {
|
|
|
|
+ dispatch_async(dispatch_get_main_queue(), ^{
|
|
|
|
+ self.textView.hidden = YES;
|
|
|
|
+ });
|
|
|
|
+
|
|
|
|
+ [super drawWithBox:box inContext:context];
|
|
|
|
+ return;
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ dispatch_async(dispatch_get_main_queue(), ^{
|
|
|
|
+ self.textView.hidden = NO;
|
|
|
|
+ });
|
|
|
|
+
|
|
[NSGraphicsContext saveGraphicsState];
|
|
[NSGraphicsContext saveGraphicsState];
|
|
if (context) {
|
|
if (context) {
|
|
[NSGraphicsContext setCurrentContext:[NSGraphicsContext graphicsContextWithGraphicsPort:context flipped:NO]];
|
|
[NSGraphicsContext setCurrentContext:[NSGraphicsContext graphicsContextWithGraphicsPort:context flipped:NO]];
|