axmol/cocos/scripting/lua-bindings/auto/api/PageView.lua

192 lines
6.5 KiB
Lua
Raw Normal View History

2014-03-10 14:04:58 +08:00
--------------------------------
-- @module PageView
-- @extend Layout
-- @parent_module ccui
--------------------------------
-- brief Query the custom scroll threshold of the PageView.<br>
-- return Custom scroll threshold in float.
-- @function [parent=#PageView] getCustomScrollThreshold
-- @param self
-- @return float#float ret (return value: float)
2014-03-10 14:04:58 +08:00
--------------------------------
-- Gets current displayed page index.<br>
-- return current page index.
2014-03-10 14:04:58 +08:00
-- @function [parent=#PageView] getCurPageIndex
-- @param self
-- @return long#long ret (return value: long)
--------------------------------
-- Add a widget as a page of PageView in a given index.<br>
-- param widget Widget to be added to pageview.<br>
-- param pageIdx A given index.<br>
-- param forceCreate If `forceCreate` is true and `widget` isn't exists, pageview would create a default page and add it.
2014-03-10 14:04:58 +08:00
-- @function [parent=#PageView] addWidgetToPage
-- @param self
-- @param #ccui.Widget widget
-- @param #long pageIdx
-- @param #bool forceCreate
-- @return PageView#PageView self (return value: ccui.PageView)
2014-03-10 14:04:58 +08:00
--------------------------------
-- brief Query whether use user defined scroll page threshold or not.<br>
-- return True if using custom scroll threshold, false otherwise.
-- @function [parent=#PageView] isUsingCustomScrollThreshold
-- @param self
-- @return bool#bool ret (return value: bool)
2014-03-10 14:04:58 +08:00
--------------------------------
-- Jump to a page with a given index without scrolling.<br>
-- This is the different between scrollToPage.<br>
-- param index A given index in PageView. Index start from 0 to pageCount -1.
-- @function [parent=#PageView] setCurPageIndex
2014-03-10 14:04:58 +08:00
-- @param self
-- @param #long index
-- @return PageView#PageView self (return value: ccui.PageView)
2014-03-10 14:04:58 +08:00
--------------------------------
-- Remove a page of PageView.<br>
-- param page Page to be removed.
2014-03-10 14:04:58 +08:00
-- @function [parent=#PageView] removePage
-- @param self
-- @param #ccui.Layout page
-- @return PageView#PageView self (return value: ccui.PageView)
2014-03-10 14:04:58 +08:00
--------------------------------
-- brief Add a page turn callback to PageView, then when one page is turning, the callback will be called.<br>
-- param callback A page turning callback.
-- @function [parent=#PageView] addEventListener
-- @param self
-- @param #function callback
-- @return PageView#PageView self (return value: ccui.PageView)
--------------------------------
-- brief Set using user defined scroll page threshold or not.<br>
-- If you set it to false, then the default scroll threshold is pageView.width / 2<br>
-- param flag True if using custom scroll threshold, false otherwise.
-- @function [parent=#PageView] setUsingCustomScrollThreshold
-- @param self
-- @param #bool flag
-- @return PageView#PageView self (return value: ccui.PageView)
--------------------------------
-- brief If you don't specify the value, the pageView will turn page when scrolling at the half width of a page.<br>
-- param threshold A threshold in float.
-- @function [parent=#PageView] setCustomScrollThreshold
-- @param self
-- @param #float threshold
-- @return PageView#PageView self (return value: ccui.PageView)
2014-03-10 14:04:58 +08:00
--------------------------------
-- Insert a page into PageView at a given index.<br>
-- param page Page to be inserted.<br>
-- param idx A given index.
2014-03-10 14:04:58 +08:00
-- @function [parent=#PageView] insertPage
-- @param self
-- @param #ccui.Layout page
-- @param #int idx
-- @return PageView#PageView self (return value: ccui.PageView)
2014-03-10 14:04:58 +08:00
--------------------------------
-- Scroll to a page with a given index.<br>
-- param idx A given index in the PageView. Index start from 0 to pageCount -1.
2014-03-10 14:04:58 +08:00
-- @function [parent=#PageView] scrollToPage
-- @param self
-- @param #long idx
-- @return PageView#PageView self (return value: ccui.PageView)
2014-03-10 14:04:58 +08:00
--------------------------------
-- brief Get a page at a given index<br>
-- param index A given index.<br>
-- return A layout pointer in PageView container.
-- @function [parent=#PageView] getPage
-- @param self
-- @param #long index
-- @return Layout#Layout ret (return value: ccui.Layout)
2014-03-10 14:04:58 +08:00
--------------------------------
-- Remove a page at a given index of PageView.<br>
-- param index A given index.
2014-03-10 14:04:58 +08:00
-- @function [parent=#PageView] removePageAtIndex
-- @param self
-- @param #long index
-- @return PageView#PageView self (return value: ccui.PageView)
2014-03-10 14:04:58 +08:00
--------------------------------
-- brief Get all the pages in the PageView.<br>
-- return A vector of Layout pionters.
2014-03-10 14:04:58 +08:00
-- @function [parent=#PageView] getPages
-- @param self
-- @return array_table#array_table ret (return value: array_table)
--------------------------------
-- brief Remove all pages of the PageView.
2014-03-10 14:04:58 +08:00
-- @function [parent=#PageView] removeAllPages
-- @param self
-- @return PageView#PageView self (return value: ccui.PageView)
2014-03-10 14:04:58 +08:00
--------------------------------
-- Insert a page into the end of PageView.<br>
-- param page Page to be inserted.
2014-03-10 14:04:58 +08:00
-- @function [parent=#PageView] addPage
-- @param self
-- @param #ccui.Layout page
-- @return PageView#PageView self (return value: ccui.PageView)
2014-03-10 14:04:58 +08:00
--------------------------------
-- Create an empty PageView.<br>
-- return A PageView instance.
2014-03-10 14:04:58 +08:00
-- @function [parent=#PageView] create
-- @param self
-- @return PageView#PageView ret (return value: ccui.PageView)
--------------------------------
--
2014-03-10 14:04:58 +08:00
-- @function [parent=#PageView] createInstance
-- @param self
-- @return Ref#Ref ret (return value: cc.Ref)
--------------------------------
--
-- @function [parent=#PageView] getLayoutType
-- @param self
-- @return int#int ret (return value: int)
--------------------------------
--
-- @function [parent=#PageView] getDescription
-- @param self
-- @return string#string ret (return value: string)
--------------------------------
--
-- @function [parent=#PageView] update
-- @param self
-- @param #float dt
-- @return PageView#PageView self (return value: ccui.PageView)
--------------------------------
--
-- @function [parent=#PageView] init
-- @param self
-- @return bool#bool ret (return value: bool)
--------------------------------
--
-- @function [parent=#PageView] setLayoutType
-- @param self
-- @param #int type
-- @return PageView#PageView self (return value: ccui.PageView)
2014-03-10 14:04:58 +08:00
--------------------------------
-- Default constructor<br>
-- js ctor<br>
-- lua new
2014-03-10 14:04:58 +08:00
-- @function [parent=#PageView] PageView
-- @param self
-- @return PageView#PageView self (return value: ccui.PageView)
2014-03-10 14:04:58 +08:00
return nil