SetState
recorderview.statusText:SetState(oldState, newState, hasSound)
Sent by the recorder view to indicate a state change when the user taps one of the buttons.
DISCUSSION
- oldState
- The recorder view's previous state. The possible values are shown in Table 7-7.
- newState
- The recorder view's new state. The possible values are shown in Table 7-7.
- hasSound
- A Boolean that is
true
if the recorder currently has some sound frames defined. This parameter allows you to determine if the recorder view has any data to play (Boolean istrue
), or if it has none (Boolean isnil
).
- return value
- Ignored; you can return anything.
Each time there's a state change, the recorder view sends this *
SetState
message to thestatusText
slot in the view. By default thestatusText
slot isnil
. You can catch state changes by implementing astatusText
slot that contains a frame that contains a *SetState
method.The constants described in Table 7-7 are passed for the values of the first and second parameters in the *
SetState
message.Table 7-7 protoRecorderView state constants
Constant Value Description kInactive
1 Sound channel is stopped (default state). kRecording
2 Indicates recording is about to be started. kPlaying
4 Indicates playing is about to be started. kPlayPaused
8 Indicates playing is paused. kRecordPaused
16 Indicates recording is paused. kStopping
32 Indicates the sound channel is about to be stopped. kSetupStore
64 Indicates recording is about to be started. SEE ALSO
For more details on how to use this method, see "Using the protoRecorderView".
Main | Top of Section | What's New | Apple Computer, Inc. | Find It | Feedback | Help