xoblite™ / Blackbox for Windows bb5 | RC6 preview | 0.25.2.14
http://xoblite.net/
WorkspacesMenu.cpp File Reference
#include "WorkspacesMenu.h"
#include "..\API\BBApi.h"
#include "..\Menu\MenuCommon.h"
#include "..\Menu\MenuItem.h"
#include "..\Settings\Settings.h"
#include "..\Workspaces\Workspaces.h"
#include <dwmapi.h>

Macros

#define WORKSPACES_FOLDER_TIMER   4434
 

Functions

BOOL CALLBACK CheckTaskEnumProc (HWND hwnd, LPARAM lParam)
 

Variables

MenuCommonpMenuCommon
 
SettingspSettings
 
WorkspacespWorkspaces
 

Macro Definition Documentation

◆ WORKSPACES_FOLDER_TIMER

#define WORKSPACES_FOLDER_TIMER   4434

Function Documentation

◆ CheckTaskEnumProc()

BOOL CALLBACK CheckTaskEnumProc ( HWND hwnd,
LPARAM lParam )
224{
225 if (!IsAppWindow(hwnd)) return true;
226
227 // Check for DWM cloaked windows... (e.g. preloading Windows 10 apps like Microsoft Edge etc, see also Taskbar::CheckCloakedWindow())
228 int cloaked = 0;
229 HRESULT hr = DwmGetWindowAttribute(hwnd, DWMWA_CLOAKED, &cloaked, 4);
230 if ((hr == S_OK) && (cloaked > 0)) return true;
231
232 //====================
233
235
236 if (wmi->m_nDesktop == 255) // -> Minimized tasks
237 {
238 if (IsIconic(hwnd)) wmi->AddWindow(hwnd);
239 }
240 else if (wmi->m_nDesktop == 254) // -> All tasks
241 {
242 wmi->AddWindow(hwnd);
243 }
244 else // -> Tasks on this specific workspace?
245 {
246 if (!IsIconic(hwnd) && (pWorkspaces->GetWorkspaceByWindow(hwnd) == wmi->m_nDesktop)) wmi->AddWindow(hwnd);
247 }
248
249 return true;
250}
bool IsAppWindow(HWND hWnd)
Definition BBApi.cpp:1836
Workspaces * pWorkspaces
Definition Blackbox.cpp:51
Definition WorkspacesMenu.h:52
int m_nDesktop
Definition WorkspacesMenu.h:65
void AddWindow(HWND hWnd)
Definition WorkspacesMenu.cpp:186

Variable Documentation

◆ pMenuCommon

MenuCommon* pMenuCommon
extern

◆ pSettings

Settings* pSettings
extern

◆ pWorkspaces

Workspaces* pWorkspaces
extern