if(con!= null ){
final JMEAnimationController conn = con;
SwingUtilities.invokeLater(new Runnable() {
public void run() {
AnimationInputSwitchSidebar bar = new AnimationInputSwitchSidebar();
bar.setTarget(conn);
JFrame frame = new JFrame();
frame.getContentPane().add(bar);
frame.setDefaultCloseOperation(WindowConstants.DISPOSE_ON_CLOSE);
frame.pack();
frame.setVisible(true);