Restricted external processors to unlocked sentences
This commit is contained in:
@@ -1 +1 @@
|
||||
version=0.1.3
|
||||
version=0.1.4
|
||||
|
||||
@@ -1145,9 +1145,11 @@ public class AudiobookRecorder extends JFrame {
|
||||
Chapter c = (Chapter)o.getObject();
|
||||
for (Enumeration s = c.children(); s.hasMoreElements();) {
|
||||
Sentence snt = (Sentence)s.nextElement();
|
||||
if (!snt.isLocked()) {
|
||||
snt.runExternalProcessor(Utils.s2i(o.getActionCommand()));
|
||||
}
|
||||
}
|
||||
}
|
||||
});
|
||||
ob.setActionCommand(Integer.toString(i));
|
||||
external.add(ob);
|
||||
|
||||
@@ -1178,6 +1178,7 @@ public class Sentence extends DefaultMutableTreeNode implements Cacheable {
|
||||
}
|
||||
|
||||
public void runExternalProcessor(int num) {
|
||||
if (isLocked()) return;
|
||||
ExternalProcessor ed = new ExternalProcessor(this, num);
|
||||
Thread t = new Thread(ed);
|
||||
t.start();
|
||||
|
||||
Reference in New Issue
Block a user