Package org.freeplane.features.map.mindmapmode

Examples of org.freeplane.features.map.mindmapmode.MMapController.newNode()


    final NodeModel node;
    if (mode.equals(PasteMode.INSIDE)) {
      node = targetNode;
    }
    else {
      node = mapController.newNode(file.getName(), targetNode.getMap());
      mapController.insertNode(node, targetNode, mode.equals(PasteMode.AS_SIBLING), isLeft, isLeft);
    }
    final ExternalResource preview = new ExternalResource(uri);
    undoableDeactivateHook(node);
    undoableActivateHook(node, preview);
View Full Code Here


            return;
          if(! FileUtils.getExtension(file.getName()).equals(IMAGE_FORMAT))
            file = new File(file.getPath() + '.' + IMAGE_FORMAT);
          final URI uri = LinkController.toLinkTypeDependantURI(mindmapFile, file);
              ImageIO.write(image, IMAGE_FORMAT, file);
        final NodeModel node = mapController.newNode(file.getName(), target.getMap());
        final ExternalResource extension = new ExternalResource(uri);
        node.addExtension(extension);
        mapController.insertNode(node, target, asSibling, isLeft, isLeft);
            }
            catch (IOException e) {
View Full Code Here

         
        }
        catch (Exception e) {
        }
      }
      final NodeModel node = mapController.newNode(text, map);
      if(uri != null){
        NodeLinks.createLinkExtension(node).setHyperLink(uri);
      }
      for (int j = parentNodes.size() - 1; j >= 0; --j) {
        if (textFragment.depth > ((Integer) parentNodesDepths.get(j)).intValue()) {
View Full Code Here

      for (final File file : fileList) {
        if(pasteImages  && viewerController.paste(file, target, PasteMode.valueOf(asSibling), isLeft)){
          continue;
        }
        final MMapController mapController = (MMapController) Controller.getCurrentModeController().getMapController();
        final NodeModel node = mapController.newNode(file.getName(), target.getMap());
        ((MLinkController) LinkController.getController()).setLinkTypeDependantLink(node, file);
        mapController.insertNode(node, target, asSibling, isLeft, isLeft);
      }
    }
  }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.