Disabling AppNap from java
steve at weblite.ca
Sat Feb 22 17:13:51 PST 2014
For doing simple Objective-C things like this, I wrote an objective-c
bridge. It uses JNA and allows you to access any OS X SDK without having
to generate stub classes for them (like you do with rococoa).
Some sample code to give you an idea:
Loading a nib file:
On Sat, Feb 22, 2014 at 4:53 PM, Michael Hall <mik3hall at gmail.com> wrote:
> On Feb 22, 2014, at 6:23 PM, Scott Palmer <swpalmer at gmail.com> wrote:
> > On Sat, Feb 22, 2014 at 4:49 PM, Paul Taylor <paul_t100 at fastmail.fm>
> >> On 22/02/2014 20:43, Eirik Bakke wrote:
> >>> JNA might be a simpler way to call native functions:
> >>> https://github.com/twall/jna
> >>> ...
> Not that more native choices are whats needed but if we are tossing out
> different options for that then...
> For my HalfPipe application I set up a simple jNI interface to the command
> line interface for FScript
> Which is supposed to be a smalltalk-like Cocoa interface.
> I think I had some fairly simple ObjectiveC runtime interface code in
> place for JRuby using FFI
> This was sort of like JNIDirect which was something Patrick Beard came up
> with a while back when JDirect was going away, or shortly after it had gone
> Michael Hall
> trz nio.2 for OS X http://www195.pair.com/mik3hall/index.html#trz
> HalfPipe Java 6/7 shell app
> AppConverter convert Apple jvm to openjdk apps
> >> I think JNA or its own is Wndows only isnt it, but there is something
> >> called rococoa.
> >> To be honest I was hoping someone else had encountered this particular
> >> problem with AppNap and had something to share.
> >> Paul
> > JNA works on Windows, OS X, Linux, and more. However, it is based on C
> > interfaces and calling conventions. Rococoa (
> > https://code.google.com/p/rococoa/) implements a similar thing for
> > interacting with Objective-C interfaces.
> > Scott
Web Lite Solutions Corp.
More information about the macosx-port-dev