スクロール位置の制御を行うコンポーネント.
More...
|
void | OnValueChanged (Action< float > callback) |
| スクロール位置が変化したときのコールバックを設定します. More...
|
|
void | OnSelectionChanged (Action< int > callback) |
| 選択位置が変化したときのコールバックを設定します. More...
|
|
void | SetTotalCount (int totalCount) |
| アイテムの総数を設定します. More...
|
|
void | ScrollTo (float position, float duration, Action onComplete=null) |
| 指定した位置まで移動します. More...
|
|
void | ScrollTo (float position, float duration, Ease easing, Action onComplete=null) |
| 指定した位置まで移動します. More...
|
|
void | ScrollTo (float position, float duration, EasingFunction easingFunction, Action onComplete=null) |
| 指定した位置まで移動します. More...
|
|
void | JumpTo (int index) |
| 指定したインデックスの位置までジャンプします. More...
|
|
MovementDirection | GetMovementDirection (int sourceIndex, int destIndex) |
| sourceIndex から destIndex に移動する際の移動方向を返します. スクロール範囲が無制限に設定されている場合は, 最短距離の移動方向を返します. More...
|
|
|
float | ViewportSize [get] |
| ビューポートのサイズ. More...
|
|
ScrollDirection | ScrollDirection [get] |
| スクロール方向. More...
|
|
MovementType | MovementType [get, set] |
| コンテンツがスクロール範囲を越えて移動するときに使用する挙動. More...
|
|
float | Elasticity [get, set] |
| コンテンツがスクロール範囲を越えて移動するときに使用する弾力性の量. More...
|
|
float | ScrollSensitivity [get, set] |
| ViewportSize の端から端まで Drag したときのスクロール位置の変化量. More...
|
|
bool | Inertia [get, set] |
| 慣性を使用するかどうか. true を指定すると慣性が有効に, false を指定すると慣性が無効になります. More...
|
|
float | DecelerationRate [get, set] |
| スクロールの減速率. Inertia が true の場合のみ有効です. More...
|
|
bool | SnapEnabled [get, set] |
| true ならスナップし, false ならスナップしません. More...
|
|
bool | Draggable [get, set] |
| Drag 入力を受付けるかどうか. More...
|
|
Scrollbar | Scrollbar [get] |
| スクロールバーのオブジェクト. More...
|
|
float | Position [get, set] |
| 現在のスクロール位置. More...
|
|
スクロール位置の制御を行うコンポーネント.
Definition at line 13 of file Scroller.cs.
◆ GetMovementDirection()
MovementDirection UnityEngine.UI.Extensions.Scroller.GetMovementDirection |
( |
int |
sourceIndex, |
|
|
int |
destIndex |
|
) |
| |
sourceIndex から destIndex に移動する際の移動方向を返します. スクロール範囲が無制限に設定されている場合は, 最短距離の移動方向を返します.
- Parameters
-
sourceIndex | 移動元のインデックス. |
destIndex | 移動先のインデックス. |
- Returns
Definition at line 297 of file Scroller.cs.
◆ JumpTo()
void UnityEngine.UI.Extensions.Scroller.JumpTo |
( |
int |
index | ) |
|
指定したインデックスの位置までジャンプします.
- Parameters
-
Definition at line 279 of file Scroller.cs.
◆ OnSelectionChanged()
void UnityEngine.UI.Extensions.Scroller.OnSelectionChanged |
( |
Action< int > |
callback | ) |
|
選択位置が変化したときのコールバックを設定します.
- Parameters
-
callback | 選択位置が変化したときのコールバック. |
◆ OnValueChanged()
void UnityEngine.UI.Extensions.Scroller.OnValueChanged |
( |
Action< float > |
callback | ) |
|
スクロール位置が変化したときのコールバックを設定します.
- Parameters
-
callback | スクロール位置が変化したときのコールバック. |
◆ ScrollTo() [1/3]
void UnityEngine.UI.Extensions.Scroller.ScrollTo |
( |
float |
position, |
|
|
float |
duration, |
|
|
Action |
onComplete = null |
|
) |
| |
指定した位置まで移動します.
- Parameters
-
position | スクロール位置. 0f ~ totalCount - 1f の範囲. |
duration | 移動にかける秒数. |
onComplete | 移動が完了した際に呼び出されるコールバック. |
◆ ScrollTo() [2/3]
void UnityEngine.UI.Extensions.Scroller.ScrollTo |
( |
float |
position, |
|
|
float |
duration, |
|
|
Ease |
easing, |
|
|
Action |
onComplete = null |
|
) |
| |
指定した位置まで移動します.
- Parameters
-
position | スクロール位置. 0f ~ totalCount - 1f の範囲. |
duration | 移動にかける秒数. |
easing | 移動に使用するイージング. |
onComplete | 移動が完了した際に呼び出されるコールバック. |
◆ ScrollTo() [3/3]
void UnityEngine.UI.Extensions.Scroller.ScrollTo |
( |
float |
position, |
|
|
float |
duration, |
|
|
EasingFunction |
easingFunction, |
|
|
Action |
onComplete = null |
|
) |
| |
指定した位置まで移動します.
- Parameters
-
position | スクロール位置. 0f ~ totalCount - 1f の範囲. |
duration | 移動にかける秒数. |
easingFunction | 移動に使用するイージング関数. |
onComplete | 移動が完了した際に呼び出されるコールバック. |
Definition at line 252 of file Scroller.cs.
◆ SetTotalCount()
void UnityEngine.UI.Extensions.Scroller.SetTotalCount |
( |
int |
totalCount | ) |
|
アイテムの総数を設定します.
totalCount を元に最大スクロール位置を計算します.
- Parameters
-
◆ Start()
override void UnityEngine.UI.Extensions.Scroller.Start |
( |
| ) |
|
|
protected |
◆ DecelerationRate
float UnityEngine.UI.Extensions.Scroller.DecelerationRate |
|
getset |
◆ Draggable
bool UnityEngine.UI.Extensions.Scroller.Draggable |
|
getset |
◆ Elasticity
float UnityEngine.UI.Extensions.Scroller.Elasticity |
|
getset |
コンテンツがスクロール範囲を越えて移動するときに使用する弾力性の量.
Definition at line 47 of file Scroller.cs.
◆ Inertia
bool UnityEngine.UI.Extensions.Scroller.Inertia |
|
getset |
慣性を使用するかどうか. true
を指定すると慣性が有効に, false
を指定すると慣性が無効になります.
Definition at line 69 of file Scroller.cs.
◆ MovementType
MovementType UnityEngine.UI.Extensions.Scroller.MovementType |
|
getset |
コンテンツがスクロール範囲を越えて移動するときに使用する挙動.
Definition at line 36 of file Scroller.cs.
◆ Position
float UnityEngine.UI.Extensions.Scroller.Position |
|
getset |
◆ Scrollbar
Scrollbar UnityEngine.UI.Extensions.Scroller.Scrollbar |
|
get |
◆ ScrollDirection
◆ ScrollSensitivity
float UnityEngine.UI.Extensions.Scroller.ScrollSensitivity |
|
getset |
◆ SnapEnabled
bool UnityEngine.UI.Extensions.Scroller.SnapEnabled |
|
getset |
true
ならスナップし, false
ならスナップしません.
スナップを有効にすると, 慣性でスクロールが止まる直前に最寄りのセルへ移動します.
Definition at line 99 of file Scroller.cs.
◆ ViewportSize
float UnityEngine.UI.Extensions.Scroller.ViewportSize |
|
get |
The documentation for this class was generated from the following file: