當前位置: 首頁>>代碼示例>>Java>>正文


Java TypeBlockManager類代碼示例

本文整理匯總了Java中edu.mit.blocks.workspace.typeblocking.TypeBlockManager的典型用法代碼示例。如果您正苦於以下問題:Java TypeBlockManager類的具體用法?Java TypeBlockManager怎麽用?Java TypeBlockManager使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


TypeBlockManager類屬於edu.mit.blocks.workspace.typeblocking包,在下文中一共展示了TypeBlockManager類的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: Workspace

import edu.mit.blocks.workspace.typeblocking.TypeBlockManager; //導入依賴的package包/類
public Workspace() {
    super();
    setLayout(null);
    setBackground(Color.WHITE);
    setPreferredSize(new Dimension(800, 600));

    this.factory = new FactoryManager(this);
    this.addWorkspaceListener(this.factory);
    this.blockCanvas.getHorizontalModel().addChangeListener(this);
    for (final Explorer exp : factory.getNavigator().getExplorers()) {
        exp.addListener(this);
    }

    this.miniMap = new MiniMap(this);
    this.addWidget(this.miniMap, true, true);
    this.addComponentListener(new ComponentAdapter() {
        public void componentResized(ComponentEvent e) {
            miniMap.repositionMiniMap();
            blockCanvas.reformBlockCanvas();
            blockCanvasLayer.setSize(getSize());
            blockCanvasLayer.validate();
        }
    });

    blockCanvasLayer = new JSplitPane(JSplitPane.HORIZONTAL_SPLIT, true,
            factory.getJComponent(), blockCanvas.getJComponent());
    blockCanvasLayer.setOneTouchExpandable(true);
    blockCanvasLayer.setDividerSize(6);
    add(blockCanvasLayer, BLOCK_LAYER);
    validate();
    addPageAt(Page.getBlankPage(this), 0, false);

    this.workspaceWidgets.add(factory);

    this.focusManager = new FocusTraversalManager(this);

    this.typeBlockManager = new TypeBlockManager(this, blockCanvas);
}
 
開發者ID:heqichen,項目名稱:openblocks,代碼行數:39,代碼來源:Workspace.java

示例2: getTypeBlockManager

import edu.mit.blocks.workspace.typeblocking.TypeBlockManager; //導入依賴的package包/類
/**
 * The type block manager, if defined.
 * @return The manager.
 * @see #enableTypeBlocking(boolean)
 */
public TypeBlockManager getTypeBlockManager() {
    return typeBlockManager;
}
 
開發者ID:heqichen,項目名稱:openblocks,代碼行數:9,代碼來源:Workspace.java


注:本文中的edu.mit.blocks.workspace.typeblocking.TypeBlockManager類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。