< prev index next >
src/java.desktop/macosx/native/libsplashscreen/splashscreen_sys.m
Print this page
rev 54098 : 8260616: Removing remaining JNF dependencies in the java.desktop module
8259729: Missed JNFInstanceOf -> IsInstanceOf conversion
@@ -26,11 +26,10 @@
#include "splashscreen_impl.h"
#import <Cocoa/Cocoa.h>
#import <objc/objc-auto.h>
-#import <JavaNativeFoundation/JavaNativeFoundation.h>
#import "NSApplicationAWT.h"
#include <sys/time.h>
#include <pthread.h>
#include <iconv.h>
@@ -200,11 +199,11 @@
splash->screenFormat.byteOrder = 1 ? BYTE_ORDER_LSBFIRST : BYTE_ORDER_MSBFIRST;
splash->screenFormat.depthBytes = 4;
// If we are running SWT we should not start a runLoop
if (!isSWTRunning()) {
- [JNFRunLoop performOnMainThreadWaiting:NO withBlock:^() {
+ [ThreadUtilities performOnMainThreadWaiting:NO block:^() {
[NSApplicationAWT runAWTLoopWithApp:[NSApplicationAWT sharedApplication]];
}];
}
}
@@ -216,11 +215,11 @@
void
SplashDonePlatform(Splash * splash) {
NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
pthread_mutex_destroy(&splash->lock);
- [JNFRunLoop performOnMainThreadWaiting:YES withBlock:^(){
+ [ThreadUtilities performOnMainThreadWaiting:YES block:^(){
if (splash->window) {
[splash->window orderOut:nil];
[splash->window release];
}
}];
@@ -255,11 +254,11 @@
void
SplashRedrawWindow(Splash * splash) {
NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
- [JNFRunLoop performOnMainThreadWaiting:YES withBlock:^(){
+ [ThreadUtilities performOnMainThreadWaiting:YES block:^(){
// drop the reference to the old view and image
[splash->window setContentView: nil];
SplashUpdateScreenData(splash);
// NSDeviceRGBColorSpace vs. NSCalibratedRGBColorSpace ?
@@ -314,11 +313,11 @@
}
void SplashReconfigureNow(Splash * splash) {
NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
- [JNFRunLoop performOnMainThreadWaiting:YES withBlock:^(){
+ [ThreadUtilities performOnMainThreadWaiting:YES block:^(){
SplashCenter(splash);
if (!splash->window) {
return;
}
@@ -403,11 +402,11 @@
pipe(splash->controlpipe);
fcntl(splash->controlpipe[0], F_SETFL,
fcntl(splash->controlpipe[0], F_GETFL, 0) | O_NONBLOCK);
splash->time = SplashTime();
splash->currentFrame = 0;
- [JNFRunLoop performOnMainThreadWaiting:YES withBlock:^(){
+ [ThreadUtilities performOnMainThreadWaiting:YES block:^(){
SplashCenter(splash);
splash->window = (void*) [[NSWindow alloc]
initWithContentRect: NSMakeRect(splash->x, splash->y, splash->width, splash->height)
styleMask: NSBorderlessWindowMask
@@ -418,11 +417,11 @@
[splash->window setOpaque: NO];
[splash->window setBackgroundColor: [NSColor clearColor]];
}];
fflush(stdout);
if (splash->window) {
- [JNFRunLoop performOnMainThreadWaiting:YES withBlock:^(){
+ [ThreadUtilities performOnMainThreadWaiting:YES block:^(){
[splash->window orderFrontRegardless];
}];
SplashRedrawWindow(splash);
SplashEventLoop(splash);
}
< prev index next >