calling it untag, simply remove the tags in the array of tags

This commit is contained in:
Jay
2015-01-29 16:24:52 +00:00
parent 05a9c76051
commit 15e4070a9b
2 changed files with 14 additions and 1 deletions

View File

@@ -32,6 +32,16 @@ module RubyMotionQuery
end
end
# *Do not* use this, use {RMQ#untag} instead:
# @example
# rmq(my_view).untag(:foo, :bar)
# Do nothing if no tag supplied or tag not present
def untag(*tag_or_tags)
tag_or_tags.each do |tag_name|
tags.delete tag_name
end
end
# Check if this view contains a specific tag
#
# @param tag_name name of tag to check

View File

@@ -21,7 +21,10 @@ module RubyMotionQuery
end
def untag(*tag_or_tags)
puts "this it untag"
selected.each do |view|
view.rmq_data.untag(tag_or_tags)
end
self
end
# @return [RMQ]