Allow disabling of legacy gadgets (Mobile support)

The mobile environment differs from the desktop environment so various
gadgets may not work as expected. ResourceLoader deals with this for
normal modules by enforcing a 'targets' property that requires
javascript that wants to run on mobile to specify a mobile target.

This change
* Allow other extensions to disallow legacy gadgets
* Allow specifying module targets in similar way to RL, effectively
creating mobile gadgets

Bug: 44918

Change-Id: I9ee852e33412826608b6039fa01a2b0027b35e7b