ftp.nice.ch/Attic/openStep/developer/resources/IconKit.4.2.1.sd.tgz#/IconKit.4.2.1/Palette/IKBrowserInspector.m

This is IKBrowserInspector.m in view mode; [Download] [Up]

#import <IconKit/IKBrowser.h>

#import "IKBrowserInspector.h"

@implementation IKBrowserInspector:IBInspector
{
        id		form;
}


/* ========================================================================== */


#define COLUMNS			0
#define MAXVISIBLE		1
#define MINWIDTH		2


/* ========================================================================== */


- init
{
    [super init];
    [NSBundle loadNibNamed:@"IKBrowserInspector" owner:self];
    return self;
}


/* ========================================================================== */


/*

All three options are reset whenever the user changes one of them.

*/

- (void)ok:(id)sender
{
    [[self object] setMinColumnWidth:1];
    [[self object] setMaxVisibleColumns: [[form cellWithTag:COLUMNS]  intValue]];
    [[self object] setMinColumnWidth:[[form cellWithTag:MINWIDTH]  intValue]];
    [[self object] setMaxVisibleColumns: [[form cellWithTag:MAXVISIBLE] intValue]];
    [super ok: sender];
}


- (void)revert:(id)sender
{
    [[form cellWithTag:COLUMNS]  setIntValue: [[self object] numberOfVisibleColumns]];
    [[form cellWithTag:MINWIDTH]  setIntValue: [[self object] minColumnWidth]];
    [[form cellWithTag:MAXVISIBLE]  setIntValue: [[self object] maxVisibleColumns]];
    [super revert: sender];
}


- (BOOL) wantsButtons
{
    return NO;
}


@end

These are the contents of the former NiCE NeXT User Group NeXTSTEP/OpenStep software archive, currently hosted by Netfuture.ch.