MCPcopy Create free account
hub / github.com/LemonOSProject/LemonOS / SetActive

Method SetActive

System/LemonWM/wm.cpp:64–81  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

62}
63
64void WMInstance::SetActive(WMWindow* win){
65 if(active == win) return;
66
67 if(shellConnected && active && !(active->flags & WINDOW_FLAGS_NOSHELL) && !active->minimized){
68 Lemon::Shell::SetWindowState(active->clientID, Lemon::Shell::ShellWindowStateNormal, shellClient);
69 }
70
71 active = win;
72
73 if(win){
74 if(shellConnected && !(win->flags & WINDOW_FLAGS_NOSHELL)){
75 Lemon::Shell::SetWindowState(win->clientID, Lemon::Shell::ShellWindowStateActive, shellClient);
76 }
77
78 windows.remove(win);
79 windows.push_back(win); // Add to top
80 }
81}
82
83int64_t WMInstance::CreateWindowBuffer(int width, int height, WindowBuffer** buffer){
84 size_t windowBufferSize = ((sizeof(WindowBuffer) + 0x1F) & (~0x1F)) + ((width * height * 4 + 0x1F) & (~0x1F) /* Round up to 32 bytes */) * 2;

Callers

nothing calls this directly

Calls 2

SetWindowStateFunction · 0.85
removeMethod · 0.45

Tested by

no test coverage detected