I am developing a GUI in swing that has a JTabbedPane with several tabs. I have written a custom FocusListener to do some work when the TabbedPane gains focus, but nothing happens when you go on to select different tabs. I have sice tried to add a Changelistener to the JTabbed paing to keep track of the state of the tabs, but it seems to be a little buggy when I try to get a reference to the component inside. Does anyone know of a good way to add a listener that would accept events fired when a user changes tabs that would allow me to get a reference to the component inside the tab?