From 33335e6149f2d6f6ebdad64588d9fba2f0ebb49b Mon Sep 17 00:00:00 2001 From: Sven Gothel Date: Thu, 27 Oct 2011 02:49:28 +0200 Subject: NEWT/OSX NewtView: Add 'soft' pthread locking impacts: needsDisplay/displayIfNeeded, .. - Add 'soft' pthread locking (blockin) - impacts: needsDisplay/displayIfNeeded, .. - needsDisplay/displayIfNeeded also respects destroyNotifySend (ignore action if set) --- src/newt/native/NewtMacWindow.h | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) (limited to 'src/newt/native/NewtMacWindow.h') diff --git a/src/newt/native/NewtMacWindow.h b/src/newt/native/NewtMacWindow.h index 945948291..cb256e71f 100644 --- a/src/newt/native/NewtMacWindow.h +++ b/src/newt/native/NewtMacWindow.h @@ -32,6 +32,7 @@ */ #import +#import #import "jni.h" #include "NewtCommon.h" @@ -53,6 +54,8 @@ int jvmVersion; BOOL destroyNotifySent; + BOOL softLocked; + pthread_mutex_t softLockSync; NSTrackingRectTag ptrTrackingTag; NSRect ptrRect; @@ -60,8 +63,7 @@ } - (id)initWithFrame:(NSRect)frameRect; - -- (NSCursor *) cursor; +- (void) dealloc; /* Set during event dispatching cycle */ - (void) setJVMHandle: (JavaVM*) vm; @@ -74,12 +76,18 @@ - (void) setJavaWindowObject: (jobject) javaWindowObj; - (jobject) getJavaWindowObject; +- (void) rightMouseDown: (NSEvent*) theEvent; +- (void) resetCursorRects; +- (NSCursor *) cursor; + - (void) setDestroyNotifySent: (BOOL) v; - (BOOL) getDestroyNotifySent; -- (void) rightMouseDown: (NSEvent*) theEvent; -- (void) resetCursorRects; +- (BOOL) softLock; +- (void) softUnlock; +- (BOOL) needsDisplay; +- (void) displayIfNeeded; - (void) viewWillDraw; - (void) drawRect:(NSRect)dirtyRect; - (void) viewDidHide; -- cgit v1.2.3