refactored swf loading classes