def __init__(self): logger.log( 9, 'ImageViewer.__init__()') GUIObject.__init__(self) self.osd_mode = 0 # Draw file info on the image self.zoom = 0 # Image zoom self.zoom_btns = { str(IMAGE_NO_ZOOM):0, str(IMAGE_ZOOM_GRID1):1, str(IMAGE_ZOOM_GRID2):2, str(IMAGE_ZOOM_GRID3):3, str(IMAGE_ZOOM_GRID4):4, str(IMAGE_ZOOM_GRID5):5, str(IMAGE_ZOOM_GRID6):6, str(IMAGE_ZOOM_GRID7):7, str(IMAGE_ZOOM_GRID8):8, str(IMAGE_ZOOM_GRID9):9 } self.slideshow = config.IMAGEVIEWER_AUTOPLAY self.duration = config.IMAGEVIEWER_DURATION self.event_context = 'image' self.last_image = (None, None) self.render = render.get_singleton() self.osd = osd.get_singleton() self.osd_height = self.osd.height self.osd_width = self.osd.width * float(config.OSD_PIXEL_ASPECT) self.timer = None self.blend = None self.__added_app = False self.free_cache()
from area import Skin_Area from gui import GUIObject import xml_skin import screen from animation import render, Transition import pygame import kaa from skin import TRANSITION_IN,TRANSITION_OUT,TRANSITION_PAGE,TRANSITION_NONE # Create the OSD object osd = osd.get_singleton() render = render.get_singleton() TRANSITION_STEPS=20 ############################################################################### # Skin main functions ############################################################################### class Skin: """ main skin class """ Rectange = xml_skin.Rectangle Image = xml_skin.Image Area = Skin_Area def __init__(self):