Music Box project

Hello all. I am making a music box for my wife using the Adafruit Music Maker Shield. I want it to shut off when the lid is closed. The solution I have right now is to install a microswitch that kills power to the Arduino when the lid is closed. Simple, but not exactly elegant. Any other suggestions on how to achieve this?

Also, does the Music Maker shield "know" when the song it is playing has ended? I want it to play a random song from the SD card, and when that song is done, pick another random song to play. Curious if it sends some sort of signal saying "Hey. I am done with this song."

Did you consult the documentation?