I have a JFrame object, and i need to support two JVM 1.5 on Mac OS X and 1.6 on Windows. On windows I need to use setIconImages function to set multiple icon sized for the application but this function is not availible on 1.5. Is it possible to call this function inside JFrame with reflection?
Application extends JFrame{
.
.
.
void init(){
//check version
//call setIconImages
}
}
I would do something like the following (wont’ compile, but should get you started):
create a class called FrameUtils and give it the following method:
This link shows you how to get the method and call it via reflection.