O'Reilly logo

Mac OS® X Advanced Development Techniques by Joe Zobkiw

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

12. Threads

“Nice threads!”

—Some guy circa 1973

There was a time when computer programs ran from beginning to end with nary a surprise. If a program had 100 instructions, they would run in order, with the exception of loops and branches. No two instructions would execute at the same time. You could not be performing more than one task at the same time. Execution was serial; each command occurred one after the other.

The Macintosh operating system introduced us to the event driven programming model. A program's instructions would still occur in order, but this mechanism allowed the computer to spin its wheels until the user clicked the mouse or typed on the keyboard. When an event such as this occurred, the computer would react to it and draw ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required