Set target platform on root node earlier.

Fix to grd_reader.py proposed by thakis@chromium.org and used verbatim
from his proposal. I added the regression test to surface the problem
(prior to this fix) in a unit test on all platforms where one of the
is_xyz shortcuts in .grd expressions is true.

BUG=https://code.google.com/p/grit-i18n/issues/detail?id=23

Review URL: https://codereview.chromium.org/118663003

git-svn-id: http://grit-i18n.googlecode.com/svn/trunk@141 7262f16d-afe8-6277-6482-052fa10e57b1