Blender V5.0
GHOST_WindowNULL.hh
Go to the documentation of this file.
1/* SPDX-FileCopyrightText: 2011-2023 Blender Authors
2 *
3 * SPDX-License-Identifier: GPL-2.0-or-later */
4
9
10#pragma once
11
12#include "GHOST_Window.hh"
13
14#include <map>
15
17
19 public:
21 {
22 return GHOST_kSuccess;
23 }
24
25 GHOST_WindowNULL(const char * /*title*/,
26 int32_t /*left*/,
27 int32_t /*top*/,
28 uint32_t width,
29 uint32_t height,
31 const GHOST_IWindow * /*parent_window*/,
33 const GHOST_ContextParams &context_params)
34 : GHOST_Window(width, height, state, context_params, false)
35 {
36 }
37
38 protected:
55 GHOST_TSuccess setWindowCustomCursorShape(const uint8_t * /*bitmap*/,
56 const uint8_t * /*mask*/,
57 const int /*size*/[2],
58 const int /*hot_spot*/[2],
59 bool /*can_invert_color*/) override
60 {
61 return GHOST_kSuccess;
62 }
63
64 bool getValid() const override
65 {
66 return true;
67 }
68 void setTitle(const char * /*title*/) override
69 { /* nothing */
70 }
71 std::string getTitle() const override
72 {
73 return "untitled";
74 }
75 GHOST_TSuccess setPath(const char * /*filepath*/) override
76 {
77 return GHOST_kFailure;
78 }
79 void getWindowBounds(GHOST_Rect &bounds) const override
80 {
82 }
83 void getClientBounds(GHOST_Rect & /*bounds*/) const override
84 { /* nothing */
85 }
86 GHOST_TSuccess setClientWidth(uint32_t /*width*/) override
87 {
88 return GHOST_kFailure;
89 }
90 GHOST_TSuccess setClientHeight(uint32_t /*height*/) override
91 {
92 return GHOST_kFailure;
93 }
94 GHOST_TSuccess setClientSize(uint32_t /*width*/, uint32_t /*height*/) override
95 {
96 return GHOST_kFailure;
97 }
98 void screenToClient(int32_t inX, int32_t inY, int32_t &outX, int32_t &outY) const override
99 {
100 outX = inX;
101 outY = inY;
102 }
103 void clientToScreen(int32_t inX, int32_t inY, int32_t &outX, int32_t &outY) const override
104 {
105 outX = inX;
106 outY = inY;
107 }
109 {
110 return GHOST_kFailure;
111 }
113 {
114 return GHOST_kFailure;
115 }
116 ~GHOST_WindowNULL() override = default;
117
118 GHOST_TSuccess setWindowCursorVisibility(bool /*visible*/) override
119 {
120 return GHOST_kSuccess;
121 }
123 {
124 return GHOST_kSuccess;
125 }
127 {
129 }
131 {
132 return GHOST_kSuccess;
133 }
135 {
136 return GHOST_kSuccess;
137 }
138
139 private:
144 GHOST_Context *newDrawingContext(GHOST_TDrawingContextType /*type*/) override
145 {
146 return nullptr;
147 }
148};
GHOST_TWindowState
@ GHOST_kWindowStateNormal
GHOST_TStandardCursor
GHOST_TDrawingContextType
GHOST_TWindowOrder
GHOST_TSuccess
Definition GHOST_Types.h:57
@ GHOST_kFailure
Definition GHOST_Types.h:57
@ GHOST_kSuccess
Definition GHOST_Types.h:57
GHOST_TGrabCursorMode
static btDbvtVolume bounds(btDbvtNode **leaves, int count)
Definition btDbvt.cpp:299
GHOST_TSuccess invalidate() override
std::string getTitle() const override
GHOST_TSuccess setState(GHOST_TWindowState) override
void clientToScreen(int32_t inX, int32_t inY, int32_t &outX, int32_t &outY) const override
GHOST_TSuccess setWindowCursorGrab(GHOST_TGrabCursorMode) override
GHOST_TSuccess setWindowCursorVisibility(bool) override
GHOST_TSuccess setClientHeight(uint32_t) override
void getWindowBounds(GHOST_Rect &bounds) const override
void setTitle(const char *) override
GHOST_TSuccess activateDrawingContext() override
GHOST_TSuccess swapBufferRelease() override
GHOST_TSuccess installDrawingContext(GHOST_TDrawingContextType)
GHOST_TSuccess hasCursorShape(GHOST_TStandardCursor) override
GHOST_TSuccess setClientWidth(uint32_t) override
void getClientBounds(GHOST_Rect &) const override
GHOST_TSuccess setClientSize(uint32_t, uint32_t) override
GHOST_TSuccess setWindowCustomCursorShape(const uint8_t *, const uint8_t *, const int[2], const int[2], bool) override
~GHOST_WindowNULL() override=default
GHOST_TSuccess setPath(const char *) override
GHOST_TWindowState getState() const override
GHOST_TSuccess removeDrawingContext()
void screenToClient(int32_t inX, int32_t inY, int32_t &outX, int32_t &outY) const override
bool getValid() const override
GHOST_WindowNULL(const char *, int32_t, int32_t, uint32_t width, uint32_t height, GHOST_TWindowState state, const GHOST_IWindow *, GHOST_TDrawingContextType, const GHOST_ContextParams &context_params)
GHOST_TSuccess setOrder(GHOST_TWindowOrder) override
GHOST_TSuccess setWindowCursorShape(GHOST_TStandardCursor) override
GHOST_Window(uint32_t width, uint32_t height, GHOST_TWindowState state, const GHOST_ContextParams &context_params, const bool exclusive=false)
static ulong state[N]