LeviLamina
Loading...
Searching...
No Matches
Library.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/client/gui/oreui/ViewCacheMode.h"
7#include "mc/client/gui/oreui/views/FramesToPaintQueue.h"
8#include "mc/common/SubClientId.h"
9#include "mc/deps/core/utility/NonOwnerPointer.h"
10
11// auto generated forward declare list
12// clang-format off
13class IClientInstance;
15class TaskGroup;
17namespace Core { class Path; }
18namespace Gameface { class ResourceHandlerBroker; }
19namespace Gameface { class TemporaryTextureHolder; }
20namespace OreUI { class IFacetRegistry; }
21namespace OreUI { class ILiveViewCollectionConsumer; }
22namespace OreUI { class IRenderingBackend; }
23namespace OreUI { class IViewProvider; }
24namespace OreUI { class InternationalizationManager; }
25namespace OreUI { class LayoutScheduler; }
26namespace OreUI { class ViewsCoordinator; }
27namespace OreUI { struct DebugData; }
28namespace OreUI { struct ViewId; }
29namespace OreUI::Detail { class ViewContextFactory; }
30namespace cohtml { class IAllocator; }
31namespace cohtml { class IFileSystemReader; }
32namespace cohtml { class ITimeZoneProvider; }
33namespace cohtml { class IVirtualAllocator; }
34namespace cohtml { class Library; }
35namespace cohtml { class System; }
36namespace cohtml { class SystemRenderer; }
37namespace cohtml { struct PlatformSpecificParams; }
38namespace cohtml::Logging { class ILogHandler; }
39namespace cohtml::Profile { class IPerformanceHandler; }
40namespace mce { class RenderContext; }
41namespace mce { class ShaderGroup; }
42// clang-format on
43
44namespace OreUI {
45
46class Library {
47public:
48 // Library inner types declare
49 // clang-format off
50 struct Impl;
51 // clang-format on
52
53 // Library inner types define
54 struct Impl {
55 public:
56 // member variables
57 // NOLINTBEGIN
58 ::ll::TypedStorage<8, 104, ::OreUI::FramesToPaintQueue> mFramesToPaint;
59 // NOLINTEND
60 };
61
62public:
63 // member variables
64 // NOLINTBEGIN
65 ::ll::TypedStorage<8, 8, ::gsl::not_null<::std::unique_ptr<::OreUI::Library::Impl>>> mImpl;
66 ::ll::TypedStorage<8, 8, ::cohtml::System*> mSystem;
67 ::ll::TypedStorage<8, 8, ::cohtml::SystemRenderer*> mSystemRenderer;
68 ::ll::TypedStorage<8, 8, ::cohtml::Library*> mLibrary;
69 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::cohtml::IAllocator>> mAllocator;
70 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::cohtml::IFileSystemReader>> mFileSystemReader;
71 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::Gameface::ResourceHandlerBroker>> mResourceHandler;
72 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::OreUI::InternationalizationManager>> mInternationalizationManager;
73 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::OreUI::IRenderingBackend>> mRenderingBackend;
74 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::cohtml::Logging::ILogHandler>> mLogHandler;
75 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::cohtml::Profile::IPerformanceHandler>> mPerformanceHandler;
76 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::cohtml::ITimeZoneProvider>> mTimeZoneProvider;
77 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::OreUI::LayoutScheduler>> mLayoutScheduler;
78 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::OreUI::ViewsCoordinator>> mViews;
79 ::ll::TypedStorage<8, 8, ::Gameface::TemporaryTextureHolder&> mTemporaryTextureHolder;
80 ::ll::TypedStorage<8, 8, ::gsl::not_null<::std::unique_ptr<::OreUI::ILiveViewCollectionConsumer>>>
81 mLiveViewConsumer;
82 ::ll::TypedStorage<8, 8, ::OreUI::DebugData&> mDebugData;
83 ::ll::TypedStorage<8, 24, ::std::vector<::std::string>> mRegisteredFonts;
84 ::ll::TypedStorage<1, 1, bool> mDoCompleteUninitialization;
85 ::ll::TypedStorage<1, 1, bool> mSuspended;
86 ::ll::TypedStorage<1, 1, bool> mICUDataInitialized;
87 ::ll::TypedStorage<8, 16, ::std::thread> mResourceThread;
88 // NOLINTEND
89
90public:
91 // prevent constructor by default
92 Library& operator=(Library const&);
93 Library(Library const&);
94 Library();
95
96public:
97 // member functions
98 // NOLINTBEGIN
99 MCAPI Library(
100 ::cohtml::PlatformSpecificParams const& platformParams,
101 ::std::unique_ptr<::cohtml::IAllocator> allocator,
102 ::std::unique_ptr<::cohtml::IFileSystemReader> fileSystemReader,
103 ::Core::Path const& packagePath,
104 ::std::unique_ptr<::Gameface::ResourceHandlerBroker> resourceHandler,
105 ::std::unique_ptr<::cohtml::Logging::ILogHandler> logHandler,
106 ::Gameface::TemporaryTextureHolder& temporaryTextureHolder,
107 ::OreUI::DebugData& debugData,
108 ::std::unique_ptr<::OreUI::ILiveViewCollectionConsumer> liveViewConsumer
109 );
110
111 MCAPI void _initializeSystem(::cohtml::PlatformSpecificParams const&);
112
113 MCAPI void _loadFonts(::Core::Path const& packagePath);
114
115 MCAPI void _loadICUData(::TaskGroup& taskGroup, ::Core::Path const& packagePath);
116
117 MCAPI bool assetsInitialized() const;
118
119 MCAPI void clearUnusedCachedViews(::SubClientId subClientId);
120
121 MCAPI ::OreUI::ViewId createView(
122 ::OreUI::Detail::ViewContextFactory& contextFactory,
123 ::std::string const& viewPath,
124 ::std::unique_ptr<::OreUI::IFacetRegistry> facets,
125 ::IClientInstance& clientInstance,
126 ::OreUI::ViewCacheMode viewCacheMode
127 );
128
129 MCAPI ::std::unique_ptr<::IGamefaceTextInputProxy> getTextInputProxy();
130
131 MCAPI ::Bedrock::NotNullNonOwnerPtr<::OreUI::IViewProvider> getViewProvider();
132
133 MCAPI void initializeAssetsAsynchronously(::TaskGroup& taskGroup, ::Core::Path const& packagePath);
134
135 MCAPI void initializeRendering(
136 ::Bedrock::NonOwnerPointer<::mce::ShaderGroup> shaderGroup,
137 ::mce::RenderContext& renderContext
138 );
139
140 MCAPI void initializeViewsCoordinator();
141
142 MCFOLD void onActiveResourcePacksChanged();
143
144 MCAPI void onAppPreSuspended(::mce::RenderContext&);
145
146 MCAPI void onAppResumed(::Bedrock::NonOwnerPointer<::mce::ShaderGroup> const& shaderGroup);
147
148 MCAPI void onKeyboardDismissed();
149
150 MCFOLD void reloadAllViews();
151
152 MCAPI void setCompleteUninitialization();
153
154 MCAPI void setTextBoxState(::TextBoxStateChange const& stateChange);
155
156 MCAPI void update(double time);
157
158 MCAPI ~Library();
159 // NOLINTEND
160
161public:
162 // static variables
163 // NOLINTBEGIN
164 MCAPI static ::std::unique_ptr<::cohtml::IVirtualAllocator>& mVirtualAllocator();
165 // NOLINTEND
166
167public:
168 // constructor thunks
169 // NOLINTBEGIN
170 MCAPI void* $ctor(
171 ::cohtml::PlatformSpecificParams const& platformParams,
172 ::std::unique_ptr<::cohtml::IAllocator> allocator,
173 ::std::unique_ptr<::cohtml::IFileSystemReader> fileSystemReader,
174 ::Core::Path const& packagePath,
175 ::std::unique_ptr<::Gameface::ResourceHandlerBroker> resourceHandler,
176 ::std::unique_ptr<::cohtml::Logging::ILogHandler> logHandler,
177 ::Gameface::TemporaryTextureHolder& temporaryTextureHolder,
178 ::OreUI::DebugData& debugData,
179 ::std::unique_ptr<::OreUI::ILiveViewCollectionConsumer> liveViewConsumer
180 );
181 // NOLINTEND
182
183public:
184 // destructor thunk
185 // NOLINTBEGIN
186 MCAPI void $dtor();
187 // NOLINTEND
188};
189
190} // namespace OreUI
Definition Path.h:12
Definition ResourceHandlerBroker.h:7
Definition TemporaryTextureHolder.h:7
Definition IClientInstance.h:5
Definition IGamefaceTextInputProxy.h:5
Definition ViewContextFactory.h:7
Definition IFacetRegistry.h:7
Definition ILiveViewCollectionConsumer.h:7
Definition IRenderingBackend.h:7
Definition IViewProvider.h:7
Definition InternationalizationManager.h:7
Definition LayoutScheduler.h:7
Definition Library.h:7
Definition ViewsCoordinator.h:7
Definition TaskGroup.h:55
Definition IAllocator.h:7
Definition IFileSystemReader.h:7
Definition ITimeZoneProvider.h:7
Definition IVirtualAllocator.h:7
Definition Library.h:7
Definition ILogHandler.h:7
Definition IPerformanceHandler.h:7
Definition SystemRenderer.h:7
Definition System.h:7
Definition RenderContext.h:7
Definition ShaderGroup.h:7
Definition DebugData.h:7
Definition Library.h:15
Definition ViewId.h:7
Definition TextBoxStateChange.h:5
Definition PlatformSpecificParams.h:7