Subversion Repositories svn.mios

Rev

Rev 716 | Rev 722 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 716 Rev 721
Line 101... Line 101...
101
    private DefaultTableModel ccModel;
101
    private DefaultTableModel ccModel;
102
102
103
    private JTable channels;
103
    private JTable channels;
104
104
105
    private DefaultTableModel channelsModel;
105
    private DefaultTableModel channelsModel;
-
 
106
   
-
 
107
    private String definitionTag = "midiFilter";
106
108
107
    private static String currentDirectory = "";
109
    private static String currentDirectory = "";
108
110
109
    private static JFileChooser fc = null;
111
    private static JFileChooser fc = null;
110
112
Line 404... Line 406...
404
        int nRetVal = fc.showOpenDialog(this);
406
        int nRetVal = fc.showOpenDialog(this);
405
407
406
        if (nRetVal == JFileChooser.APPROVE_OPTION) {
408
        if (nRetVal == JFileChooser.APPROVE_OPTION) {
407
            File file = fc.getSelectedFile();
409
            File file = fc.getSelectedFile();
408
410
409
            MidiFilterXML.loadMidiFilter(midiFilter, file);
411
            MidiFilterXML midiFilterXML = new MidiFilterXML(midiFilter, definitionTag);
-
 
412
           
-
 
413
            midiFilterXML.loadXML(file);
410
414
411
            setButtonStates();
415
            setButtonStates();
412
416
413
            currentDirectory = fc.getCurrentDirectory().toString();
417
            currentDirectory = fc.getCurrentDirectory().toString();
414
        }
418
        }
Line 432... Line 436...
432
        int nRetVal = fc.showSaveDialog(this);
436
        int nRetVal = fc.showSaveDialog(this);
433
437
434
        if (nRetVal == JFileChooser.APPROVE_OPTION) {
438
        if (nRetVal == JFileChooser.APPROVE_OPTION) {
435
            File file = fc.getSelectedFile();
439
            File file = fc.getSelectedFile();
436
440
437
            MidiFilterXML.saveMidiFilter(midiFilter, file);
441
            MidiFilterXML midiFilterXML = new MidiFilterXML(midiFilter, definitionTag);
-
 
442
           
-
 
443
            midiFilterXML.saveXML(file);
438
444
439
            currentDirectory = fc.getCurrentDirectory().toString();
445
            currentDirectory = fc.getCurrentDirectory().toString();
440
        }
446
        }
441
    }
447
    }
442
448