LeviLamina
Loading...
Searching...
No Matches
OreUISystem.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/client/gui/oreui/LiveViewCollection.h"
7#include "mc/client/gui/oreui/resources/TemporaryTextureHolder.h"
8#include "mc/client/gui/oreui/routing/RouterConfiguration.h"
9#include "mc/deps/core/file/Path.h"
10#include "mc/deps/core/utility/NonOwnerPointer.h"
11#include "mc/deps/core/utility/pub_sub/Subscription.h"
12#include "mc/platform/brstd/move_only_function.h"
13
14// auto generated forward declare list
15// clang-format off
16class IClientInstance;
17class IFileAccess;
18class IOptionRegistry;
19class ISceneStack;
20class SceneFactory;
21namespace Core { class FileSystem; }
22namespace Gameface { class ResourceHandlerBroker; }
23namespace Input::Debug { class ISplitscreenRedirect; }
24namespace OreUI { class FacetRegistryFactory; }
25namespace OreUI { class IRoutePrerequisiteHandler; }
26namespace OreUI { class Library; }
27namespace OreUI { class ResourceAllowList; }
28namespace OreUI { class Router; }
29namespace OreUI { class RouterEventing; }
30namespace OreUI { class SceneProvider; }
31namespace OreUI { struct DebugData; }
32namespace OreUI { struct LibraryFactoryArguments; }
33namespace OreUI { struct RegisterResourceHandlersArguments; }
34namespace OreUI { struct ResourceHandlerFactory; }
35namespace OreUI { struct ResourceHandlerFactoryArguments; }
36namespace OreUI::Debug { class DevServerListener; }
37namespace OreUI::Detail { class ViewContextFactory; }
38// clang-format on
39
40namespace OreUI {
41
42class OreUISystem {
43public:
44 // OreUISystem inner types declare
45 // clang-format off
47 struct Impl;
48 struct CallbackEntry;
49 // clang-format on
50
51 // OreUISystem inner types define
53 public:
54 // OreUISystemDependencies inner types define
55 using ResourceHandlerBrokerFactory = ::brstd::move_only_function<::std::unique_ptr<
56 ::Gameface::ResourceHandlerBroker>(::OreUI::RegisterResourceHandlersArguments const&) const>;
57
58 using LibraryFactory =
59 ::brstd::move_only_function<::std::unique_ptr<::OreUI::Library>(::OreUI::LibraryFactoryArguments&&) const>;
60
61 using SceneProviderFactory = ::brstd::move_only_function<::std::unique_ptr<::OreUI::SceneProvider>(
62 ::Bedrock::NotNullNonOwnerPtr<::IClientInstance> const&,
63 ::std::unique_ptr<::OreUI::FacetRegistryFactory>,
64 ::std::unique_ptr<::OreUI::Detail::ViewContextFactory>,
65 ::OreUI::Library&
66 ) const>;
67
68 public:
69 // member variables
70 // NOLINTBEGIN
71 ::ll::TypedStorage<
72 8,
73 64,
74 ::brstd::move_only_function<::std::unique_ptr<
75 ::Gameface::ResourceHandlerBroker>(::OreUI::RegisterResourceHandlersArguments const&) const>>
76 mCreateResourceHandlerBroker;
77 ::ll::TypedStorage<
78 8,
79 64,
80 ::brstd::move_only_function<::std::unique_ptr<::OreUI::Library>(::OreUI::LibraryFactoryArguments&&) const>>
81 mCreateLibrary;
82 ::ll::TypedStorage<
83 8,
84 64,
85 ::brstd::move_only_function<::std::unique_ptr<::OreUI::SceneProvider>(
86 ::Bedrock::NotNullNonOwnerPtr<::IClientInstance> const&,
87 ::std::unique_ptr<::OreUI::FacetRegistryFactory>,
88 ::std::unique_ptr<::OreUI::Detail::ViewContextFactory>,
89 ::OreUI::Library&
90 ) const>>
91 mSceneProviderFactory;
92 ::ll::TypedStorage<8, 208, ::OreUI::RouterConfiguration> mRouterConfiguration;
93 ::ll::TypedStorage<8, 32, ::Core::Path> mPackagePath;
94 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::OreUI::ResourceAllowList>> mAllowList;
95 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::OreUI::DebugData>> mDebugData;
96 ::ll::TypedStorage<8, 64, ::std::function<void(::std::string_view)>> mShowDebugToast;
97 ::ll::TypedStorage<8, 24, ::OreUI::LiveViewCollection> mLiveViewCollection;
98 ::ll::TypedStorage<8, 24, ::Bedrock::NotNullNonOwnerPtr<::Input::Debug::ISplitscreenRedirect>>
99 mDebugSplitscreenInputRedirect;
100 // NOLINTEND
101
102 public:
103 // static functions
104 // NOLINTBEGIN
105 MCAPI static ::brstd::move_only_function<::std::unique_ptr<::OreUI::Library>(::OreUI::LibraryFactoryArguments&&)
106 const>
107 createLibraryFactory(
108 ::Bedrock::NotNullNonOwnerPtr<::Core::FileSystem> fileSystem,
109 ::Bedrock::NotNullNonOwnerPtr<::IFileAccess> appPackageFileAccess
110 );
111
112 MCAPI static ::brstd::move_only_function<::std::unique_ptr<
113 ::Gameface::ResourceHandlerBroker>(::OreUI::RegisterResourceHandlersArguments const&) const>
114 createResourceHandlerBrokerFactory(::OreUI::ResourceHandlerFactoryArguments const& args);
115
116 MCAPI static ::OreUI::ResourceHandlerFactory
117 createResourceHandlerFactory(::OreUI::ResourceHandlerFactoryArguments const& args);
118 // NOLINTEND
119 };
120
121 struct Impl {
122 public:
123 // member variables
124 // NOLINTBEGIN
125 ::ll::TypedStorage<8, 8, ::gsl::not_null<::std::unique_ptr<::OreUI::ResourceAllowList>>> mResourceAllowList;
126 ::ll::TypedStorage<
127 8,
128 64,
129 ::brstd::move_only_function<::std::unique_ptr<::OreUI::SceneProvider>(
130 ::Bedrock::NotNullNonOwnerPtr<::IClientInstance> const&,
131 ::std::unique_ptr<::OreUI::FacetRegistryFactory>,
132 ::std::unique_ptr<::OreUI::Detail::ViewContextFactory>,
133 ::OreUI::Library&
134 ) const>>
135 mCreateSceneProvider;
136 ::ll::TypedStorage<8, 208, ::OreUI::RouterConfiguration> mRouterConfiguration;
137 ::ll::TypedStorage<8, 104, ::Gameface::TemporaryTextureHolder> mTemporaryTextureHolder;
138 ::ll::TypedStorage<8, 8, ::gsl::not_null<::std::unique_ptr<::OreUI::DebugData>>> mDebugData;
139 ::ll::TypedStorage<8, 64, ::std::function<void(::std::string_view)>> mShowDebugToast;
140 // NOLINTEND
141 };
142
143 struct CallbackEntry {
144 public:
145 // member variables
146 // NOLINTBEGIN
147 ::ll::TypedStorage<8, 8, void*> token;
148 ::ll::TypedStorage<8, 64, ::std::function<void()>> callback;
149 // NOLINTEND
150 };
151
152public:
153 // member variables
154 // NOLINTBEGIN
155 ::ll::TypedStorage<8, 8, ::gsl::not_null<::std::unique_ptr<::OreUI::OreUISystem::Impl>>> mImpl;
156 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::OreUI::Library>> mLibrary;
157 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::OreUI::Debug::DevServerListener>> mDevServerListener;
158 ::ll::TypedStorage<1, 1, bool> mAppWillRestart;
159 ::ll::TypedStorage<8, 24, ::std::vector<::OreUI::OreUISystem::CallbackEntry>> mRouteConfigurationChangeCallbacks;
160 ::ll::TypedStorage<8, 24, ::std::vector<::Bedrock::PubSub::Subscription>> mOptionSubscriptions;
161 ::ll::TypedStorage<8, 16, ::Bedrock::PubSub::Subscription> mFlightingTogglesTrialMode;
162 ::ll::TypedStorage<8, 16, ::Bedrock::PubSub::Subscription> mFlightingTogglesFriendsDrawerOnMultipleScreens;
163 ::ll::TypedStorage<8, 16, ::Bedrock::PubSub::Subscription> mFlightingTogglesSettingsScreen;
164 ::ll::TypedStorage<8, 16, ::Bedrock::PubSub::Subscription> mFlightingTogglesPreviewSettingsScreen;
165 ::ll::TypedStorage<8, 16, ::Bedrock::PubSub::Subscription> mFlightingTogglesStorageSettingsScreen;
166 ::ll::TypedStorage<8, 16, ::Bedrock::PubSub::Subscription> mFlightingTogglesNewSettingsInGame;
167 ::ll::TypedStorage<8, 16, ::Bedrock::PubSub::Subscription> mFlightingTogglesNewSettingsOnThirdPartyServers;
168 ::ll::TypedStorage<8, 16, ::Bedrock::PubSub::Subscription> mFlightingTogglesCloudStorageManager;
169 // NOLINTEND
170
171public:
172 // prevent constructor by default
173 OreUISystem();
174
175public:
176 // member functions
177 // NOLINTBEGIN
178 MCAPI explicit OreUISystem(::OreUI::OreUISystem::OreUISystemDependencies&& deps);
179
180 MCAPI ::std::unique_ptr<::OreUI::Router> createInGameRouter(
181 ::std::unique_ptr<::OreUI::IRoutePrerequisiteHandler> prerequisiteHandler,
182 ::std::unique_ptr<::OreUI::RouterEventing> routerEventing,
183 ::SceneFactory& sceneFactory,
184 ::Bedrock::NotNullNonOwnerPtr<::ISceneStack> const& sceneStack
185 ) const;
186
187 MCAPI ::std::unique_ptr<::OreUI::Router> createOutOfGameRouter(
188 ::std::unique_ptr<::OreUI::IRoutePrerequisiteHandler> prerequisiteHandler,
189 ::std::unique_ptr<::OreUI::RouterEventing> routerEventing,
190 ::SceneFactory& sceneFactory,
191 ::Bedrock::NotNullNonOwnerPtr<::ISceneStack> const& sceneStack
192 ) const;
193
194 MCAPI ::std::unique_ptr<::OreUI::SceneProvider> createSceneProvider(
195 ::Bedrock::NotNullNonOwnerPtr<::IClientInstance> const& clientInstance,
196 ::std::unique_ptr<::OreUI::FacetRegistryFactory> facetRegistryFactory,
197 ::std::unique_ptr<::OreUI::Detail::ViewContextFactory> contextFactory
198 ) const;
199
200 MCAPI void registerOptionObservers(::IOptionRegistry& options);
201
202 MCAPI void registerRouteConfigurationChangeCallback(void* token, ::std::function<void()> const& callback);
203
204 MCAPI void unregisterRouteConfigurationChangeCallback(void* token);
205
206 MCAPI void update(double time);
207
208 MCAPI ~OreUISystem();
209 // NOLINTEND
210
211public:
212 // constructor thunks
213 // NOLINTBEGIN
214 MCAPI void* $ctor(::OreUI::OreUISystem::OreUISystemDependencies&& deps);
215 // NOLINTEND
216
217public:
218 // destructor thunk
219 // NOLINTBEGIN
220 MCAPI void $dtor();
221 // NOLINTEND
222};
223
224} // namespace OreUI
Definition FileSystem.h:28
Definition ResourceHandlerBroker.h:7
Definition IClientInstance.h:5
Definition IFileAccess.h:15
Definition IOptionRegistry.h:5
Definition ISceneStack.h:5
Definition ISplitscreenRedirect.h:7
Definition DevServerListener.h:7
Definition ViewContextFactory.h:7
Definition FacetRegistryFactory.h:7
Definition IRoutePrerequisiteHandler.h:7
Definition Library.h:7
Definition OreUISystem.h:7
Definition ResourceAllowList.h:7
Definition RouterEventing.h:7
Definition Router.h:7
Definition SceneProvider.h:7
Definition SceneFactory.h:5
Definition DebugData.h:7
Definition LibraryFactoryArguments.h:7
Definition OreUISystem.h:21
Definition OreUISystem.h:19
Definition RegisterResourceHandlersArguments.h:7
Definition ResourceHandlerFactoryArguments.h:7
Definition ResourceHandlerFactory.h:7