rm-extensions 0.4.2 → 0.4.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ae87bc3a3bdce1a898dd7d3d06b2b55b50f1481a
4
- data.tar.gz: c0de2749095fdcad336fc00dfd6789df24908348
3
+ metadata.gz: 2973c7a90a5838620647613242b3487718d1185a
4
+ data.tar.gz: 4f5e2038035fb1c14efc4d1345867cfdb407236a
5
5
  SHA512:
6
- metadata.gz: 69c65ccd7b57946f989add3ed3374a1b5bee33425b24ef21cadee6af17e6e8e108501563188d4b247cc2817c8916bcddb0cc188458d67c33531be16731273235
7
- data.tar.gz: 1c5ff538928243c319850c855b80180d421285b191fcd3ef4f7e9083ed6c8d0e846d45001861fc50417a721b55cbc48f27ff06b4023de27d2a4e27de5e3f4650
6
+ metadata.gz: acd625c55911e5df81975983b3dfb80eda03480d765d3b41402ba810da2668bdacd36cec865bd5b94bb6b6d659f31568a7a6d10df86545b7a81d341cfa0f1390
7
+ data.tar.gz: 7fbeda940ecd46dc99fc1e6d8692b176766391c9137aa943e53b38a83938546688a2336dcef0021771bf65a9a50da8ef8a7cfca5df97abf6eb459e5f7b6228eb
data/lib/motion/events.rb CHANGED
@@ -8,6 +8,10 @@ module RMExtensions
8
8
  @rmext_events_proxy ||= EventsProxy.new(self)
9
9
  end
10
10
 
11
+ def rmext_events_proxy?
12
+ !@rmext_events_proxy.nil?
13
+ end
14
+
11
15
  # register a callback when an event is triggered on this object.
12
16
  def rmext_on(object, event, &block)
13
17
  object.rmext_events_proxy.on(event, limit:-1, inContext:self, withBlock:block)
@@ -152,7 +156,9 @@ module RMExtensions
152
156
  p "CONTEXT:", @weak_object.rmext_object_desc, "UNLISTENING TO:", object.rmext_object_desc
153
157
  end
154
158
  @listenings.removeObject(object)
155
- object.rmext_events_proxy.off_context(@weak_object)
159
+ if object.rmext_events_proxy?
160
+ object.rmext_events_proxy.off_context(@weak_object)
161
+ end
156
162
  end
157
163
  end
158
164
 
@@ -1,3 +1,3 @@
1
1
  module RMExtensions
2
- VERSION = "0.4.2"
2
+ VERSION = "0.4.3"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rm-extensions
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.2
4
+ version: 0.4.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Joe Noon
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-01-22 00:00:00.000000000 Z
11
+ date: 2014-01-25 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: Extensions and helpers for dealing with various areas of rubymotion
14
14
  email: