LeviLamina
Loading...
Searching...
No Matches
EDUServersScreenController.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/client/gui/DirtyFlag.h"
7#include "mc/client/gui/ViewRequest.h"
8#include "mc/client/gui/screens/controllers/EduRefreshType.h"
9#include "mc/client/gui/screens/controllers/SettingsScreenControllerBase.h"
10#include "mc/deps/core/file/PathBuffer.h"
11#include "mc/deps/core/threading/BasicLockbox.h"
12#include "mc/deps/core/threading/TaskGroup.h"
13#include "mc/platform/brstd/flat_map.h"
14#include "mc/platform/threading/Mutex.h"
15#include "mc/social/EduResponseError.h"
16
17// auto generated forward declare list
18// clang-format off
19class DlcUIWrapper;
22class IContentManager;
23class PlayScreenModel;
24class UIPropertyBag;
26struct ScreenEvent;
27namespace Json { class Value; }
28namespace Social { struct EduDedicatedServerDetails; }
29// clang-format on
30
32public:
33 // member variables
34 // NOLINTBEGIN
35 ::ll::TypedStorage<8, 16, ::std::shared_ptr<::PlayScreenModel>> mPlayScreenModel;
36 ::ll::TypedStorage<1, 1, bool> mShowNestedButtons;
37 ::ll::TypedStorage<1, 1, bool> mMatchedServersNeedsRefresh;
38 ::ll::TypedStorage<8, 32, ::std::string> mSearchString;
39 ::ll::TypedStorage<8, 32, ::std::string> mAddServerInfoString;
40 ::ll::TypedStorage<8, 32, ::std::string> mMostRecentlyAddedServer;
41 ::ll::TypedStorage<8, 24, ::std::vector<::std::string>> mMatchedServers;
42 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::DlcUIWrapper>> mDlcUIWrapper;
43 ::ll::TypedStorage<8, 8, ::PackManagerContentSource*> mWorldContentSource;
44 ::ll::TypedStorage<8, 8, ::IContentManager&> mContentManager;
45 ::ll::TypedStorage<1, 1, bool> mHasInitializedServerList;
46 ::ll::TypedStorage<1, 1, bool> mErrorFromRefresh;
47 ::ll::TypedStorage<1, 1, bool> mIsDoneLoadingKnownServers;
48 ::ll::TypedStorage<1, 1, bool> mIsDoneLoadingUnknownServers;
49 ::ll::TypedStorage<1, 1, bool> mIsDoneFetchHandler;
50 ::ll::TypedStorage<1, 1, bool> mNeedsRefocus;
51 ::ll::TypedStorage<8, 8, ::std::chrono::steady_clock::time_point> mLastFullServerInfoRefresh;
52 ::ll::TypedStorage<8, 40, ::std::queue<::Social::EduResponseError, ::std::deque<::Social::EduResponseError>>>
53 mFetchErrorQueue;
54 ::ll::TypedStorage<8, 40, ::std::queue<::Social::EduResponseError, ::std::deque<::Social::EduResponseError>>>
55 mAddErrorQueue;
56 ::ll::TypedStorage<8, 32, ::std::string> mBannerErrorString;
57 ::ll::TypedStorage<1, 1, bool> mPopupOpen;
58 ::ll::TypedStorage<8, 32, ::std::string> mAddServerId;
59 ::ll::TypedStorage<8, 32, ::std::string> mJoinServerId;
60 ::ll::TypedStorage<
61 8,
62 48,
63 ::brstd::flat_map<
64 ::std::string,
65 ::std::string,
66 ::std::less<::std::string>,
67 ::std::vector<::std::string>,
68 ::std::vector<::std::string>>>
69 mUnmatchedServers;
70 ::ll::TypedStorage<8, 16, ::std::shared_ptr<::EDUAddServerScreenController>> mAddServerScreenController;
71 ::ll::TypedStorage<8, 16, ::std::shared_ptr<::EDUPasscodeEntryScreenController>> mPasscodeEntryScreenController;
72 ::ll::TypedStorage<
73 8,
74 128,
75 ::Bedrock::Threading::BasicLockbox<
76 ::brstd::flat_map<
77 ::std::string,
78 ::Social::EduDedicatedServerDetails,
79 ::std::less<::std::string>,
80 ::std::vector<::std::string>,
81 ::std::vector<::Social::EduDedicatedServerDetails>>,
82 ::Bedrock::Threading::Mutex>>
83 mServersBox;
84 ::ll::TypedStorage<8, 32, ::Core::PathBuffer<::std::string>> mCacheFilePath;
85 ::ll::TypedStorage<8, 336, ::TaskGroup> mTaskGroup;
86 // NOLINTEND
87
88public:
89 // prevent constructor by default
90 EDUServersScreenController& operator=(EDUServersScreenController const&);
91 EDUServersScreenController(EDUServersScreenController const&);
92 EDUServersScreenController();
93
94public:
95 // virtual functions
96 // NOLINTBEGIN
97 virtual ~EDUServersScreenController() /*override*/ = default;
98
99 virtual void onOpen() /*override*/;
100
101 virtual void onTerminate() /*override*/;
102
103 virtual ::ui::DirtyFlag tick() /*override*/;
104
105 virtual ::ui::ViewRequest handleEvent(::ScreenEvent& screenEvent) /*override*/;
106
107 virtual void addStaticScreenVars(::Json::Value& globalVars) /*override*/;
108 // NOLINTEND
109
110public:
111 // member functions
112 // NOLINTBEGIN
113 MCAPI explicit EDUServersScreenController(::std::shared_ptr<::PlayScreenModel> model);
114
115 MCAPI void _closeAddServerModal();
116
117 MCAPI void _closePasscodeEntryModal();
118
119 MCAPI void _closeSharePopup();
120
121 MCAPI ::std::optional<::Social::EduDedicatedServerDetails> _getServerDetails(::UIPropertyBag& bag) const;
122
123 MCAPI void _launchShareUri(::std::string const& uri, ::std::string const& toastMsg, ::std::string const& eventName);
124
125 MCAPI void _refreshServerInfo(::std::vector<::std::string> serverIds, ::Social::EduRefreshType const& refreshType);
126
127 MCAPI void _requestAddServer(::std::string const& serverId);
128
129 MCAPI void _requestJoinServer(::Social::EduDedicatedServerDetails const& details, ::std::string const& passcode);
130
131 MCAPI void _showAddServerModal();
132
133 MCAPI void _showFetchErrorMessage(::Social::EduResponseError& error);
134
135 MCAPI void _showPasscodeEntryModal(::Social::EduDedicatedServerDetails const& details);
136 // NOLINTEND
137
138public:
139 // static functions
140 // NOLINTBEGIN
141 MCAPI static uint64 _getTileIndex(::UIPropertyBag& bag);
142 // NOLINTEND
143
144public:
145 // constructor thunks
146 // NOLINTBEGIN
147 MCAPI void* $ctor(::std::shared_ptr<::PlayScreenModel> model);
148 // NOLINTEND
149
150public:
151 // virtual function thunks
152 // NOLINTBEGIN
153 MCAPI void $onOpen();
154
155 MCAPI void $onTerminate();
156
157 MCAPI ::ui::DirtyFlag $tick();
158
159 MCAPI ::ui::ViewRequest $handleEvent(::ScreenEvent& screenEvent);
160
161 MCAPI void $addStaticScreenVars(::Json::Value& globalVars);
162 // NOLINTEND
163};
Definition DlcUIWrapper.h:5
Definition EDUAddServerScreenController.h:5
Definition EDUPasscodeEntryScreenController.h:5
Definition EDUServersScreenController.h:5
Definition IContentManager.h:5
Definition Value.h:16
Definition PlayScreenModel.h:5
Definition SettingsScreenControllerBase.h:5
Definition UIPropertyBag.h:5
Definition PackManagerContentSource.h:5
Definition ScreenEvent.h:5
Definition EduDedicatedServerDetails.h:15