javax.swing.JTable.getCursor()方法的使用及代码示例

x33g5p2x  于2022-01-21 转载在 其他  
字(5.1k)|赞(0)|评价(0)|浏览(140)

本文整理了Java中javax.swing.JTable.getCursor()方法的一些代码示例,展示了JTable.getCursor()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。JTable.getCursor()方法的具体详情如下:
包路径:javax.swing.JTable
类名称:JTable
方法名:getCursor

JTable.getCursor介绍

暂无

代码示例

代码示例来源:origin: org.fudaa.framework.ctulu/ctulu-common

private void swapCursor() {
 final Cursor tmp = table_.getCursor();
 table_.setCursor(otherCursor_);
 otherCursor_ = tmp;
}

代码示例来源:origin: org.fudaa.framework.ctulu/ctulu-common

private void swapCursor(){
  final Cursor tmp = table_.getCursor();
  table_.setCursor(otherCursor_);
  otherCursor_ = tmp;
}

代码示例来源:origin: UNIVALI-LITE/Portugol-Studio

@Override
  public void mouseMoved(MouseEvent e)
  {
    if (tabelaMensagens.rowAtPoint(e.getPoint()) >= 0)
    {
      if (tabelaMensagens.getCursor() != cursorItem)
      {
        cursorTabela = tabelaMensagens.getCursor();
        tabelaMensagens.setCursor(cursorItem);
      }
    }
    else if (tabelaMensagens.getCursor() != cursorTabela)
    {
      tabelaMensagens.setCursor(cursorTabela);
    }
  }
});

代码示例来源:origin: org.fudaa.framework.ctulu/ctulu-common

public void mouseMoved(final MouseEvent _e) {
 if ((getResizingRow(_e.getPoint()) >= 0) != (table_.getCursor() == RESIZE_CURSOR)) {
  swapCursor();
 }
}

代码示例来源:origin: tinyMediaManager/tinyMediaManager

@Override
public void mouseMoved(MouseEvent e) {
 JTable table = (JTable) e.getSource();
 int col = table.columnAtPoint(new Point(e.getX(), e.getY()));
 if (col != 0 && table.getCursor().getType() == Cursor.HAND_CURSOR) {
  table.setCursor(new Cursor(Cursor.DEFAULT_CURSOR));
 }
 if (col == 0 && table.getCursor().getType() == Cursor.DEFAULT_CURSOR) {
  table.setCursor(new Cursor(Cursor.HAND_CURSOR));
 }
}

代码示例来源:origin: tinyMediaManager/tinyMediaManager

@Override
public void mouseMoved(MouseEvent e) {
 JTable table = (JTable) e.getSource();
 int col = table.columnAtPoint(new Point(e.getX(), e.getY()));
 if (col != 0 && table.getCursor().getType() == Cursor.HAND_CURSOR) {
  table.setCursor(new Cursor(Cursor.DEFAULT_CURSOR));
 }
 if (col == 0 && table.getCursor().getType() == Cursor.DEFAULT_CURSOR) {
  table.setCursor(new Cursor(Cursor.HAND_CURSOR));
 }
}

代码示例来源:origin: GoogleCloudPlatform/google-cloud-intellij

@Override
 public void mouseMoved(MouseEvent event) {
  JTable table = (JTable) event.getSource();
  Point point = event.getPoint();
  int column = table.columnAtPoint(point);
  Breakpoint breakpoint = getBreakPoint(point);
  if (column == 4 && breakpoint != null && supportsMoreConfig(breakpoint)) {
   if (table.getCursor() != HAND_CURSOR) {
    table.setCursor(HAND_CURSOR);
   }
   return;
  }
  if (table.getCursor() != DEFAULT_CURSOR) {
   table.setCursor(DEFAULT_CURSOR);
  }
 }
}

代码示例来源:origin: org.fudaa.framework.ctulu/ctulu-common

public void mouseMoved(final MouseEvent _e){
  if(canResize(getResizingColumn(_e.getPoint()))
    != (table_.getCursor() == resizeCursor)){
    swapCursor();
  }
}

代码示例来源:origin: tinyMediaManager/tinyMediaManager

@Override
public void mouseMoved(MouseEvent e) {
 JTable table = (JTable) e.getSource();
 int col = table.columnAtPoint(new Point(e.getX(), e.getY()));
 if (col != 0 && table.getCursor().getType() == Cursor.HAND_CURSOR) {
  table.setCursor(new Cursor(Cursor.DEFAULT_CURSOR));
 }
 if (col == 0 && table.getCursor().getType() == Cursor.DEFAULT_CURSOR) {
  table.setCursor(new Cursor(Cursor.HAND_CURSOR));
 }
}

代码示例来源:origin: tinyMediaManager/tinyMediaManager

@Override
public void mouseMoved(MouseEvent e) {
 JTable table = (JTable) e.getSource();
 int col = table.columnAtPoint(new Point(e.getX(), e.getY()));
 if (col != 0 && col != 1 && table.getCursor().getType() == Cursor.HAND_CURSOR) {
  table.setCursor(new Cursor(Cursor.DEFAULT_CURSOR));
 }
 if ((col == 0 || col == 1) && table.getCursor().getType() == Cursor.DEFAULT_CURSOR) {
  table.setCursor(new Cursor(Cursor.HAND_CURSOR));
 }
}

代码示例来源:origin: org.bidib.jbidib.swinglabs.swingx/swingx-core

private void setRolloverCursor(Point location) {
  if (hasRollover(location)) {
    if (oldCursor == null) {
      oldCursor = component.getCursor();
      component.setCursor(Cursor
          .getPredefinedCursor(Cursor.HAND_CURSOR));
    }
  } else {
    if (oldCursor != null) {
      component.setCursor(oldCursor);
      oldCursor = null;
    }
  }
}

代码示例来源:origin: org.swinglabs.swingx/swingx-all

private void setRolloverCursor(Point location) {
  if (hasRollover(location)) {
    if (oldCursor == null) {
      oldCursor = component.getCursor();
      component.setCursor(Cursor
          .getPredefinedCursor(Cursor.HAND_CURSOR));
    }
  } else {
    if (oldCursor != null) {
      component.setCursor(oldCursor);
      oldCursor = null;
    }
  }
}

代码示例来源:origin: org.swinglabs.swingx/swingx-core

private void setRolloverCursor(Point location) {
  if (hasRollover(location)) {
    if (oldCursor == null) {
      oldCursor = component.getCursor();
      component.setCursor(Cursor
          .getPredefinedCursor(Cursor.HAND_CURSOR));
    }
  } else {
    if (oldCursor != null) {
      component.setCursor(oldCursor);
      oldCursor = null;
    }
  }
}

代码示例来源:origin: org.codehaus.jtstand/jtstand-desktop

private void setRolloverCursor(Point location) {
  if (hasRollover(location)) {
    if (oldCursor == null) {
      oldCursor = component.getCursor();
      component.setCursor(Cursor
          .getPredefinedCursor(Cursor.HAND_CURSOR));
    }
  } else {
    if (oldCursor != null) {
      component.setCursor(oldCursor);
      oldCursor = null;
    }
  }
}

代码示例来源:origin: com.haulmont.thirdparty/swingx-core

private void setRolloverCursor(Point location) {
  if (hasRollover(location)) {
    if (oldCursor == null) {
      oldCursor = component.getCursor();
      component.setCursor(Cursor
          .getPredefinedCursor(Cursor.HAND_CURSOR));
    }
  } else {
    if (oldCursor != null) {
      component.setCursor(oldCursor);
      oldCursor = null;
    }
  }
}

相关文章

JTable类方法