OpenConcerto

Dépôt officiel du code source de l'ERP OpenConcerto
sonarqube

svn://code.openconcerto.org/openconcerto

Rev

Rev 74 | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 74 Rev 181
Line 4... Line 4...
4
 
4
 
5
import org.openconcerto.modules.extensionbuilder.Extension;
5
import org.openconcerto.modules.extensionbuilder.Extension;
6
import org.openconcerto.ui.DefaultListModel;
6
import org.openconcerto.ui.DefaultListModel;
7
 
7
 
8
public class AllKnownActionsListModel extends DefaultListModel {
8
public class AllKnownActionsListModel extends DefaultListModel {
-
 
9
    private final Extension extension;
9
 
10
 
10
    public AllKnownActionsListModel(Extension module) {
11
    public AllKnownActionsListModel(Extension extension) {
11
        List<ActionDescriptor> l = module.getActionDescriptors();
12
        final List<ActionDescriptor> l = extension.getActionDescriptors();
12
        this.addAll(l);
13
        this.addAll(l);
-
 
14
        this.extension = extension;
-
 
15
    }
-
 
16
 
-
 
17
    public void addAction() {
-
 
18
        final ActionDescriptor obj = new ActionDescriptor("Action_" + this.size());
-
 
19
        this.addElement(obj);
-
 
20
        this.extension.addCreateAction(obj);
-
 
21
 
13
    }
22
    }
14
}
23
}