This week's giveaways are in the MongoDB and Jobs Discussion forums. We're giving away four copies of Mongo DB Applied Patterns and 4 resume reviews from Five Year Itch and have the authors/reps on-line! See this thread and this one for details.
this should be fairly simple but i am having difficulty. here is some code.
i want the fadeMenuItem to display a dialog very much like the strokeMenuItem does only with a slider instead of a textfield. i looked at the tutorial for custom dialog but it only confuses me. what exactly do i have to do? it seems i have to declare a JDialog and then add a JOptionPane to it?
i also face another problem. when the slider moves i want either the main image to change, or i want a small preview image in the dialog.
any help appreciated
Joined: Oct 21, 2000
i found a simpler example of extending JDialog. even better, i found this:
If you don't need much in the way of custom behavior, JOptionPane is a good time saver. It takes care of the placement and localization of OK / Cancel options, and is a quick-and-dirty way to show a custom dialog without needing to define your own classes. Most of the time the "message" parameter in JOptionPane is a String, but you can pass in a JComponent or array of JComponents as well.