Mercurial > projects > dwt-mac
diff dwt/custom/CCombo.d @ 130:3d4579727e0e
Fixes #2 and #3
author | Jacob Carlborg <doob@me.com> |
---|---|
date | Tue, 10 Feb 2009 21:01:24 +0100 |
parents | 07399639c0c8 |
children | 52d360200ae4 |
line wrap: on
line diff
--- a/dwt/custom/CCombo.d Sun Jan 18 18:39:46 2009 +0100 +++ b/dwt/custom/CCombo.d Tue Feb 10 21:01:24 2009 +0100 @@ -134,26 +134,40 @@ if ((style & DWT.FLAT) !is 0) arrowStyle |= DWT.FLAT; arrow = new Button (this, arrowStyle); - listener = new class() Listener { + listener = new class(text, list, popup, arrow) Listener { + + Text text; + List list; + Shell popup; + Button arrow; + + this (Text text, List list, Shell popup, Button arrow) + { + this.text = text; + this.list = list; + this.popup = popup; + this.arrow = arrow; + } + public void handleEvent (Event event) { if (popup is event.widget) { - popupEvent (event); + this.outer.popupEvent (event); return; } if (text is event.widget) { - textEvent (event); + this.outer.textEvent (event); return; } if (list is event.widget) { - listEvent (event); + this.outer.listEvent (event); return; } if (arrow is event.widget) { - arrowEvent (event); + this.outer.arrowEvent (event); return; } if (this.outer is event.widget) { - comboEvent (event); + this.outer.comboEvent (event); return; } if (getShell () is event.widget) {