use of org.freeplane.features.map.IMapSelection in project freeplane by freeplane.
the class MapViewController method afterViewChange.
public void afterViewChange(final Component oldMap, final Component pNewMap) {
Controller controller = Controller.getCurrentController();
final ModeController oldModeController = controller.getModeController();
ModeController newModeController = oldModeController;
if (pNewMap != null) {
final IMapSelection mapSelection = getMapSelection();
final NodeModel selected = mapSelection.getSelected();
mapSelection.scrollNodeToVisible(selected);
setZoomComboBox(getZoom());
obtainFocusForSelected();
newModeController = getModeController(pNewMap);
if (newModeController != oldModeController) {
controller.selectMode(newModeController);
}
}
setTitle();
controller.getViewController().viewNumberChanged(getViewNumber());
newModeController.getUserInputListenerFactory().updateMapList();
if (pNewMap != null) {
newModeController.setVisible(true);
}
}
use of org.freeplane.features.map.IMapSelection in project freeplane by freeplane.
the class ShowNotesInMapAction method actionPerformed.
public void actionPerformed(ActionEvent e) {
final MapModel map = Controller.getCurrentController().getMap();
final MNoteController noteController = (MNoteController) NoteController.getController();
noteController.setShowNotesInMap(map, !NoteController.getController().showNotesInMap(map));
final IMapSelection selection = Controller.getCurrentController().getSelection();
selection.keepNodePosition(selection.getSelected(), 0.0f, 0.0f);
setSelected();
}
Aggregations