本文整理汇总了Java中com.intellij.xdebugger.impl.ui.tree.nodes.EvaluatingExpressionRootNode类的典型用法代码示例。如果您正苦于以下问题:Java EvaluatingExpressionRootNode类的具体用法?Java EvaluatingExpressionRootNode怎么用?Java EvaluatingExpressionRootNode使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
EvaluatingExpressionRootNode类属于com.intellij.xdebugger.impl.ui.tree.nodes包,在下文中一共展示了EvaluatingExpressionRootNode类的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: evaluate
import com.intellij.xdebugger.impl.ui.tree.nodes.EvaluatingExpressionRootNode; //导入依赖的package包/类
private void evaluate() {
final XDebuggerEditorBase inputEditor = getInputEditor();
int offset = -1;
//try to save caret position
Editor editor = inputEditor.getEditor();
if (editor != null) {
offset = editor.getCaretModel().getOffset();
}
final XDebuggerTree tree = myTreePanel.getTree();
tree.markNodesObsolete();
tree.setRoot(new EvaluatingExpressionRootNode(this, tree), false);
myResultPanel.invalidate();
//editor is already changed
editor = inputEditor.getEditor();
//selectAll puts focus back
inputEditor.selectAll();
//try to restore caret position and clear selection
if (offset >= 0 && editor != null) {
offset = Math.min(editor.getDocument().getTextLength(), offset);
editor.getCaretModel().moveToOffset(offset);
editor.getSelectionModel().setSelection(offset, offset);
}
}
示例2: evaluate
import com.intellij.xdebugger.impl.ui.tree.nodes.EvaluatingExpressionRootNode; //导入依赖的package包/类
private void evaluate() {
final XDebuggerTree tree = myTreePanel.getTree();
final EvaluatingExpressionRootNode root = new EvaluatingExpressionRootNode(this, tree);
tree.setRoot(root, false);
myResultPanel.invalidate();
myInputComponent.getInputEditor().selectAll();
}