aboutsummaryrefslogtreecommitdiff
path: root/include/cru/win/native/window_class.hpp
blob: fec3b32e44462d2a08daf1b27d1619b12baf1ca4 (plain)
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
#pragma once
#include "../win_pre_config.hpp"

#include "cru/common/base.hpp"

#include <string>

namespace cru::platform::native::win {
class WindowClass : public Object {
 public:
  WindowClass(const std::wstring& name, WNDPROC window_proc,
              HINSTANCE h_instance);
  WindowClass(const WindowClass& other) = delete;
  WindowClass(WindowClass&& other) = delete;
  WindowClass& operator=(const WindowClass& other) = delete;
  WindowClass& operator=(WindowClass&& other) = delete;
  ~WindowClass() override = default;

  const wchar_t* GetName() const { return name_.c_str(); }

  ATOM GetAtom() const { return atom_; }

 private:
  std::wstring name_;
  ATOM atom_;
};
}  // namespace cru::win::native