root/Trunk/AIUtilities.framework/Versions/A/Headers/AIDelayedTextField.h @ 2

Revision 2, 1.9 KB (checked in by jon, 16 years ago)

Initial commit of skeletal project.

Line 
1//
2//  AIDelayedTextField.h
3//  Adium
4//
5//  Created by Evan Schoenberg on Wed Mar 10 2004.
6//  Copyright (c) 2004-2005 The Adium Team. All rights reserved.
7//
8
9/*!
10 * @class AIDelayedTextField
11 * @brief Text field which groups changes, triggering its action after a period without changes
12 *
13 * An <tt>AIDelayedTextField</tt> is identical to an NSTextField except, instead of sending its target an action only when enter is pressed or the field loses focus, it sends the action after a specified delay without changes.  This allows an intermediate behavior between changing every time the text chagnes (via the textDidChange: notification) and changing only when editing is complete.
14 */
15@interface AIDelayedTextField : NSTextField {
16        BOOL    pendingAction;
17        float   delayInterval;
18}
19
20/*!
21 * @brief Immediately send the action to the target.
22 *
23 * Immediately send the action to the target. If the field had changed but has not yet sent its action (because the delay interval has not been reached), it immediately sends the action and cancels the delayed send.  This should be sent before programatically changing the text (if the view is configuring for some new display but the changes the user made previously should saved). It should also be called before its containing view is closed so changes may be immediately applied..
24 */ 
25- (void)fireImmediately;
26
27/*!
28 * @brief Set the interval which must pass without changes before the action is triggered.
29 *
30 * Set the interval which must pass without changes before the action is triggered.  If changes are made within this interval, the timer is reset and inInterval must then pass from the time of the new edit.
31 * @param inInterval The new interval (in seconds). The default value is 0.5 seconds.
32 */
33- (void)setDelayInterval:(float)inInterval;
34
35/*!
36 * @brief The current triggering delay interval
37 *
38 * The current triggering delay interval
39 * @return inInterval The delay interval (in seconds).
40 */
41- (float)delayInterval;
42
43@end
Note: See TracBrowser for help on using the browser.