MCPcopy Create free account
hub / github.com/danoon2/Boxedwine / x11_GetWMNormalHints

Function x11_GetWMNormalHints

source/x11/x11common.cpp:2290–2314  ·  view source on GitHub ↗

Status XGetWMNormalHints(Display* display, Window w, XSizeHints* hints_return, long* supplied_return)

Source from the content-addressed store, hash-verified

2288
2289// Status XGetWMNormalHints(Display* display, Window w, XSizeHints* hints_return, long* supplied_return)
2290static void x11_GetWMNormalHints(CPU* cpu) {
2291 KMemory* memory = cpu->memory;
2292 KThread* thread = cpu->thread;
2293 XServer* server = XServer::getServer();
2294 XWindowPtr w = server->getWindow(ARG2);
2295
2296 if (!w) {
2297 EAX = BadWindow;
2298 return;
2299 }
2300 if (!ARG3) {
2301 EAX = BadValue;
2302 return;
2303 }
2304 XPropertyPtr prop = w->getProperty(XA_WM_NORMAL_HINTS);
2305 if (!prop || prop->length != sizeof(XSizeHints)) {
2306 EAX = 0;
2307 return;
2308 }
2309 memory->memcpy(ARG3, prop->value, sizeof(XSizeHints));
2310 if (ARG4) {
2311 memory->writed(ARG4, sizeof(XSizeHints));
2312 }
2313 EAX = Success;
2314}
2315
2316// XSizeHints* XAllocSizeHints()
2317static void x11_AllocSizeHints(CPU* cpu) {

Callers

nothing calls this directly

Calls 4

getWindowMethod · 0.80
memcpyMethod · 0.80
getPropertyMethod · 0.45
writedMethod · 0.45

Tested by

no test coverage detected