[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSPopUpButton*, NSMenu* patch.

From: Michael Hanni
Subject: NSPopUpButton*, NSMenu* patch.
Date: Wed, 20 Feb 2002 04:53:59 -0800 (PST)


Here is a rather large patch that makes some changes to NSMenu* and
NSPopUpButton*. Basically it allows one to use images in popupbuttons once
again and it removes many redisplays which were causing the menus and popups to
be quite painful on slow machines (bonus: the windows menu should display a
little better both as a tornoff and as a regular menu.) Finally, it also
includes a change to NSTabView which addresses a bug noted on discuss-gnustep.

There are still issues, but I believe this patch is some improvement (it makes
things nicer on my slow machine. :))


        * Source/NSApplication.m: (-changeWindowsItem:) If the item in
        question already exists we abort further processing.
        * Source/NSMenu.m: (-itemChanged:) Mark the menuitemcell that has
        changed for redisplay (thus allowing us to only redisplay the
        item changed as opposed to the entire view.)
        (-sizeToFit) Alot of reformulation to suppress multiple
        (-_popUpButtonCell) Allow access to the popupbuttoncell privately.
        * Source/NSMenuItemCell.m: Moved drawing of popupbutton icon here.
        Also, reallow use of NSImages in an NSPopUpButton.
        (-imageRectForBounds:) Remove popupbutton code.
        (-drawImageWithFrame:) Dim image if item is not enabled.
        (-_drawPopUpIconWithFrame:) New method to draw popupbutton icons.
        (-drawInteriorWithFrame:) Draw popupbutton icon if needed.
        * Source/NSMenuView.m: (-sizeToFit) Check for popupbutton to
        remove additional 1 pixel.
        * Source/NSPopUpButtonCell.m: reformulate drawing.
        (-drawWithFrame:) Have the menuRepresentation fetch us the
        NSMenuItemCell for the selectedItem and draw it.
        (-drawInteriorWithFrame:) Remove all code save for NSDottedRect
        * Source/NSTabView.m: (-mouseDown:) new method to fix problems
        with NSSplitView interaction.
        (-hitTest:) removed.



Do You Yahoo!?
Yahoo! Sports - Coverage of the 2002 Olympic Games

Attachment: NSPop-NSMenu-fixes.patch
Description: NSPop-NSMenu-fixes.patch

reply via email to

[Prev in Thread] Current Thread [Next in Thread]