}
public void action() {
filesToOpen.clear();
final MergeDialog md = new MergeDialog(frame, Globals.lang("Append database"), true);
Util.placeDialog(md, panel);
md.setVisible(true);
if (md.isOkPressed()) {
String[] chosen = FileDialogs.getMultipleFiles(frame, new File(Globals.prefs.get("workingDirectory")),
null, false);
//String chosenFile = Globals.getNewFile(frame, new File(Globals.prefs.get("workingDirectory")),
// null, JFileChooser.OPEN_DIALOG, false);
if(chosen == null)
return;
for (int i=0; i<chosen.length; i++)
filesToOpen.add(new File(chosen[i]));
// Run the actual open in a thread to prevent the program
// locking until the file is loaded.
(new Thread() {
public void run() {
openIt(md.importEntries(), md.importStrings(),
md.importGroups(), md.importSelectorWords());
}
}).start();
//frame.getFileHistory().newFile(panel.fileToOpen.getPath());
}