gekko513 said:
According to Apple's "How to use Sheets documentation" your code isn't as it should be. Docs -> Cocoa -> User Experience -> Sheets
To show the sheet, just the two first lines should be sufficient.
To close the sheet, listen to actions from a button or something similar and call
Code:
nsapp.endSheet(encipherPanel)
there.
Then you need to order the sheet out when the endSheet is done, in Objective C you would have set a didEndSelector where this is done, but I don't know how to do that in Java.
Your third line shouldn't be anywhere at all if I read the docs correctly.
Like I said...it works fine when called from a button. Even if it is depreciated, so is the Cocoa-Java bridge, and therefore it may require it.
caveman_uk said:
Because you're a Java programmer? If you're Apple, wasting your time keeping up a Java bridge that very few people use for production apps seems a waste of time and money. Should they maintain a Cobol-bridge as well just to keep cobol old-timers happy?
I'm not just a Java programmer. I'm using Java because I already wrote the implementation of the cipher I'm using, and cipher mode in Java, and I don't want to mess with endians or pointers doing it in C, and then wrapping it in Objective-C objects.
I find it very odd for you to compare a legacy language to Java.
If you look at a company like Microsoft, they have C#, J#, etc which they not only maintain, but document thoroughly.
I just feel that by limiting the languages that can access the primary API, you're limiting the number of applications for your platform.
In addition, very few people use it because there is no documentation for it. There are no real examples. I've talked to dozons of Java programmers who've tried and given up on Cocoa Java...not because they didn't know Java well, but because they couldn't figure out Cocoa Java due to lack of documentation and examples.
I have an idea of what is wrong with my program. I'll re-do a few things, and see if I can get it to work.
Thanks to all who have replied up to this point. I'll keep you informed on how it goes.