private boolean isTouchingToolbar(JComponent component) {
    var toolbar = getToolbar();
    if (toolbar == null || !toolbar.isVisible() || !component.isShowing()) {
      return false;
    }
    var toolbarBounds = SwingUtilities.convertRectangle(toolbar.getParent(), toolbar.getBounds(), this);
    var expectedCoordinate = (myVertical ? toolbarBounds.y + toolbarBounds.height : toolbarBounds.x + toolbarBounds.width) + GAP;
    var paneLocation = SwingUtilities.convertPoint(component.getParent(), component.getLocation(), this);
    var actualCoordinate = myVertical ? paneLocation.y : paneLocation.x;
    return expectedCoordinate == actualCoordinate;
  }
private boolean isTouchingToolbar(JComponent component)