class 'ExtraConceptArtBase' (ExtraCollectionPageBase)

function ExtraConceptArtBase:__init(extraScreen, order)
	ExtraCollectionPageBase.__init(self, extraScreen, 'conceptArtPage', order)

	self.previewFileFormat		= 'Data/ExtraContent/Textures/Screens/Extra/ConceptArt/Previews/preview_%s.png'
	self.previewNameFormat		= 'concept_art_%s'
	self.count					= 0

	self.sourceFileFormat		= 'Data/ExtraContent/Textures/Screens/Extra/ConceptArt/concept_art_%s.jpg'
	self.destinationFileFormat	= 'ConceptArt_%s.jpg'
end
-------------------------------------------------------------------------------
function ExtraConceptArtBase:show()
	ExtraPageBase.show(self)
	self.screen:getButton('save'):setOpacity(1)
end
-------------------------------------------------------------------------------
function ExtraConceptArtBase:getSourceFileName()
	local id = (self.index > 9) and tostring(self.index) or '0'..self.index
	return string.format(self.sourceFileFormat, id)
end
-------------------------------------------------------------------------------

function ExtraConceptArtBase:getDestinationFileName()
	local id = (self.index > 9) and tostring(self.index) or '0'..self.index
	return string.format(self.destinationFileFormat, id)
end
-------------------------------------------------------------------------------

function ExtraConceptArtBase:save()
	createYesNoScreen(	'SAVE_IMAGE_CONFIRMATION', bind(self.onSavingConfirmed, self), bind(self.onSavingCanceled,  self), false)
end
-------------------------------------------------------------------------------

function ExtraConceptArtBase:onSavingConfirmed()
	local sourcefileName      = self:getSourceFileName()
	local destinationFileName = self:getDestinationFileName()

	copyResourceIntoMyDocumentsFolder(sourcefileName, destinationFileName)
end
-------------------------------------------------------------------------------

function ExtraConceptArtBase:onSavingCanceled()
end
-------------------------------------------------------------------------------