LeviLamina
Loading...
Searching...
No Matches
FactoryComponent.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/client/gui/ChildInsertPosition.h"
7#include "mc/client/gui/controls/UIComponent.h"
8
9// auto generated forward declare list
10// clang-format off
11class UIControl;
13class UIPropertyBag;
14namespace Json { class Value; }
15// clang-format on
16
17class FactoryComponent : public ::UIComponent {
18public:
19 // member variables
20 // NOLINTBEGIN
21 ::ll::TypedStorage<8, 16, ::std::weak_ptr<::UIControlFactory>> mControlFactory;
22 ::ll::TypedStorage<8, 32, ::std::string> mFactoryName;
23 ::ll::TypedStorage<8, 64, ::std::unordered_map<::std::string, ::std::string>> mControlIdToTemplateLookup;
24 ::ll::TypedStorage<8, 24, ::std::vector<::std::pair<::std::string const, ::Json::Value const>>> mVariables;
25 ::ll::TypedStorage<8, 16, ::std::shared_ptr<::UIControl>> mControlTemplate;
26 ::ll::TypedStorage<8, 24, ::std::vector<::std::weak_ptr<::UIControl>>> mProgeny;
27 ::ll::TypedStorage<1, 1, bool> mFactoryIsChild;
28 ::ll::TypedStorage<4, 4, int> mMaxSize;
29 ::ll::TypedStorage<4, 4, ::ui::ChildInsertPosition> mInsertPosition;
30 // NOLINTEND
31
32public:
33 // prevent constructor by default
34 FactoryComponent();
35
36public:
37 // virtual functions
38 // NOLINTBEGIN
39 virtual ::std::unique_ptr<::UIComponent> clone(::UIControl& cloneOwner) const /*override*/;
40
41 virtual void reset() /*override*/;
42 // NOLINTEND
43
44public:
45 // member functions
46 // NOLINTBEGIN
47 MCAPI FactoryComponent(::UIControl& owner, ::std::weak_ptr<::UIControlFactory> factoryPtr);
48
49 MCAPI void _prepareControlForDestruction(::std::shared_ptr<::UIControl> control);
50
51 MCAPI void addVariable(::std::string const& varName, ::Json::Value const& var);
52
53 MCAPI ::std::weak_ptr<::UIControl> create(::UIPropertyBag const& properties, bool ensureCreation);
54
55 MCAPI void destroy(::std::string const& name);
56
57 MCAPI void destroyAll();
58
59 MCAPI void destroyAllStartingAtIndex(uint const index);
60 // NOLINTEND
61
62public:
63 // constructor thunks
64 // NOLINTBEGIN
65 MCAPI void* $ctor(::UIControl& owner, ::std::weak_ptr<::UIControlFactory> factoryPtr);
66 // NOLINTEND
67
68public:
69 // virtual function thunks
70 // NOLINTBEGIN
71 MCAPI ::std::unique_ptr<::UIComponent> $clone(::UIControl& cloneOwner) const;
72
73 MCFOLD void $reset();
74 // NOLINTEND
75
76public:
77 // vftables
78 // NOLINTBEGIN
79 MCNAPI static void** $vftable();
80 // NOLINTEND
81};
Definition FactoryComponent.h:5
static MCAPI void ** $vftable()
Definition Value.h:16
Definition UIComponent.h:5
Definition UIControlFactory.h:5
Definition UIControl.h:5
Definition UIPropertyBag.h:5