Mercurial > projects > dwt-addons
diff dwtx/jface/viewers/ViewerCell.d @ 90:7ffeace6c47f
Update 3.4M7 to 3.4
author | Frank Benoit <benoit@tionex.de> |
---|---|
date | Sun, 06 Jul 2008 23:30:07 +0200 |
parents | 5df4896124c7 |
children |
line wrap: on
line diff
--- a/dwtx/jface/viewers/ViewerCell.d Sun Jun 22 22:57:31 2008 +0200 +++ b/dwtx/jface/viewers/ViewerCell.d Sun Jul 06 23:30:07 2008 +0200 @@ -8,7 +8,7 @@ * Contributors: * IBM Corporation - initial API and implementation * Tom Schindl <tom.schindl@bestsolution.at> - initial API and implementation - * - fix in bug: 195908,198035,215069,215735 + * - fix in bug: 195908,198035,215069,215735,227421 * Port to the D programming language: * Frank Benoit <benoit@tionex.de> *******************************************************************************/ @@ -296,7 +296,7 @@ if (columnIndex >= 0 && columnIndex < row.getColumnCount()) { ViewerCell cell = row.getCellAtVisualIndex(columnIndex); if( cell !is null ) { - while( cell !is null ) { + while( cell !is null && columnIndex < row.getColumnCount() - 1 && columnIndex > 0 ) { if( cell.isVisible() ) { break; } @@ -416,8 +416,12 @@ return false; return true; } - + + private int getWidth() { + return row.getWidth(columnIndex); + } + private bool isVisible() { - return getBounds().width > 0; + return getWidth() > 0; } }