Sha256: 33d703a1f281b2a8e96235c674a0d09d1507bac854f4192eb417239907fa7cda

Contents?: true

Size: 432 Bytes

Versions: 9

Compression:

Stored size: 432 Bytes

Contents

module Mohawk
  module Accessors
    class CheckBox
      attr_reader :view

      def initialize(adapter, locator)
        @view = adapter.window.checkbox(locator)
      end

      def checked?
        @view.set?
      end

      def set_check(should_check)
        @view.set if should_check
        @view.clear unless should_check
      end

      def value
        @view.value
      end
    end
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
mohawk-0.1.4 lib/mohawk/accessors/checkbox.rb
mohawk-0.1.0 lib/mohawk/accessors/checkbox.rb
mohawk-0.0.9 lib/mohawk/accessors/checkbox.rb
mohawk-0.0.8 lib/mohawk/accessors/checkbox.rb
mohawk-0.0.7 lib/mohawk/accessors/checkbox.rb
mohawk-0.0.6 lib/mohawk/accessors/checkbox.rb
mohawk-0.0.5 lib/mohawk/accessors/checkbox.rb
mohawk-0.0.4 lib/mohawk/accessors/checkbox.rb
mohawk-0.0.3 lib/mohawk/accessors/checkbox.rb