Apple Newton Utilities User's Guide Page 556

  • Download
  • Add to my manuals
  • Print
  • Page
    / 942
  • Table of contents
  • BOOKMARKS
  • Rated. / 5. Based on customer reviews
Page view 555
CHAPTER 14
Sound
14-2 About Newton Sound
All operations on sound frames are created by sending messages to a sound
channel that encapsulates the sound frame and the methods that operate on it.
Sound channels can play sampled sounds starting from any point within the data.
For more advanced uses of sound you can open a sound channel which allows
multiple channels to play simultaneously, or multiple sounds to be queued in a
single channel. You use a sound channel by sending messages to a sound channel
frame. Additionally, playback can be paused at any point in the sample data and
later resumed from that point.
Sound channels have the following characteristics:
There is no visual representation of a sound to the user.
Sound channels must explicitly be created and destroyed.
The creation and disposal of sound channels follow this model:
To create a sound channel, you send the Open message to a sound channel frame.
To dispose of the sound channel, you send the Close message to it.
Event-related Sounds 14
Views can play sounds to accompany various events. For example, the system
plays certain sounds to accompany user actions such as opening the Extras Drawer,
scrolling the Notepad, and so forth.
Sounds in ROM 14
The system provides a number of sounds in ROM that are played to accompany
various events. See “Sound Resources” (page 11-10) in the Newton Programmers
Reference for complete details.
Sounds for Predened Events 14
All views recognize a set of predened slot names that specify sounds to
accompany certain system events. To add a ROM-based sound to one of these
events, store the name of the ROM-based sound in the appropriate view slot.
The following predened slots can be included in views to play event-related sounds:
showSound The sound is played when the view is shown.
hideSound The sound is played when the view is hidden.
scrollUpSound The sound is played when the view receives a
ViewScrollUpScript message.
scrollDownSound
The sound is played when the view receives a
ViewScrollDownScript message.
Page view 555
1 2 ... 551 552 553 554 555 556 557 558 559 560 561 ... 941 942

Comments to this Manuals

No comments