#include <window_placement_helper.h>
Definition at line 6 of file window_placement_helper.h.
cfg_window_placement::cfg_window_placement |
( |
const GUID & |
p_guid | ) |
|
Retrieves state of the variable. Called only from main thread, when writing configuration file.
- Parameters
-
p_stream | Stream receiving state of the variable. |
Implements cfg_var_writer.
Definition at line 98 of file window_placement_helper.cpp.
104 PFC_ASSERT(IsWindow(window));
bool read_from_window(HWND window)
static bool g_is_enabled()
pfc::list_hybrid_t< HWND, 2 > m_windows
bool cfg_window_placement::on_window_creation |
( |
HWND |
window | ) |
|
Definition at line 68 of file window_placement_helper.cpp.
78 if (SetWindowPlacement(window,&
m_data))
static bool test_rect(const RECT *rc)
t_size add_item(const T &item)
static bool g_is_enabled()
pfc::list_hybrid_t< HWND, 2 > m_windows
bool have_item(const t_search &p_item) const
void cfg_window_placement::on_window_creation_silent |
( |
HWND |
window | ) |
|
Definition at line 64 of file window_placement_helper.cpp.
t_size add_item(const T &item)
pfc::list_hybrid_t< HWND, 2 > m_windows
bool have_item(const t_search &p_item) const
void cfg_window_placement::on_window_destruction |
( |
HWND |
window | ) |
|
Definition at line 89 of file window_placement_helper.cpp.
bool read_from_window(HWND window)
pfc::list_hybrid_t< HWND, 2 > m_windows
void remove_item(const T &item)
bool have_item(const t_search &p_item) const
bool cfg_window_placement::read_from_window |
( |
HWND |
window | ) |
|
Definition at line 41 of file window_placement_helper.cpp.
43 WINDOWPLACEMENT wp = {};
45 wp.length =
sizeof(wp);
46 if (!GetWindowPlacement(window,&wp)) {
47 PFC_ASSERT(!
"GetWindowPlacement fail!");
48 memset(&wp,0,
sizeof(wp));
static bool g_is_enabled()
Sets state of the variable. Called only from main thread, when reading configuration file.
- Parameters
-
p_stream | Stream containing new state of the variable. |
p_sizehint | Number of bytes contained in the stream; reading past p_sizehint bytes will fail (EOF). |
Implements cfg_var_reader.
Definition at line 115 of file window_placement_helper.cpp.
116 if (p_sizehint == 0)
return;
117 WINDOWPLACEMENT temp;
119 p_stream->read_object(&temp,
sizeof(temp),p_abort);
120 }
catch(exception_io_data) {
return;}
121 if (temp.length ==
sizeof(temp))
m_data = temp;
WINDOWPLACEMENT cfg_window_placement::m_data |
|
private |
The documentation for this class was generated from the following files: