Click or drag to resize

BaseParams Class

Input params to be passed to Init

This can be used Monobehaviour's field and exposed via inspector (most common case)

Or can be manually constructed, depending on what's easier in your context

Inheritance Hierarchy

Namespace:  Com.ForbiddenByte.OSA.Core
Assembly:  Assembly-CSharp (in Assembly-CSharp.dll) Version: 0.0.0.0
Syntax
C#
[SerializableAttribute]
public class BaseParams

The BaseParams type exposes the following members.

Constructors
  NameDescription
Public methodBaseParams
It's here just so the class can be serialized by Unity when used as a MonoBehaviour's field
Top
Properties
  NameDescription
Public propertycontent Obsolete.
Public propertyContent
Public propertycontentGravity Obsolete.
Public propertycontentPadding Obsolete.
Public propertyContentPadding
Padding for the 4 edges of the content panel
Public propertycontentSpacing Obsolete.
Public propertyContentSpacing
Spacing between items (horizontal if the ScrollView is horizontal. else, vertical)
Public propertyDefaultItemSize
The size of all items for which the size is not specified
Public propertyDragEnabled
Allows you to click and drag the content directly (enabled by default). The ForwardDragToParents is not affected by this. NOTE: Do not change this property during a drag event (i.e. when IsDragging is true)
Public propertyForwardDragToParents
You'll probably need this if the scroll view is a child of another scroll view. If enabled, the first parent that implements all of IInitializePotentialDragHandler, IBeginDragHandler, IDragHandler and IEndDragHandler will be informed about these events when they occur on this scroll view. This works both with Unity's ScrollRect and OSA
Public propertygalleryEffectAmount Obsolete.
Public propertygalleryEffectViewportPivot Obsolete.
Public propertyGravity
The effect of this property can only be seen when the content size is smaller than the viewport, case in which there are 3 possibilities: place the content at the start, middle or end. FROM_PIVOT doesn't change the content's position (it'll be preserved from the way you aligned it in edit-mode)
Public propertyIsHorizontal
Public propertyloopItems Obsolete.
Public propertyorientation Obsolete.
Public propertyOrientation
Public propertyrecycleBinCapacity Obsolete.
Public propertyscrollbar Obsolete.
Public propertyScrollbar
Public propertyScrollEnabled
Allows you to scroll by mouse wheel or other similar input devices (enabled by default). The ForwardDragToParents is not affected by this. NOTE: Do not change this property during a drag event (i.e. when IsDragging is true)
Public propertyScrollSensivity
The sensivity to the Mouse's scrolling wheel or similar input methods. Not related to dragging or scrolling via scrollbar
Public propertyScrollViewRT
Public propertySnapper
Public propertyTransientSpeedBetweenDrags
If enabled, multiple drags in the same direction will lead to greater speeds
Public propertyviewport Obsolete.
Public propertyViewport
If null, ScrollViewRT is considered to be the viewport
Top
Methods
  NameDescription
Public methodGetAbstractNormalizedScrollPosition Obsolete.
Public methodInitIfNeeded
Called internally in Init and every time the scrollview's size changes. This makes sure the content and viewport have valid values. It can also be overridden to initialize custom data
Public methodMigrateFieldsToVersion4
Public methodUpdateContentPivotFromGravityType
Top
Fields
  NameDescription
Public fieldeffects
Public fieldoptimization
Top
Version Information

Optimized ScrollView Adapter

Supported in: 4.1
See Also