Fix recording of wake_lock_in.

There was a bug that would allow the nesting count
to get off.  Also better documentation of times in
HistoryItem, and new option to disable resetting of
the stats when unplugging.

Change-Id: If1b39a02475c5b620c67b700a323a6d0462d5c61
3 files changed