Dayz 1.25
Dayz Code Explorer by KGB
Загрузка...
Поиск...
Не найдено
Класс LayoutHolder
+ Граф наследования:LayoutHolder:

Защищенные члены

void OnDropReceivedFromHeader (Widget w, int x, int y, Widget receiver)
 
void DraggingOver (Widget w, int x, int y, Widget receiver)
 
void DraggingOverHeader (Widget w, int x, int y, Widget receiver)
 
void UpdateSpacer ()
 
Header GetHeader ()
 
void SetHeader (Header header)
 
void CheckHeaderDragability ()
 
void Container (LayoutHolder parent)
 
Container GetFocusedContainer ()
 
Container GetContainer (int index)
 
void SetFocusedContainer (Container cont)
 
SlotsIcon GetFocusedSlotsIcon ()
 
int GetActiveIndex ()
 
void SetActiveIndex (int index)
 
ScrollWidget GetScrollWidget ()
 
void UpdateRadialIcon ()
 
void SetSlotIcon (SlotsIcon icon)
 
void SetDefaultFocus (bool while_micromanagment_mode=false)
 
void SetLastFocus ()
 
void Unfocus ()
 
void MoveGridCursor (int direction)
 
void ScrollToActiveContainer ()
 
void CheckScrollbarVisibility ()
 
void Open ()
 
void Close ()
 
bool IsOpened ()
 
void SetOpenForSlotIcon (bool open, SlotsIcon icon=null)
 
void Toggle ()
 
float GetFocusedContainerHeight (bool contents=false)
 
float GetFocusedContainerYPos (bool contents=false)
 
float GetFocusedContainerYScreenPos (bool contents=false)
 
int Count ()
 
bool SelectItem ()
 
bool Select ()
 
bool OnSelectButton ()
 
bool Combine ()
 
bool TransferItemToVicinity ()
 
bool TransferItem ()
 
bool InspectItem ()
 
bool SplitItem ()
 
bool EquipItem ()
 
bool CanOpenCloseContainer ()
 
bool CanOpenCloseContainerEx (EntityAI focusedEntity)
 
bool CanSplit ()
 
bool CanSplitEx (EntityAI focusedEntity)
 
bool CanDrop ()
 
bool CanDropEx (EntityAI focusedEntity)
 
bool CanSwapOrTakeToHands ()
 
bool CanSwapOrTakeToHandsEx (EntityAI focusedEntity)
 
bool CanEquip ()
 
bool CanEquipEx (EntityAI focusedEntity)
 
bool CanTakeToInventory ()
 
bool CanTakeToInventoryEx (EntityAI focusedEntity)
 
bool CanCombine ()
 
bool CanCombineEx (EntityAI focusedEntity)
 
bool CanCombineAmmo ()
 
bool CanAddToQuickbarEx (EntityAI focusedEntity)
 
bool AddItemToQuickbarRadial (EntityAI itemToAssign)
 
bool IsEmpty ()
 
bool IsItemActive ()
 
bool IsItemWithQuantityActive ()
 
EntityAI GetFocusedItem ()
 
EntityAI GetFocusedContainerEntity ()
 
int GetColumnCount ()
 
void SetColumnCount (int count)
 
int GetFocusedColumn ()
 
void SetFocusedColumn (int column)
 
override void UpdateInterval ()
 
override void SetLastActive ()
 
override void SetFirstActive ()
 
override void SetActive (bool active)
 
void UnfocusAll ()
 
void UnfocusGrid ()
 
bool IsLastIndex ()
 
bool IsFirstIndex ()
 
bool IsFirstContainerFocused ()
 
bool IsLastContainerFocused ()
 
void ResetFocusedContainer ()
 
void SetNextActive ()
 
void SetPreviousActive (bool force=false)
 
void SetNextRightActive ()
 
void SetNextLeftActive ()
 
void SetSameLevelNextActive ()
 
void SetSameLevelPreviousActive ()
 
void RecomputeOpenedContainers ()
 
override void SetLayoutName ()
 
void Insert (LayoutHolder container, int pos=-1, bool immedUpdate=true)
 
void Remove (LayoutHolder container)
 
LayoutHolder Get (int x)
 
override void Refresh ()
 
void UpdateBodySpacers ()
 
void HideContent (bool force_hide=false)
 
void ShowContent (bool force_show=false)
 
void SetForceShow (bool value)
 
override void UpdateSelectionIcons ()
 
void ExpandCollapseContainer ()
 

Защищенные данные

ref array< ref LayoutHolderm_Body
 
ref array< LayoutHolderm_OpenedContainers
 
int m_ActiveIndex = 0
 
bool m_LastIndex
 
bool m_Closed
 
Container m_FocusedContainer
 
float m_PrevAlpha
 
const int ITEMS_IN_ROW = 8
 
int m_ColumnCount
 
int m_FocusedColumn = 0
 
bool m_ForcedHide
 
bool m_ForcedShow
 
SlotsIcon m_SlotIcon
 
EntityAI m_Entity
 
const int SORT_ATTACHMENTS_OWN = 1
 
const int SORT_CARGO_OWN = 2
 
const int SORT_ATTACHMENTS_NEXT_OFFSET = 2
 
const int SORT_CARGO_NEXT_OFFSET = 3
 

Подробное описание

Методы

◆ AddItemToQuickbarRadial()

bool AddItemToQuickbarRadial ( EntityAI itemToAssign)
inlineprotected
622 {
624 {
627 dpi = player.GetDayZPlayerInventory();
628
629 if (itemToAssign && dpi && !dpi.IsProcessing())
630 {
631 RadialQuickbarMenu.SetItemToAssign(itemToAssign);
632
633 //open radial quickbar menu
634 if (!GetGame().GetUIManager().IsMenuOpen(MENU_RADIAL_QUICKBAR))
635 {
636 RadialQuickbarMenu.OpenMenu(GetGame().GetUIManager().FindMenu(MENU_INVENTORY));
637 }
638 }
639 return true;
640 }
641 return false;
642 }
PlayerBase GetPlayer()
Definition ModifierBase.c:47
Definition DayZPlayerInventory.c:112
bool CanAddToQuickbarEx(EntityAI focusedEntity)
Definition Container.c:604
Definition EntityAI.c:95
Definition PlayerBaseClient.c:2
proto native CGame GetGame()
const int MENU_INVENTORY
Definition constants.c:170
const int MENU_RADIAL_QUICKBAR
Definition constants.c:188

Перекрестные ссылки GetGame(), GetPlayer(), MENU_INVENTORY и MENU_RADIAL_QUICKBAR.

◆ CanAddToQuickbarEx()

bool CanAddToQuickbarEx ( EntityAI focusedEntity)
inlineprotected
605 {
606 if ( ItemManager.GetInstance().IsMicromanagmentMode() )
607 return false;
608
609 if (focusedEntity)
610 {
612 if (focusedEntity.GetHierarchyRootPlayer() == player)
613 {
614 return true;
615 }
616 }
617
618 return false;
619 }
Definition ItemManager.c:2
static ItemManager GetInstance()
Definition ItemManager.c:283

Перекрестные ссылки GetGame(), ItemManager::GetInstance() и GetPlayer().

◆ CanCombine()

bool CanCombine ( )
inlineprotected
568 {
570 if (focusedEntity)
571 {
573 return GetFocusedContainer().CanCombineEx(focusedEntity);
574
576 }
577
578 return false;
579 }
Definition Building.c:6
EntityAI GetFocusedItem()
Definition Container.c:663
Container GetFocusedContainer()
Definition Container.c:48
bool CanCombineEx(EntityAI focusedEntity)
Definition Container.c:581

Перекрестные ссылки Container::GetFocusedItem().

◆ CanCombineAmmo()

bool CanCombineAmmo ( )
inlineprotected
598 {
599 if( GetFocusedContainer() )
601 return false;
602 }
override bool CanCombineAmmo()
Definition CargoContainer.c:779

◆ CanCombineEx()

bool CanCombineEx ( EntityAI focusedEntity)
inlineprotected
582 {
583 if (ItemManager.GetInstance().IsMicromanagmentMode())
584 return false;
585
586 if (focusedEntity)
587 {
588 EntityAI entityInHands = PlayerBase.Cast(GetGame().GetPlayer()).GetItemInHands();
590 {
592 }
593 }
594 return false;
595 }
static int GetCombinationFlags(EntityAI entity1, EntityAI entity2)
Definition ItemManager.c:804

Перекрестные ссылки ItemManager::GetCombinationFlags(), GetGame(), ItemManager::GetInstance() и GetPlayer().

◆ CanDrop()

bool CanDrop ( )
inlineprotected
421 {
423 if (focusedEntity)
424 {
426 return GetFocusedContainer().CanDropEx(focusedEntity);
427
428 return CanDropEx(focusedEntity);
429
430 }
431
432 return false;
433 }
bool CanDropEx(EntityAI focusedEntity)
Definition Container.c:435

Перекрестные ссылки Container::GetFocusedItem().

◆ CanDropEx()

bool CanDropEx ( EntityAI focusedEntity)
inlineprotected
436 {
437 if ( ItemManager.GetInstance().IsMicromanagmentMode() )
438 return false;
439
440 if (focusedEntity)
441 {
443
444 if (player)
445 {
446 return player.CanDropEntity(focusedEntity);
447 }
448 }
449 return false;
450 }

Перекрестные ссылки GetGame(), ItemManager::GetInstance() и GetPlayer().

◆ CanEquip()

bool CanEquip ( )
inlineprotected
497 {
499 if (focusedEntity)
500 {
502 return GetFocusedContainer().CanEquipEx(focusedEntity);
503
505 }
506
507 return false;
508 }
bool CanEquipEx(EntityAI focusedEntity)
Definition Container.c:510

Перекрестные ссылки Container::GetFocusedItem().

◆ CanEquipEx()

bool CanEquipEx ( EntityAI focusedEntity)
inlineprotected
511 {
512 if ( ItemManager.GetInstance().IsMicromanagmentMode() )
513 return false;
514
515 bool found = false;
516 if (focusedEntity)
517 {
520 found = player.GetInventory().FindFreeLocationFor(focusedEntity,FindInventoryLocationType.ATTACHMENT,il);
521
522 if (!found)
523 {
524 for (int i = 0; i < focusedEntity.GetInventory().GetSlotIdCount(); i++)
525 {
526 int slot_id = focusedEntity.GetInventory().GetSlotId(i);
527 EntityAI slot_item = player.GetInventory().FindAttachment( slot_id );
528 if (slot_item && player.GetInventory().CanSwapEntitiesEx( focusedEntity, slot_item ))
529 {
530 found = true;
531 break;
532 }
533
534 }
535 }
536 }
537 return found;
538 }
FindInventoryLocationType
flags for searching locations in inventory
Definition InventoryLocation.c:16
InventoryLocation.
Definition InventoryLocation.c:28

Перекрестные ссылки GetGame(), ItemManager::GetInstance() и GetPlayer().

◆ CanOpenCloseContainer()

bool CanOpenCloseContainer ( )
inlineprotected
373 {
374 if ( ItemManager.GetInstance().IsMicromanagmentMode() )
375 return false;
376
378 if (focusedEntity)
379 {
381 return GetFocusedContainer().CanOpenCloseContainerEx(focusedEntity);
382
384 }
385
386 return false;
387 }
bool CanOpenCloseContainerEx(EntityAI focusedEntity)
Definition Container.c:389

Перекрестные ссылки Container::GetFocusedItem() и ItemManager::GetInstance().

◆ CanOpenCloseContainerEx()

bool CanOpenCloseContainerEx ( EntityAI focusedEntity)
inlineprotected
390 {
391 return false;
392 }

◆ CanSplit()

bool CanSplit ( )
inlineprotected
395 {
397 if (focusedEntity)
398 {
400 return GetFocusedContainer().CanSplitEx(focusedEntity);
401
403 }
404
405 return false;
406 }
bool CanSplitEx(EntityAI focusedEntity)
Definition Container.c:408

Перекрестные ссылки Container::GetFocusedItem().

◆ CanSplitEx()

bool CanSplitEx ( EntityAI focusedEntity)
inlineprotected
409 {
410 if ( ItemManager.GetInstance().IsMicromanagmentMode() )
411 return false;
412
413 if (focusedEntity)
414 {
415 return focusedEntity.CanBeSplit();
416 }
417 return false;
418 }

Перекрестные ссылки ItemManager::GetInstance().

◆ CanSwapOrTakeToHands()

bool CanSwapOrTakeToHands ( )
inlineprotected
453 {
455 if (focusedEntity)
456 {
458 return GetFocusedContainer().CanSwapOrTakeToHandsEx(focusedEntity);
459
461 }
462
463 return false;
464 }
bool CanSwapOrTakeToHandsEx(EntityAI focusedEntity)
Definition Container.c:466

Перекрестные ссылки Container::GetFocusedItem().

◆ CanSwapOrTakeToHandsEx()

bool CanSwapOrTakeToHandsEx ( EntityAI focusedEntity)
inlineprotected
467 {
468 if ( ItemManager.GetInstance().IsMicromanagmentMode() )
469 return false;
470
471 if (focusedEntity)
472 {
474 EntityAI entityInHands = player.GetItemInHands();
475 if (entityInHands)
476 {
478
480 {
482 }
483 else
484 {
485 return true;
486 }
487 }
488 else
489 {
490 return player.GetInventory().CanAddEntityIntoHands(focusedEntity);
491 }
492 }
493 return false;
494 }
script counterpart to engine's class Inventory
Definition Inventory.c:79
static bool CanForceSwapEntitiesEx(notnull EntityAI item1, InventoryLocation item1_dst, notnull EntityAI item2, out InventoryLocation item2_dst)
Definition Inventory.c:665
static bool CanSwapEntitiesEx(notnull EntityAI item1, notnull EntityAI item2)
Definition Inventory.c:628

Перекрестные ссылки GameInventory::CanForceSwapEntitiesEx(), GameInventory::CanSwapEntitiesEx(), GetGame(), ItemManager::GetInstance() и GetPlayer().

◆ CanTakeToInventory()

bool CanTakeToInventory ( )
inlineprotected
541 {
543 if (focusedEntity)
544 {
546 return GetFocusedContainer().CanTakeToInventoryEx(focusedEntity);
547
549 }
550
551 return false;
552 }
bool CanTakeToInventoryEx(EntityAI focusedEntity)
Definition Container.c:554

Перекрестные ссылки Container::GetFocusedItem().

◆ CanTakeToInventoryEx()

bool CanTakeToInventoryEx ( EntityAI focusedEntity)
inlineprotected
555 {
556 if ( ItemManager.GetInstance().IsMicromanagmentMode() )
557 return false;
558
559 if (focusedEntity)
560 {
562 return player.GetInventory().CanAddEntityToInventory(focusedEntity,FindInventoryLocationType.CARGO);
563 }
564 return false;
565 }

Перекрестные ссылки GetGame(), ItemManager::GetInstance() и GetPlayer().

◆ CheckHeaderDragability()

void CheckHeaderDragability ( )
protected

◆ CheckScrollbarVisibility()

void CheckScrollbarVisibility ( )
inlineprotected
185 {
187 if (sw)
188 {
189 if (!sw.IsScrollbarVisible())
190 {
191 sw.VScrollToPos01(0.0);
192 }
193 else if (sw.GetVScrollPos01() > 1.0)
194 {
195 sw.VScrollToPos01(1.0);
196 }
197 }
198 }
ScrollWidget GetScrollWidget()
Definition Container.c:92

◆ Close()

void Close ( )
inlineprotected
207 {
208 m_Closed = true;
210 }
override void UpdateSelectionIcons()
Definition Container.c:1179
bool m_Closed
Definition Container.c:7

◆ Combine()

bool Combine ( )
inlineprotected
331 {
332 if( GetFocusedContainer() )
333 return GetFocusedContainer().Combine();
334 return true;
335 }
override bool Combine()
Definition CargoContainer.c:932

◆ Container()

void Container ( LayoutHolder parent)
inlineprotected
36 {
39 m_PrevAlpha = m_RootWidget.GetAlpha();
41 m_ForcedHide = false;
42 m_ForcedShow = false;
43
44 m_ActiveIndex = 0;
45 m_IsActive = false;
46 }
bool m_IsActive
Definition ModifierBase.c:20
ref Widget m_RootWidget[MAX_SIMULTANIOUS_PLAYERS]
Definition PluginRemotePlayerDebugClient.c:14
int m_ActiveIndex
Definition Container.c:5
ref array< ref LayoutHolder > m_Body
Definition Container.c:3
float m_PrevAlpha
Definition Container.c:9
SlotsIcon m_SlotIcon
Definition Container.c:19
ref array< LayoutHolder > m_OpenedContainers
Definition Container.c:4
bool m_ForcedHide
Definition Container.c:16
bool m_ForcedShow
Definition Container.c:17

Перекрестные ссылки m_IsActive и m_RootWidget.

◆ Count()

◆ DraggingOver()

void DraggingOver ( Widget w,
int x,
int y,
Widget receiver )
protected

◆ DraggingOverHeader()

void DraggingOverHeader ( Widget w,
int x,
int y,
Widget receiver )
protected

◆ EquipItem()

bool EquipItem ( )
inlineprotected
366 {
367 if( GetFocusedContainer() )
369 return false;
370 }
override bool EquipItem()
Definition CargoContainer.c:835

◆ ExpandCollapseContainer()

void ExpandCollapseContainer ( )
inlineprotected
1184{}

◆ Get()

LayoutHolder Get ( int x)
inlineprotected
1119 {
1120 return m_Body.Get( x );
1121 }
Icon x

Перекрестные ссылки x.

Используется в PluginBase::Broadcast(), PluginBase::BroadcastFloat(), PluginBase::BroadcastInt(), PluginBase::BroadcastParam() и PluginBase::BroadcastString().

◆ GetActiveIndex()

int GetActiveIndex ( )
inlineprotected
83 {
84 return m_ActiveIndex;
85 }

◆ GetColumnCount()

int GetColumnCount ( )
inlineprotected
681 {
682 return m_ColumnCount;
683 }
int m_ColumnCount
Definition Container.c:13

◆ GetContainer()

Container GetContainer ( int index)
inlineprotected
58 {
59 if (index < m_Body.Count())
60 {
61 return Container.Cast( m_Body[index] );
62 }
63 return null;
64 }
Definition CargoContainer.c:3

◆ GetFocusedColumn()

int GetFocusedColumn ( )
inlineprotected
691 {
692 return m_FocusedColumn;
693 }
int m_FocusedColumn
Definition Container.c:15

◆ GetFocusedContainer()

Container GetFocusedContainer ( )
inlineprotected
49 {
51 {
53 }
54 return null;
55 }

◆ GetFocusedContainerEntity()

EntityAI GetFocusedContainerEntity ( )
inlineprotected
673 {
675 if( GetFocusedContainer() )
676 item = GetFocusedContainer().GetFocusedContainerEntity();
677 return item;
678 }

◆ GetFocusedContainerHeight()

float GetFocusedContainerHeight ( bool contents = false)
inlineprotected
249 {
250 float x, y, result;
251 if( GetFocusedContainer() )
253 else if( GetRootWidget() )
254 GetRootWidget().GetScreenSize( x, y );
255
256 result = y;
257
258 if ( m_ActiveIndex == 0 )
259 {
260 if ( GetHeader() )
261 {
262 GetHeader().GetRootWidget().GetScreenSize( x, y );
263 result += y;
264 }
265 }
266 return result;
267 }
Icon y
override float GetFocusedContainerHeight(bool contents=false)
Definition CargoContainer.c:434
Header GetHeader()

Перекрестные ссылки GetFocusedContainerHeight(), Container::GetHeader(), x и y.

Используется в Container::GetFocusedContainerHeight() и GetFocusedContainerHeight().

◆ GetFocusedContainerYPos()

float GetFocusedContainerYPos ( bool contents = false)
inlineprotected
270 {
271 float x, y;
272 if( GetFocusedContainer() )
274 else if( GetRootWidget() )
275 GetRootWidget().GetPos( x, y );
276
277 return y;
278 }
override float GetFocusedContainerYPos(bool contents=false)
Definition CargoContainer.c:444

Перекрестные ссылки GetFocusedContainerYPos(), x и y.

Используется в Container::GetFocusedContainerYPos() и GetFocusedContainerYPos().

◆ GetFocusedContainerYScreenPos()

float GetFocusedContainerYScreenPos ( bool contents = false)
inlineprotected
281 {
282 float x, y, result;
283 if( GetFocusedContainer() )
285 else if( GetRootWidget() )
286 GetRootWidget().GetScreenPos( x, y );
287
288
289 result = y;
290
291 if ( m_ActiveIndex == 0 )
292 {
293 if ( GetHeader() )
294 {
295 GetHeader().GetRootWidget().GetScreenPos( x, y );
296 result = y;
297 }
298 }
299 return result;
300 }
override float GetFocusedContainerYScreenPos(bool contents=false)
Definition CargoContainer.c:454

Перекрестные ссылки GetFocusedContainerYScreenPos(), Container::GetHeader(), x и y.

Используется в Container::GetFocusedContainerYScreenPos() и GetFocusedContainerYScreenPos().

◆ GetFocusedItem()

EntityAI GetFocusedItem ( )
inlineprotected
664 {
666 if( GetFocusedContainer() )
668
669 return item;
670 }
override EntityAI GetFocusedItem()
Definition CargoContainer.c:720

◆ GetFocusedSlotsIcon()

SlotsIcon GetFocusedSlotsIcon ( )
inlineprotected
73 {
75 if (c)
76 {
77 return c.GetFocusedSlotsIcon();
78 }
79 return null;
80 }

◆ GetHeader()

Header GetHeader ( )
protected

◆ GetScrollWidget()

ScrollWidget GetScrollWidget ( )
inlineprotected
93 {
94 return null;
95 }

◆ HideContent()

void HideContent ( bool force_hide = false)
inlineprotected
1147 {
1148 if( !m_ForcedHide )
1149 {
1151 }
1152 for(int i = 0; i < m_Body.Count(); i++)
1153 {
1154 if( m_Body.Get( i ) )
1155 m_Body.Get( i ).OnHide();
1156 }
1157 }

◆ Insert()

void Insert ( LayoutHolder container,
int pos = -1,
bool immedUpdate = true )
inlineprotected
1074 {
1075 if ( pos > -1 && pos < m_Body.Count() )
1076 {
1077 if ( pos <= m_ActiveIndex )
1078 m_ActiveIndex++;
1079 m_Body.InsertAt( container, pos );
1080 }
1081 else
1082 m_Body.Insert( container );
1083
1084 if ( immedUpdate )
1085 Refresh();
1086 }
override void Refresh()
Definition Container.c:1123

Перекрестные ссылки Container::Refresh().

◆ InspectItem()

bool InspectItem ( )
inlineprotected
352 {
353 if( GetFocusedContainer() )
354 return GetFocusedContainer().InspectItem();
355 return false;
356 }

Используется в Icon::MouseClick().

◆ IsEmpty()

bool IsEmpty ( )
inlineprotected
645 {
646 return m_OpenedContainers.Count() == 0;
647 }

◆ IsFirstContainerFocused()

bool IsFirstContainerFocused ( )
inlineprotected
869 {
870 return m_ActiveIndex == 0;
871 }

◆ IsFirstIndex()

bool IsFirstIndex ( )
inlineprotected
864 {
865 return m_ActiveIndex == 0;
866 }

◆ IsItemActive()

bool IsItemActive ( )
inlineprotected
650 {
651 if( GetFocusedContainer() )
653 return false;
654 }
override bool IsItemActive()
Definition CargoContainer.c:748

◆ IsItemWithQuantityActive()

bool IsItemWithQuantityActive ( )
inlineprotected
657 {
658 if( GetFocusedContainer() )
660 return false;
661 }
override bool IsItemWithQuantityActive()
Definition CargoContainer.c:758

◆ IsLastContainerFocused()

bool IsLastContainerFocused ( )
inlineprotected
874 {
875 return m_ActiveIndex >= ( m_OpenedContainers.Count() - 1 );
876 }

◆ IsLastIndex()

bool IsLastIndex ( )
inlineprotected
859 {
860 return m_ActiveIndex == ( m_OpenedContainers.Count() - 1 );
861 }

◆ IsOpened()

bool IsOpened ( )
inlineprotected
213 {
214 return !m_Closed;
215 }

◆ MoveGridCursor()

void MoveGridCursor ( int direction)
inlineprotected
130 {
131 if ( direction == Direction.UP )
132 {
134 }
135 else if ( direction == Direction.DOWN )
136 {
138 }
139 else if ( direction == Direction.RIGHT )
140 {
142 }
143 else if ( direction == Direction.LEFT )
144 {
146 }
147
149
150 Inventory.GetInstance().UpdateConsoleToolbar();
151 }
Direction
Definition Inventory.c:19
void Inventory(LayoutHolder parent)
Definition Inventory.c:76
void SetPreviousActive(bool force=false)
Definition Container.c:924
void SetNextLeftActive()
Definition Container.c:974
void SetNextRightActive()
Definition Container.c:960
void SetNextActive()
Definition Container.c:888

Перекрестные ссылки Inventory(), Container::SetNextActive(), Container::SetNextLeftActive(), Container::SetNextRightActive() и Container::SetPreviousActive().

◆ OnDropReceivedFromHeader()

void OnDropReceivedFromHeader ( Widget w,
int x,
int y,
Widget receiver )
protected

◆ OnSelectButton()

bool OnSelectButton ( )
inlineprotected
322 {
324 {
325 return GetFocusedContainer().OnSelectButton();
326 }
327 return false;
328 }

◆ Open()

void Open ( )
inlineprotected
201 {
202 m_Closed = false;
204 }

◆ RecomputeOpenedContainers()

void RecomputeOpenedContainers ( )
inlineprotected
1021 {
1022 m_OpenedContainers.Clear();
1023 int i;
1024 bool need_reset_focus = false;
1025 Container c;
1026 for (i = 0; i < m_Body.Count(); i++)
1027 {
1028 c = Container.Cast(m_Body.Get( i ));
1029 if ( c )
1030 {
1031 c.RecomputeOpenedContainers();
1032 if (c.IsDisplayable() && c.IsVisible())
1033 {
1034 m_OpenedContainers.Insert(c);
1035 }
1036 else if (c.IsActive())
1037 {
1038 c.SetActive(false);
1039 need_reset_focus = true;
1040 }
1041
1042 }
1043 }
1044
1045 //In case of removing focused container or change order of containers
1046 if (IsActive())
1047 {
1049 {
1050 need_reset_focus = true;
1051 for (i = 0; i < m_OpenedContainers.Count(); i++)
1052 {
1054 {
1055 need_reset_focus = false;
1056 m_ActiveIndex = i;
1057 }
1058 }
1059 }
1060
1061 if (need_reset_focus)
1062 {
1064 }
1065 }
1066 }
bool IsActive()
Definition ModifierBase.c:130
override void SetFirstActive()
Definition Container.c:755

Перекрестные ссылки IsActive().

◆ Refresh()

override void Refresh ( )
inlineprotected
1124 {
1125 for ( int i = 0; i < m_Body.Count(); i++ )
1126 {
1127 if( m_Body.Get( i ) )
1128 m_Body.Get( i ).Refresh();
1129 }
1130 }

◆ Remove()

void Remove ( LayoutHolder container)
inlineprotected
1089 {
1090 if( m_Body )
1091 {
1092 int index = m_Body.Find( container );
1093 if( index > -1 )
1094 {
1096 if (index > -1)
1097 {
1098 if (index <= m_ActiveIndex)
1099 {
1101 {
1102 SetPreviousActive( true );
1103 }
1104 else
1105 {
1106 m_ActiveIndex--;
1107 }
1108 }
1109 m_OpenedContainers.RemoveItem( container );
1110 }
1111 m_Body.RemoveItem( container );
1112 }
1113 }
1114
1115 Refresh();
1116 }

Перекрестные ссылки Container::Refresh() и Container::SetPreviousActive().

◆ ResetFocusedContainer()

void ResetFocusedContainer ( )
inlineprotected
879 {
880 if ( GetFocusedContainer() )
881 {
882 GetFocusedContainer().ResetFocusedContainer();
883 }
884
885 m_ActiveIndex == 0;
886 }

◆ ScrollToActiveContainer()

void ScrollToActiveContainer ( )
inlineprotected
154 {
156 if (sw)
157 {
158 float x, y, y_s;
159
160 sw.GetScreenPos( x, y );
161 sw.GetScreenSize( x, y_s );
162 float f_y,f_h;
163 float amount;
166
167 float next_pos = f_y + f_h;
168
169 if (next_pos > ( y + y_s ))
170 {
171 amount = sw.GetVScrollPos() + next_pos - ( y + y_s ) + 2;
172 sw.VScrollToPos( amount );
173 }
174 else if (f_y < y)
175 {
176 amount = sw.GetVScrollPos() + f_y - y - 2;
177 sw.VScrollToPos(amount);
178 }
179
180 //CheckScrollbarVisibility();
181 }
182 }
float GetFocusedContainerHeight(bool contents=false)
Definition Container.c:248
float GetFocusedContainerYScreenPos(bool contents=false)
Definition Container.c:280

Перекрестные ссылки Container::GetFocusedContainerHeight(), Container::GetFocusedContainerYScreenPos(), x и y.

◆ Select()

bool Select ( )
inlineprotected
315 {
316 if( GetFocusedContainer() )
317 return GetFocusedContainer().Select();
318 return false;
319 }
override bool Select()
Definition CargoContainer.c:867

◆ SelectItem()

bool SelectItem ( )
inlineprotected
308 {
309 if( GetFocusedContainer() )
311 return false;
312 }
override bool SelectItem()
Definition CargoContainer.c:852

◆ SetActive()

override void SetActive ( bool active)
inlineprotected
786 {
787 if (!active)
788 {
789 HideOwnedTooltip();
790 }
791
792 if (!active && !m_IsActive)
793 return;
794
795 super.SetActive( active );
796 if ( GetHeader() )
797 {
799 }
800
801 if (m_MainWidget.FindAnyWidget("SelectedContainer"))
802 {
803 m_MainWidget.FindAnyWidget("SelectedContainer").Show(active);
804 }
805
806 Container c;
807 if( active )
808 {
809
811 if( m_OpenedContainers.Count() )
812 {
814 if (c)
815 {
816 c.SetActive(active);
817 }
818 }
819 }
820 else
821 {
823 if (c)
824 {
826 }
827 Unfocus();
828 m_ActiveIndex = 0;
829 m_FocusedColumn = 0;
830 }
831 }
override void SetActive(bool active)
Definition CargoContainer.c:742
override void SetActive(bool active)
Definition Header.c:64
void SetDefaultFocus(bool while_micromanagment_mode=false)
Definition Container.c:110
void Unfocus()
Definition Container.c:125

Перекрестные ссылки Container::GetHeader(), m_IsActive, Container::SetDefaultFocus() и Container::Unfocus().

◆ SetActiveIndex()

void SetActiveIndex ( int index)
inlineprotected
88 {
90 }

◆ SetColumnCount()

void SetColumnCount ( int count)
inlineprotected
686 {
688 }

◆ SetDefaultFocus()

void SetDefaultFocus ( bool while_micromanagment_mode = false)
inlineprotected
111 {
112 m_ActiveIndex = 0;
113 }

◆ SetFirstActive()

override void SetFirstActive ( )
inlineprotected
756 {
757 if (!m_IsActive)
758 {
759 SetActive(true);
760 }
761 else
762 {
763 if (m_OpenedContainers.Count())
764 {
767 {
768 for (int i = 1; i < m_OpenedContainers.Count(); i++)
769 {
771 {
772 m_OpenedContainers[i].SetActive(false);
773 }
774 }
775 m_OpenedContainers[m_ActiveIndex].SetActive(true);
776 }
777 else
778 {
779 m_OpenedContainers[m_ActiveIndex].SetFirstActive();
780 }
781 }
782 }
783 }
void SetActive()
Definition TrapBase.c:437

Перекрестные ссылки IsActive(), m_IsActive, SetActive() и Container::SetDefaultFocus().

◆ SetFocusedColumn()

void SetFocusedColumn ( int column)
inlineprotected
696 {
698 }

◆ SetFocusedContainer()

void SetFocusedContainer ( Container cont)
inlineprotected
68 {
70 }
Container m_FocusedContainer
Definition Container.c:8

◆ SetForceShow()

void SetForceShow ( bool value)
inlineprotected
1175 {
1177 }

◆ SetHeader()

void SetHeader ( Header header)
protected

◆ SetLastActive()

override void SetLastActive ( )
inlineprotected
712 {
713 if (m_IsActive)
714 {
715 m_IsActive = true;
716 if (m_OpenedContainers.Count())
717 {
718 SetLastFocus();
720 {
721 for (int i = 0; i < m_OpenedContainers.Count() - 1; i++)
722 {
724 {
725 m_OpenedContainers[i].SetActive(false);
726 }
727 }
728 m_OpenedContainers[m_ActiveIndex].SetLastActive();
729 }
730 else
731 {
732 m_OpenedContainers[m_ActiveIndex].SetLastActive();
733 }
734 }
735 }
736 else
737 {
738 m_IsActive = true;
739 if (GetHeader())
740 {
742 }
743 SetLastFocus();
744 if (m_OpenedContainers.Count())
745 {
747 if (c)
748 {
749 c.SetLastActive( );
750 }
751 }
752 }
753 }
void SetLastFocus()
Definition Container.c:115

Перекрестные ссылки Container::GetHeader(), IsActive(), m_IsActive и Container::SetLastFocus().

◆ SetLastFocus()

void SetLastFocus ( )
inlineprotected
116 {
117 m_ActiveIndex = 0;
118 m_FocusedColumn = 0;
119 if ( m_OpenedContainers.Count() > 0 )
120 {
121 m_ActiveIndex = m_OpenedContainers.Count() - 1;
122 }
123 }

◆ SetLayoutName()

override void SetLayoutName ( )
inlineprotected
1069 {
1070 m_LayoutName = WidgetLayoutName.Container;
1071 }
Definition WidgetLayoutName.c:2
const string Container
Definition WidgetLayoutName.c:47

Перекрестные ссылки WidgetLayoutName::Container.

Используется в ScriptedWidgetEventHandler::LayoutHolder().

◆ SetNextActive()

void SetNextActive ( )
inlineprotected
889 {
890 HideOwnedTooltip();
891
893 if (m_OpenedContainers.Count())
894 {
896 }
897
898 if (active && active.IsActive())
899 {
900 active.SetNextActive();
901 }
902 if (!active || !active.IsActive())
903 {
906 {
908
910 next.SetActive(true);
911 }
912 else if (Container.Cast( GetParent() ))
913 {
914 SetActive(false);
915 }
916 else
917 {
918 SetActive(false);
920 }
921 }
922 }
bool IsLastContainerFocused()
Definition Container.c:873
proto native Widget GetParent()
Get parent of the Effect.
Definition Effect.c:405

Перекрестные ссылки GetParent() и SetActive().

◆ SetNextLeftActive()

void SetNextLeftActive ( )
inlineprotected
975 {
977 if (m_OpenedContainers.Count())
978 {
980 }
981
982 if (active)
983 {
984 active.SetNextLeftActive();
985 }
986 }

◆ SetNextRightActive()

void SetNextRightActive ( )
inlineprotected
961 {
963 if (m_OpenedContainers.Count())
964 {
966 }
967
968 if (active)
969 {
970 active.SetNextRightActive();
971 }
972 }

◆ SetOpenForSlotIcon()

void SetOpenForSlotIcon ( bool open,
SlotsIcon icon = null )
inlineprotected
218 {
219 if (!icon)
220 {
222 }
223
224 if (icon)
225 {
226 icon.GetRadialIcon().Show(open);
227 icon.GetRadialIconClosed().Show(!open);
228 }
229 /*else
230 {
231 ErrorEx("Dbg No Icon");
232 }*/
233 }

◆ SetPreviousActive()

void SetPreviousActive ( bool force = false)
inlineprotected
925 {
926 HideOwnedTooltip();
928 if (m_OpenedContainers.Count())
929 {
931 }
932
933 if (active && active.IsActive())
934 {
935 active.SetPreviousActive();
936 }
937
938 if (!active || !active.IsActive())
939 {
942 {
944
946 prev.SetLastActive();
947 }
948 else if (Container.Cast( GetParent() ))
949 {
950 SetActive(false);
951 }
952 else
953 {
954 SetActive(false);
956 }
957 }
958 }
bool IsFirstContainerFocused()
Definition Container.c:868
override void SetLastActive()
Definition Container.c:711

Перекрестные ссылки GetParent(), SetActive() и Container::SetLastActive().

◆ SetSameLevelNextActive()

void SetSameLevelNextActive ( )
inlineprotected
989 {
992 active.SetActive(false);
993
995 if (m_ActiveIndex > m_OpenedContainers.Count() - 1)
996 {
997 m_ActiveIndex = 0;
998 }
999
1001 active.SetActive(true);
1002 }

◆ SetSameLevelPreviousActive()

void SetSameLevelPreviousActive ( )
inlineprotected
1005 {
1008 active.SetActive(false);
1009
1010 m_ActiveIndex--;
1011 if (m_ActiveIndex < 0)
1012 {
1013 m_ActiveIndex = m_OpenedContainers.Count() - 1;
1014 }
1015
1017 active.SetActive(true);
1018 }

◆ SetSlotIcon()

void SetSlotIcon ( SlotsIcon icon)
inlineprotected
106 {
108 }

◆ ShowContent()

void ShowContent ( bool force_show = false)
inlineprotected
1160 {
1161 if( force_show )
1162 m_ForcedHide = false;
1163
1164 if( !m_ForcedHide )
1165 {
1166 for(int i = 0; i < m_Body.Count(); i++)
1167 {
1168 if( m_Body.Get( i ) )
1169 m_Body.Get( i ).OnShow();
1170 }
1171 }
1172 }

◆ SplitItem()

bool SplitItem ( )
inlineprotected
359 {
360 if( GetFocusedContainer() )
362 return false;
363 }
override bool SplitItem()
Definition CargoContainer.c:810

◆ Toggle()

void Toggle ( )
inlineprotected
236 {
237 if (IsOpened())
238 {
239 Close();
240 }
241 else
242 {
243 Open();
244 }
246 }
void Open()
Definition Container.c:200
void Close()
Definition Container.c:206
bool IsOpened()
Definition Container.c:212
void SetOpenForSlotIcon(bool open, SlotsIcon icon=null)
Definition Container.c:217

Перекрестные ссылки Container::Close(), IsOpened() и Container::Open().

◆ TransferItem()

bool TransferItem ( )
inlineprotected
345 {
346 if( GetFocusedContainer() )
348 return false;
349 }
override bool TransferItem()
Definition CargoContainer.c:793

◆ TransferItemToVicinity()

bool TransferItemToVicinity ( )
inlineprotected
338 {
339 if( GetFocusedContainer() )
341 return false;
342 }
override bool TransferItemToVicinity()
Definition CargoContainer.c:578

◆ Unfocus()

void Unfocus ( )
inlineprotected
126 {
127 }

◆ UnfocusAll()

void UnfocusAll ( )
inlineprotected
834 {
835 for ( int i = 0; i < Count(); i++ )
836 {
837 for ( int j = 0; j < ITEMS_IN_ROW; j++ )
838 {
840 if (Get(i) && Get(i).GetMainWidget())
841 Get( i ).GetMainWidget().GetUserData(icon);
842
843 if (icon)
844 icon.GetCursorWidget().Show( false );
845 }
846 }
847 }
array< ref PlayerStatBase > Get()
Definition PlayerStatsPCO.c:103
int Count()
Definition Container.c:302
const int ITEMS_IN_ROW
Definition Container.c:10
Definition SlotsIcon.c:2

Перекрестные ссылки Count, Get() и ITEMS_IN_ROW.

◆ UnfocusGrid()

void UnfocusGrid ( )
inlineprotected
850 {
851 if( GetFocusedContainer() )
852 {
853 m_FocusedColumn = 0;
855 }
856 }
override void UnfocusAll()
Definition CargoContainer.c:622

◆ UpdateBodySpacers()

void UpdateBodySpacers ( )
inlineprotected
1133 {
1134 for ( int i = 0; i < m_Body.Count(); i++ )
1135 {
1136 Container c = Container.Cast( m_Body.Get( i ) );
1137 if( c && c.IsInherited( Container ) )
1138 {
1139 c.UpdateSpacer();
1140 }
1141 }
1142
1143 UpdateSpacer();
1144 }
void UpdateSpacer()

◆ UpdateInterval()

override void UpdateInterval ( )
inlineprotected
701 {
702 for ( int i = 0; i < m_Body.Count(); i++ )
703 {
704 if ( m_Body.Get( i ) )
705 m_Body.Get( i ).UpdateInterval();
706 }
707
709 }
void CheckHeaderDragability()

Перекрестные ссылки Container::CheckHeaderDragability().

◆ UpdateRadialIcon()

void UpdateRadialIcon ( )
inlineprotected
98 {
99 if ( m_SlotIcon )
100 {
101 m_SlotIcon.GetRadialIconPanel().Show( false );
102 }
103 }
Widget GetRadialIconPanel()
Definition SlotsIcon.c:302

Перекрестные ссылки SlotsIcon::GetRadialIconPanel().

◆ UpdateSelectionIcons()

override void UpdateSelectionIcons ( )
inlineprotected
1180 {
1181 m_Parent.UpdateSelectionIcons();
1182 }
Widget m_Parent
Definition SizeToChild.c:92

Перекрестные ссылки m_Parent.

◆ UpdateSpacer()

void UpdateSpacer ( )
protected

Поля

◆ ITEMS_IN_ROW

const int ITEMS_IN_ROW = 8
protected

◆ m_ActiveIndex

int m_ActiveIndex = 0
protected

◆ m_Body

ref array<ref LayoutHolder> m_Body
protected

◆ m_Closed

bool m_Closed
protected

◆ m_ColumnCount

int m_ColumnCount
protected

◆ m_Entity

EntityAI m_Entity
protected

◆ m_FocusedColumn

int m_FocusedColumn = 0
protected

◆ m_FocusedContainer

Container m_FocusedContainer
protected

◆ m_ForcedHide

bool m_ForcedHide
protected

◆ m_ForcedShow

bool m_ForcedShow
protected

◆ m_LastIndex

bool m_LastIndex
protected

◆ m_OpenedContainers

ref array<LayoutHolder> m_OpenedContainers
protected

◆ m_PrevAlpha

float m_PrevAlpha
protected

◆ m_SlotIcon

SlotsIcon m_SlotIcon
protected

◆ SORT_ATTACHMENTS_NEXT_OFFSET

const int SORT_ATTACHMENTS_NEXT_OFFSET = 2
protected

◆ SORT_ATTACHMENTS_OWN

const int SORT_ATTACHMENTS_OWN = 1
protected

◆ SORT_CARGO_NEXT_OFFSET

const int SORT_CARGO_NEXT_OFFSET = 3
protected

◆ SORT_CARGO_OWN

const int SORT_CARGO_OWN = 2
protected

Объявления и описания членов класса находятся в файле: