//
//  KSTKSmartListMaker.h
//  GumiToolKit
//
//  Created by Pierre Oleo on 20/04/05.
//  Copyright 2005 GumiTech. All rights reserved.
//
//  $Id: KSTKSmartListMaker.h,v 1.8 2006/03/06 18:37:34 guigui Exp $

#import <Cocoa/Cocoa.h>

@class KSTKSmartListDatasource;
@class KSTKSmartListRowController;
@class REScrollView;
@class KSTKSmartListAllRowsView;
@interface KSTKSmartListMaker : NSObject
{
	//top level objects
	IBOutlet NSView* smartListEditorView;
	IBOutlet NSArrayController * anyOrAllArrayController;
	
	IBOutlet REScrollView * containerScroll;
	IBOutlet KSTKSmartListAllRowsView *smartListView;
	IBOutlet NSTextField *smartListNameTF ;
	IBOutlet NSPopUpButton * anyOrAllPopUp ;
	
	NSMutableArray *anyOrAllArray,* rowsArray;
	NSArray * modelArray;

	KSTKSmartListDatasource *datasource;
	
	NSString * smartTitle,*smartTitleLabel,*popUpLeftLabel,*popUpRightLabel;
	
	float deltaWindow;
}
@property (retain, nonatomic) NSMutableArray*anyOrAllArray,* rowsArray;
@property (retain, nonatomic) NSArray * modelArray;
@property (assign) KSTKSmartListDatasource *datasource;
@property (retain, nonatomic) NSString * smartTitle,*smartTitleLabel,*popUpLeftLabel,*popUpRightLabel;

- (id)initWithArray:(NSArray *)dataArray;
-(void) addFirstRow:(KSTKSmartListRowController *)firstRow;
-(void) addNewRowFromRow:(KSTKSmartListRowController *)previousRow;
-(void) removeRow:(KSTKSmartListRowController *)removableRow;

-(void ) setSmartListRowWithData:(NSArray *)dataArray  anyOrAll:(unsigned int)anyOrAllIndex;
-(NSView *)smartListEditorView;
-(NSMutableDictionary *) rulesDictionary;
-(NSTextField *) smartListNameTF;
@end
