Cleanup the generic object inspector, fix issues in GormDocument, add outlets to IBInspector

This commit is contained in:
Gregory John Casamento 2025-01-01 16:20:59 -05:00
parent 42bab95e08
commit f6d8c3999b
5 changed files with 5 additions and 9 deletions

View file

@ -4069,7 +4069,9 @@ willBeInsertedIntoToolbar: (BOOL)flag
if ([item respondsToSelector: @selector(title)])
{
title = [item title];
value = [NSString stringWithFormat: @"%@ : %@", title, (name != nil)?name:@"*Unnamed*"];
value = [NSString stringWithFormat: @"%@ : %@",
(title != nil && ![title isEqualToString: @""]) ? title : @"*Untitled*",
(name != nil) ? name : @"*Unnamed*"];
}
else
{

View file

@ -42,12 +42,7 @@
sets = [[NSMutableArray alloc] init];
gets = [[NSMutableDictionary alloc] init];
types = [[NSMutableDictionary alloc] init];
okButton = [[NSButton alloc] initWithFrame: NSMakeRect(0,0,90,20)];
[okButton setAutoresizingMask: NSViewMaxYMargin | NSViewMinXMargin];
[okButton setAction: @selector(ok:)];
[okButton setTarget: self];
[okButton setTitle: _(@"OK")];
[okButton setEnabled: NO];
revertButton = nil;
@ -96,7 +91,6 @@ selectCellWithString: (NSString*)title
RELEASE(gets);
RELEASE(sets);
RELEASE(types);
RELEASE(okButton);
[super dealloc];
}

View file

@ -149,7 +149,7 @@
};
IBInspector = {
Actions = ("ok:", "revert:", "touch:");
Outlets = (window);
Outlets = (window, okButton, revertButton);
Super = NSObject;
};
IBPalette = {Actions = (); Outlets = (originalWindow); Super = NSObject; };