DDraceNetwork Docs
menus.h
Go to the documentation of this file.
1/* (c) Magnus Auvinen. See licence.txt in the root of the distribution for more information. */
2/* If you are missing that file, acquire a complete release at teeworlds.com. */
3#ifndef GAME_CLIENT_COMPONENTS_MENUS_H
4#define GAME_CLIENT_COMPONENTS_MENUS_H
5
6#include <base/types.h>
7#include <base/vmath.h>
8
9#include <chrono>
10#include <deque>
11#include <unordered_set>
12#include <vector>
13
14#include <engine/console.h>
15#include <engine/demo.h>
16#include <engine/friends.h>
19#include <engine/shared/http.h>
20#include <engine/shared/jobs.h>
22#include <engine/textrender.h>
23
27#include <game/client/render.h>
28#include <game/client/ui.h>
29#include <game/voting.h>
30
32
34{
36};
37
38// component to fetch keypresses, override all other input
40{
41public:
42 const void *m_pKeyReaderId;
48 virtual int Sizeof() const override { return sizeof(*this); }
49 virtual bool OnInput(const IInput::CEvent &Event) override;
50};
51
53{
58};
59
60class CMenus : public CComponent
61{
72
73 int DoButton_FontIcon(CButtonContainer *pButtonContainer, const char *pText, int Checked, const CUIRect *pRect, int Corners = IGraphics::CORNER_ALL, bool Enabled = true);
74 int DoButton_Toggle(const void *pId, int Checked, const CUIRect *pRect, bool Active);
75 int DoButton_Menu(CButtonContainer *pButtonContainer, const char *pText, int Checked, const CUIRect *pRect, const char *pImageName = nullptr, int Corners = IGraphics::CORNER_ALL, float Rounding = 5.0f, float FontFactor = 0.0f, ColorRGBA Color = ColorRGBA(1.0f, 1.0f, 1.0f, 0.5f));
76 int DoButton_MenuTab(CButtonContainer *pButtonContainer, const char *pText, int Checked, const CUIRect *pRect, int Corners, SUIAnimator *pAnimator = nullptr, const ColorRGBA *pDefaultColor = nullptr, const ColorRGBA *pActiveColor = nullptr, const ColorRGBA *pHoverColor = nullptr, float EdgeRounding = 10.0f, const SCommunityIcon *pCommunityIcon = nullptr);
77
78 int DoButton_CheckBox_Common(const void *pId, const char *pText, const char *pBoxText, const CUIRect *pRect);
79 int DoButton_CheckBox(const void *pId, const char *pText, int Checked, const CUIRect *pRect);
80 int DoButton_CheckBoxAutoVMarginAndSet(const void *pId, const char *pText, int *pValue, CUIRect *pRect, float VMargin);
81 int DoButton_CheckBox_Number(const void *pId, const char *pText, int Checked, const CUIRect *pRect);
82
83 ColorHSLA DoLine_ColorPicker(CButtonContainer *pResetId, float LineSize, float LabelSize, float BottomMargin, CUIRect *pMainRect, const char *pText, unsigned int *pColorValue, ColorRGBA DefaultColor, bool CheckBoxSpacing = true, int *pCheckBoxValue = nullptr, bool Alpha = false);
84 ColorHSLA DoButton_ColorPicker(const CUIRect *pRect, unsigned int *pHslaColor, bool Alpha);
85 void DoLaserPreview(const CUIRect *pRect, ColorHSLA OutlineColor, ColorHSLA InnerColor, const int LaserType);
86 int DoButton_GridHeader(const void *pId, const char *pText, int Checked, const CUIRect *pRect);
87 int DoButton_Favorite(const void *pButtonId, const void *pParentId, bool Checked, const CUIRect *pRect);
88
89 int DoKeyReader(const void *pId, const CUIRect *pRect, int Key, int ModifierCombination, int *pNewModifierCombination);
90
91 void DoSettingsControlsButtons(int Start, int Stop, CUIRect View);
92
95 void DoJoystickBar(const CUIRect *pRect, float Current, float Tolerance, bool Active);
96
99
101
102 // menus_settings_assets.cpp
103public:
105 {
107
108 char m_aName[50];
109
110 bool operator<(const SCustomItem &Other) const { return str_comp(m_aName, Other.m_aName) < 0; }
111 };
112
114 {
116 {
118 };
120 };
121
122 struct SCustomGame : public SCustomItem
123 {
124 };
125
127 {
128 };
129
131 {
132 };
133
134 struct SCustomHud : public SCustomItem
135 {
136 };
137
139 {
140 };
141
142protected:
143 std::vector<SCustomEntities> m_vEntitiesList;
144 std::vector<SCustomGame> m_vGameList;
145 std::vector<SCustomEmoticon> m_vEmoticonList;
146 std::vector<SCustomParticle> m_vParticlesList;
147 std::vector<SCustomHud> m_vHudList;
148 std::vector<SCustomExtras> m_vExtrasList;
149
150 bool m_IsInit = false;
151
152 static void LoadEntities(struct SCustomEntities *pEntitiesItem, void *pUser);
153 static int EntitiesScan(const char *pName, int IsDir, int DirType, void *pUser);
154
155 static int GameScan(const char *pName, int IsDir, int DirType, void *pUser);
156 static int EmoticonsScan(const char *pName, int IsDir, int DirType, void *pUser);
157 static int ParticlesScan(const char *pName, int IsDir, int DirType, void *pUser);
158 static int HudScan(const char *pName, int IsDir, int DirType, void *pUser);
159 static int ExtrasScan(const char *pName, int IsDir, int DirType, void *pUser);
160
161 static void ConchainAssetsEntities(IConsole::IResult *pResult, void *pUserData, IConsole::FCommandCallback pfnCallback, void *pCallbackUserData);
162 static void ConchainAssetGame(IConsole::IResult *pResult, void *pUserData, IConsole::FCommandCallback pfnCallback, void *pCallbackUserData);
163 static void ConchainAssetParticles(IConsole::IResult *pResult, void *pUserData, IConsole::FCommandCallback pfnCallback, void *pCallbackUserData);
164 static void ConchainAssetEmoticons(IConsole::IResult *pResult, void *pUserData, IConsole::FCommandCallback pfnCallback, void *pCallbackUserData);
165 static void ConchainAssetHud(IConsole::IResult *pResult, void *pUserData, IConsole::FCommandCallback pfnCallback, void *pCallbackUserData);
166 static void ConchainAssetExtras(IConsole::IResult *pResult, void *pUserData, IConsole::FCommandCallback pfnCallback, void *pCallbackUserData);
167
168 void ClearCustomItems(int CurTab);
169
175
176 bool m_JoinTutorial = false;
179
180 char m_aNextServer[256];
181
182 // images
184 {
185 char m_aName[64];
188 };
189 std::vector<CMenuImage> m_vMenuImages;
190 static int MenuImageScan(const char *pName, int IsDir, int DirType, void *pUser);
191 const CMenuImage *FindMenuImage(const char *pName);
192
193 // loading
195 {
196 public:
197 std::chrono::nanoseconds m_LastRender{0};
200 };
202
203 //
205 char m_aMessageBody[512];
207
210
211 // generic popups
212 typedef void (CMenus::*FPopupButtonCallback)();
214 {
215 // do nothing
216 }
217 enum
218 {
219 BUTTON_CONFIRM = 0, // confirm / yes / close / ok
220 BUTTON_CANCEL, // cancel / no
222 };
223 char m_aPopupTitle[128];
225 struct
226 {
227 char m_aLabel[64];
231
232 void PopupMessage(const char *pTitle, const char *pMessage,
233 const char *pButtonLabel, int NextPopup = POPUP_NONE, FPopupButtonCallback pfnButtonCallback = &CMenus::DefaultButtonCallback);
234 void PopupConfirm(const char *pTitle, const char *pMessage,
235 const char *pConfirmButtonLabel, const char *pCancelButtonLabel,
236 FPopupButtonCallback pfnConfirmButtonCallback = &CMenus::DefaultButtonCallback, int ConfirmNextPopup = POPUP_NONE,
237 FPopupButtonCallback pfnCancelButtonCallback = &CMenus::DefaultButtonCallback, int CancelNextPopup = POPUP_NONE);
238
239 // some settings
240 static float ms_ButtonHeight;
243
244 // for settings
251
252 // 0.7 skins
253 bool m_CustomSkinMenu = false;
259
260 // for map download popup
264
265 // for password popup
267
268 // for call vote
274
275 // demo
276 enum
277 {
281 };
282
284 {
290 time_t m_Date;
291
297
298 int NumMarkers() const
299 {
301 }
302
303 int Length() const
304 {
306 }
307
308 unsigned Size() const
309 {
311 }
312
313 bool operator<(const CDemoItem &Other) const
314 {
315 if(!str_comp(m_aFilename, ".."))
316 return true;
317 if(!str_comp(Other.m_aFilename, ".."))
318 return false;
319 if(m_IsDir && !Other.m_IsDir)
320 return true;
321 if(!m_IsDir && Other.m_IsDir)
322 return false;
323
324 const CDemoItem &Left = g_Config.m_BrDemoSortOrder ? Other : *this;
325 const CDemoItem &Right = g_Config.m_BrDemoSortOrder ? *this : Other;
326
327 if(g_Config.m_BrDemoSort == SORT_DEMONAME)
328 return str_comp_filenames(Left.m_aFilename, Right.m_aFilename) < 0;
329 if(g_Config.m_BrDemoSort == SORT_DATE)
330 return Left.m_Date < Right.m_Date;
331
332 if(!Other.m_InfosLoaded)
333 return m_InfosLoaded;
334 if(!m_InfosLoaded)
335 return !Other.m_InfosLoaded;
336
337 if(g_Config.m_BrDemoSort == SORT_LENGTH)
338 return Left.Length() < Right.Length();
339
340 // Unknown sort
341 return true;
342 }
343 };
344
350#if defined(CONF_VIDEORECORDER)
352#endif
357 int m_Speed = 4;
358 bool m_StartPaused = false;
359
360 std::chrono::nanoseconds m_DemoPopulateStartTime{0};
361
362 void DemolistOnUpdate(bool Reset);
363 static int DemolistFetchCallback(const CFsFileInfo *pInfo, int IsDir, int StorageType, void *pUser);
364
365 // friends
367 {
374 // skin
379
380 public:
382 CFriendItem(const CFriendInfo *pFriendInfo) :
383 m_pServerInfo(nullptr),
384 m_IsPlayer(false),
385 m_IsAfk(false),
386 m_CustomSkinColors(false),
389 {
390 str_copy(m_aName, pFriendInfo->m_aName);
391 str_copy(m_aClan, pFriendInfo->m_aClan);
393 m_aSkin[0] = '\0';
394 }
395 CFriendItem(const CServerInfo::CClient &CurrentClient, const CServerInfo *pServerInfo) :
396 m_pServerInfo(pServerInfo),
397 m_FriendState(CurrentClient.m_FriendState),
398 m_IsPlayer(CurrentClient.m_Player),
399 m_IsAfk(CurrentClient.m_Afk),
403 {
404 str_copy(m_aName, CurrentClient.m_aName);
405 str_copy(m_aClan, CurrentClient.m_aClan);
406 str_copy(m_aSkin, CurrentClient.m_aSkin);
407 }
408
409 const char *Name() const { return m_aName; }
410 const char *Clan() const { return m_aClan; }
411 const CServerInfo *ServerInfo() const { return m_pServerInfo; }
412 int FriendState() const { return m_FriendState; }
413 bool IsPlayer() const { return m_IsPlayer; }
414 bool IsAfk() const { return m_IsAfk; }
415 const char *Skin() const { return m_aSkin; }
416 bool CustomSkinColors() const { return m_CustomSkinColors; }
419
420 const void *ListItemId() const { return &m_aName; }
421 const void *RemoveButtonId() const { return &m_FriendState; }
422 const void *CommunityTooltipId() const { return &m_IsPlayer; }
423 const void *SkinTooltipId() const { return &m_aSkin; }
424
425 bool operator<(const CFriendItem &Other) const
426 {
427 const int Result = str_comp_nocase(m_aName, Other.m_aName);
428 return Result < 0 || (Result == 0 && str_comp_nocase(m_aClan, Other.m_aClan) < 0);
429 }
430 };
431
432 enum
433 {
438 };
439 std::vector<CFriendItem> m_avFriends[NUM_FRIEND_TYPES];
440 const CFriendItem *m_pRemoveFriend = nullptr;
441
442 // found in menus.cpp
443 void Render();
444 void RenderPopupFullscreen(CUIRect Screen);
445 void RenderPopupConnecting(CUIRect Screen);
446 void RenderPopupLoading(CUIRect Screen);
447#if defined(CONF_VIDEORECORDER)
449#endif
450 void RenderMenubar(CUIRect Box, IClient::EClientState ClientState);
451 void RenderNews(CUIRect MainView);
452 static void ConchainBackgroundEntities(IConsole::IResult *pResult, void *pUserData, IConsole::FCommandCallback pfnCallback, void *pCallbackUserData);
453 static void ConchainUpdateMusicState(IConsole::IResult *pResult, void *pUserData, IConsole::FCommandCallback pfnCallback, void *pCallbackUserData);
454 void UpdateMusicState();
455
456 // found in menus_demo.cpp
458 float m_LastPauseChange = -1.0f;
459 float m_LastSpeedChange = -1.0f;
460 static bool DemoFilterChat(const void *pData, int Size, void *pUser);
461 bool FetchHeader(CDemoItem &Item);
462 void FetchAllHeaders();
463 void HandleDemoSeeking(float PositionToSeek, float TimeToSeek);
464 void RenderDemoPlayer(CUIRect MainView);
467 void RenderDemoBrowser(CUIRect MainView);
468 void RenderDemoBrowserList(CUIRect ListView, bool &WasListboxItemActivated);
469 void RenderDemoBrowserDetails(CUIRect DetailsView);
470 void RenderDemoBrowserButtons(CUIRect ButtonsView, bool WasListboxItemActivated);
473
474 // found in menus_start.cpp
475 void RenderStartMenu(CUIRect MainView);
478
479 // found in menus_ingame.cpp
481 void RenderGame(CUIRect MainView);
484 void RenderPlayers(CUIRect MainView);
485 void RenderServerInfo(CUIRect MainView);
486 void RenderServerInfoMotd(CUIRect Motd);
487 void RenderServerControl(CUIRect MainView);
488 bool RenderServerControlKick(CUIRect MainView, bool FilterSpectators);
489 bool RenderServerControlServer(CUIRect MainView);
490 void RenderIngameHint();
491
492 // found in menus_browser.cpp
496 void RenderServerbrowserServerList(CUIRect View, bool &WasListboxItemActivated);
497 void RenderServerbrowserStatusBox(CUIRect StatusBox, bool WasListboxItemActivated);
498 void Connect(const char *pAddress);
503 IFilterList &Filter,
504 float ItemHeight, int MaxItems, int ItemsPerRow,
505 CScrollRegion &ScrollRegion, std::vector<unsigned char> &vItemIds,
506 bool UpdateCommunityCacheOnChange,
507 const std::function<const char *(int ItemIndex)> &GetItemName,
508 const std::function<void(int ItemIndex, CUIRect Item, const void *pItemId, bool Active)> &RenderItem);
513 {
516 bool m_New;
517 };
518 static CUi::EPopupMenuFunctionResult PopupCountrySelection(void *pContext, CUIRect View, bool Active);
520 void RenderServerbrowserInfoScoreboard(CUIRect View, const CServerInfo *pSelectedServer);
522 void FriendlistOnUpdate();
526 void RenderServerbrowser(CUIRect MainView);
527 template<typename F>
528 bool PrintHighlighted(const char *pName, F &&PrintFn);
529 CTeeRenderInfo GetTeeRenderInfo(vec2 Size, const char *pSkinName, bool CustomSkinColors, int CustomSkinColorBody, int CustomSkinColorFeet) const;
530 static void ConchainFriendlistUpdate(IConsole::IResult *pResult, void *pUserData, IConsole::FCommandCallback pfnCallback, void *pCallbackUserData);
531 static void ConchainFavoritesUpdate(IConsole::IResult *pResult, void *pUserData, IConsole::FCommandCallback pfnCallback, void *pCallbackUserData);
532 static void ConchainCommunitiesUpdate(IConsole::IResult *pResult, void *pUserData, IConsole::FCommandCallback pfnCallback, void *pCallbackUserData);
533 static void ConchainUiPageUpdate(IConsole::IResult *pResult, void *pUserData, IConsole::FCommandCallback pfnCallback, void *pCallbackUserData);
534 void UpdateCommunityCache(bool Force);
535
536 // community icons
538 {
539 protected:
544 bool m_Success = false;
546
547 CAbstractCommunityIconJob(CMenus *pMenus, const char *pCommunityId, int StorageType);
549
550 public:
551 const char *CommunityId() const { return m_aCommunityId; }
552 bool Success() const { return m_Success; }
553 const SHA256_DIGEST &Sha256() const { return m_Sha256; }
554 };
555
557 {
559
560 protected:
561 void Run() override;
562
563 public:
564 CCommunityIconLoadJob(CMenus *pMenus, const char *pCommunityId, int StorageType);
566
568 };
569
571 {
572 public:
573 CCommunityIconDownloadJob(CMenus *pMenus, const char *pCommunityId, const char *pUrl, const SHA256_DIGEST &Sha256);
574 };
575
576 std::vector<SCommunityIcon> m_vCommunityIcons;
577 std::deque<std::shared_ptr<CCommunityIconLoadJob>> m_CommunityIconLoadJobs;
578 std::deque<std::shared_ptr<CCommunityIconDownloadJob>> m_CommunityIconDownloadJobs;
580 static int CommunityIconScan(const char *pName, int IsDir, int DirType, void *pUser);
581 const SCommunityIcon *FindCommunityIcon(const char *pCommunityId);
582 bool LoadCommunityIconFile(const char *pPath, int DirType, CImageInfo &Info, SHA256_DIGEST &Sha256);
583 void LoadCommunityIconFinish(const char *pCommunityId, CImageInfo &Info, const SHA256_DIGEST &Sha256);
584 void RenderCommunityIcon(const SCommunityIcon *pIcon, CUIRect Rect, bool Active);
586
587 // skin favorite list
589 std::unordered_set<std::string> m_SkinFavorites;
590 static void Con_AddFavoriteSkin(IConsole::IResult *pResult, void *pUserData);
591 static void Con_RemFavoriteSkin(IConsole::IResult *pResult, void *pUserData);
592 static void ConfigSaveCallback(IConfigManager *pConfigManager, void *pUserData);
593 void OnConfigSave(IConfigManager *pConfigManager);
594
595 // found in menus_settings.cpp
596 bool RenderLanguageSelection(CUIRect MainView);
597 void RenderThemeSelection(CUIRect MainView);
598 void RenderSettingsGeneral(CUIRect MainView);
599 void RenderSettingsPlayer(CUIRect MainView);
601 void RenderSettingsTee(CUIRect MainView);
602 void RenderSettingsTee7(CUIRect MainView);
603 void RenderSettingsTeeCustom7(CUIRect MainView);
604 void RenderSkinSelection7(CUIRect MainView);
605 void RenderSkinPartSelection7(CUIRect MainView);
606 void RenderSettingsControls(CUIRect MainView);
608 void RenderSettingsGraphics(CUIRect MainView);
609 void RenderSettingsSound(CUIRect MainView);
610 void RenderSettings(CUIRect MainView);
611 void RenderSettingsCustom(CUIRect MainView);
612
614 {
615 public:
618 };
620 {
621 public:
622 std::vector<CMapListItem> m_vMaps;
624 static int MapListFetchCallback(const CFsFileInfo *pInfo, int IsDir, int StorageType, void *pUser);
625 void MapListPopulate();
628 };
629
630 static bool CompareFilenameAscending(const CMapListItem Lhs, const CMapListItem Rhs)
631 {
632 if(str_comp(Lhs.m_aFilename, "..") == 0)
633 return true;
634 if(str_comp(Rhs.m_aFilename, "..") == 0)
635 return false;
636 if(Lhs.m_IsDirectory != Rhs.m_IsDirectory)
637 return Lhs.m_IsDirectory;
638 return str_comp_filenames(Lhs.m_aFilename, Rhs.m_aFilename) < 0;
639 }
640
641 static CUi::EPopupMenuFunctionResult PopupMapPicker(void *pContext, CUIRect View, bool Active);
642
643 void SetNeedSendInfo();
644 void SetActive(bool Active);
645 void UpdateColors();
646
648
649 bool CheckHotKey(int Key) const;
650
651public:
652 void RenderBackground();
653
655
656 CMenus();
657 virtual int Sizeof() const override { return sizeof(*this); }
658
659 void RenderLoading(const char *pCaption, const char *pContent, int IncreaseCounter, bool RenderLoadingBar = true, bool RenderMenuBackgroundMap = true);
660
661 bool IsInit() { return m_IsInit; }
662
663 bool IsActive() const { return m_MenuActive; }
664 void KillServer();
665
666 virtual void OnInit() override;
667 void OnConsoleInit() override;
668
669 virtual void OnStateChange(int NewState, int OldState) override;
670 virtual void OnWindowResize() override;
671 virtual void OnRefreshSkins() override;
672 virtual void OnReset() override;
673 virtual void OnRender() override;
674 virtual bool OnInput(const IInput::CEvent &Event) override;
675 virtual bool OnCursorMove(float x, float y, IInput::ECursorType CursorType) override;
676 virtual void OnShutdown() override;
677
678 enum
679 {
697
699
710
712
723
725
735
737 };
738
742
743 // DDRace
744 int DoButton_CheckBox_Tristate(const void *pId, const char *pText, TRISTATE Checked, const CUIRect *pRect);
745 std::vector<CDemoItem> m_vDemos;
746 std::vector<CDemoItem *> m_vpFilteredDemos;
747 void DemolistPopulate();
749 void DemoSeekTick(IDemoPlayer::ETickOffset TickOffset);
751
752 const char *GetCurrentDemoFolder() const { return m_aCurrentDemoFolder; }
753
754 // Ghost
756 {
759
763 bool m_Own;
764 time_t m_Date;
765
767 m_Slot(-1), m_Own(false) { m_aFilename[0] = 0; }
768
769 bool operator<(const CGhostItem &Other) const { return m_Time < Other.m_Time; }
770
771 bool Active() const { return m_Slot != -1; }
772 bool HasFile() const { return m_aFilename[0]; }
773 };
774
775 enum
776 {
781 };
782
783 std::vector<CGhostItem> m_vGhosts;
784
785 std::chrono::nanoseconds m_GhostPopulateStartTime{0};
786
787 void GhostlistPopulate();
789 void UpdateOwnGhost(CGhostItem Item);
790 void DeleteGhostItem(int Index);
791 void SortGhostlist();
792
793 bool CanDisplayWarning() const;
794
795 void PopupWarning(const char *pTopic, const char *pBody, const char *pButton, std::chrono::nanoseconds Duration);
796
797 std::chrono::nanoseconds m_PopupWarningLastTime;
798 std::chrono::nanoseconds m_PopupWarningDuration;
799
801
802 enum
803 {
805 POPUP_MESSAGE, // generic message popup (one button)
806 POPUP_CONFIRM, // generic confirmation popup (two buttons)
819
820 // demo player states
823 };
824
825private:
826 static int GhostlistFetchCallback(const CFsFileInfo *pInfo, int IsDir, int StorageType, void *pUser);
827 void SetMenuPage(int NewPage);
828 void RefreshBrowserTab(bool Force);
829
830 // found in menus_ingame.cpp
831 void RenderInGameNetwork(CUIRect MainView);
832 void RenderGhost(CUIRect MainView);
833
834 // found in menus_settings.cpp
835 void RenderSettingsDDNet(CUIRect MainView);
836 void RenderSettingsAppearance(CUIRect MainView);
837 bool RenderHslaScrollbars(CUIRect *pRect, unsigned int *pColor, bool Alpha, float DarkestLight);
838
840};
841#endif
const SHA256_DIGEST SHA256_ZEROED
Definition: hash.cpp:6
Definition: ui.h:248
Definition: component.h:20
Definition: ghost.h:34
Definition: http.h:53
Definition: image.h:12
Definition: lineinput.h:25
Definition: menus.h:40
virtual bool OnInput(const IInput::CEvent &Event) override
Definition: menus_settings.cpp:55
IInput::CEvent m_Key
Definition: menus.h:45
const void * m_pKeyReaderId
Definition: menus.h:42
int m_ModifierCombination
Definition: menus.h:46
virtual int Sizeof() const override
Definition: menus.h:48
bool m_GotKey
Definition: menus.h:44
CMenusKeyBinder()
Definition: menus_settings.cpp:47
bool m_TakeKey
Definition: menus.h:43
Definition: menus.h:538
bool m_Success
Definition: menus.h:544
bool Success() const
Definition: menus.h:552
const char * CommunityId() const
Definition: menus.h:551
char m_aPath[IO_MAX_PATH_LENGTH]
Definition: menus.h:542
CMenus * m_pMenus
Definition: menus.h:540
int m_StorageType
Definition: menus.h:543
virtual ~CAbstractCommunityIconJob()
Definition: menus.h:548
char m_aCommunityId[CServerInfo::MAX_COMMUNITY_ID_LENGTH]
Definition: menus.h:541
const SHA256_DIGEST & Sha256() const
Definition: menus.h:553
SHA256_DIGEST m_Sha256
Definition: menus.h:545
CAbstractCommunityIconJob(CMenus *pMenus, const char *pCommunityId, int StorageType)
Definition: menus_browser.cpp:1923
Definition: menus.h:571
CCommunityIconDownloadJob(CMenus *pMenus, const char *pCommunityId, const char *pUrl, const SHA256_DIGEST &Sha256)
Definition: menus_browser.cpp:1931
Definition: menus.h:557
CCommunityIconLoadJob(CMenus *pMenus, const char *pCommunityId, int StorageType)
Definition: menus_browser.cpp:1946
CImageInfo & ImageInfo()
Definition: menus.h:567
void Run() override
Definition: menus_browser.cpp:1941
CImageInfo m_ImageInfo
Definition: menus.h:558
~CCommunityIconLoadJob()
Definition: menus_browser.cpp:1952
Definition: menus.h:367
const char * Clan() const
Definition: menus.h:410
const void * CommunityTooltipId() const
Definition: menus.h:422
bool m_CustomSkinColors
Definition: menus.h:376
int CustomSkinColorFeet() const
Definition: menus.h:418
char m_aSkin[MAX_SKIN_LENGTH]
Definition: menus.h:375
int m_CustomSkinColorBody
Definition: menus.h:377
bool m_IsPlayer
Definition: menus.h:372
bool m_IsAfk
Definition: menus.h:373
bool IsAfk() const
Definition: menus.h:414
bool operator<(const CFriendItem &Other) const
Definition: menus.h:425
bool CustomSkinColors() const
Definition: menus.h:416
const CServerInfo * m_pServerInfo
Definition: menus.h:370
const void * ListItemId() const
Definition: menus.h:420
int CustomSkinColorBody() const
Definition: menus.h:417
CFriendItem()
Definition: menus.h:381
CFriendItem(const CServerInfo::CClient &CurrentClient, const CServerInfo *pServerInfo)
Definition: menus.h:395
int FriendState() const
Definition: menus.h:412
int m_FriendState
Definition: menus.h:371
const char * Skin() const
Definition: menus.h:415
char m_aClan[MAX_CLAN_LENGTH]
Definition: menus.h:369
const CServerInfo * ServerInfo() const
Definition: menus.h:411
int m_CustomSkinColorFeet
Definition: menus.h:378
const char * Name() const
Definition: menus.h:409
char m_aName[MAX_NAME_LENGTH]
Definition: menus.h:368
bool IsPlayer() const
Definition: menus.h:413
const void * SkinTooltipId() const
Definition: menus.h:423
CFriendItem(const CFriendInfo *pFriendInfo)
Definition: menus.h:382
const void * RemoveButtonId() const
Definition: menus.h:421
Definition: menus.h:195
std::chrono::nanoseconds m_LastRender
Definition: menus.h:197
int m_Current
Definition: menus.h:198
int m_Total
Definition: menus.h:199
Definition: menus.h:614
char m_aFilename[IO_MAX_PATH_LENGTH]
Definition: menus.h:616
bool m_IsDirectory
Definition: menus.h:617
Definition: menus.h:620
void MapListPopulate()
Definition: menus_settings.cpp:3542
static int MapListFetchCallback(const CFsFileInfo *pInfo, int IsDir, int StorageType, void *pUser)
Definition: menus_settings.cpp:3551
CMenus * m_pMenus
Definition: menus.h:626
std::vector< CMapListItem > m_vMaps
Definition: menus.h:622
char m_aCurrentMapFolder[IO_MAX_PATH_LENGTH]
Definition: menus.h:623
int m_Selection
Definition: menus.h:627
Definition: menus.h:61
bool m_StartPaused
Definition: menus.h:358
void RefreshFilteredDemos()
Definition: menus_demo.cpp:989
void RenderSettingsTee7(CUIRect MainView)
Definition: menus_settings7.cpp:36
char m_aCurrentDemoSelectionName[IO_MAX_PATH_LENGTH]
Definition: menus.h:346
char m_aMessageBody[512]
Definition: menus.h:205
bool PrintHighlighted(const char *pName, F &&PrintFn)
Definition: menus_browser.cpp:1818
@ SETTINGS_GRAPHICS
Definition: menus.h:706
@ PAGE_FAVORITE_COMMUNITY_2
Definition: menus.h:689
@ PAGE_INTERNET
Definition: menus.h:685
@ PAGE_CALLVOTE
Definition: menus.h:684
@ SMALL_TAB_BROWSER_INFO
Definition: menus.h:733
@ PAGE_PLAYERS
Definition: menus.h:682
@ PAGE_FAVORITE_COMMUNITY_1
Definition: menus.h:688
@ SETTINGS_ASSETS
Definition: menus.h:709
@ SMALL_TAB_BROWSER_FILTER
Definition: menus.h:732
@ SMALL_TAB_QUIT
Definition: menus.h:727
@ SMALL_TAB_HOME
Definition: menus.h:726
@ SETTINGS_PLAYER
Definition: menus.h:702
@ PAGE_GAME
Definition: menus.h:681
@ BIT_TAB_FAVORITE_COMMUNITY_3
Definition: menus.h:719
@ SMALL_TAB_EDITOR
Definition: menus.h:729
@ SMALL_TAB_BROWSER_FRIENDS
Definition: menus.h:734
@ SMALL_TAB_LENGTH
Definition: menus.h:736
@ PAGE_SETTINGS
Definition: menus.h:694
@ BIG_TAB_INTERNET
Definition: menus.h:714
@ BIT_TAB_FAVORITE_COMMUNITY_2
Definition: menus.h:718
@ SMALL_TAB_SERVER
Definition: menus.h:731
@ SETTINGS_LANGUAGE
Definition: menus.h:700
@ PAGE_LAN
Definition: menus.h:686
@ SETTINGS_GENERAL
Definition: menus.h:701
@ PAGE_NETWORK
Definition: menus.h:695
@ BIG_TAB_FAVORITES
Definition: menus.h:716
@ SETTINGS_TEE
Definition: menus.h:703
@ PAGE_NEWS
Definition: menus.h:680
@ PAGE_SERVER_INFO
Definition: menus.h:683
@ BIT_TAB_FAVORITE_COMMUNITY_4
Definition: menus.h:720
@ PAGE_LENGTH
Definition: menus.h:698
@ SETTINGS_LENGTH
Definition: menus.h:711
@ SMALL_TAB_DEMOBUTTON
Definition: menus.h:730
@ PAGE_FAVORITES
Definition: menus.h:687
@ PAGE_DEMOS
Definition: menus.h:693
@ PAGE_FAVORITE_COMMUNITY_3
Definition: menus.h:690
@ SMALL_TAB_SETTINGS
Definition: menus.h:728
@ SETTINGS_SOUND
Definition: menus.h:707
@ SETTINGS_DDNET
Definition: menus.h:708
@ BIT_TAB_FAVORITE_COMMUNITY_1
Definition: menus.h:717
@ BIG_TAB_LAN
Definition: menus.h:715
@ BIG_TAB_NEWS
Definition: menus.h:713
@ SETTINGS_CONTROLS
Definition: menus.h:705
@ PAGE_FAVORITE_COMMUNITY_5
Definition: menus.h:692
@ BIT_TAB_FAVORITE_COMMUNITY_5
Definition: menus.h:721
@ PAGE_GHOST
Definition: menus.h:696
@ SETTINGS_APPEARANCE
Definition: menus.h:704
@ BIG_TAB_DEMOS
Definition: menus.h:722
@ PAGE_FAVORITE_COMMUNITY_4
Definition: menus.h:691
@ BIG_TAB_LENGTH
Definition: menus.h:724
int DoButton_CheckBox_Tristate(const void *pId, const char *pText, TRISTATE Checked, const CUIRect *pRect)
Definition: menus.cpp:2380
float m_DownloadSpeed
Definition: menus.h:263
bool m_SkinListNeedsUpdate
Definition: menus.h:97
CTeeRenderInfo GetTeeRenderInfo(vec2 Size, const char *pSkinName, bool CustomSkinColors, int CustomSkinColorBody, int CustomSkinColorFeet) const
Definition: menus_browser.cpp:1852
void RenderServerbrowserTypesFilter(CUIRect View)
Definition: menus_browser.cpp:1065
bool FetchHeader(CDemoItem &Item)
Definition: menus_demo.cpp:1038
void RenderNews(CUIRect MainView)
Definition: menus.cpp:812
static ColorRGBA ms_ColorTabbarActiveOutgame
Definition: menus.h:64
bool CheckHotKey(int Key) const
Definition: menus.cpp:2373
CLineInput m_PasswordInput
Definition: menus.h:266
void RenderInGameNetwork(CUIRect MainView)
Definition: menus_ingame.cpp:835
virtual void OnReset() override
Definition: menus.cpp:2163
int m_GamePage
Definition: menus.h:171
void DefaultButtonCallback()
Definition: menus.h:213
bool m_ServerBrowserShouldRevealSelection
Definition: menus.h:494
void RenderSettingsPlayer(CUIRect MainView)
Definition: menus_settings.cpp:260
static void ConfigSaveCallback(IConfigManager *pConfigManager, void *pUserData)
Definition: menus_settings.cpp:434
void UpdateColors()
Definition: menus.cpp:2292
void OnConsoleInit() override
Definition: menus.cpp:919
std::vector< CDemoItem > m_vDemos
Definition: menus.h:745
void RenderPopupLoading(CUIRect Screen)
Definition: menus.cpp:1921
static void ConchainUiPageUpdate(IConsole::IResult *pResult, void *pUserData, IConsole::FCommandCallback pfnCallback, void *pCallbackUserData)
Definition: menus_browser.cpp:1890
void RenderServerControl(CUIRect MainView)
Definition: menus_ingame.cpp:633
static ColorRGBA ms_ColorTabbarHover
Definition: menus.h:71
bool m_CustomSkinMenu
Definition: menus.h:253
void DeleteGhostItem(int Index)
Definition: menus_ingame.cpp:995
const SCommunityIcon * FindCommunityIcon(const char *pCommunityId)
Definition: menus_browser.cpp:1973
ColorHSLA DoLine_ColorPicker(CButtonContainer *pResetId, float LineSize, float LabelSize, float BottomMargin, CUIRect *pMainRect, const char *pText, unsigned int *pColorValue, ColorRGBA DefaultColor, bool CheckBoxSpacing=true, int *pCheckBoxValue=nullptr, bool Alpha=false)
Definition: menus.cpp:376
void RenderDemoBrowserButtons(CUIRect ButtonsView, bool WasListboxItemActivated)
Definition: menus_demo.cpp:1375
static void Con_RemFavoriteSkin(IConsole::IResult *pResult, void *pUserData)
Definition: menus_settings.cpp:423
void RefreshBrowserTab(bool Force)
Definition: menus.cpp:2465
int DoButton_MenuTab(CButtonContainer *pButtonContainer, const char *pText, int Checked, const CUIRect *pRect, int Corners, SUIAnimator *pAnimator=nullptr, const ColorRGBA *pDefaultColor=nullptr, const ColorRGBA *pActiveColor=nullptr, const ColorRGBA *pHoverColor=nullptr, float EdgeRounding=10.0f, const SCommunityIcon *pCommunityIcon=nullptr)
Definition: menus.cpp:159
static ColorRGBA ms_ColorTabbarInactiveOutgame
Definition: menus.h:63
static bool DemoFilterChat(const void *pData, int Size, void *pUser)
Definition: menus_demo.cpp:58
void RenderServerbrowserServerList(CUIRect View, bool &WasListboxItemActivated)
Definition: menus_browser.cpp:105
int DoButton_Menu(CButtonContainer *pButtonContainer, const char *pText, int Checked, const CUIRect *pRect, const char *pImageName=nullptr, int Corners=IGraphics::CORNER_ALL, float Rounding=5.0f, float FontFactor=0.0f, ColorRGBA Color=ColorRGBA(1.0f, 1.0f, 1.0f, 0.5f))
Definition: menus.cpp:122
static bool CompareFilenameAscending(const CMapListItem Lhs, const CMapListItem Rhs)
Definition: menus.h:630
@ SORT_DEMONAME
Definition: menus.h:278
@ SORT_DATE
Definition: menus.h:280
@ SORT_LENGTH
Definition: menus.h:279
static void ConchainFavoritesUpdate(IConsole::IResult *pResult, void *pUserData, IConsole::FCommandCallback pfnCallback, void *pCallbackUserData)
Definition: menus_browser.cpp:1872
bool m_SkinListScrollToSelected
Definition: menus.h:98
void RenderDemoBrowser(CUIRect MainView)
Definition: menus_demo.cpp:1059
static int EntitiesScan(const char *pName, int IsDir, int DirType, void *pUser)
Definition: menus_settings_assets.cpp:71
const CSkins7::CSkin * m_pSelectedSkin
Definition: menus.h:255
int DoButton_Favorite(const void *pButtonId, const void *pParentId, bool Checked, const CUIRect *pRect)
Definition: menus.cpp:261
int DoButton_FontIcon(CButtonContainer *pButtonContainer, const char *pText, int Checked, const CUIRect *pRect, int Corners=IGraphics::CORNER_ALL, bool Enabled=true)
Definition: menus_demo.cpp:31
static ColorRGBA ms_ColorTabbarActiveIngame
Definition: menus.h:67
std::vector< CFriendItem > m_avFriends[NUM_FRIEND_TYPES]
Definition: menus.h:439
FPopupButtonCallback m_pfnCallback
Definition: menus.h:229
const char * GetCurrentDemoFolder() const
Definition: menus.h:752
std::unordered_set< std::string > m_SkinFavorites
Definition: menus.h:589
bool m_CreateDefaultFavoriteCommunities
Definition: menus.h:177
std::vector< SCustomExtras > m_vExtrasList
Definition: menus.h:148
void UpdateMusicState()
Definition: menus.cpp:945
void PopupConfirmRemoveFriend()
Definition: menus_browser.cpp:1675
int m_DirectionQuadContainerIndex
Definition: menus.h:100
CLineInputBuffered< IO_MAX_PATH_LENGTH > m_DemoRenderInput
Definition: menus.h:351
void RenderServerbrowserFilters(CUIRect View)
Definition: menus_browser.cpp:668
CLineInputBuffered< IO_MAX_PATH_LENGTH > m_DemoRenameInput
Definition: menus.h:347
void RenderServerbrowserDDNetFilter(CUIRect View, IFilterList &Filter, float ItemHeight, int MaxItems, int ItemsPerRow, CScrollRegion &ScrollRegion, std::vector< unsigned char > &vItemIds, bool UpdateCommunityCacheOnChange, const std::function< const char *(int ItemIndex)> &GetItemName, const std::function< void(int ItemIndex, CUIRect Item, const void *pItemId, bool Active)> &RenderItem)
Definition: menus_browser.cpp:860
std::vector< CDemoItem * > m_vpFilteredDemos
Definition: menus.h:746
virtual int Sizeof() const override
Definition: menus.h:657
void OnConfigSave(IConfigManager *pConfigManager)
Definition: menus_settings.cpp:440
int m_CallvoteSelectedPlayer
Definition: menus.h:270
struct CMenus::@150 m_aPopupButtons[NUM_BUTTONS]
void RenderServerbrowserCountriesFilter(CUIRect View)
Definition: menus_browser.cpp:1040
std::chrono::nanoseconds m_PopupWarningLastTime
Definition: menus.h:797
virtual void OnStateChange(int NewState, int OldState) override
Definition: menus.cpp:2196
void ClearCustomItems(int CurTab)
Definition: menus_settings_assets.cpp:259
std::chrono::nanoseconds m_GhostPopulateStartTime
Definition: menus.h:785
virtual void OnRefreshSkins() override
Definition: menus_settings.cpp:404
bool m_DemolistMultipleStorages
Definition: menus.h:356
void LoadCommunityIconFinish(const char *pCommunityId, CImageInfo &Info, const SHA256_DIGEST &Sha256)
Definition: menus_browser.cpp:2007
CLineInputBuffered< IO_MAX_PATH_LENGTH > m_DemoSearchInput
Definition: menus.h:349
bool m_DemolistSelectedReveal
Definition: menus.h:354
float RenderSettingsControlsJoystick(CUIRect View)
Definition: menus_settings.cpp:959
int m_NextPopup
Definition: menus.h:228
bool m_JoinTutorial
Definition: menus.h:176
CUIElement m_ConnectButton
Definition: menus.h:209
std::deque< std::shared_ptr< CCommunityIconDownloadJob > > m_CommunityIconDownloadJobs
Definition: menus.h:578
bool IsInit()
Definition: menus.h:661
virtual bool OnInput(const IInput::CEvent &Event) override
Definition: menus.cpp:2185
SUIAnimator m_aAnimatorsSmallPage[SMALL_TAB_LENGTH]
Definition: menus.h:740
void ResetServerbrowserFilters()
Definition: menus_browser.cpp:825
float m_LastPauseChange
Definition: menus.h:458
int m_TeePartSelected
Definition: menus.h:254
char m_aLabel[64]
Definition: menus.h:227
void RenderSkinPartSelection7(CUIRect MainView)
Definition: menus_settings7.cpp:404
void RenderGame(CUIRect MainView)
Definition: menus_ingame.cpp:41
virtual void OnRender() override
Definition: menus.cpp:2242
virtual void OnShutdown() override
Definition: menus.cpp:2167
const CFriendItem * m_pRemoveFriend
Definition: menus.h:440
bool RenderHslaScrollbars(CUIRect *pRect, unsigned int *pColor, bool Alpha, float DarkestLight)
Definition: menus_settings.cpp:2044
bool m_NeedSendinfo
Definition: menus.h:248
int m_MenuPage
Definition: menus.h:170
void RenderSkinSelection7(CUIRect MainView)
Definition: menus_settings7.cpp:315
bool m_Dummy
Definition: menus.h:750
static void Con_AddFavoriteSkin(IConsole::IResult *pResult, void *pUserData)
Definition: menus_settings.cpp:409
void RenderSettings(CUIRect MainView)
Definition: menus_settings.cpp:1916
int m_DownloadLastCheckSize
Definition: menus.h:262
std::vector< SCommunityIcon > m_vCommunityIcons
Definition: menus.h:576
void UpdateCommunityIcons()
Definition: menus_browser.cpp:2048
void(CMenus::* FPopupButtonCallback)()
Definition: menus.h:212
CUIElement m_RefreshButton
Definition: menus.h:208
static int DemolistFetchCallback(const CFsFileInfo *pInfo, int IsDir, int StorageType, void *pUser)
Definition: menus_demo.cpp:892
void RenderSettingsAppearance(CUIRect MainView)
Definition: menus_settings.cpp:2294
void RenderStartMenu(CUIRect MainView)
Definition: menus_start.cpp:22
void PopupWarning(const char *pTopic, const char *pBody, const char *pButton, std::chrono::nanoseconds Duration)
Definition: menus.cpp:984
bool RenderServerControlKick(CUIRect MainView, bool FilterSpectators)
Definition: menus_ingame.cpp:580
static int MenuImageScan(const char *pName, int IsDir, int DirType, void *pUser)
Definition: menus.cpp:2396
void RenderPopupConnecting(CUIRect Screen)
Definition: menus.cpp:1856
bool m_ControlPageOpening
Definition: menus.h:273
void SetNeedSendInfo()
Definition: menus_settings.cpp:252
void RenderDemoBrowserDetails(CUIRect DetailsView)
Definition: menus_demo.cpp:1262
static ColorRGBA ms_ColorTabbarHoverIngame
Definition: menus.h:68
void RenderPopupFullscreen(CUIRect Screen)
Definition: menus.cpp:1216
bool LoadCommunityIconFile(const char *pPath, int DirType, CImageInfo &Info, SHA256_DIGEST &Sha256)
Definition: menus_browser.cpp:1981
void RenderGhost(CUIRect MainView)
Definition: menus_ingame.cpp:1018
CLineInputBuffered< IO_MAX_PATH_LENGTH > m_DemoSliceInput
Definition: menus.h:348
float m_EditorHotKeyChecktime
Definition: menus.h:477
bool m_SkinFavoritesChanged
Definition: menus.h:588
int DoButton_CheckBoxAutoVMarginAndSet(const void *pId, const char *pText, int *pValue, CUIRect *pRect, float VMargin)
Definition: menus.cpp:445
void RenderServerbrowserInfoScoreboard(CUIRect View, const CServerInfo *pSelectedServer)
Definition: menus_browser.cpp:1240
std::chrono::nanoseconds m_DemoPopulateStartTime
Definition: menus.h:360
@ POPUP_SAVE_SKIN
Definition: menus.h:818
@ DEMOPLAYER_NONE
Definition: menus.h:821
@ POPUP_DISCONNECTED
Definition: menus.h:809
@ POPUP_PASSWORD
Definition: menus.h:814
@ POPUP_RENDER_DONE
Definition: menus.h:813
@ DEMOPLAYER_SLICE_SAVE
Definition: menus.h:822
@ POPUP_QUIT
Definition: menus.h:815
@ POPUP_RESTART
Definition: menus.h:816
@ POPUP_FIRST_LAUNCH
Definition: menus.h:807
@ POPUP_LANGUAGE
Definition: menus.h:810
@ POPUP_WARNING
Definition: menus.h:817
@ POPUP_NONE
Definition: menus.h:804
@ POPUP_MESSAGE
Definition: menus.h:805
@ POPUP_RENDER_DEMO
Definition: menus.h:812
@ POPUP_POINTS
Definition: menus.h:808
@ POPUP_RENAME_DEMO
Definition: menus.h:811
@ POPUP_CONFIRM
Definition: menus.h:806
bool RenderLanguageSelection(CUIRect MainView)
Definition: menus_settings.cpp:1867
void ResetSettingsControls()
Definition: menus_settings.cpp:1364
static CUi::EPopupMenuFunctionResult PopupCountrySelection(void *pContext, CUIRect View, bool Active)
Definition: menus_browser.cpp:1089
char m_aMessageButton[512]
Definition: menus.h:206
void SetMenuPage(int NewPage)
Definition: menus.cpp:2445
static int GameScan(const char *pName, int IsDir, int DirType, void *pUser)
Definition: menus_settings_assets.cpp:172
int m_CallvoteSelectedOption
Definition: menus.h:269
bool m_DemoBrowserListInitialized
Definition: menus.h:466
int m_DemoPlayerState
Definition: menus.h:800
static ColorRGBA ms_ColorTabbarActive
Definition: menus.h:70
void RenderDemoBrowserList(CUIRect ListView, bool &WasListboxItemActivated)
Definition: menus_demo.cpp:1076
void DoJoystickAxisPicker(CUIRect View)
Definition: menus_settings.cpp:1082
int m_DemolistSelectedIndex
Definition: menus.h:353
void RenderSettingsTeeCustom7(CUIRect MainView)
Definition: menus_settings7.cpp:250
void PopupConfirmDeleteFolder()
Definition: menus_demo.cpp:1603
void PopupConfirmDeleteDemo()
Definition: menus_demo.cpp:1586
void KillServer()
Definition: menus_start.cpp:286
int DoButton_Toggle(const void *pId, int Checked, const CUIRect *pRect, bool Active)
Definition: menus.cpp:102
void DoJoystickBar(const CUIRect *pRect, float Current, float Tolerance, bool Active)
Definition: menus_settings.cpp:1152
CServerProcess m_ServerProcess
Definition: menus.h:839
int m_DemolistStorageType
Definition: menus.h:355
void Connect(const char *pAddress)
Definition: menus_browser.cpp:652
float m_LastSpeedChange
Definition: menus.h:459
std::vector< SCustomParticle > m_vParticlesList
Definition: menus.h:146
void RenderDemoPlayerSliceSavePopup(CUIRect MainView)
Definition: menus_demo.cpp:753
void RenderServerbrowserTabBar(CUIRect TabBar)
Definition: menus_browser.cpp:1691
void GhostlistPopulate()
Definition: menus_ingame.cpp:931
void RenderLoading(const char *pCaption, const char *pContent, int IncreaseCounter, bool RenderLoadingBar=true, bool RenderMenuBackgroundMap=true)
Definition: menus.cpp:759
int DoKeyReader(const void *pId, const CUIRect *pRect, int Key, int ModifierCombination, int *pNewModifierCombination)
Definition: menus.cpp:470
std::vector< SCustomEmoticon > m_vEmoticonList
Definition: menus.h:145
void RenderServerbrowser(CUIRect MainView)
Definition: menus_browser.cpp:1755
bool m_NeedSendDummyinfo
Definition: menus.h:249
static void ConchainAssetExtras(IConsole::IResult *pResult, void *pUserData, IConsole::FCommandCallback pfnCallback, void *pCallbackUserData)
Definition: menus_settings_assets.cpp:721
static void ConchainAssetGame(IConsole::IResult *pResult, void *pUserData, IConsole::FCommandCallback pfnCallback, void *pCallbackUserData)
Definition: menus_settings_assets.cpp:661
bool m_NeedRestartUpdate
Definition: menus.h:247
static ColorRGBA ms_ColorTabbarInactive
Definition: menus.h:69
void DemoSeekTick(IDemoPlayer::ETickOffset TickOffset)
Definition: menus_demo.cpp:98
void DoSettingsControlsButtons(int Start, int Stop, CUIRect View)
Definition: menus_settings.cpp:931
static ColorRGBA ms_ColorTabbarInactiveIngame
Definition: menus.h:66
@ GHOST_SORT_NONE
Definition: menus.h:777
@ GHOST_SORT_TIME
Definition: menus.h:779
@ GHOST_SORT_DATE
Definition: menus.h:780
@ GHOST_SORT_NAME
Definition: menus.h:778
static void ConchainFriendlistUpdate(IConsole::IResult *pResult, void *pUserData, IConsole::FCommandCallback pfnCallback, void *pCallbackUserData)
Definition: menus_browser.cpp:1861
CLineInputBuffered< protocol7::MAX_SKIN_ARRAY_SIZE, protocol7::MAX_SKIN_LENGTH > m_SkinNameInput
Definition: menus.h:256
bool m_SkinPartListNeedsUpdate
Definition: menus.h:257
virtual void OnInit() override
Definition: menus.cpp:844
void RenderServerbrowserFriends(CUIRect View)
Definition: menus_browser.cpp:1372
void RenderSettingsControls(CUIRect MainView)
Definition: menus_settings.cpp:1170
static int EmoticonsScan(const char *pName, int IsDir, int DirType, void *pUser)
Definition: menus_settings_assets.cpp:180
bool m_NeedRestartGraphics
Definition: menus.h:245
int DoButton_CheckBox_Number(const void *pId, const char *pText, int Checked, const CUIRect *pRect)
Definition: menus.cpp:463
void RenderSettingsTee(CUIRect MainView)
Definition: menus_settings.cpp:450
void RenderSettingsCustom(CUIRect MainView)
Definition: menus_settings_assets.cpp:349
bool m_MenuActive
Definition: menus.h:174
static void ConchainCommunitiesUpdate(IConsole::IResult *pResult, void *pUserData, IConsole::FCommandCallback pfnCallback, void *pCallbackUserData)
Definition: menus_browser.cpp:1879
void UpdateCommunityCache(bool Force)
Definition: menus_browser.cpp:1907
void RenderServerInfoMotd(CUIRect Motd)
Definition: menus_ingame.cpp:490
char m_aMessageTopic[512]
Definition: menus.h:204
static int GhostlistFetchCallback(const CFsFileInfo *pInfo, int IsDir, int StorageType, void *pUser)
Definition: menus_ingame.cpp:901
static int ExtrasScan(const char *pName, int IsDir, int DirType, void *pUser)
Definition: menus_settings_assets.cpp:204
std::vector< SCustomGame > m_vGameList
Definition: menus.h:144
void PopupConfirmDisconnectDummy()
Definition: menus_ingame.cpp:224
vec2 m_DemoControlsPositionOffset
Definition: menus.h:457
void RenderCommunityIcon(const SCommunityIcon *pIcon, CUIRect Rect, bool Active)
Definition: menus_browser.cpp:2036
CLineInputBuffered< 64 > m_FilterInput
Definition: menus.h:272
bool m_ShowStart
Definition: menus.h:173
void RenderSettingsGraphics(CUIRect MainView)
Definition: menus_settings.cpp:1381
void RenderThemeSelection(CUIRect MainView)
Definition: menus.cpp:2058
std::vector< CMenuImage > m_vMenuImages
Definition: menus.h:189
CLineInputBuffered< VOTE_REASON_LENGTH > m_CallvoteReasonInput
Definition: menus.h:271
bool m_ForceRefreshLanPage
Definition: menus.h:178
void RenderServerInfo(CUIRect MainView)
Definition: menus_ingame.cpp:364
bool m_NeedRestartSound
Definition: menus.h:246
static ColorRGBA ms_ColorTabbarHoverOutgame
Definition: menus.h:65
static void ConchainAssetParticles(IConsole::IResult *pResult, void *pUserData, IConsole::FCommandCallback pfnCallback, void *pCallbackUserData)
Definition: menus_settings_assets.cpp:676
void RenderPlayers(CUIRect MainView)
Definition: menus_ingame.cpp:230
std::deque< std::shared_ptr< CCommunityIconLoadJob > > m_CommunityIconLoadJobs
Definition: menus.h:577
@ FRIEND_OFF
Definition: menus.h:436
@ FRIEND_PLAYER_ON
Definition: menus.h:434
@ NUM_FRIEND_TYPES
Definition: menus.h:437
@ FRIEND_CLAN_ON
Definition: menus.h:435
void PopupConfirmDisconnect()
Definition: menus_ingame.cpp:219
int m_Speed
Definition: menus.h:357
static float ms_ButtonHeight
Definition: menus.h:240
std::vector< SCustomEntities > m_vEntitiesList
Definition: menus.h:143
void RenderDemoPlayer(CUIRect MainView)
Definition: menus_demo.cpp:106
SUIAnimator m_aAnimatorsBigPage[BIG_TAB_LENGTH]
Definition: menus.h:739
SHA256_DIGEST m_CommunityIconsInfoSha256
Definition: menus.h:579
static int HudScan(const char *pName, int IsDir, int DirType, void *pUser)
Definition: menus_settings_assets.cpp:196
void RenderSettingsSound(CUIRect MainView)
Definition: menus_settings.cpp:1776
static CMenusKeyBinder m_Binder
Definition: menus.h:654
CMenus()
Definition: menus.cpp:57
void SetActive(bool Active)
Definition: menus.cpp:2130
void PopupConfirmSwitchServer()
Definition: menus_browser.cpp:663
void DemolistOnUpdate(bool Reset)
Definition: menus_demo.cpp:1001
void Render()
Definition: menus.cpp:1010
int DoButton_CheckBox(const void *pId, const char *pText, int Checked, const CUIRect *pRect)
Definition: menus.cpp:458
void PopupConfirmDeleteSkin7()
Definition: menus_settings7.cpp:238
static void ConchainUpdateMusicState(IConsole::IResult *pResult, void *pUserData, IConsole::FCommandCallback pfnCallback, void *pCallbackUserData)
Definition: menus.cpp:937
void HandleDemoSeeking(float PositionToSeek, float TimeToSeek)
Definition: menus_demo.cpp:76
static void ConchainBackgroundEntities(IConsole::IResult *pResult, void *pUserData, IConsole::FCommandCallback pfnCallback, void *pCallbackUserData)
Definition: menus.cpp:926
char m_aCurrentDemoFolder[IO_MAX_PATH_LENGTH]
Definition: menus.h:345
std::vector< SCustomHud > m_vHudList
Definition: menus.h:147
void RenderSettingsDDNet(CUIRect MainView)
Definition: menus_settings.cpp:3178
bool RenderServerControlServer(CUIRect MainView)
Definition: menus_ingame.cpp:535
int DoButton_GridHeader(const void *pId, const char *pText, int Checked, const CUIRect *pRect)
Definition: menus.cpp:248
@ BUTTON_CANCEL
Definition: menus.h:220
@ NUM_BUTTONS
Definition: menus.h:221
@ BUTTON_CONFIRM
Definition: menus.h:219
void PopupMessage(const char *pTitle, const char *pMessage, const char *pButtonLabel, int NextPopup=POPUP_NONE, FPopupButtonCallback pfnButtonCallback=&CMenus::DefaultButtonCallback)
Definition: menus.cpp:954
bool m_EditorHotkeyWasPressed
Definition: menus.h:476
char m_aPopupTitle[128]
Definition: menus.h:223
bool CanDisplayWarning() const
Definition: menus.cpp:1005
void RenderSettingsDummyPlayer(CUIRect MainView)
int m_Popup
Definition: menus.h:172
IGraphics::CTextureHandle m_TextureBlob
Definition: menus.h:647
void RenderMenubar(CUIRect Box, IClient::EClientState ClientState)
Definition: menus.cpp:522
bool m_IsInit
Definition: menus.h:150
void PopupConfirmDemoReplaceVideo()
Definition: menus.cpp:2039
static float ms_ListheaderHeight
Definition: menus.h:241
static CUi::EPopupMenuFunctionResult PopupMapPicker(void *pContext, CUIRect View, bool Active)
Definition: menus_settings.cpp:3465
void DemolistPopulate()
Definition: menus_demo.cpp:929
static void ConchainAssetsEntities(IConsole::IResult *pResult, void *pUserData, IConsole::FCommandCallback pfnCallback, void *pCallbackUserData)
Definition: menus_settings_assets.cpp:646
virtual void OnWindowResize() override
Definition: menus.cpp:2237
static int CommunityIconScan(const char *pName, int IsDir, int DirType, void *pUser)
Definition: menus_browser.cpp:1957
virtual bool OnCursorMove(float x, float y, IInput::ECursorType CursorType) override
Definition: menus.cpp:2174
int m_SelectedIndex
Definition: menus.h:493
static void ConchainAssetHud(IConsole::IResult *pResult, void *pUserData, IConsole::FCommandCallback pfnCallback, void *pCallbackUserData)
Definition: menus_settings_assets.cpp:706
int m_SettingPlayerPage
Definition: menus.h:250
SUIAnimator m_aAnimatorsSettingsTab[SETTINGS_LENGTH]
Definition: menus.h:741
void RenderServerbrowserStatusBox(CUIRect StatusBox, bool WasListboxItemActivated)
Definition: menus_browser.cpp:477
const CMenuImage * FindMenuImage(const char *pName)
Definition: menus.cpp:2437
void RenderServerbrowserCommunitiesFilter(CUIRect View)
Definition: menus_browser.cpp:978
void DoLaserPreview(const CUIRect *pRect, ColorHSLA OutlineColor, ColorHSLA InnerColor, const int LaserType)
Definition: menus.cpp:305
void SortGhostlist()
Definition: menus_ingame.cpp:1002
bool IsActive() const
Definition: menus.h:663
std::vector< CUIElement * > m_avpServerBrowserUiElements[IServerBrowser::NUM_TYPES]
Definition: menus.h:495
char m_aPopupMessage[IO_MAX_PATH_LENGTH+256]
Definition: menus.h:224
void RenderBackground()
Definition: menus.cpp:2318
STextContainerIndex m_MotdTextContainerIndex
Definition: menus.h:480
CGhostItem * GetOwnGhost()
Definition: menus_ingame.cpp:953
static float ms_ListitemAdditionalHeight
Definition: menus.h:242
void RenderIngameHint()
Definition: menus_ingame.cpp:1282
void RenderServerbrowserInfo(CUIRect View)
Definition: menus_browser.cpp:1137
static ColorRGBA ms_GuiColor
Definition: menus.h:62
ColorHSLA DoButton_ColorPicker(const CUIRect *pRect, unsigned int *pHslaColor, bool Alpha)
Definition: menus.cpp:414
static void LoadEntities(struct SCustomEntities *pEntitiesItem, void *pUser)
Definition: menus_settings_assets.cpp:38
void RenderSettingsGeneral(CUIRect MainView)
Definition: menus_settings.cpp:78
void UpdateOwnGhost(CGhostItem Item)
Definition: menus_ingame.cpp:961
static int ParticlesScan(const char *pName, int IsDir, int DirType, void *pUser)
Definition: menus_settings_assets.cpp:188
char m_aNextServer[256]
Definition: menus.h:180
void RenderServerbrowserToolBox(CUIRect ToolBox)
Definition: menus_browser.cpp:1734
std::vector< CGhostItem > m_vGhosts
Definition: menus.h:783
CLoadingState m_LoadingState
Definition: menus.h:201
int64_t m_DownloadLastCheckTime
Definition: menus.h:261
void PopupConfirm(const char *pTitle, const char *pMessage, const char *pConfirmButtonLabel, const char *pCancelButtonLabel, FPopupButtonCallback pfnConfirmButtonCallback=&CMenus::DefaultButtonCallback, int ConfirmNextPopup=POPUP_NONE, FPopupButtonCallback pfnCancelButtonCallback=&CMenus::DefaultButtonCallback, int CancelNextPopup=POPUP_NONE)
Definition: menus.cpp:967
void FetchAllHeaders()
Definition: menus_demo.cpp:1050
void FriendlistOnUpdate()
Definition: menus_browser.cpp:1670
std::chrono::nanoseconds m_PopupWarningDuration
Definition: menus.h:798
static void ConchainAssetEmoticons(IConsole::IResult *pResult, void *pUserData, IConsole::FCommandCallback pfnCallback, void *pCallbackUserData)
Definition: menus_settings_assets.cpp:691
int DoButton_CheckBox_Common(const void *pId, const char *pText, const char *pBoxText, const CUIRect *pRect)
Definition: menus.cpp:279
Definition: ui_scrollregion.h:90
Definition: serverbrowser.h:65
char m_aSkin[MAX_SKIN_LENGTH]
Definition: serverbrowser.h:75
char m_aName[MAX_NAME_LENGTH]
Definition: serverbrowser.h:67
char m_aClan[MAX_CLAN_LENGTH]
Definition: serverbrowser.h:68
Definition: serverbrowser.h:23
@ MAX_COMMUNITY_ID_LENGTH
Definition: serverbrowser.h:59
Definition: skins7.h:45
Definition: render.h:34
Definition: ui.h:149
Definition: ui_rect.h:11
EPopupMenuFunctionResult
Definition: ui.h:289
Definition: color.h:173
Definition: color.h:210
EClientState
Definition: client.h:49
Definition: config.h:9
Definition: console.h:45
void(* FCommandCallback)(IResult *pResult, void *pUserData)
Definition: console.h:92
ETickOffset
Definition: demo.h:78
Definition: serverbrowser.h:241
@ FRIEND_CLAN
Definition: friends.h:25
@ FRIEND_PLAYER
Definition: friends.h:26
Definition: graphics.h:200
@ CORNER_ALL
Definition: graphics.h:430
Definition: input.h:24
ECursorType
Definition: input.h:39
Definition: jobs.h:20
@ NUM_TYPES
Definition: serverbrowser.h:295
CConfig g_Config
Definition: config.cpp:12
@ MAX_TIMELINE_MARKERS
Definition: demo.h:15
@ MAX_CLAN_LENGTH
Definition: protocol.h:98
@ MAX_SKIN_LENGTH
Definition: protocol.h:99
@ MAX_NAME_LENGTH
Definition: protocol.h:97
pid_t PROCESS
Definition: system.h:2599
int str_comp_filenames(const char *a, const char *b)
Definition: system.cpp:2943
int str_comp_nocase(const char *a, const char *b)
Definition: system.cpp:2915
int str_comp(const char *a, const char *b)
Definition: system.cpp:2933
int str_copy(char *dst, const char *src, int dst_size)
Definition: system.cpp:2720
@ MAP_IMAGE_MOD_TYPE_COUNT
Definition: mapimages.h:30
@ SKINPART_BODY
Definition: protocol7.h:30
Definition: demo.h:31
unsigned char m_aLength[sizeof(int32_t)]
Definition: demo.h:39
unsigned char m_aMapSize[sizeof(int32_t)]
Definition: demo.h:36
Definition: friends.h:11
char m_aClan[MAX_CLAN_LENGTH]
Definition: friends.h:13
char m_aName[MAX_NAME_LENGTH]
Definition: friends.h:12
Definition: types.h:23
Definition: demo.h:52
Definition: menus.h:284
char m_aFilename[IO_MAX_PATH_LENGTH]
Definition: menus.h:285
CDemoHeader m_Info
Definition: menus.h:294
int NumMarkers() const
Definition: menus.h:298
int m_StorageType
Definition: menus.h:289
unsigned Size() const
Definition: menus.h:308
bool m_InfosLoaded
Definition: menus.h:292
bool operator<(const CDemoItem &Other) const
Definition: menus.h:313
char m_aName[IO_MAX_PATH_LENGTH]
Definition: menus.h:286
bool m_IsLink
Definition: menus.h:288
int Length() const
Definition: menus.h:303
CTimelineMarkers m_TimelineMarkers
Definition: menus.h:295
bool m_Valid
Definition: menus.h:293
time_t m_Date
Definition: menus.h:290
bool m_IsDir
Definition: menus.h:287
CMapInfo m_MapInfo
Definition: menus.h:296
Definition: menus.h:756
CGhostItem()
Definition: menus.h:766
bool HasFile() const
Definition: menus.h:772
bool operator<(const CGhostItem &Other) const
Definition: menus.h:769
bool m_Own
Definition: menus.h:763
time_t m_Date
Definition: menus.h:764
int m_Time
Definition: menus.h:761
char m_aPlayer[MAX_NAME_LENGTH]
Definition: menus.h:758
bool m_Failed
Definition: menus.h:760
int m_Slot
Definition: menus.h:762
bool Active() const
Definition: menus.h:771
char m_aFilename[IO_MAX_PATH_LENGTH]
Definition: menus.h:757
Definition: menus.h:184
IGraphics::CTextureHandle m_OrgTexture
Definition: menus.h:186
char m_aName[64]
Definition: menus.h:185
IGraphics::CTextureHandle m_GreyTexture
Definition: menus.h:187
Definition: menus.h:127
IGraphics::CTextureHandle m_Texture
Definition: menus.h:117
Definition: menus.h:114
SEntitiesImage m_aImages[MAP_IMAGE_MOD_TYPE_COUNT]
Definition: menus.h:119
Definition: menus.h:139
Definition: menus.h:123
Definition: menus.h:135
Definition: menus.h:105
bool operator<(const SCustomItem &Other) const
Definition: menus.h:110
char m_aName[50]
Definition: menus.h:108
IGraphics::CTextureHandle m_RenderTexture
Definition: menus.h:106
Definition: menus.h:131
bool m_New
Definition: menus.h:516
int m_Selection
Definition: menus.h:515
CMenus * m_pMenus
Definition: menus.h:514
Definition: menus.h:34
PROCESS m_Process
Definition: menus.h:35
Definition: demo.h:46
unsigned char m_aNumTimelineMarkers[sizeof(int32_t)]
Definition: demo.h:47
Definition: menus.h:53
SHA256_DIGEST m_Sha256
Definition: menus.h:55
char m_aCommunityId[CServerInfo::MAX_COMMUNITY_ID_LENGTH]
Definition: menus.h:54
IGraphics::CTextureHandle m_OrgTexture
Definition: menus.h:56
IGraphics::CTextureHandle m_GreyTexture
Definition: menus.h:57
Definition: hash.h:15
Definition: textrender.h:293
Definition: ui.h:39
unsigned bytes_be_to_uint(const unsigned char *bytes)
Definition: system.cpp:4085
TRISTATE
Definition: types.h:7
@ IO_MAX_PATH_LENGTH
Definition: types.h:43
vector2_base< float > vec2
Definition: vmath.h:158