1 |
/* |
/* |
2 |
* JSampler - a java front-end for LinuxSampler |
* JSampler - a java front-end for LinuxSampler |
3 |
* |
* |
4 |
* Copyright (C) 2005-2008 Grigor Iliev <grigor@grigoriliev.com> |
* Copyright (C) 2005-2011 Grigor Iliev <grigor@grigoriliev.com> |
5 |
* |
* |
6 |
* This file is part of JSampler. |
* This file is part of JSampler. |
7 |
* |
* |
30 |
import java.awt.GridBagLayout; |
import java.awt.GridBagLayout; |
31 |
import java.awt.Insets; |
import java.awt.Insets; |
32 |
|
|
|
import java.awt.datatransfer.Transferable; |
|
|
|
|
33 |
import java.awt.event.ActionEvent; |
import java.awt.event.ActionEvent; |
34 |
import java.awt.event.ActionListener; |
import java.awt.event.ActionListener; |
35 |
import java.awt.event.HierarchyEvent; |
import java.awt.event.HierarchyEvent; |
72 |
import javax.swing.event.ChangeEvent; |
import javax.swing.event.ChangeEvent; |
73 |
import javax.swing.event.ChangeListener; |
import javax.swing.event.ChangeListener; |
74 |
|
|
75 |
import net.sf.juife.InformationDialog; |
import net.sf.juife.swing.InformationDialog; |
76 |
import net.sf.juife.JuifeUtils; |
import net.sf.juife.swing.JuifeUtils; |
77 |
|
|
78 |
import org.jsampler.AudioDeviceModel; |
import org.jsampler.AudioDeviceModel; |
79 |
import org.jsampler.CC; |
import org.jsampler.CC; |
102 |
import org.jsampler.view.std.JSChannelOutputRoutingDlg; |
import org.jsampler.view.std.JSChannelOutputRoutingDlg; |
103 |
import org.jsampler.view.std.JSFxSendsPane; |
import org.jsampler.view.std.JSFxSendsPane; |
104 |
import org.jsampler.view.std.JSInstrumentChooser; |
import org.jsampler.view.std.JSInstrumentChooser; |
105 |
|
import org.jsampler.view.swing.SHF; |
106 |
|
|
107 |
import org.linuxsampler.lscp.AudioOutputDevice; |
import org.linuxsampler.lscp.AudioOutputDevice; |
108 |
import org.linuxsampler.lscp.MidiInputDevice; |
import org.linuxsampler.lscp.MidiInputDevice; |
112 |
|
|
113 |
import static org.jsampler.view.classic.ClassicI18n.i18n; |
import static org.jsampler.view.classic.ClassicI18n.i18n; |
114 |
import static org.jsampler.view.classic.ClassicPrefs.preferences; |
import static org.jsampler.view.classic.ClassicPrefs.preferences; |
115 |
import static org.jsampler.view.std.StdPrefs.*; |
import static org.jsampler.JSPrefs.*; |
116 |
|
|
117 |
|
|
118 |
/** |
/** |
119 |
* |
* |
120 |
* @author Grigor Iliev |
* @author Grigor Iliev |
121 |
*/ |
*/ |
122 |
public class Channel extends org.jsampler.view.JSChannel { |
public class Channel extends org.jsampler.view.swing.SwingChannel { |
123 |
private final static ImageIcon iconEdit; |
private final static ImageIcon iconEdit; |
124 |
|
|
125 |
private final static ImageIcon iconMuteOn; |
private final static ImageIcon iconMuteOn; |
876 |
|
|
877 |
private void |
private void |
878 |
loadInstrument() { |
loadInstrument() { |
879 |
JSInstrumentChooser dlg = ClassicUtils.createInstrumentChooser(CC.getMainFrame()); |
JSInstrumentChooser dlg = ClassicUtils.createInstrumentChooser(SHF.getMainFrame()); |
880 |
dlg.setVisible(true); |
dlg.setVisible(true); |
881 |
|
|
882 |
if(dlg.isCancelled()) return; |
if(dlg.isCancelled()) return; |
1062 |
public void |
public void |
1063 |
actionPerformed(ActionEvent e) { |
actionPerformed(ActionEvent e) { |
1064 |
SamplerChannel c = getModel().getChannelInfo(); |
SamplerChannel c = getModel().getChannelInfo(); |
1065 |
new JSChannelOutputRoutingDlg(CC.getMainFrame(), c).setVisible(true); |
new JSChannelOutputRoutingDlg(SHF.getMainFrame(), c).setVisible(true); |
1066 |
|
|
1067 |
} |
} |
1068 |
}); |
}); |
1078 |
|
|
1079 |
FxSendsPane p = new FxSendsPane(getModel()); |
FxSendsPane p = new FxSendsPane(getModel()); |
1080 |
int id = getModel().getChannelId(); |
int id = getModel().getChannelId(); |
1081 |
fxSendsDlg = new InformationDialog(CC.getMainFrame(), p); |
fxSendsDlg = new InformationDialog(SHF.getMainFrame(), p); |
1082 |
fxSendsDlg.setTitle(i18n.getLabel("FxSendsDlg.title", id)); |
fxSendsDlg.setTitle(i18n.getLabel("FxSendsDlg.title", id)); |
1083 |
fxSendsDlg.setModal(false); |
fxSendsDlg.setModal(false); |
1084 |
fxSendsDlg.showCloseButton(false); |
fxSendsDlg.showCloseButton(false); |