Changeset View
Changeset View
Standalone View
Standalone View
netinfo.cpp
Show First 20 Lines • Show All 132 Lines • ▼ Show 20 Line(s) | 130 | { | |||
---|---|---|---|---|---|
133 | delete s_self; | 133 | delete s_self; | ||
134 | s_self = NULL; | 134 | s_self = NULL; | ||
135 | xcb_destroy_window(connection(), supportWindow); | 135 | xcb_destroy_window(connection(), supportWindow); | ||
136 | } | 136 | } | ||
137 | 137 | | |||
138 | RootInfo::RootInfo(xcb_window_t w, const char *name, NET::Properties properties, NET::WindowTypes types, | 138 | RootInfo::RootInfo(xcb_window_t w, const char *name, NET::Properties properties, NET::WindowTypes types, | ||
139 | NET::States states, NET::Properties2 properties2, NET::Actions actions, int scr) | 139 | NET::States states, NET::Properties2 properties2, NET::Actions actions, int scr) | ||
140 | : NETRootInfo(connection(), w, name, properties, types, states, properties2, actions, scr) | 140 | : NETRootInfo(connection(), w, name, properties, types, states, properties2, actions, scr) | ||
141 | , m_activeWindow(activeWindow()) | ||||
141 | { | 142 | { | ||
142 | } | 143 | } | ||
143 | 144 | | |||
144 | void RootInfo::changeNumberOfDesktops(int n) | 145 | void RootInfo::changeNumberOfDesktops(int n) | ||
145 | { | 146 | { | ||
146 | VirtualDesktopManager::self()->setCount(n); | 147 | VirtualDesktopManager::self()->setCount(n); | ||
147 | } | 148 | } | ||
148 | 149 | | |||
▲ Show 20 Lines • Show All 70 Lines • ▼ Show 20 Line(s) | 219 | if (Client* c = Workspace::self()->findClient(Predicate::WindowMatch, w)) | |||
219 | c->gotPing(timestamp); | 220 | c->gotPing(timestamp); | ||
220 | } | 221 | } | ||
221 | 222 | | |||
222 | void RootInfo::changeShowingDesktop(bool showing) | 223 | void RootInfo::changeShowingDesktop(bool showing) | ||
223 | { | 224 | { | ||
224 | Workspace::self()->setShowingDesktop(showing); | 225 | Workspace::self()->setShowingDesktop(showing); | ||
225 | } | 226 | } | ||
226 | 227 | | |||
228 | void RootInfo::setActiveClient(AbstractClient *client) | ||||
229 | { | ||||
230 | const xcb_window_t w = client ? client->window() : xcb_window_t{XCB_WINDOW_NONE}; | ||||
231 | if (m_activeWindow == w) { | ||||
232 | return; | ||||
233 | } | ||||
234 | m_activeWindow = w; | ||||
235 | setActiveWindow(m_activeWindow); | ||||
236 | } | ||||
237 | | ||||
227 | // **************************************** | 238 | // **************************************** | ||
228 | // WinInfo | 239 | // WinInfo | ||
229 | // **************************************** | 240 | // **************************************** | ||
230 | 241 | | |||
231 | WinInfo::WinInfo(Client * c, xcb_window_t window, | 242 | WinInfo::WinInfo(Client * c, xcb_window_t window, | ||
232 | xcb_window_t rwin, NET::Properties properties, NET::Properties2 properties2) | 243 | xcb_window_t rwin, NET::Properties properties, NET::Properties2 properties2) | ||
233 | : NETWinInfo(connection(), window, rwin, properties, properties2, NET::WindowManager), m_client(c) | 244 | : NETWinInfo(connection(), window, rwin, properties, properties2, NET::WindowManager), m_client(c) | ||
234 | { | 245 | { | ||
▲ Show 20 Lines • Show All 52 Lines • Show Last 20 Lines |