dofile('Data/Scripts/Common/Screens/YesNoScreenBase.lua')

class 'YesNoScreen' (YesNoScreenBase)

function YesNoScreen:__init(name)
    YesNoScreenBase.__init(self, name)
end

function YesNoScreen:setData(message, yesHandler, noHandler, windowHeader)
    YesNoScreenBase.setData(self, message, yesHandler, noHandler)
	
	if windowHeader then
	    if windowHeader == YES_NO_SCREEN_DELETE_PLAYER_HEADER or 
                windowHeader == YES_NO_SCREEN_EXIT_HEADER or 
                windowHeader == YES_NO_SCREEN_EXIT_TO_MAIN_MENU_HEADER or 
                windowHeader == YES_NO_SCREEN_INTERACTIVE_HELP_HEADER then
	        local header_obj = CreateSpriteEntity('Data/Textures/Screens/YesNo/'..windowHeader..'.png')
            header_obj:attachTo(self:getEntityNamed('YesNoScreen'))
            header_obj:setName('YesNoScreenHeader')
            header_obj:setXY(0, -184)
            header_obj:setOrder(1)
            header_obj:setRespondable(false)
        end
	end
end

--------------------------------------------------------------------------------
--                      GENERATED CONTENT. DO NOT EDIT.                       --
--------------------------------------------------------------------------------

function YesNoScreen:CreateLoaderTable()
	local objects =
	{
		{ name = 'YesNoScreen',  entityType = 'SpriteEntity',  x = 512,  y = 384,  order = 10,  editingLocked = false,  treeItemIsExpanded = true,  hotSpot = {x = 268, y = 221},  texturePath = 'Data/Textures/Screens/YesNo/YesNoScreen.png',  width = 536,  height = 442,  },
		{ name = 'bttn_yes',  entityType = 'ButtonEntity',  parentName = 'YesNoScreen',  x = -60,  y = 214,  order = 5,  editingLocked = false,  treeItemIsExpanded = true,  texturePath = 'Data/Textures/GUI/Buttons/bttn_yes.png',  text = '',  },
		{ name = 'bttn_no',  entityType = 'ButtonEntity',  parentName = 'YesNoScreen',  x = 60,  y = 214,  order = 5,  editingLocked = false,  treeItemIsExpanded = false,  texturePath = 'Data/Textures/GUI/Buttons/bttn_no.png',  text = '',  },
		{ name = 'textMessage',  entityType = 'TextEntity',  x = 512,  y = 369,  order = 30,  editingLocked = false,  treeItemIsExpanded = false,  text = 'MyText',  font = 'Data/Fonts/Options.fnt',  height = 32,  boundsX = 300,  boundsY = 175,  },
	}
	return objects
end
