Ensure that the appearance of an NSPopUpButton is not inadvertently

changed when the menu view of its menu is set.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30939 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Wolfgang Lux 2010-07-09 20:06:18 +00:00
parent 1c4797d2a0
commit c2be707091
2 changed files with 15 additions and 0 deletions

View file

@ -1,3 +1,9 @@
2010-07-09 Wolfgang Lux <wolfgang.lux@gmail.com>
* Source/NSPopUpButtonCell.m (-setMenuView:): Override super class
method so that the button's appearance is not inadvertently
changed when the menu view is set.
2010-06-23 Wolfgang Lux <wolfgang.lux@gmail.com>
* Source/NSMenuView.m (-sizeToFit): Correctly take into account

View file

@ -184,6 +184,15 @@ static NSImage *_pbc_image[5];
[self synchronizeTitleAndSelectedItem];
}
- (void)setMenuView: (NSMenuView *)aMenuView
{
// NB Don't call NSMenuItemCell's implementation here because it also
// changes various items of the receiver, which is reasonable for a
// menu item cell that is part of a menu, but not for a pop up button
// cell.
_menuView = aMenuView;
}
/**
* Return the menu for the popup.
*/