org.eclipse.swt.widgets.TableColumn.isDisposed()方法的使用及代码示例

x33g5p2x  于2022-01-29 转载在 其他  
字(10.6k)|赞(0)|评价(0)|浏览(116)

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

TableColumn.isDisposed介绍

暂无

代码示例

代码示例来源:origin: org.codehaus.openxma/xmartclient

  1. public void run() {
  2. if(!column.isDisposed()) {
  3. // if it is executed inside the event method,
  4. // the horizontal scrollbar does not appear or disappear correctly
  5. columnResized(column);
  6. }
  7. }
  8. });

代码示例来源:origin: org.codehaus.openxma/xmartserver

  1. public void run() {
  2. if(!column.isDisposed()) {
  3. // if it is executed inside the event method,
  4. // the horizontal scrollbar does not appear or disappear correctly
  5. columnResized(column);
  6. }
  7. }
  8. });

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

  1. /**
  2. * Is this Column currently visible in the table?
  3. *
  4. * @return true if the Column is currently visible, false otherwise
  5. */
  6. @SuppressWarnings("SimplifiableIfStatement")
  7. public boolean isVisible() {
  8. if (swtColumn.isDisposed()) {
  9. return false;
  10. }
  11. return (swtColumn.getWidth() > 0);
  12. }

代码示例来源:origin: org.eclipse.scout.sdk.deps/org.eclipse.swt.win32.win32.x86

  1. @Override
  2. void updateImages () {
  3. if (sortColumn != null && !sortColumn.isDisposed ()) {
  4. if (OS.COMCTL32_MAJOR < 6) {
  5. switch (sortDirection) {
  6. case SWT.UP:
  7. case SWT.DOWN:
  8. sortColumn.setImage (display.getSortImage (sortDirection), true, true);
  9. break;
  10. }
  11. }
  12. }
  13. }

代码示例来源:origin: org.eclipse.scout.sdk.deps/org.eclipse.swt.win32.win32.x86

  1. /**
  2. * Sets the direction of the sort indicator for the receiver. The value
  3. * can be one of <code>UP</code>, <code>DOWN</code> or <code>NONE</code>.
  4. *
  5. * @param direction the direction of the sort indicator
  6. *
  7. * @exception SWTException <ul>
  8. * <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li>
  9. * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li>
  10. * </ul>
  11. *
  12. * @since 3.2
  13. */
  14. public void setSortDirection (int direction) {
  15. checkWidget ();
  16. if ((direction & (SWT.UP | SWT.DOWN)) == 0 && direction != SWT.NONE) return;
  17. sortDirection = direction;
  18. if (sortColumn != null && !sortColumn.isDisposed ()) {
  19. sortColumn.setSortDirection (direction);
  20. }
  21. }

代码示例来源:origin: org.eclipse.rap/org.eclipse.rap.rwt

  1. /**
  2. * Sets the column used by the sort indicator for the receiver. A null
  3. * value will clear the sort indicator. The current sort column is cleared
  4. * before the new column is set.
  5. *
  6. * @param column the column used by the sort indicator or <code>null</code>
  7. *
  8. * @exception IllegalArgumentException <ul>
  9. * <li>ERROR_INVALID_ARGUMENT - if the column is disposed</li>
  10. * </ul>
  11. * @exception SWTException <ul>
  12. * <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li>
  13. * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li>
  14. * </ul>
  15. */
  16. public void setSortColumn( TableColumn column ) {
  17. checkWidget();
  18. if( column != null && column.isDisposed() ) {
  19. error( SWT.ERROR_INVALID_ARGUMENT );
  20. }
  21. sortColumn = column;
  22. }

代码示例来源:origin: org.eclipse.swt.cocoa.macosx/x86_64

  1. void reskinChildren (int flags) {
  2. if (items != null) {
  3. for (int i=0; i<itemCount; i++) {
  4. TableItem item = items [i];
  5. if (item != null) item.reskin (flags);
  6. }
  7. }
  8. if (columns != null) {
  9. for (int i=0; i<columnCount; i++) {
  10. TableColumn column = columns [i];
  11. if (!column.isDisposed ()) column.reskin (flags);
  12. }
  13. }
  14. super.reskinChildren (flags);
  15. }

代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.ppc

  1. @Override
  2. void reskinChildren (int flags) {
  3. if (items != null) {
  4. for (int i=0; i<itemCount; i++) {
  5. TableItem item = items [i];
  6. if (item != null) item.reskin (flags);
  7. }
  8. }
  9. if (columns != null) {
  10. for (int i=0; i<columnCount; i++) {
  11. TableColumn column = columns [i];
  12. if (!column.isDisposed ()) column.reskin (flags);
  13. }
  14. }
  15. super.reskinChildren (flags);
  16. }

代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.s390x

  1. @Override
  2. void reskinChildren (int flags) {
  3. if (items != null) {
  4. for (int i=0; i<itemCount; i++) {
  5. TableItem item = items [i];
  6. if (item != null) item.reskin (flags);
  7. }
  8. }
  9. if (columns != null) {
  10. for (int i=0; i<columnCount; i++) {
  11. TableColumn column = columns [i];
  12. if (!column.isDisposed ()) column.reskin (flags);
  13. }
  14. }
  15. super.reskinChildren (flags);
  16. }

代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.aix.ppc

  1. @Override
  2. void reskinChildren (int flags) {
  3. if (items != null) {
  4. for (int i=0; i<itemCount; i++) {
  5. TableItem item = items [i];
  6. if (item != null) item.reskin (flags);
  7. }
  8. }
  9. if (columns != null) {
  10. for (int i=0; i<columnCount; i++) {
  11. TableColumn column = columns [i];
  12. if (!column.isDisposed ()) column.reskin (flags);
  13. }
  14. }
  15. super.reskinChildren (flags);
  16. }

代码示例来源:origin: org.eclipse.swt.cocoa.macosx/x86_64

  1. /**
  2. * Sets the column used by the sort indicator for the receiver. A null
  3. * value will clear the sort indicator. The current sort column is cleared
  4. * before the new column is set.
  5. *
  6. * @param column the column used by the sort indicator or <code>null</code>
  7. *
  8. * @exception IllegalArgumentException <ul>
  9. * <li>ERROR_INVALID_ARGUMENT - if the column is disposed</li>
  10. * </ul>
  11. * @exception SWTException <ul>
  12. * <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li>
  13. * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li>
  14. * </ul>
  15. *
  16. * @since 3.2
  17. */
  18. public void setSortColumn (TableColumn column) {
  19. checkWidget ();
  20. if (column != null && column.isDisposed ()) error (SWT.ERROR_INVALID_ARGUMENT);
  21. if (column == sortColumn) return;
  22. setSort(column, sortDirection);
  23. }

代码示例来源:origin: org.eclipse.swt.cocoa.macosx/x86_64

  1. void releaseChildren (boolean destroy) {
  2. if (items != null) {
  3. for (int i=0; i<itemCount; i++) {
  4. TableItem item = items [i];
  5. if (item != null && !item.isDisposed ()) {
  6. item.release (false);
  7. }
  8. }
  9. items = null;
  10. }
  11. if (columns != null) {
  12. for (int i=0; i<columnCount; i++) {
  13. TableColumn column = columns [i];
  14. if (column != null && !column.isDisposed ()) {
  15. column.release (false);
  16. }
  17. }
  18. columns = null;
  19. }
  20. super.releaseChildren (destroy);
  21. }

代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.s390x

  1. @Override
  2. void releaseChildren (boolean destroy) {
  3. if (items != null) {
  4. for (int i=0; i<itemCount; i++) {
  5. TableItem item = items [i];
  6. if (item != null && !item.isDisposed ()) {
  7. item.release (false);
  8. }
  9. }
  10. items = null;
  11. }
  12. if (columns != null) {
  13. for (int i=0; i<columnCount; i++) {
  14. TableColumn column = columns [i];
  15. if (column != null && !column.isDisposed ()) {
  16. column.release (false);
  17. }
  18. }
  19. columns = null;
  20. }
  21. super.releaseChildren (destroy);
  22. }

代码示例来源:origin: org.eclipse.rap/org.eclipse.rap.rwt

  1. @Override
  2. void reskinChildren( int flags ) {
  3. if( items != null ) {
  4. for( int i = 0; i < items.length; i++ ) {
  5. TableItem item = items[ i ];
  6. if( item != null ) {
  7. item.reskin( flags );
  8. }
  9. }
  10. }
  11. TableColumn[] columns = getColumns();
  12. if( columns != null ) {
  13. for( int i = 0; i < columns.length; i++ ) {
  14. TableColumn column = columns[ i ];
  15. if( !column.isDisposed() ) {
  16. column.reskin( flags );
  17. }
  18. }
  19. }
  20. super.reskinChildren( flags );
  21. }
  22. }

代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.aix.ppc

  1. @Override
  2. void releaseChildren (boolean destroy) {
  3. if (items != null) {
  4. for (int i=0; i<itemCount; i++) {
  5. TableItem item = items [i];
  6. if (item != null && !item.isDisposed ()) {
  7. item.release (false);
  8. }
  9. }
  10. items = null;
  11. }
  12. if (columns != null) {
  13. for (int i=0; i<columnCount; i++) {
  14. TableColumn column = columns [i];
  15. if (column != null && !column.isDisposed ()) {
  16. column.release (false);
  17. }
  18. }
  19. columns = null;
  20. }
  21. super.releaseChildren (destroy);
  22. }

代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.ppc

  1. @Override
  2. void releaseChildren (boolean destroy) {
  3. if (items != null) {
  4. for (int i=0; i<itemCount; i++) {
  5. TableItem item = items [i];
  6. if (item != null && !item.isDisposed ()) {
  7. item.release (false);
  8. }
  9. }
  10. items = null;
  11. }
  12. if (columns != null) {
  13. for (int i=0; i<columnCount; i++) {
  14. TableColumn column = columns [i];
  15. if (column != null && !column.isDisposed ()) {
  16. column.release (false);
  17. }
  18. }
  19. columns = null;
  20. }
  21. super.releaseChildren (destroy);
  22. }

代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.ppc

  1. /**
  2. * Shows the column. If the column is already showing in the receiver,
  3. * this method simply returns. Otherwise, the columns are scrolled until
  4. * the column is visible.
  5. *
  6. * @param column the column to be shown
  7. *
  8. * @exception IllegalArgumentException <ul>
  9. * <li>ERROR_NULL_ARGUMENT - if the column is null</li>
  10. * <li>ERROR_INVALID_ARGUMENT - if the column has been disposed</li>
  11. * </ul>
  12. * @exception SWTException <ul>
  13. * <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li>
  14. * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li>
  15. * </ul>
  16. *
  17. * @since 3.0
  18. */
  19. public void showColumn (TableColumn column) {
  20. checkWidget ();
  21. if (column == null) error (SWT.ERROR_NULL_ARGUMENT);
  22. if (column.isDisposed()) error(SWT.ERROR_INVALID_ARGUMENT);
  23. if (column.parent != this) return;
  24. OS.gtk_tree_view_scroll_to_cell (handle, 0, column.handle, false, 0, 0);
  25. }

代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.ppc

  1. /**
  2. * Sets the direction of the sort indicator for the receiver. The value
  3. * can be one of <code>UP</code>, <code>DOWN</code> or <code>NONE</code>.
  4. *
  5. * @param direction the direction of the sort indicator
  6. *
  7. * @exception SWTException <ul>
  8. * <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li>
  9. * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li>
  10. * </ul>
  11. *
  12. * @since 3.2
  13. */
  14. public void setSortDirection (int direction) {
  15. checkWidget ();
  16. if (direction != SWT.UP && direction != SWT.DOWN && direction != SWT.NONE) return;
  17. sortDirection = direction;
  18. if (sortColumn == null || sortColumn.isDisposed ()) return;
  19. if (sortDirection == SWT.NONE) {
  20. OS.gtk_tree_view_column_set_sort_indicator (sortColumn.handle, false);
  21. } else {
  22. OS.gtk_tree_view_column_set_sort_indicator (sortColumn.handle, true);
  23. OS.gtk_tree_view_column_set_sort_order (sortColumn.handle, sortDirection == SWT.DOWN ? 0 : 1);
  24. }
  25. }

代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.aix.ppc

  1. /**
  2. * Sets the direction of the sort indicator for the receiver. The value
  3. * can be one of <code>UP</code>, <code>DOWN</code> or <code>NONE</code>.
  4. *
  5. * @param direction the direction of the sort indicator
  6. *
  7. * @exception SWTException <ul>
  8. * <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li>
  9. * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li>
  10. * </ul>
  11. *
  12. * @since 3.2
  13. */
  14. public void setSortDirection (int direction) {
  15. checkWidget ();
  16. if (direction != SWT.UP && direction != SWT.DOWN && direction != SWT.NONE) return;
  17. sortDirection = direction;
  18. if (sortColumn == null || sortColumn.isDisposed ()) return;
  19. if (sortDirection == SWT.NONE) {
  20. OS.gtk_tree_view_column_set_sort_indicator (sortColumn.handle, false);
  21. } else {
  22. OS.gtk_tree_view_column_set_sort_indicator (sortColumn.handle, true);
  23. OS.gtk_tree_view_column_set_sort_order (sortColumn.handle, sortDirection == SWT.DOWN ? 0 : 1);
  24. }
  25. }

代码示例来源:origin: org.eclipse.scout.sdk.deps/org.eclipse.swt.win32.win32.x86

  1. @Override
  2. void reskinChildren (int flags) {
  3. if (_hasItems ()) {
  4. int itemCount = (int)/*64*/OS.SendMessage (handle, OS.LVM_GETITEMCOUNT, 0, 0);
  5. for (int i=0; i<itemCount; i++) {
  6. TableItem item = _getItem (i, false);
  7. if (item != null) item.reskin (flags);
  8. }
  9. }
  10. if (columns != null) {
  11. for (int i=0; i<columnCount; i++) {
  12. TableColumn column = columns [i];
  13. if (!column.isDisposed ()) column.reskin (flags);
  14. }
  15. }
  16. super.reskinChildren (flags);
  17. }

相关文章