REFACTOR make method more readable
parent
c8de1b9289
commit
14f42df81c
|
@ -250,6 +250,6 @@ namespace UnityEngine.UI.Extensions
|
|||
}
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
#endregion
|
||||
}
|
||||
}
|
|
@ -314,8 +314,8 @@ namespace UnityEngine.UI.Extensions
|
|||
internal int GetPageforPosition(Vector3 pos)
|
||||
{
|
||||
return _isVertical ?
|
||||
-(int)Math.Round((pos.y - _scrollStartPosition) / _childSize) :
|
||||
-(int)Math.Round((pos.x - _scrollStartPosition) / _childSize);
|
||||
(int)Math.Round((_scrollStartPosition - pos.y) / _childSize) :
|
||||
(int)Math.Round((_scrollStartPosition - pos.x) / _childSize);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
|
Loading…
Reference in New Issue