Class: UIView

Inherits:
Object show all
Defined in:
motion/ext.rb

Instance Method Summary (collapse)

Instance Method Details

- (Object) rmq(*selectors)

I intend for this to be protected Do not call rmq from outside a view. Because of some weirdness with table cells and event blocks this has to be public (later I want to figure out why exactly).

Technically my_view.rmq is the same as rmq(my_view), so it may seem enticing to use but the really nice thing about rmq is its consistent API, and doing this for one view: my_view.rmq and this for two views: rmq(my_view, my_other_view) sucks



34
35
36
37
38
39
40
# File 'motion/ext.rb', line 34

def rmq(*selectors)
  RubyMotionQuery::RMQ.create_with_selectors(selectors, self).tap do |o|
    if vc = self.rmq_data.view_controller
      o.weak_view_controller = vc
    end
  end
end

- (Object) rmq_appended



24
25
# File 'motion/ext.rb', line 24

def rmq_appended
end

- (Object) rmq_build

Override this to build your view and view's subviews



21
22
# File 'motion/ext.rb', line 21

def rmq_build
end

- (Object) rmq_created



17
18
# File 'motion/ext.rb', line 17

def rmq_created
end

- (Object) rmq_data



10
11
12
# File 'motion/ext.rb', line 10

def rmq_data
  @_rmq_data ||= RubyMotionQuery::ViewData.new
end

- (Object) rmq_did_create(self_in_rmq)

Deprecated.

No longer needed, use rmq_build



15
16
# File 'motion/ext.rb', line 15

def rmq_did_create(self_in_rmq)
end