Mercurial > projects > mde
diff mde/gui/widget/layout.d @ 133:9fd705793568
Fixed menu popup bug, improved recursion detection.
Menu popups can now determine whether or not they are sub-menus.
Recursion detection can now also check content (if not the same, there's not a risk of infinite recursion).
author | Diggory Hardy <diggory.hardy@gmail.com> |
---|---|
date | Fri, 23 Jan 2009 16:05:05 +0000 |
parents | 9cff74f68b84 |
children | 4084f07f2c7a |
line wrap: on
line diff
--- a/mde/gui/widget/layout.d Fri Jan 23 14:59:05 2009 +0000 +++ b/mde/gui/widget/layout.d Fri Jan 23 16:05:05 2009 +0000 @@ -116,6 +116,12 @@ } } + override void recursionCheck (widgetID wID, IContent c) { + if (wID is id && c is cList) + throw new WidgetRecursionException (wID); + parent.recursionCheck (wID, c); + } + override bool saveChanges () { // Since all sub-widgets have the same id, it only makes sense to call on one if (subWidgets is null)