Update changelog

This commit is contained in:
Gregory Casamento 2023-09-01 15:54:54 +00:00
commit 672ea350f8
2 changed files with 34 additions and 10 deletions

View file

@ -4,10 +4,16 @@
* Source/NSMenu.m (-removeAllItems): Add implementation to remove
all menu items in the reciever.
2023-08-30 Gregory John Casamento <greg.casamento@gmail.com>
* Source/GSXib5KeyedUnarchive.m: Fix for issue#192. Added code to
-decodeObjectForXib:forClassName:withID: to decode toolTip using
alternative format described in the issue.
2023-08-13 Fred Kiefer <FredKiefer@gmx.de>
* Source/NSSwitch.m (-drawRect:): Correct drawing as suggested by
Austin Clow (dr_clow@me.com).
Austin Clow (dr_clow@me.com).
2023-02-12 Gregory John Casamento <greg.casamento@gmail.com>

View file

@ -3169,6 +3169,31 @@ didStartElement: (NSString*)elementName
}
}
- (void) addToolTip: (GSXibElement *)element forObject: (id)object
{
NSString *toolTipString = [element attributeForKey: @"toolTip"];
// Process tooltips...
if (toolTipString == nil)
{
GSXibElement *toolTipElement = [element elementForKey: @"toolTip"];
toolTipString = [toolTipElement value];
}
if (toolTipString != nil)
{
if ([object respondsToSelector: @selector(setToolTip:)])
{
[object setToolTip: toolTipString];
}
else if ([object respondsToSelector: @selector(setHeaderToolTip:)])
{
[object setHeaderToolTip: toolTipString];
}
}
}
- (id) decodeObjectForXib: (GSXibElement*)element
forClassName: (NSString*)classname
withID: (NSString*)objID
@ -3177,15 +3202,8 @@ didStartElement: (NSString*)elementName
id object = [super decodeObjectForXib: element forClassName: classname withID: objID];
[self addOrderedObject: element];
// Process tooltips...
if ([element attributeForKey: @"toolTip"])
{
if ([object respondsToSelector: @selector(setToolTip:)])
[object setToolTip: [element attributeForKey: @"toolTip"]];
else if ([object respondsToSelector: @selector(setHeaderToolTip:)])
[object setHeaderToolTip: [element attributeForKey: @"toolTip"]];
}
[self addToolTip: element forObject: object];
// Process IB runtime attributes for element...
// Ensure we don't process the placeholders...
if ([element elementForKey: @"userDefinedRuntimeAttributes"] &&