Origin of 'Fly off the Handle'?

Posted by J S on October 20, 1999

When talking with a friend, I used the idiom:
'fly off the handle'
to discribe someone who would abruptly lose his temper.
(I believe that is the correct meaning). Subsequently,
we got into a discussion about the origins of the
phrase; he believes that it has something to do with
the railroad and I believe that it has to do with
firearms. I searched the list here and did find it.

Could someone clarify the origins of this phrase for us?
Any help is greatly appreciated.