No good answer for the recharging question. I'm sure it is becoming quite the issue at campgrounds all over, as most of us now have electronic devices that need recharging, yet camp sites are blessed free of electricity.
Don't under any circumstances leave food in your car in Yosemite or in fact anywhere in the Sierra.
The bear boxes at the TH parking lot will probably fit your food. The reason I say probably rather than certainly has to do with the hanta virus that sickened and killed several Yosemite visitors this past summer that David referred to further up this thread. Hanta virus is spread by mice and mice can get in to the current bear boxes. In the short term Yosemite recommends that you use mouse proof containers inside the bear boxes, this means hard plastic containers, ice cheasts, coolers and the like, all of which will fill up the bear lockers. The long term solution I suspect will involve new mouse proof bear lockers, but who knows when that will happen.
Arts solution of buying food in the store seems like a good one. You'll be ready for some fresh food after a few days of backpacking.