Fix NPE when opening new layout file.

When adding the parsing of the device XML files, I mostly tested with a
layout file already opened when Eclipse launched.

Well it turns out there's a slightly different code path when opening a file
*after* Eclipse has launched. The load of the device UI in the config
selected caused a rendering before the XML model was loaded which ended
up in an NPE in the recomputeLayout method.

Additionnally, I hadn't finalized the code for the GLE2, so this brings it
in line with the GLE1.

Change-Id: Ic86de6e91ca13793aceecb5706bc963edddb9241
5 files changed