Issue with OSX 10.9 multiple desktops - java

I run about multiple desktops at all times and if I stay on the desktop that My App is running on everything seems fine. If I move away from the desktop with my app on and work on a different desktop this is where my app will stop downloading once it has finished its current process, it will switch to the next process but will not start next downloading.
I identified that that it might be virtual desktop related. If I switch all desktops for a second then operation works fine.
I was working on 10.8 OS X where my app (built in java) was working absolutely fine.
but as I upgraded it to 10.9, I am facing problem like above.
Is that have any solution or It is a bug of 10.9 OS X.

Related

Mac OS and java.lang.NullPointerException at java.awt.Window.init(Window.java:497)

I've been setting up a 2018 MacBook Pro for Java development. It's running Mojave 10.14.1 - just like the older machine I'm migrating from, an early 2013 MacBook Pro. I installed Java 1.8.0_192 and immediately noticed that I could not launch jars or any Java app that had a UI on this mac. I uninstalled and tried each of these: 1.8.0_172, 1.8.0_191, 1.8.0_192, and 11.0.1. I traced the issue further and found a common error:
Caused by: java.lang.NullPointerException
at java.awt.Window.init(Window.java:497)
at java.awt.Window.<init>(Window.java:537)
at java.awt.Frame.<init>(Frame.java:420)
at java.awt.Frame.<init>(Frame.java:385)
at javax.swing.SwingUtilities$SharedOwnerFrame.<init>(SwingUtilities.java:1763)
at javax.swing.SwingUtilities.getSharedOwnerFrame(SwingUtilities.java:1838)
at javax.swing.JWindow.<init>(JWindow.java:187)
at javax.swing.JWindow.<init>(JWindow.java:139)
Curious, I launched our Swing-based product and it reported the same error. I googled and found only unanswered posts.
(revising this to be formatted as a question and not a blog post)
What gives?
I had the same issue and I found it reported here.
In my case, I was using a docking station for my MacBook Pro and DisplayLink Driver for extended display. This made Jmeter crash.
The workaround was to disconnect my laptop from its docking station and launching the application.
The solution to this problem was simple, but not immediately obvious.
I dug into the JVM and found that the native code wasn't able to identify a compatible graphics mode from the OS. This results in a null GraphicsConfiguration. That's not good - it causes a NullPointerException in Window.java...guess what line. (Line 497)
I suspected the OS wasn't returning the right information about its graphics setup and then started to suspect the graphics driver. That's when I remembered Macs have parameter RAM (PRAM) and non-volatile RAM (NVRAM).
I zapped the PRAM and NVRAM and now the machine is working fine!
To zap the PRAM and NVRAM:
shut down your mac
restart while holding option+command+P+R
keep holding these until the mac appears to reboot again (the apple logo
will appear, disappear, and reappear)
If your mac starts up without the disappearing mac logo, shut it down and retry.
Reset NVRAM or PRAM on your Mac
I hope resetting the PRAM helps others!
We have the same issue when trying to open an inhouse Java-based application in conjunction with Dell D6000 docks using DisplayLink software.
As others have suggested disconnecting the Dock then launching the application works after which you can reconnect the dock and move the application to the other screen.
The other way we have managed to get it to work is with the laptop open making the laptop screen the main display this is done in the system prefs in the display settings and moving the white bar to the laptop screen then opening the application.
I think it has been said before when the main display is one run through DisplayLink it can't detect the display so return a null value, even running most recent drivers (24th Aug 2020) this is still the case.
So its workarounds not solutions if you are in the same boat

Java app no longer runs under OS X 10.11 El Capitan

We have a set of Java applications that have been working fine on OS X for years. They work fine on OS X 10.10.
A few people just upgraded to 10.11, and one of the apps no longer runs. It gets a:
com.apple.xpc.launchd[1]: (com.apple.xpc.launchd.oneshot.0x10000004.OSXJavaLauncher[395]) Service exited with abnormal code: 1
Error in the console, and never starts at all. (icon shows on the taskbar for just a second.)
Our other app starts just fine. It is built with the same Java Launcher code.
Is there any way to find out what OS X doesn't like about the app that fails to start?
I was having the same problem, basically even with Java for OS X 2015-001 installed my app wouldn't start. In researching this problem, I came across information on this github page, which does a really good job of explaining the issue. In short, Java apps built into native executables for mac using older tools will no longer work because of incompatibilities in the plist format, and applicationstubs. Apps built for Apple's java are not running with Oracle's java and vice-versa.
Using the information from the referenced page, I rewrote our ant build using this ant task, and this application stub. I now have a native app that runs on both Apple's Java 6 and Oracle's Java 8 and runs in testing on OSX 10.9-10.11.

Swing app freezes in dual screen windows 7 environment when moving app to top right hand corner of second monitor

I built this Swing app to help my girlfriend get a particular job done faster. On my dual monitor windows system, the app and the Operating System freeze when moving the app to the extreme right hand side of the second monitor. Windows recovers, but the app does not. Has anyone experienced this sort of issue and know how to solve it? Below is the github link to the source code.
I tried to also provide a screenshot of the frozen app and the OS but it is difficult to take one when the OS freezes.
The app works fine on her Mac.
https://github.com/johndeverall/BehaviourCoder

Gui application halting on OSX when left unattended

My (java based) Gui application processes digital music files, and is designed so it can be left unattended. I have noticed that if I leave it running overnight on my OSX Mavericks computer that it stops shortly after I leave it, only restarting when I touch the keybaord in the morning.
How can I prevent this, I do not have the same problem running the application on a Windows 8 machine.
Select your app in the Finder and "Get Info" and then check "Disable App Nap"…
See the Apple Developer notes for Mavericks for more info

Blank image (frame buffer)

I have a really annoying problem which I'm pretty sure is due to the hybrid graphics on my laptop in some way....
I have a dell 15r laptop with hybrid nvidia/intel graphics.
If I have an external monitor plugged into my HDMI port when I run anything from libGDX I just get a blank screen the program is running fine, but nothing appears/displayed. So I can click on my application and it works correctly, however I cannot see anything.
If I run it just on the laptop then plug the monitor in half way through, it carries on running as normal.
If I start running it on the monitor but then unplug the monitor so it reverts to the laptop screen, it displays nothing again.
Using this...
System.out.println(Gdx.graphics.getGL20().glGetString(GL20.GL_VENDOR));
The program reports
NVIDIA Corporation
Fixed it.
Upgraded to latest NVidia drivers and everything seems fine.

Categories

Resources