Add validation to ListFragment template

The ListFragment template previously was using globals to calculate
its layout resource values. This is now handled by properly validated
parameters.

Fixes https://code.google.com/p/android/issues/detail?id=74253
Change-Id: I87ad3f72d047ce6af859d19a182838836327c916
7 files changed