def image(name, locator)
      define_method("click_#{name}") do
        platform.click_image(locator)
      end
      define_method("wait_for_#{name}") do
        wait_until do
          platform.has_drawable?(locator)
        end
      end
      define_method("#{name}_view") do
        Gametel::Views::Image.new(platform, locator)
      end
    end
def image(name, locator)
      define_method("click_#{name}") do
        platform.click_image(locator)
      end
      define_method("wait_for_#{name}") do
        wait_until do
          platform.has_drawable?(locator)
        end
      end
      define_method("#{name}_view") do
        Gametel::Views::Image.new(platform, locator)
      end
    end
Generaes method to interact with an image.

 @example
   image(:headshot, :id => 'headshot')
   # will generate 'click_headshot' method to click the image,
   # 'wait_for_headshot' which will wait until the image has
   # loaded a drawable and 'headshot_view' to return the view

 @param  [Symbol]  the name used for the generated methods
 @param  [Hash]  locator indicating an id for how the image is found.
 The only valid keys are:
   * :index