# Path: epymc/modules.py
# class EmcModule(object):
#     name = ''
#     label = ''
#     icon = ''
#     info = ''
# 
#     def __init__(self):
#         pass
# 
#     def __shutdown__(self):
#         pass
# 
#     def __restart__(self):
#         self.__shutdown__()
#         self.__init__()
# 
# Path: epymc/gui.py
# EXPAND_BOTH = evas.EVAS_HINT_EXPAND, evas.EVAS_HINT_EXPAND
# 
# FILL_BOTH = evas.EVAS_HINT_FILL, evas.EVAS_HINT_FILL


import os
import epymc.config_gui as config_gui
import epymc.input_events as input_events
import epymc.gui as gui
from efl.elementary.image import Image
from epymc.modules import EmcModule
from epymc.gui import EXPAND_BOTH, FILL_BOTH
    'bars601.jpg',
    'Slide01.jpg',
    '6291.png',
]


# http://gonedigital.net/2010/04/19/

class CalibratorModule(EmcModule):
    name = 'calibrator'
    label = _('Screen calibrator')
    icon = 'icon/calib'
    info = _('Use this module to calibrate your screen parameters.')
    path = os.path.dirname(__file__)

    def __init__(self):
        config_gui.root_item_add('calibrator', 100, _('Screen calibrator'),
                                 icon='icon/calib', callback=self.startup)
        self.i = None
        self.current = -1

    def __shutdown__(self):
        config_gui.root_item_del('calibrator')

    def startup(self):
        self.i = Image(gui.win, aspect_fixed=False,
                       size_hint_weight=EXPAND_BOTH, size_hint_align=FILL_BOTH)
        gui.win.resize_object_add(self.i)
        self.i.show()


# Path: epymc/modules.py
# class EmcModule(object):
#     name = ''
#     label = ''
#     icon = ''
#     info = ''
# 
#     def __init__(self):
#         pass
# 
#     def __shutdown__(self):
#         pass
# 
#     def __restart__(self):
#         self.__shutdown__()
#         self.__init__()
# 
# Path: epymc/gui.py
# EXPAND_BOTH = evas.EVAS_HINT_EXPAND, evas.EVAS_HINT_EXPAND
# 
# FILL_BOTH = evas.EVAS_HINT_FILL, evas.EVAS_HINT_FILL


# Path: epymc/plugins/calibrator/calibrator.py
import os
import epymc.config_gui as config_gui
import epymc.input_events as input_events
import epymc.gui as gui
from efl.elementary.image import Image
from epymc.modules import EmcModule
from epymc.gui import EXPAND_BOTH, FILL_BOTH

    'bars601.jpg',
    'Slide01.jpg',
    '6291.png',
]


# http://gonedigital.net/2010/04/19/

class CalibratorModule(EmcModule):
    name = 'calibrator'
    label = _('Screen calibrator')
    icon = 'icon/calib'
    info = _('Use this module to calibrate your screen parameters.')
    path = os.path.dirname(__file__)

    def __init__(self):
        config_gui.root_item_add('calibrator', 100, _('Screen calibrator'),
                                 icon='icon/calib', callback=self.startup)
        self.i = None
        self.current = -1

    def __shutdown__(self):
        config_gui.root_item_del('calibrator')

    def startup(self):
        self.i = Image(gui.win, aspect_fixed=False,
                       size_hint_weight=EXPAND_BOTH, size_hint_align=FILL_BOTH)
        gui.win.resize_object_add(self.i)
        self.i.show()


        input_events.listener_add(self.name, self.input_event_cb)