summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorAki <nthirtyone@gmail.com>2017-09-04 21:14:36 +0200
committerAki <nthirtyone@gmail.com>2017-09-04 21:14:36 +0200
commit3f353552da6bb67aa1e7018399e62c7eace9b8c2 (patch)
tree336895102fea72e191af30d8743d96cbc1f46638
parent87e0b1eb45117ced574df07534f6666470f218a7 (diff)
downloadroflnauts-3f353552da6bb67aa1e7018399e62c7eace9b8c2.zip
roflnauts-3f353552da6bb67aa1e7018399e62c7eace9b8c2.tar.gz
roflnauts-3f353552da6bb67aa1e7018399e62c7eace9b8c2.tar.bz2
Clearing up getLocked, docs changes
-rw-r--r--not/Selector.lua7
1 files changed, 3 insertions, 4 deletions
diff --git a/not/Selector.lua b/not/Selector.lua
index fa00286..9083b24 100644
--- a/not/Selector.lua
+++ b/not/Selector.lua
@@ -49,22 +49,21 @@ function Selector:setIndex (index)
end
--- Returns selected item's value.
--- @return item selected from list
+-- @return item selected from the list
function Selector:getSelected ()
return self.list[self.index]
end
--- Checks if selection is locked and returns item's value.
--- Nil returning part is there to clarify method's behaviour.
--- @return nil if not locked, value from list if locked
+-- @return item selected from the list if locked, nil otherwise
function Selector:getLocked ()
if self.locked then
return self:getSelected()
end
- return nil
end
--- Checks if Selected value is unique in group's scope.
+-- @return boolean answering question
function Selector:isUnique ()
if self.group then
-- In this case next is used to determine if table returned by call is empty.