MCPcopy Create free account
hub / github.com/apache/arrow / CustomWindow

Method CustomWindow

cpp/src/arrow/flight/sql/odbc/odbc_impl/ui/custom_window.cc:87–108  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

85}
86
87CustomWindow::CustomWindow(Window* parent, const wchar_t* class_name,
88 const wchar_t* title)
89 : Window(parent, class_name, title) {
90 WNDCLASS wcx;
91
92 wcx.style = CS_HREDRAW | CS_VREDRAW;
93 wcx.lpfnWndProc = WndProc;
94 wcx.cbClsExtra = 0;
95 wcx.cbWndExtra = 0;
96 wcx.hInstance = GetHInstance();
97 wcx.hIcon = NULL;
98 wcx.hCursor = LoadCursor(NULL, IDC_ARROW);
99 wcx.hbrBackground = (HBRUSH)COLOR_WINDOW;
100 wcx.lpszMenuName = NULL;
101 wcx.lpszClassName = class_name;
102
103 if (!RegisterClass(&wcx)) {
104 std::stringstream buf;
105 buf << "Can not register window class, error code: " << GetLastError();
106 throw DriverException(buf.str());
107 }
108}
109
110CustomWindow::~CustomWindow() { UnregisterClass(class_name_.c_str(), GetHInstance()); }
111

Callers

nothing calls this directly

Calls 3

GetHInstanceFunction · 0.85
DriverExceptionClass · 0.85
strMethod · 0.80

Tested by

no test coverage detected