Si infatti ho visto che funziona questo ma non è esattamente quello che vorrei

Io ho questa classe all'interno del mio package

package miopackage;

import javax.swing.*;

public class InternalFrame extends JInternalFrame{

private JScrollPane sp;
private JTextArea ta;
private JTextField tf;

/** Creates a new instance of intFr */
public IntFr() {
sp = new JScrollPane();
ta = new JTextArea();
tf = new JTextField();

setClosable(true);
setIconifiable(true);
setMaximizable(true);
setResizable(true);
setVisible(true);

ta.setColumns(255);
ta.setFont(new java.awt.Font("Courier", 0, 14));
ta.setRows(5);
sp.setViewportView(ta);
tf.setEditable(false);
tf.setFont(new java.awt.Font("Courier", 0, 14));

org.jdesktop.layout.GroupLayout intfrLayout = new org.jdesktop.layout.GroupLayout(getContentPane());
getContentPane().setLayout(intfrLayout);
intfrLayout.setHorizontalGroup(
intfrLayout.createParallelGroup(org.jdesktop.layou t.GroupLayout.LEADING)
.add(tf, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 720, Short.MAX_VALUE)
.add(sp, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 720, Short.MAX_VALUE)
);
intfrLayout.setVerticalGroup(
intfrLayout.createParallelGroup(org.jdesktop.layou t.GroupLayout.LEADING)
.add(intfrLayout.createSequentialGroup()
.add(tf, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
.addPreferredGap(org.jdesktop.layout.LayoutStyle.R ELATED)
.add(sp, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 378, Short.MAX_VALUE))
);
}

public JTextArea getTextArea(){
return ta;
}

/*public JScrollPane getScrollPane(){
return sp;
}*/

public JTextField getTextField(){
return tf;
}

}

Quando apro il file (selezionandolo tramite un Jfilechooser) da visualizzare all'interno vorrei che mi desse un messaggio che mi chiedesse "Vuoi visualizzare il file anche all'esterno?"

Se clicco su "SI" il file che ho visualizzato nel jinternalframe si dovrebbe aprire anche come jframe esterno altrimenti rimane solo nel jinternalframe