I'm having a problem using the Swing Application Framework's Component Resource Injection, I read the tutorial provided by Sun and it kinda works.
The case is that I have a class Program
that extends from the SingleFrameApplication
provided by de SAF, now I want to get the text of my components (buttons and labels, etc.) from a properties file and it works as expected for that Program
class, (I created a subdirectory called resources
and put the Program.properties
file in there). But, I have a MainFrame
within a subpackage named mainpkg.gui
(the Program
is within the mainpkg
package) and I created the corresponding resources
subsubpackage for placing the MainFrame.properties
file, and it does not work! I cannot get the bundle (automatically, I guess if I use the ResourceMap.getXXX()
method I'd get the stuff.
What am I doing wrong?
Thanks in advance!