-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCUIElement.h
More file actions
101 lines (76 loc) · 2.19 KB
/
Copy pathCUIElement.h
File metadata and controls
101 lines (76 loc) · 2.19 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
/** $VER: CUIElement.h (2026.07.25) P. Stuer - Columns User Interface support **/
#pragma once
#include "PlaylistUIElement.h"
#include <ui_extension.h>
namespace uie
{
class cui_color_client_t;
/// <summary>
/// Implements a Columns UI element.
/// </summary>
class cui_element_t : public playlist_uielement_t, public uie::window
{
public:
cui_element_t();
cui_element_t(const cui_element_t &) = delete;
cui_element_t & operator=(const cui_element_t &) = delete;
cui_element_t(cui_element_t &&) = delete;
cui_element_t & operator=(cui_element_t &&) = delete;
virtual ~cui_element_t() { }
#pragma region uie::window
/// <summary>
/// Gets the category of the extension.
/// </summary>
void get_category(pfc::string_base & out) const final
{
out = "Panels";
}
/// <summary>
/// Gets the type of the extension.
/// </summary>
uint32_t get_type() const final
{
return uie::type_panel;
}
HWND create_or_transfer_window(HWND parent, const window_host_ptr & newHost, const ui_helpers::window_position_t & position);
virtual void destroy_window();
/// <summary>
/// Returns true if the extension is available.
/// </summary>
virtual bool is_available(const window_host_ptr & p) const
{
return true;
}
/// <summary>
/// Gets the window handle of the extension.
/// </summary>
virtual HWND get_wnd() const
{
return *this;
}
#pragma endregion
#pragma region extension_base
/// <summary>
/// Gets the unique ID of extension.
/// </summary>
const GUID & get_extension_guid() const
{
return GetGUID();
}
/// <summary>
/// Gets a user-readable name of the extension.
/// </summary>
void get_name(pfc::string_base & out) const
{
out = STR_COMPONENT_NAME;
}
void set_config(stream_reader * stream, size_t size, abort_callback & abortHandler) final;
void get_config(stream_writer * stream, abort_callback & abortHandler) const final;
#pragma endregion
void GetColors() noexcept final;
void GetFonts() noexcept final;
private:
window_host_ptr _Host;
HWND _hParent;
};
}