public void afterMapChange(final MapModel oldMap, final MapModel newMap) {
addStyleMenu(menuBuilder, "main_menu_styles", newMap);
addStyleMenu(menuBuilder, "node_popup_styles", newMap);
}
});
final MapController mapController = modeController.getMapController();
mapController.addMapChangeListener(new IMapChangeListener() {
public void onPreNodeMoved(final NodeModel oldParent, final int oldIndex, final NodeModel newParent,
final NodeModel child, final int newIndex) {
}
public void onPreNodeDelete(final NodeModel oldParent, final NodeModel selectedNode, final int index) {
}
public void onNodeMoved(final NodeModel oldParent, final int oldIndex, final NodeModel newParent,
final NodeModel child, final int newIndex) {
}
public void onNodeInserted(final NodeModel parent, final NodeModel child, final int newIndex) {
}
public void onNodeDeleted(final NodeModel parent, final NodeModel child, final int index) {
}
public void mapChanged(final MapChangeEvent event) {
if (event.getProperty().equals(MapStyle.MAP_STYLES)) {
removeStyleMenu(menuBuilder, "main_menu_styles");
addStyleMenu(menuBuilder, "main_menu_styles", event.getMap());
removeStyleMenu(menuBuilder, "node_popup_styles");
addStyleMenu(menuBuilder, "node_popup_styles", event.getMap());
}
}
});
mapController.addNodeSelectionListener(new INodeSelectionListener() {
public void onSelect(final NodeModel node) {
selectActions();
}
public void onDeselect(final NodeModel node) {