2 // SUStatusController.h
5 // Created by Andy Matuschak on 3/14/06.
6 // Copyright 2006 Andy Matuschak. All rights reserved.
9 #ifndef SUSTATUSCONTROLLER_H
10 #define SUSTATUSCONTROLLER_H
12 #import "SUWindowController.h"
14 @interface SUStatusController
: SUWindowController
{
15 double progressValue
, maxProgressValue
;
16 NSString
*title
, *statusText
, *buttonTitle
;
17 IBOutlet NSButton
*actionButton
;
18 IBOutlet NSProgressIndicator
* progressBar
;
22 - (id
)initWithHostBundle
:(NSBundle
*)hostBundle
;
24 // Pass 0 for the max progress value to get an indeterminate progress bar.
25 // Pass nil for the status text to not show it.
26 - (void)beginActionWithTitle
:(NSString
*)title maxProgressValue
:(double)maxProgressValue statusText
:(NSString
*)statusText
;
28 // If isDefault is YES, the button's key equivalent will be \r.
29 - (void)setButtonTitle
:(NSString
*)buttonTitle target
:target action
:(SEL
)action isDefault
:(BOOL
)isDefault
;
30 - (void)setButtonEnabled
:(BOOL
)enabled
;
32 - (double)progressValue
;
33 - (void)setProgressValue
:(double)value
;
34 - (double)maxProgressValue
;
35 - (void)setMaxProgressValue
:(double)value
;
37 - (void)setStatusText
:(NSString
*)statusText
;