Revision: 13025
          http://sourceforge.net/p/skim-app/code/13025
Author:   hofman
Date:     2022-07-16 09:38:26 +0000 (Sat, 16 Jul 2022)
Log Message:
-----------
post accessibility notifications when pdf control view is shown or hidden

Modified Paths:
--------------
    trunk/SKSecondaryPDFView.m
    trunk/SKSnapshotPDFView.m

Modified: trunk/SKSecondaryPDFView.m
===================================================================
--- trunk/SKSecondaryPDFView.m  2022-07-16 09:14:17 UTC (rev 13024)
+++ trunk/SKSecondaryPDFView.m  2022-07-16 09:38:26 UTC (rev 13025)
@@ -325,6 +325,7 @@
             [[controlView animator] setAlphaValue:0.0];
         } completionHandler:^{
             [controlView removeFromSuperview];
+            
NSAccessibilityPostNotificationWithUserInfo(NSAccessibilityUnignoredAncestor([self
 documentView]), NSAccessibilityLayoutChangedNotification, nil);
         }];
     }
 }
@@ -629,10 +630,12 @@
 - (void)keyDown:(NSEvent *)theEvent {
     if ([theEvent firstCharacter] == '?' && ([theEvent standardModifierFlags] 
& ~NSShiftKeyMask) == 0) {
         [[self class] cancelPreviousPerformRequestsWithTarget:self 
selector:@selector(showControlView) object:nil];
-        if ([controlView superview])
+        if ([controlView superview]) {
             [controlView removeFromSuperview];
-        else
+            
NSAccessibilityPostNotificationWithUserInfo(NSAccessibilityUnignoredAncestor([self
 documentView]), NSAccessibilityLayoutChangedNotification, nil);
+        } else {
             [self showControlView];
+        }
     } else {
         [super keyDown:theEvent];
     }

Modified: trunk/SKSnapshotPDFView.m
===================================================================
--- trunk/SKSnapshotPDFView.m   2022-07-16 09:14:17 UTC (rev 13024)
+++ trunk/SKSnapshotPDFView.m   2022-07-16 09:38:26 UTC (rev 13025)
@@ -228,6 +228,7 @@
             [[controlView animator] setAlphaValue:0.0];
         } completionHandler:^{
             [controlView removeFromSuperview];
+            
NSAccessibilityPostNotificationWithUserInfo(NSAccessibilityUnignoredAncestor([self
 documentView]), NSAccessibilityLayoutChangedNotification, nil);
         }];
     }
 }
@@ -569,10 +570,12 @@
 - (void)keyDown:(NSEvent *)theEvent {
     if ([theEvent firstCharacter] == '?' && ([theEvent standardModifierFlags] 
& ~NSShiftKeyMask) == 0) {
         [[self class] cancelPreviousPerformRequestsWithTarget:self 
selector:@selector(showControlView) object:nil];
-        if ([controlView superview])
+        if ([controlView superview]) {
             [controlView removeFromSuperview];
-        else
+            
NSAccessibilityPostNotificationWithUserInfo(NSAccessibilityUnignoredAncestor([self
 documentView]), NSAccessibilityLayoutChangedNotification, nil);
+        } else {
             [self showControlView];
+        }
     } else {
         [super keyDown:theEvent];
     }

This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.



_______________________________________________
Skim-app-commit mailing list
Skim-app-commit@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/skim-app-commit

Reply via email to