Mercurial > projects > dwt-linux
diff dwt/custom/CCombo.d @ 259:c0d810de7093
Update SWT 3.4M7 to 3.4
author | Frank Benoit <benoit@tionex.de> |
---|---|
date | Sun, 29 Jun 2008 14:33:38 +0200 |
parents | 5a30aa9820f3 |
children | f1bb3949939b |
line wrap: on
line diff
--- a/dwt/custom/CCombo.d Tue Jun 24 22:12:18 2008 +0200 +++ b/dwt/custom/CCombo.d Sun Jun 29 14:33:38 2008 +0200 @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2000, 2007 IBM Corporation and others. + * Copyright (c) 2000, 2008 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at @@ -76,6 +76,10 @@ * <dt><b>Events:</b> * <dd>DefaultSelection, Modify, Selection, Verify</dd> * </dl> + * + * @see <a href="http://www.eclipse.org/swt/snippets/#ccombo">CCombo snippets</a> + * @see <a href="http://www.eclipse.org/swt/examples.php">DWT Example: CustomControlExample</a> + * @see <a href="http://www.eclipse.org/swt/">Sample code and further information</a> */ public final class CCombo : Composite { @@ -528,7 +532,7 @@ list.deselectAll (); } void dropDown (bool drop) { - if (drop is isDropped ()) return; + if (drop is isDropped () || !isVisible()) return; if (!drop) { popup.setVisible (false); if (!isDisposed () && isFocusControl()) { @@ -1575,7 +1579,9 @@ * If so then do not continue. */ if (isDisposed ()) return; - if (!visible) popup.setVisible(false); + // TEMPORARY CODE + if (popup is null || popup.isDisposed ()) return; + if (!visible) popup.setVisible (false); } /** * Sets the number of items that are visible in the drop