I would do a:

  $app = F::app()

and use it for the global variable (e.g. $app->wg->Enable...) and for the checkSkin call