module Spiced
  module Module
    LCD1 = {:core_image => "Hardware Accelerated", :main_display? => true, 
            :mirror => "off", :online => true}

    LCD1RW = {:readers => {:core_image => "Hardware Accelerated"}, 
              :accessors => {:main_display => true, :mirror => "off", :online => true}}

    LCD1RW1 = LCD1RW.merge(:track_spices => true)

    LCD1RW_CVARS = LCD1RW[:readers].merge(LCD1RW[:accessors]).keys.map {|k| "@@#{k}".gsub(/\?$/,'')}

    LCD1RW_SPICES = LCD1RW[:readers].keys.map {|k| k.to_s} + LCD1RW[:accessors].keys.map {|k| k.to_s} + LCD1RW[:accessors].keys.map {|k|(k.to_s.gsub(/\?/,'') << '=')}

    LCD1_CVARS = LCD1.keys.map {|k| "@@#{k}".gsub(/\?$/,'')}

    LCD2 = LCD1.merge(:track_spices => true)

    LCD2_CVARS = LCD2.keys.map {|k| "@@#{k}"}

    LCD2_SPICES = LCD1.keys.map {|k| k.to_s} + LCD1.keys.map {|k|(k.to_s.gsub(/\?/,'') << '=')}
    
    # DISPLAY1 = {:resolution => "1440x960", :colors => "Millions", :brightness => 50, 
    #             :auto_adjust => true, :show_in_menu => true, :refresh_rate => "n/a"}
    # DISPLAY1_CVARS = DISPLAY1.keys.map {|k| "@@#{k}"}
    # 
    # DISPLAY2 = DISPLAY1.merge(:track_spices => true)
    # DISPLAY2_CVARS = DISPLAY2.keys.map {|k| "@@#{k}"}

    FORMATS = {:short => "%m/%d/%y", :long => "%A, %B %d, %Y"}

    TSPICES = {:fecha =>  Proc.new {|time,key| time.strftime(FORMATS[key.to_sym])},
               :ahora =>  Proc.new {Time.now}}
  end
end
