• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

Java MultiViewElementCallback类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了Java中org.netbeans.core.spi.multiview.MultiViewElementCallback的典型用法代码示例。如果您正苦于以下问题:Java MultiViewElementCallback类的具体用法?Java MultiViewElementCallback怎么用?Java MultiViewElementCallback使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



MultiViewElementCallback类属于org.netbeans.core.spi.multiview包,在下文中一共展示了MultiViewElementCallback类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。

示例1: MultiViewModel

import org.netbeans.core.spi.multiview.MultiViewElementCallback; //导入依赖的package包/类
/**
     * constructor used at deserialization...
     */
    MultiViewModel(MultiViewDescription[] descs, MultiViewDescription defaultDescr, 
                   MultiViewModel.ActionRequestObserverFactory factory, Map<MultiViewDescription, MultiViewElement> existingElements) {
        observerFactory = factory;
        nestedElements = new HashMap<MultiViewDescription, MultiViewElement>();
//        nestedPerspectiveComponents = new HashMap();
        nestedPerspectives = new HashMap<MultiViewDescription,MultiViewPerspective>();
        nestedCallbacks = new HashMap<MultiViewElement, MultiViewElementCallback>();
        shownElements = new HashSet<MultiViewElement>(descs.length + 3);
        descriptions = descs;
        for (int i = 0; i < descriptions.length; i++) {
            MultiViewElement element = existingElements.get(descriptions[i]);
            nestedElements.put(descriptions[i], element);
            nestedPerspectives.put(descriptions[i], Accessor.DEFAULT.createPerspective(descriptions[i]));
            if (element != null) {
                // set the observer..
                MultiViewElementCallback call = factory.createElementCallback(descriptions[i]);
                nestedCallbacks.put(element, call);
                element.setMultiViewCallback(call);
//                nestedPerspectiveComponents.put(descriptions[i], Accessor.DEFAULT.createPersComponent(element));
            }
        }
        currentEditor = (defaultDescr == null || !nestedElements.containsKey(defaultDescr) ? descriptions[0] : defaultDescr);
        group = new BtnGroup();
	groupSplit = new BtnGroup();
    }
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:29,代码来源:MultiViewModel.java


示例2: setMultiViewCallback

import org.netbeans.core.spi.multiview.MultiViewElementCallback; //导入依赖的package包/类
@Override
public void setMultiViewCallback(MultiViewElementCallback callback) {
    multiViewObserver = callback;
    
    // needed for deserialization...
    if (dataObject instanceof FormDataObject) {
        // this is used (or misused?) to obtain the deserialized
        // multiview topcomponent and set it to FormEditorSupport
        FormDataObject formDataObject = (FormDataObject) dataObject;
        FormEditorSupport fes = (FormEditorSupport)formDataObject.getFormEditorSupport();
        if (javaEditor == null) {
            javaEditor = fes;
        }
        fes.setTopComponent(callback.getTopComponent());
    }
    super.setMultiViewCallback(callback);
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:18,代码来源:FormEditorSupport.java


示例3: setMultiViewCallback

import org.netbeans.core.spi.multiview.MultiViewElementCallback; //导入依赖的package包/类
@Override
public void setMultiViewCallback(MultiViewElementCallback callback) {
    multiViewObserver = callback;

    // add FormDesigner as a client property so it can be obtained
    // from multiview TopComponent (it is not sufficient to put
    // it into lookup - only content of the lookup of the active
    // element is accessible)
    callback.getTopComponent().putClientProperty("formDesigner", this); // NOI18N

    // needed for deserialization...
    if (formEditorSupport != null) {
        // this is used (or misused?) to obtain the deserialized multiview
        // topcomponent and set it to FormEditorSupport
        formEditorSupport.setTopComponent(callback.getTopComponent());
    }
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:18,代码来源:FormDesignerTC.java


示例4: run

import org.netbeans.core.spi.multiview.MultiViewElementCallback; //导入依赖的package包/类
public void run() {
    MultiViewElementCallback c = callback;
    if (c == null) {
        return;
    }
    TopComponent tc = c.getTopComponent();
    if (tc == null) {
        return;
    }
    
    super.updateName();
    Node nd = ((JrxmlDataObject)((JrxmlEditorSupport)cloneableEditorSupport()).getDataObject()).getNodeDelegate();
    tc.setName(nd.getName() );
    tc.setDisplayName(nd.getDisplayName());
    tc.setHtmlDisplayName(nd.getHtmlDisplayName());
    //tc.setIcon( nd.getIcon( BeanInfo.ICON_COLOR_16x16));
}
 
开发者ID:JockiHendry,项目名称:ireport-fork,代码行数:18,代码来源:JrxmlSourceEditor.java


示例5: updateName

import org.netbeans.core.spi.multiview.MultiViewElementCallback; //导入依赖的package包/类
public void updateName() {

        Runnable run = new Runnable() {
            public void run() {
                MultiViewElementCallback c = callback;

                if (c == null) {
                    return;
                }
                TopComponent tc = c.getTopComponent();
                if (tc == null) {
                    return;
                }
                Node nd = ((JRTXDataObject)support.getDataObject()).getNodeDelegate();
                tc.setName(nd.getName() );
                tc.setDisplayName(nd.getDisplayName());
                tc.setHtmlDisplayName(nd.getHtmlDisplayName());
                tc.setToolTipText( nd.getShortDescription() );
            }
        };

        if (SwingUtilities.isEventDispatchThread ())
            run.run();
        else
            SwingUtilities.invokeLater (run);
    }
 
开发者ID:JockiHendry,项目名称:ireport-fork,代码行数:27,代码来源:JRTXVisualView.java


示例6: run

import org.netbeans.core.spi.multiview.MultiViewElementCallback; //导入依赖的package包/类
public void run() {
    MultiViewElementCallback c = callback;
    if (c == null) {
        return;
    }
    TopComponent tc = c.getTopComponent();
    if (tc == null) {
        return;
    }
    
    super.updateName();
    Node nd = ((JRTXDataObject)((JRTXEditorSupport)cloneableEditorSupport()).getDataObject()).getNodeDelegate();
    tc.setName(nd.getName() );
    tc.setDisplayName(nd.getDisplayName());
    tc.setHtmlDisplayName(nd.getHtmlDisplayName());
    //tc.setIcon( nd.getIcon( BeanInfo.ICON_COLOR_16x16));
}
 
开发者ID:JockiHendry,项目名称:ireport-fork,代码行数:18,代码来源:JRTXSourceEditor.java


示例7: updateName

import org.netbeans.core.spi.multiview.MultiViewElementCallback; //导入依赖的package包/类
public void updateName() {
    
    Runnable run = new Runnable() {
        public void run() {
            MultiViewElementCallback c = callback;
            
            if (c == null) {
                return;
            }
            TopComponent tc = c.getTopComponent();
            if (tc == null) {
                return;
            }
            Node nd = ((JrxmlDataObject)support.getDataObject()).getNodeDelegate();
            tc.setName(nd.getName() );
            tc.setDisplayName(nd.getDisplayName());
            tc.setHtmlDisplayName(nd.getHtmlDisplayName());
            tc.setToolTipText( nd.getShortDescription() );
        }
    };
    
    if (SwingUtilities.isEventDispatchThread ())
        run.run();
    else
        SwingUtilities.invokeLater (run);
}
 
开发者ID:JockiHendry,项目名称:ireport-fork,代码行数:27,代码来源:JrxmlVisualView.java


示例8: run

import org.netbeans.core.spi.multiview.MultiViewElementCallback; //导入依赖的package包/类
public void run() {
    MultiViewElementCallback c = callback;
    if (c == null) {
        return;
    }
    TopComponent tc = c.getTopComponent();
    if (tc == null) {
        return;
    }
    
    super.updateName();
    Node nd = ((JRCTXDataObject)((JRCTXEditorSupport)cloneableEditorSupport()).getDataObject()).getNodeDelegate();
    tc.setName(nd.getName() );
    tc.setDisplayName(nd.getDisplayName());
    tc.setHtmlDisplayName(nd.getHtmlDisplayName());
    //tc.setIcon( nd.getIcon( BeanInfo.ICON_COLOR_16x16));
}
 
开发者ID:JockiHendry,项目名称:ireport-fork,代码行数:18,代码来源:JRCTXSourceEditor.java


示例9: updateName

import org.netbeans.core.spi.multiview.MultiViewElementCallback; //导入依赖的package包/类
public void updateName() {

        Runnable run = new Runnable() {
            public void run() {
                MultiViewElementCallback c = callback;

                if (c == null) {
                    return;
                }
                TopComponent tc = c.getTopComponent();
                if (tc == null) {
                    return;
                }
                Node nd = ((JRCTXDataObject)support.getDataObject()).getNodeDelegate();
                tc.setName(nd.getName() );
                tc.setDisplayName(nd.getDisplayName());
                tc.setHtmlDisplayName(nd.getHtmlDisplayName());
                tc.setToolTipText( nd.getShortDescription() );
            }
        };

        if (SwingUtilities.isEventDispatchThread ())
            run.run();
        else
            SwingUtilities.invokeLater (run);
    }
 
开发者ID:JockiHendry,项目名称:ireport-fork,代码行数:27,代码来源:JRCTXVisualView.java


示例10: getElementForDescription

import org.netbeans.core.spi.multiview.MultiViewElementCallback; //导入依赖的package包/类
/**
    * used primarily at deserialization time.
    */
    synchronized MultiViewElement getElementForDescription(MultiViewDescription description, boolean create) {
       MultiViewElement element = nestedElements.get(description);
       if (element == null && create) {
           element = description.createElement();
           MultiViewElementCallback call = observerFactory.createElementCallback(description);
           nestedCallbacks.put(element, call);
           element.setMultiViewCallback(call);
           nestedElements.put(description, element);
//           nestedPerspectiveComponents.put(description, Accessor.DEFAULT.createPersComponent(element));
       }
       return element;
   }
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:16,代码来源:MultiViewModel.java


示例11: ensureVisible

import org.netbeans.core.spi.multiview.MultiViewElementCallback; //导入依赖的package包/类
/**
 * callback for the Pane implementation to adjust itself to the openAt() request.
 */
public void ensureVisible() {
    MultiViewElement paneEl = findPaneElement();
    if (paneEl != null) {
        open();
        MultiViewElementCallback call = peer.getModel().getCallbackForElement(paneEl);
        call.requestVisible();
    }
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:12,代码来源:MultiViewCloneableTopComponent.java


示例12: setMultiViewCallback

import org.netbeans.core.spi.multiview.MultiViewElementCallback; //导入依赖的package包/类
public void setMultiViewCallback(MultiViewElementCallback callback) {
    this.callback = callback;
    if (dObj!=null) {
        XmlMultiViewEditorSupport support = dObj.getEditorSupport();
        if (support!=null) {
            support.setMVTC(callback.getTopComponent());
            support.updateDisplayName();
        }
    }
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:11,代码来源:AbstractMultiViewElement.java


示例13: setMultiViewCallback

import org.netbeans.core.spi.multiview.MultiViewElementCallback; //导入依赖的package包/类
@Override
public void setMultiViewCallback(MultiViewElementCallback callback) {
    this.callback = callback;
    // Needed as Title and Tooltip could be calculated from currently set
    // jdbc connection - which changes after deserialization (none is set)
    updateName();
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:8,代码来源:SQLCloneableEditor.java


示例14: copyNameToCallbackTopComponent

import org.netbeans.core.spi.multiview.MultiViewElementCallback; //导入依赖的package包/类
private void copyNameToCallbackTopComponent() {
  final MultiViewElementCallback c = this.callback;
  if (c != null) {
    final TopComponent tc = c.getTopComponent();
    if (tc != null) {
      tc.setHtmlDisplayName(this.getHtmlDisplayName());
      tc.setDisplayName(this.getDisplayName());
      tc.setName(this.getName());
      tc.setToolTipText(this.getToolTipText());
    }
  }
  if (this.editorSupport != null) {
    this.editorSupport.updateTitles();
  }
}
 
开发者ID:raydac,项目名称:netbeans-mmd-plugin,代码行数:16,代码来源:MMDGraphEditor.java


示例15: updateName

import org.netbeans.core.spi.multiview.MultiViewElementCallback; //导入依赖的package包/类
public void updateName() {
   // Mutex.EVENT.readAccess(this);
   //IOUtils.runInAWTNoBlocking(
    
    Runnable run = new Runnable() {
        public void run() {
            MultiViewElementCallback c = callback;
            
            if (c == null) {
                return;
            }
            TopComponent tc = c.getTopComponent();
            if (tc == null) {
                return;
            }
            Node nd = ((JrxmlDataObject)((JrxmlEditorSupport)cloneableEditorSupport()).getDataObject()).getNodeDelegate();
            tc.setName(nd.getName() );
            tc.setDisplayName(nd.getDisplayName());
            tc.setHtmlDisplayName(nd.getHtmlDisplayName());
            tc.setIcon( nd.getIcon( BeanInfo.ICON_COLOR_16x16));
        }
    };
    
    if (SwingUtilities.isEventDispatchThread ())
        run.run();
    else
        SwingUtilities.invokeLater (run);
}
 
开发者ID:JockiHendry,项目名称:ireport-fork,代码行数:29,代码来源:JrxmlSourceEditor.java


示例16: updateName

import org.netbeans.core.spi.multiview.MultiViewElementCallback; //导入依赖的package包/类
public void updateName() {
   // Mutex.EVENT.readAccess(this);
   //IOUtils.runInAWTNoBlocking(
    
    Runnable run = new Runnable() {
        public void run() {
            MultiViewElementCallback c = callback;
            
            if (c == null) {
                return;
            }
            TopComponent tc = c.getTopComponent();
            if (tc == null) {
                return;
            }
            Node nd = ((JRTXDataObject)((JRTXEditorSupport)cloneableEditorSupport()).getDataObject()).getNodeDelegate();
            tc.setName(nd.getName() );
            tc.setDisplayName(nd.getDisplayName());
            tc.setHtmlDisplayName(nd.getHtmlDisplayName());
            tc.setIcon( nd.getIcon( BeanInfo.ICON_COLOR_16x16));
        }
    };
    
    if (SwingUtilities.isEventDispatchThread ())
        run.run();
    else
        SwingUtilities.invokeLater (run);
}
 
开发者ID:JockiHendry,项目名称:ireport-fork,代码行数:29,代码来源:JRTXSourceEditor.java


示例17: updateName

import org.netbeans.core.spi.multiview.MultiViewElementCallback; //导入依赖的package包/类
public void updateName() {
   // Mutex.EVENT.readAccess(this);
   //IOUtils.runInAWTNoBlocking(
    
    Runnable run = new Runnable() {
        public void run() {
            MultiViewElementCallback c = callback;
            
            if (c == null) {
                return;
            }
            TopComponent tc = c.getTopComponent();
            if (tc == null) {
                return;
            }
            Node nd = ((JRCTXDataObject)((JRCTXEditorSupport)cloneableEditorSupport()).getDataObject()).getNodeDelegate();
            tc.setName(nd.getName() );
            tc.setDisplayName(nd.getDisplayName());
            tc.setHtmlDisplayName(nd.getHtmlDisplayName());
            tc.setIcon( nd.getIcon( BeanInfo.ICON_COLOR_16x16));
        }
    };
    
    if (SwingUtilities.isEventDispatchThread ())
        run.run();
    else
        SwingUtilities.invokeLater (run);
}
 
开发者ID:JockiHendry,项目名称:ireport-fork,代码行数:29,代码来源:JRCTXSourceEditor.java


示例18: setMultiViewCallback

import org.netbeans.core.spi.multiview.MultiViewElementCallback; //导入依赖的package包/类
@Override
public void setMultiViewCallback(MultiViewElementCallback callback) {
    this.callback = callback;
    if(context != null) {
        DataObject obj = context.lookup(DataObject.class);
        callback.getTopComponent().setDisplayName(obj.getName());
    }
}
 
开发者ID:Depter,项目名称:JRLib,代码行数:9,代码来源:LinkRatioExpandableMultiview.java


示例19: setMultiViewCallback

import org.netbeans.core.spi.multiview.MultiViewElementCallback; //导入依赖的package包/类
@Override
public void setMultiViewCallback(MultiViewElementCallback callback) {
    this.callBack = callback;
    TopComponent tc = callback.getTopComponent();
    tc.setDisplayName(ds.getName());
    tc.setToolTipText(ds.getPath());
}
 
开发者ID:Depter,项目名称:JRLib,代码行数:8,代码来源:DataSourceTableMultiviewElement.java


示例20: setMultiViewCallback

import org.netbeans.core.spi.multiview.MultiViewElementCallback; //导入依赖的package包/类
@Override
public void setMultiViewCallback(MultiViewElementCallback callback) {
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:4,代码来源:BasicArtifactPanel.java



注:本文中的org.netbeans.core.spi.multiview.MultiViewElementCallback类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
Java Guardian类代码示例发布时间:2022-05-21
下一篇:
Java Version类代码示例发布时间:2022-05-21
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap