Line | |
---|
1 | package org.openstreetmap.josm.gui.dialogs.relation.actions;
|
---|
2 |
|
---|
3 | /**
|
---|
4 | * This interface can be used to register the event listeners for a
|
---|
5 | * {@link AbstractRelationEditorAction}.
|
---|
6 | * <p>
|
---|
7 | * It holds common constants that are often used.
|
---|
8 | *
|
---|
9 | * @author Michael Zangl
|
---|
10 | * @since 14027
|
---|
11 | */
|
---|
12 | @FunctionalInterface
|
---|
13 | public interface IRelationEditorUpdateOn {
|
---|
14 | /**
|
---|
15 | * Update when the member table contents change
|
---|
16 | */
|
---|
17 | IRelationEditorUpdateOn MEMBER_TABLE_CHANGE = (editor, action) -> editor.getMemberTableModel()
|
---|
18 | .addTableModelListener(action);
|
---|
19 | /**
|
---|
20 | * Update upon a member table selection change
|
---|
21 | */
|
---|
22 | IRelationEditorUpdateOn MEMBER_TABLE_SELECTION = (editor, action) -> editor.getMemberTable().getSelectionModel()
|
---|
23 | .addListSelectionListener(action);
|
---|
24 |
|
---|
25 | IRelationEditorUpdateOn TAG_CHANGE = (editor, action) -> editor.getTagModel().addPropertyChangeListener(action);
|
---|
26 | IRelationEditorUpdateOn SELECTION_TABLE_CHANGE = (editor, action) -> editor.getSelectionTableModel()
|
---|
27 | .addTableModelListener(action);
|
---|
28 |
|
---|
29 | void register(IRelationEditorActionAccess editor, AbstractRelationEditorAction action);
|
---|
30 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.