MEDIUM / FGE refactoring / Fixed compile errors in various projects