当前位置: 首页>>代码示例>>Java>>正文


Java TimedDeadzone类代码示例

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


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

示例1: ContentTabLabel

import com.intellij.util.ui.TimedDeadzone; //导入依赖的package包/类
public ContentTabLabel(final Content content, TabContentLayout layout) {
  super(layout.myUi, true);
  myLayout = layout;
  myContent = content;
  update();

  myBehavior = new BaseButtonBehavior(this) {
    protected void execute(final MouseEvent e) {
      final ContentManager mgr = contentManager();
      if (mgr.getIndexOfContent(myContent) >= 0) {
        mgr.setSelectedContent(myContent, true);
      }
    }
  };
  myBehavior.setActionTrigger(MouseEvent.MOUSE_PRESSED);
  myBehavior.setMouseDeadzone(TimedDeadzone.NULL);
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:18,代码来源:ContentTabLabel.java

示例2: ToolbarAlikeButton

import com.intellij.util.ui.TimedDeadzone; //导入依赖的package包/类
private ToolbarAlikeButton(@NotNull final Icon icon) {
  myIcon = icon;

  myBehavior = new BaseButtonBehavior(this, TimedDeadzone.NULL) {
    @Override
    protected void execute(MouseEvent e) {
      onClick(e);
    }
  };

  setOpaque(false);
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:13,代码来源:ConfigurationErrorsComponent.java

示例3: setTabLabelActionsMouseDeadzone

import com.intellij.util.ui.TimedDeadzone; //导入依赖的package包/类
@Override
@NotNull
public JBTabsPresentation setTabLabelActionsMouseDeadzone(final TimedDeadzone.Length length) {
  myTabActionsMouseDeadzone = length;
  final List<TabInfo> all = getTabs();
  for (TabInfo each : all) {
    final TabLabel eachLabel = myInfo2Label.get(each);
    eachLabel.updateTabActions();
  }
  return this;
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:12,代码来源:JBTabsImpl.java

示例4: ActionButton

import com.intellij.util.ui.TimedDeadzone; //导入依赖的package包/类
public ActionButton(JBTabsImpl tabs, TabInfo tabInfo, AnAction action, String place, Pass<MouseEvent> pass, TimedDeadzone.Length deadzone) {
  super(null, action.getTemplatePresentation().getIcon());
  myTabs = tabs;
  myTabInfo = tabInfo;
  myAction = action;
  myPlace = place;

  myButton = new InplaceButton(this, this, pass, deadzone) {
    @Override
    protected void doRepaintComponent(Component c) {
      repaintComponent(c);
    }
  };
  myButton.setVisible(false);
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:16,代码来源:ActionButton.java

示例5: ToolbarAlikeButton

import com.intellij.util.ui.TimedDeadzone; //导入依赖的package包/类
private ToolbarAlikeButton(@NotNull Icon icon) {
  myIcon = icon;

  myBehavior = new BaseButtonBehavior(this, TimedDeadzone.NULL) {
    @Override
    protected void execute(MouseEvent e) {
      onClick(e);
    }
  };

  setOpaque(false);
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:13,代码来源:ConfigurationErrorsPanel.java

示例6: ToolWindowsWidget

import com.intellij.util.ui.TimedDeadzone; //导入依赖的package包/类
private ToolWindowsWidget() {
  new BaseButtonBehavior(this, TimedDeadzone.NULL) {
    @Override
    protected void execute(MouseEvent e) {
      performAction();
    }
  }.setActionTrigger(MouseEvent.MOUSE_PRESSED);

  UISettings.getInstance().addUISettingsListener(this, this);
  KeyboardFocusManager.getCurrentKeyboardFocusManager().addPropertyChangeListener("focusOwner", this);
}
 
开发者ID:lshain-android-source,项目名称:tools-idea,代码行数:12,代码来源:IdeStatusBarImpl.java

示例7: setTabLabelActionsMouseDeadzone

import com.intellij.util.ui.TimedDeadzone; //导入依赖的package包/类
@Override
@Nonnull
public JBTabsPresentation setTabLabelActionsMouseDeadzone(final TimedDeadzone.Length length) {
  myTabActionsMouseDeadzone = length;
  final List<TabInfo> all = getTabs();
  for (TabInfo each : all) {
    final TabLabel eachLabel = myInfo2Label.get(each);
    eachLabel.updateTabActions();
  }
  return this;
}
 
开发者ID:consulo,项目名称:consulo,代码行数:12,代码来源:JBTabsImpl.java

示例8: ToolWindowsWidget

import com.intellij.util.ui.TimedDeadzone; //导入依赖的package包/类
ToolWindowsWidget(@Nonnull Disposable parent) {
  new BaseButtonBehavior(this, TimedDeadzone.NULL) {
    @Override
    protected void execute(MouseEvent e) {
      performAction();
    }
  }.setActionTrigger(MouseEvent.MOUSE_PRESSED);

  IdeEventQueue.getInstance().addDispatcher(e -> {
    if (e instanceof MouseEvent) {
      MouseEvent mouseEvent = (MouseEvent)e;
      if (mouseEvent.getComponent() == null || !SwingUtilities.isDescendingFrom(mouseEvent.getComponent(), SwingUtilities.getWindowAncestor(this))) {
        return false;
      }

      if (e.getID() == MouseEvent.MOUSE_MOVED && isShowing()) {
        Point p = mouseEvent.getLocationOnScreen();
        Point screen = this.getLocationOnScreen();
        if (new Rectangle(screen.x - 4, screen.y - 2, getWidth() + 4, getHeight() + 4).contains(p)) {
          mouseEntered();
          wasExited = false;
        }
        else {
          if (!wasExited) {
            wasExited = mouseExited(p);
          }
        }
      }
      else if (e.getID() == MouseEvent.MOUSE_EXITED) {
        //mouse exits WND
        mouseExited(mouseEvent.getLocationOnScreen());
      }
    }
    return false;
  }, parent);

  ApplicationManager.getApplication().getMessageBus().connect(this).subscribe(UISettingsListener.TOPIC, this);
  KeyboardFocusManager.getCurrentKeyboardFocusManager().addPropertyChangeListener("focusOwner", this);
  myAlarm = new Alarm(parent);
}
 
开发者ID:consulo,项目名称:consulo,代码行数:41,代码来源:ToolWindowsWidget.java

示例9: ToolbarAlikeButton

import com.intellij.util.ui.TimedDeadzone; //导入依赖的package包/类
ToolbarAlikeButton(@Nonnull final Icon icon) {
  myIcon = icon;

  myBehavior = new BaseButtonBehavior(this, TimedDeadzone.NULL) {
    @Override
    protected void execute(MouseEvent e) {
      onClick(e);
    }
  };

  setOpaque(false);
}
 
开发者ID:consulo,项目名称:consulo,代码行数:13,代码来源:ConfigurationErrorsComponent.java

示例10: InplaceButton

import com.intellij.util.ui.TimedDeadzone; //导入依赖的package包/类
public InplaceButton(IconButton source, final ActionListener listener, final Pass<MouseEvent> me) {
  this(source, listener, me, TimedDeadzone.DEFAULT);
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:4,代码来源:InplaceButton.java

示例11: setMouseDeadzone

import com.intellij.util.ui.TimedDeadzone; //导入依赖的package包/类
public void setMouseDeadzone(final TimedDeadzone.Length deadZone) {
  myBehavior.setMouseDeadzone(deadZone);
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:4,代码来源:InplaceButton.java

示例12: setTabLabelActionsMouseDeadzone

import com.intellij.util.ui.TimedDeadzone; //导入依赖的package包/类
@NotNull
JBTabsPresentation setTabLabelActionsMouseDeadzone(TimedDeadzone.Length length);
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:3,代码来源:JBTabsPresentation.java

示例13: getTabActionsMouseDeadzone

import com.intellij.util.ui.TimedDeadzone; //导入依赖的package包/类
public TimedDeadzone.Length getTabActionsMouseDeadzone() {
  return myTabActionsMouseDeadzone;
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:4,代码来源:JBTabsImpl.java

示例14: setMouseDeadZone

import com.intellij.util.ui.TimedDeadzone; //导入依赖的package包/类
public void setMouseDeadZone(TimedDeadzone.Length deadZone) {
  myButton.setMouseDeadzone(deadZone);
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:4,代码来源:ActionButton.java

示例15: setMouseDeadZone

import com.intellij.util.ui.TimedDeadzone; //导入依赖的package包/类
public void setMouseDeadZone(TimedDeadzone.Length deadZone) {
  myButton.setMouseDeadzone(deadZone);    
}
 
开发者ID:lshain-android-source,项目名称:tools-idea,代码行数:4,代码来源:ActionButton.java


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