I wondered what the Mercury actually did with the felt, as I couldn't think of anything from the top of my hat:
Mercury made the felting process in hat production more efficient. The compound used to moisten the fibers was Mercury Nitrate, a process known as carroting. It produced a superior-quality felt, which in turn, resulted in higher-quality hats
Which, should be noted, is not the mercury show in the picture. Mercuric nitrates are a white/yellow dry powder that is the result of mixing mercury with nitric acid. The process of making mercuric nitrates, and carroting itself, both result in rather toxic fumes that you really should not breathe in.
Handling liquid mercury is basically almost harmless as it absorbs through the skin really slowly and doesn't produce much vapours. Putting it in acid, heating it up, and putting the cloth treated with it in an oven is not.
I wonder what secondary compounds this was creating. Elemental mercury is pretty much fine, but if it was reacting with other things to create wacky fun times...