53 |
private final static String LS_PORT = "LinuxSampler.port"; |
private final static String LS_PORT = "LinuxSampler.port"; |
54 |
private final static int DEF_LS_PORT = 8888; |
private final static int DEF_LS_PORT = 8888; |
55 |
|
|
|
private final static String ORCHESTRAS = "Orchestras"; |
|
|
private final static String DEF_ORCHESTRAS = null; |
|
|
|
|
56 |
|
|
57 |
private static Preferences userPrefs = Preferences.userRoot().node(prefNode); |
private static Preferences userPrefs = Preferences.userRoot().node(prefNode); |
58 |
|
|
218 |
if(port == -1) user().remove(LS_PORT); |
if(port == -1) user().remove(LS_PORT); |
219 |
else if(port != getLSPort()) user().putInt(LS_PORT, port); |
else if(port != getLSPort()) user().putInt(LS_PORT, port); |
220 |
} |
} |
|
|
|
|
/** |
|
|
* Gets the orchestras' content (in XML format). |
|
|
* @return The orchestras' content (in XML format). |
|
|
*/ |
|
|
public static String |
|
|
getOrchestras() { return user().get(ORCHESTRAS, DEF_ORCHESTRAS); } |
|
|
|
|
|
/** |
|
|
* Sets the orchestras' content (in XML format). |
|
|
* @param s The orchestras' content (in XML format). |
|
|
*/ |
|
|
public static void |
|
|
setOrchestras(String s) { |
|
|
if(s == null) { |
|
|
user().remove(ORCHESTRAS); |
|
|
return; |
|
|
} |
|
|
if(s.equals(getOrchestras())) return; |
|
|
|
|
|
user().put(ORCHESTRAS, s); |
|
|
} |
|
221 |
} |
} |