Mercurial > cpython-lru_cache-weakref
view Mac/Lib/test/tsnd.py @ 5817:48b94de85bf3 legacy-trunk
Extensive changes by AMK.
| author | Guido van Rossum <guido@python.org> |
|---|---|
| date | Thu, 17 Jul 1997 16:29:42 +0000 |
| parents | 7411b6a06920 |
| children | 42b2f1936254 |
line wrap: on
line source
# Show off SndPlay (and some resource manager functions). # Get a list of all 'snd ' resources in the system and play them all. from Res import * from Snd import * ch = SndNewChannel(0, 0, None) print "Channel:", ch type = 'snd ' for i in range(CountResources(type)): r = GetIndResource(type, i+1) print r.GetResInfo(), r.size if r.GetResInfo()[0] == 1: print "Skipping simple beep" continue ch.SndPlay(r, 0)
