Author: junrue Date: Sat Mar 4 16:54:25 2006 New Revision: 27
Modified: trunk/src/uitoolkit/widgets/menu.lisp trunk/src/uitoolkit/widgets/widget-generics.lisp trunk/src/uitoolkit/widgets/widget-with-items.lisp Log: fixed cleanup bug when submenu items disposed, which caused duplication in layout-tester menu tree
Modified: trunk/src/uitoolkit/widgets/menu.lisp ============================================================================== --- trunk/src/uitoolkit/widgets/menu.lisp (original) +++ trunk/src/uitoolkit/widgets/menu.lisp Sat Mar 4 16:54:25 2006 @@ -154,7 +154,6 @@ (increment-menuitem-id tc) (insert-submenu hparent id text (cffi:null-pointer) hmenu) (setf (item-id item) id) - (setf (slot-value item 'gfi:handle) hmenu) (put-menuitem tc item) (vector-push-extend item (items parent)) (put-widget tc submenu)
Modified: trunk/src/uitoolkit/widgets/widget-generics.lisp ============================================================================== --- trunk/src/uitoolkit/widgets/widget-generics.lisp (original) +++ trunk/src/uitoolkit/widgets/widget-generics.lisp Sat Mar 4 16:54:25 2006 @@ -40,7 +40,7 @@ (:documentation "If the object is visible, move it to the top of the display z-order and request the window manager to set it active."))
(defgeneric alignment (object) - (:documentation "Returns an integer describing the position of internal content within the object.")) + (:documentation "Returns a keyword symbol describing the position of internal content within the object."))
(defgeneric ancestor-p (ancestor descendant) (:documentation "Returns T if ancestor is an ancestor of descendant; nil otherwise."))
Modified: trunk/src/uitoolkit/widgets/widget-with-items.lisp ============================================================================== --- trunk/src/uitoolkit/widgets/widget-with-items.lisp (original) +++ trunk/src/uitoolkit/widgets/widget-with-items.lisp Sat Mar 4 16:54:25 2006 @@ -56,8 +56,8 @@ (error 'gfi:disposed-error)))
(defmethod clear-span ((w widget-with-items) (sp gfi:span)) - (loop for index from (gfi:span-start sp) to (gfi:span-end sp) - collect (clear-item w 0))) + (dotimes (i (1+ (- (gfi:span-end sp) (gfi:span-start sp)))) + (clear-item w (gfi:span-start sp))))
(defmethod item-at :before ((w widget-with-items) index) (declare (ignore index))