Arma Reforger Script API
Loading...
Searching...
No Matches
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
SCR_PooledServerListComponent Interface Reference

Pooled scrollable list with server entries handling. More...

Inheritance diagram for SCR_PooledServerListComponent:
[legend]

Public Member Functions

override void MoveToTop ()
 Move list scroll to top.
 
void SetRooms (array< Room > rooms, int allRoomsCount=-1, bool animate=false)
 
void ShowEmptyRooms ()
 
void UpdateLoadedPage ()
 Call this to verify currently displayed data are loaded.
 
bool IsRoomLoaded (notnull SCR_ServerBrowserEntryComponent entry)
 Return true if room of given entry is loaded Base on widget and current id check if it's in loaded servers batch.
 
array< SCR_ServerBrowserEntryComponentGetRoomEntries ()
 
int GetLoadedPage ()
 
int GetCurrentPage ()
 
- Public Member Functions inherited from SCR_PooledListComponent
override void HandlerAttached (Widget w)
 
void UpdateEntries (bool animated=false)
 Fill entries with data.
 
void UpdateScroll ()
 Update positions of pages and offsets.
 
void FocusFirstAvailableEntry ()
 Find first available entry and focus it.
 
void MoveToTop ()
 Move list scroll to top.
 
void ShowScrollbar (bool show)
 Clip scroll bar to hide.
 
int GetPageEntriesCount ()
 
array< Widget > GetEntryWidgets ()
 
void SetDataEntries (int entriesCount)
 
Widget FirstAvailableEntry ()
 Return first that is visible and enabled.
 
void SetIsListFocused (bool focused)
 
bool IsListFocused ()
 
Widget GetScrollWidget ()
 
ScriptInvokerInt GetOnSetPage ()
 
- Public Member Functions inherited from SCR_ScriptedWidgetComponent
override void HandlerAttached (Widget w)
 
override bool OnClick (Widget w, int x, int y, int button)
 
Widget GetRootWidget ()
 
bool IsVisible ()
 

Protected Member Functions

override Widget CreateEntry (Widget parent)
 Create entry to given page and setup it's behavior

 
override void FillEntry (Widget w)
 Set server entry it's room data to display server info.
 
override void SetCurrentPage (int page)
 Set which page should be currently displayed.
 
bool IsPageLoaded (Widget wPage)
 
void OnServerEntryFocusEnter (SCR_ScriptedWidgetComponent entry)
 Call this when focusing on server entry Show data about server.
 
SCR_ServerBrowserEntryComponent ServerEntryByWidget (Widget entryWidget, out int id)
 
bool IsEntryVisible (Widget entry)
 
- Protected Member Functions inherited from SCR_PooledListComponent
void OnActionUp ()
 Call this when up action is activated.
 
void OnActionDown ()
 Call this when down action is activated.
 
void OnScroll (float scrollY)
 Call this position of scroll is changed.
 
int CurrentPageFromScrollPos (float scrollY)
 Return current page from scroll position.
 
float EntriesOutOfView ()
 How many entries are of view - how many entries can be scrolled.
 
void SetCurrentPage (int page)
 Set which page should be currently displayed.
 
void SetCurrentPageBase (int page)
 Base function for updating current page.
 
void SwitchPages (bool invert, float size, int page)
 Change order of list to fake endless scrolling.
 
void SetupOffsets (int page)
 Set sizes of top and bottom offsets.
 
void AccessingHandlers ()
 Get reference to all needed component for handling.
 
void CreateEntriesWidgets ()
 Create server entries widget.
 
void CreateEntriesWidgetsInPage (Widget parent, int count, out Widget firstEntry, out Widget lastEntry)
 Create entries to selected page and assing first and last entries.
 
Widget CreateEntry (Widget parent)
 Create entry to given page and setup it's behavior

 
void CheckEntrySize ()
 Get size of widget entry used in list.
 
void SetupEntryBehavior (Widget entry)
 Empty functions for setting up widget entry beavhior actions, callbacks, etc.
 
void FillEntry (Widget w)
 Empty function for filling entries with data Override this to fill entries with data.
 
void AnimateEntryOpacity (Widget w, int delay, float animTime, float opacityEnd, float opacityStart=-1)
 Setup opacity animation.
 
void OpacityAnimation (Widget w, int time, float opacityEnd)
 
void ShowEntries (int dataCount)
 Display right entries with right position by scroll.
 
Widget FocusedWidgetFromEntryList ()
 Return if and which entry widget is actually focus.
 

Protected Attributes

ref array< SCR_ServerBrowserEntryComponentm_aRoomEntries = {}
 
ref array< Room > m_aRooms = {}
 
int m_iLoadedPage
 
- Protected Attributes inherited from SCR_PooledListComponent
ResourceName m_sEntry
 
float m_fAnimationAppearTime
 
int m_iPageEntriesCount
 
int m_iPageChangeOffset
 
int m_iAllEntriesCount
 
float m_fListPxHeight = SIZE_UNMEASURED
 
float m_fPagePxHeight = SIZE_UNMEASURED
 
float m_fViewPxHeight = SIZE_UNMEASURED
 
float m_fEntryPxHeight = SIZE_UNMEASURED
 
ScrollLayoutWidget m_wScroll
 
Widget m_wPagesWrap
 
Widget m_wPage0
 
Widget m_wPage1
 
Widget m_wPage0FirstEntry
 
Widget m_wPage0LastEntry
 
Widget m_wPage1FirstEntry
 
Widget m_wPage1LastEntry
 
Widget m_wLastFocused
 
ref array< Widget > m_aEntryWidgets = {}
 
SizeLayoutWidget m_wSizeOffsetTop
 
SizeLayoutWidget m_wSizeOffsetBottom
 
bool m_bPagesInverted
 
int m_iCurrentPage
 
float m_ScrollLastY
 
ref ScriptInvokerInt m_OnSetPage
 
bool m_bIsMeasured = false
 
- Protected Attributes inherited from SCR_ScriptedWidgetComponent
Widget m_wRoot
 

Additional Inherited Members

- Static Public Member Functions inherited from SCR_ScriptedWidgetComponent
static SCR_ScriptedWidgetComponent GetComponent (TypeName componentType, string name, Widget parent, bool searchAllChildren=true)
 Base method for component lookup through the widget library.
 
- Public Attributes inherited from SCR_PooledListComponent
bool m_bIsListFocused
 
- Public Attributes inherited from SCR_ScriptedWidgetComponent
ref ScriptInvoker m_OnClick = new ScriptInvoker
 
- Static Public Attributes inherited from SCR_PooledListComponent
const float SIZE_UNMEASURED = -1
 
const int CHECK_ENTRY_SIZE_DELAY = 100
 
const float ENTRY_OFFSET_UP = 0.1
 
const int ZORDER_OFFSET_TOP
 
const int ZORDER_OFFSET_BOTTOM = 3
 
const string WIDGET_PAGES = "VPages"
 
const string WIDGET_PAGE0 = "VPage0"
 
const string WIDGET_PAGE1 = "VPage1"
 
const string WIDGET_SCROLL_LAYOUT = "ScrollLayout"
 
const string WIDGET_SIZE_OFFSET_TOP = "SizeOffsetTop"
 
const string WIDGET_SIZE_OFFSET_BOTTOM = "SizeOffsetBottom"
 
const string WIDGET_FOCUS_REST = "FocusRest"
 

Detailed Description

Pooled scrollable list with server entries handling.

Member Function Documentation

◆ CreateEntry()

override Widget SCR_PooledServerListComponent.CreateEntry ( Widget  parent)
protected

Create entry to given page and setup it's behavior

Implements SCR_PooledListComponent.

◆ FillEntry()

override void SCR_PooledServerListComponent.FillEntry ( Widget  w)
protected

Set server entry it's room data to display server info.

Parameters
[in]w

Implements SCR_PooledListComponent.

◆ GetCurrentPage()

int SCR_PooledServerListComponent.GetCurrentPage ( )
Returns

◆ GetLoadedPage()

int SCR_PooledServerListComponent.GetLoadedPage ( )
Returns

◆ GetRoomEntries()

array< SCR_ServerBrowserEntryComponent > SCR_PooledServerListComponent.GetRoomEntries ( )
Returns

◆ IsEntryVisible()

bool SCR_PooledServerListComponent.IsEntryVisible ( Widget  entry)
protected
Parameters
[in]entry
Returns
true if entry not pass whole found server list

◆ IsPageLoaded()

bool SCR_PooledServerListComponent.IsPageLoaded ( Widget  wPage)
protected

◆ IsRoomLoaded()

bool SCR_PooledServerListComponent.IsRoomLoaded ( notnull SCR_ServerBrowserEntryComponent  entry)

Return true if room of given entry is loaded Base on widget and current id check if it's in loaded servers batch.

Parameters
[in]entry
Returns

◆ MoveToTop()

override void SCR_PooledServerListComponent.MoveToTop ( )

Move list scroll to top.

Implements SCR_PooledListComponent.

◆ OnServerEntryFocusEnter()

void SCR_PooledServerListComponent.OnServerEntryFocusEnter ( SCR_ScriptedWidgetComponent  entry)
protected

Call this when focusing on server entry Show data about server.

Parameters
[in]entry

◆ ServerEntryByWidget()

SCR_ServerBrowserEntryComponent SCR_PooledServerListComponent.ServerEntryByWidget ( Widget  entryWidget,
out int  id 
)
protected
Parameters
[in]entryWidget
[out]id
Returns
server entry owned by given entry widget root

◆ SetCurrentPage()

override void SCR_PooledServerListComponent.SetCurrentPage ( int  page)
protected

Set which page should be currently displayed.

Implements SCR_PooledListComponent.

◆ SetRooms()

void SCR_PooledServerListComponent.SetRooms ( array< Room >  rooms,
int  allRoomsCount = -1,
bool  animate = false 
)
Parameters
[in]rooms
[in]allRoomsCount
[in]animate

◆ ShowEmptyRooms()

void SCR_PooledServerListComponent.ShowEmptyRooms ( )

◆ UpdateLoadedPage()

void SCR_PooledServerListComponent.UpdateLoadedPage ( )

Call this to verify currently displayed data are loaded.

Member Data Documentation

◆ m_aRoomEntries

ref array<SCR_ServerBrowserEntryComponent> SCR_PooledServerListComponent.m_aRoomEntries = {}
protected

◆ m_aRooms

ref array<Room> SCR_PooledServerListComponent.m_aRooms = {}
protected

◆ m_iLoadedPage

int SCR_PooledServerListComponent.m_iLoadedPage
protected

The documentation for this interface was generated from the following file: