ReactOS 0.4.15-dev-5896-g3f5bcf5
applpage.c
Go to the documentation of this file.
1/*
2 * ReactOS Task Manager
3 *
4 * applpage.c
5 *
6 * Copyright (C) 1999 - 2001 Brian Palmer <brianp@reactos.org>
7 * 2005 Klemens Friedl <frik85@reactos.at>
8 * 2021 Katayama Hirofumi MZ <katayama.hirofumi.mz@gmail.com>
9 *
10 * This library is free software; you can redistribute it and/or
11 * modify it under the terms of the GNU Lesser General Public
12 * License as published by the Free Software Foundation; either
13 * version 2.1 of the License, or (at your option) any later version.
14 *
15 * This library is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18 * Lesser General Public License for more details.
19 *
20 * You should have received a copy of the GNU Lesser General Public
21 * License along with this library; if not, write to the Free Software
22 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
23 */
24
25#include "precomp.h"
26
27typedef struct
28{
34
35HWND hApplicationPage; /* Application List Property Page */
36HWND hApplicationPageListCtrl; /* Application ListCtrl Window */
37HWND hApplicationPageEndTaskButton; /* Application End Task button */
38HWND hApplicationPageSwitchToButton; /* Application Switch To button */
39HWND hApplicationPageNewTaskButton; /* Application New Task button */
46
49void ApplicationPageUpdate(void);
53int CALLBACK ApplicationPageCompareFunc(LPARAM lParam1, LPARAM lParam2, LPARAM lParamSort);
54int ProcGetIndexByProcessId(DWORD dwProcessId);
55
56#ifdef RUN_APPS_PAGE
59#endif
60
61static INT
63{
64 DEVMODE pDevMode;
65 INT ColorDepth;
66
67 pDevMode.dmSize = sizeof(DEVMODE);
68 pDevMode.dmDriverExtra = 0;
69
70 if (!EnumDisplaySettings(NULL, ENUM_CURRENT_SETTINGS, &pDevMode))
71 return ILC_COLOR;
72
73 switch (pDevMode.dmBitsPerPel)
74 {
75 case 32: ColorDepth = ILC_COLOR32; break;
76 case 24: ColorDepth = ILC_COLOR24; break;
77 case 16: ColorDepth = ILC_COLOR16; break;
78 case 8: ColorDepth = ILC_COLOR8; break;
79 case 4: ColorDepth = ILC_COLOR4; break;
80 default: ColorDepth = ILC_COLOR; break;
81 }
82
83 return ColorDepth;
84}
85
87{
88 int i;
92 {
93 memset(&item, 0, sizeof(LV_ITEM));
94 item.mask = LVIF_PARAM;
95 item.iItem = i;
99 }
100}
101
102
105{
106 RECT rc;
107 int nXDifference;
108 int nYDifference;
110 WCHAR szTemp[256];
111 int cx, cy;
112
113 switch (message) {
114 case WM_INITDIALOG:
115
116 /* Save the width and height */
117 GetClientRect(hDlg, &rc);
120
121 /* Update window position */
123
124 /* Get handles to the controls */
129
131
132 /* Initialize the application page's controls */
134
135 LoadStringW(hInst, IDS_TAB_TASK, szTemp, 256);
136 column.pszText = szTemp;
137 column.cx = 250;
138 (void)ListView_InsertColumn(hApplicationPageListCtrl, 0, &column); /* Add the "Task" column */
140 LoadStringW(hInst, IDS_TAB_STATUS, szTemp, 256);
141 column.pszText = szTemp;
142 column.cx = 95;
143 (void)ListView_InsertColumn(hApplicationPageListCtrl, 1, &column); /* Add the "Status" column */
144
147
149
150 /* Start our refresh thread */
151#ifdef RUN_APPS_PAGE
153#endif
154
155 /* Refresh page */
157
158 return TRUE;
159
160 case WM_DESTROY:
161 /* Close refresh thread */
162#ifdef RUN_APPS_PAGE
164#endif
166 break;
167
168 case WM_COMMAND:
169
170 /* Handle the button clicks */
171 switch (LOWORD(wParam))
172 {
173 case IDC_ENDTASK:
175 break;
176 case IDC_SWITCHTO:
178 break;
179 case IDC_NEWTASK:
181 break;
182 }
183
184 break;
185
186 case WM_SIZE:
187 if (wParam == SIZE_MINIMIZED)
188 return 0;
189
190 cx = LOWORD(lParam);
191 cy = HIWORD(lParam);
192 nXDifference = cx - nApplicationPageWidth;
193 nYDifference = cy - nApplicationPageHeight;
196
197 /* Reposition the application page's controls */
199 cx = (rc.right - rc.left) + nXDifference;
200 cy = (rc.bottom - rc.top) + nYDifference;
203
205 MapWindowPoints(hApplicationPageEndTaskButton, hDlg, (LPPOINT)(PRECT)(&rc), sizeof(RECT)/sizeof(POINT));
206 cx = rc.left + nXDifference;
207 cy = rc.top + nYDifference;
210
212 MapWindowPoints(hApplicationPageSwitchToButton, hDlg, (LPPOINT)(PRECT)(&rc), sizeof(RECT)/sizeof(POINT));
213 cx = rc.left + nXDifference;
214 cy = rc.top + nYDifference;
217
219 MapWindowPoints(hApplicationPageNewTaskButton, hDlg, (LPPOINT)(PRECT)(&rc), sizeof(RECT)/sizeof(POINT));
220 cx = rc.left + nXDifference;
221 cy = rc.top + nYDifference;
224
225 break;
226
227 case WM_NOTIFY:
229 break;
230
231 case WM_KEYDOWN:
232 if (wParam == VK_DELETE)
234 break;
235
236 }
237
238 return 0;
239}
240
242{
243#ifdef RUN_APPS_PAGE
244 /* Signal the event so that our refresh thread */
245 /* will wake up and refresh the application page */
247#endif
248}
249
251{
253
254 dwStyle &= ~(LVS_REPORT | LVS_ICON | LVS_LIST | LVS_SMALLICON);
255
257 case ID_VIEW_LARGE: dwStyle |= LVS_ICON; break;
258 case ID_VIEW_SMALL: dwStyle |= LVS_SMALLICON; break;
259 case ID_VIEW_DETAILS: dwStyle |= LVS_REPORT; break;
260 }
262
264}
265
267{
268 MSG msg;
269 INT i;
270 BOOL bItemRemoved = FALSE;
273 HIMAGELIST hImageListLarge;
274 HIMAGELIST hImageListSmall;
275
276 /* If we couldn't create the event then exit the thread */
277 while (1)
278 {
279 /* Wait for an the event or application close */
280 if (GetMessage(&msg, NULL, 0, 0) <= 0)
281 return 0;
282
283 if (msg.message == WM_TIMER)
284 {
285 /*
286 * FIXME:
287 *
288 * Should this be EnumDesktopWindows() instead?
289 */
290 noApps = TRUE;
292 if (noApps)
293 {
296 }
297
298 /* Get the image lists */
301
302 /* Check to see if we need to remove any items from the list */
304 {
305 memset(&item, 0, sizeof(LV_ITEM));
307 item.iItem = i;
309
310 pAPLI = (LPAPPLICATION_PAGE_LIST_ITEM)item.lParam;
311 if (!IsWindow(pAPLI->hWnd)||
312 (wcslen(pAPLI->szTitle) <= 0) ||
313 !IsWindowVisible(pAPLI->hWnd) ||
314 (GetParent(pAPLI->hWnd) != NULL) ||
315 (GetWindow(pAPLI->hWnd, GW_OWNER) != NULL) ||
317 {
318 ImageList_Remove(hImageListLarge, item.iItem);
319 ImageList_Remove(hImageListSmall, item.iItem);
320
322 HeapFree(GetProcessHeap(), 0, pAPLI);
323 bItemRemoved = TRUE;
324 }
325 }
326
327 /*
328 * If an item was removed from the list then
329 * we need to resync all the items with the
330 * image list
331 */
332 if (bItemRemoved)
333 {
335 {
336 memset(&item, 0, sizeof(LV_ITEM));
337 item.mask = LVIF_IMAGE;
338 item.iItem = i;
339 item.iImage = i;
341 }
342 bItemRemoved = FALSE;
343 }
344
346 }
347 }
348}
349
351{
352 HICON hIcon;
353 WCHAR szText[260];
354 BOOL bLargeIcon;
355 BOOL bHung = FALSE;
356 LRESULT bAlive;
357
358 typedef int (FAR __stdcall *IsHungAppWindowProc)(HWND);
359 IsHungAppWindowProc IsHungAppWindow;
360
361 /* Skip our window */
362 if (hWnd == hMainWnd)
363 return TRUE;
364
366
367 GetWindowTextW(hWnd, szText, 260); /* Get the window text */
368
369 /* Check and see if this is a top-level app window */
370 if ((wcslen(szText) <= 0) ||
372 (GetParent(hWnd) != NULL) ||
373 (GetWindow(hWnd, GW_OWNER) != NULL) ||
375 {
376 return TRUE; /* Skip this window */
377 }
378
379 noApps = FALSE;
380
381#define GET_ICON(type) \
382 SendMessageTimeoutW(hWnd, WM_GETICON, (type), 0, SMTO_ABORTIFHUNG, 100, (PDWORD_PTR)&hIcon)
383
384 /* Get the icon for this window */
385 hIcon = NULL;
386 bAlive = GET_ICON(bLargeIcon ? ICON_BIG : ICON_SMALL);
387 if (!hIcon)
388 {
389 /* We failed, try to retrieve other icons... */
390 if (!hIcon && bAlive)
391 GET_ICON(bLargeIcon ? ICON_SMALL : ICON_BIG);
392 if (!hIcon)
394 if (!hIcon)
396
397 /* If we still do not have any icon, load the default one */
399 }
400#undef GET_ICON
401
402 bHung = FALSE;
403
404 IsHungAppWindow = (IsHungAppWindowProc)(FARPROC)GetProcAddress(GetModuleHandleW(L"USER32.DLL"), "IsHungAppWindow");
405
406 if (IsHungAppWindow)
407 bHung = IsHungAppWindow(hWnd);
408
409 AddOrUpdateHwnd(hWnd, szText, hIcon, bHung);
410
411 return TRUE;
412}
413
415{
417 HIMAGELIST hImageListLarge;
418 HIMAGELIST hImageListSmall;
420 int i;
421 BOOL bAlreadyInList = FALSE;
422
423 memset(&item, 0, sizeof(LV_ITEM));
424
425 /* Get the image lists */
428
429 /* Check to see if it's already in our list */
431 {
432 memset(&item, 0, sizeof(LV_ITEM));
434 item.iItem = i;
436
437 pAPLI = (LPAPPLICATION_PAGE_LIST_ITEM)item.lParam;
438 if (pAPLI->hWnd == hWnd)
439 {
440 bAlreadyInList = TRUE;
441 break;
442 }
443 }
444
445 /* If it is already in the list then update it if necessary */
446 if (bAlreadyInList)
447 {
448 /* Check to see if anything needs updating */
449 if ((pAPLI->hIcon != hIcon) ||
450 (_wcsicmp(pAPLI->szTitle, szTitle) != 0) ||
451 (pAPLI->bHung != bHung))
452 {
453 /* Update the structure */
454 pAPLI->hIcon = hIcon;
455 pAPLI->bHung = bHung;
456 wcscpy(pAPLI->szTitle, szTitle);
457
458 /* Update the image list */
459 ImageList_ReplaceIcon(hImageListLarge, item.iItem, hIcon);
460 ImageList_ReplaceIcon(hImageListSmall, item.iItem, hIcon);
461
462 /* Update the list view */
464 /* UpdateWindow(hApplicationPageListCtrl); */
466 }
467 }
468 /* It is not already in the list so add it */
469 else
470 {
472
473 pAPLI->hWnd = hWnd;
474 pAPLI->hIcon = hIcon;
475 pAPLI->bHung = bHung;
476 wcscpy(pAPLI->szTitle, szTitle);
477
478 /* Add the item to the list */
479 memset(&item, 0, sizeof(LV_ITEM));
481 ImageList_AddIcon(hImageListLarge, hIcon);
482 item.iImage = ImageList_AddIcon(hImageListSmall, hIcon);
483 item.pszText = LPSTR_TEXTCALLBACK;
485 item.lParam = (LPARAM)pAPLI;
487 }
488
489 /* Select first item if any */
492 {
495 }
496 /*
497 else
498 {
499 bApplicationPageSelectionMade = FALSE;
500 }
501 */
502}
503
505{
506 /* Enable or disable the "End Task" & "Switch To" buttons */
508 {
510 }
511 else
512 {
514 }
515 /* Enable "Switch To" button only if only one app is selected */
517
518 /* If we are on the applications tab the windows menu will be */
519 /* present on the menu bar so enable & disable the menu items */
520 if (TabCtrl_GetCurSel(hTabWnd) == 0)
521 {
522 HMENU hMenu;
523 HMENU hWindowsMenu;
524
525 hMenu = GetMenu(hMainWnd);
526 hWindowsMenu = GetSubMenu(hMenu, 3);
527
528 /* Only one item selected */
530 {
537 }
538 /* More than one item selected */
540 {
547 }
548 /* No items selected */
549 else
550 {
557 }
558 }
559}
560
562{
563 LPNMHDR pnmh;
564 LV_DISPINFO* pnmdi;
566 WCHAR szMsg[256];
567
568 pnmh = (LPNMHDR) lParam;
569 pnmdi = (LV_DISPINFO*) lParam;
570
571 if (pnmh->hwndFrom == hApplicationPageListCtrl) {
572 switch (pnmh->code) {
573 case LVN_ITEMCHANGED:
575 break;
576
577 case LVN_GETDISPINFO:
578 pAPLI = (LPAPPLICATION_PAGE_LIST_ITEM)pnmdi->item.lParam;
579
580 /* Update the item text */
581 if (pnmdi->item.iSubItem == 0)
582 {
583 wcsncpy(pnmdi->item.pszText, pAPLI->szTitle, pnmdi->item.cchTextMax);
584 }
585
586 /* Update the item status */
587 else if (pnmdi->item.iSubItem == 1)
588 {
589 if (pAPLI->bHung)
590 {
591 LoadStringW( GetModuleHandleW(NULL), IDS_NOT_RESPONDING , szMsg, sizeof(szMsg) / sizeof(szMsg[0]));
592 }
593 else
594 {
595 LoadStringW( GetModuleHandleW(NULL), IDS_RUNNING, (LPWSTR) szMsg, sizeof(szMsg) / sizeof(szMsg[0]));
596 }
597 wcsncpy(pnmdi->item.pszText, szMsg, pnmdi->item.cchTextMax);
598 }
599
600 break;
601
602 case NM_RCLICK:
603
605 {
607 }
608 else
609 {
611 }
612
613 break;
614
615 case NM_DBLCLK:
616
618
619 break;
620
621 case LVN_KEYDOWN:
622
623 if (((LPNMLVKEYDOWN)lParam)->wVKey == VK_DELETE)
625
626 break;
627
628 }
629 }
631 {
632 switch (pnmh->code)
633 {
634 case NM_RCLICK:
635
637 {
639 }
640 else
641 {
643 }
644
645 break;
646
647 case HDN_ITEMCLICK:
648
651
652 break;
653 }
654 }
655
656}
657
659{
660 HMENU hMenu;
661 HMENU hSubMenu;
662 POINT pt;
663
665
667 hSubMenu = GetSubMenu(hMenu, 0);
668
670
672
673 DestroyMenu(hMenu);
674}
675
677{
678 HMENU hMenu;
679 HMENU hSubMenu;
680 POINT pt;
681
683
685 hSubMenu = GetSubMenu(hMenu, 0);
686
688 {
696 }
698 {
706 }
707 else
708 {
716 }
717
719
721
722 DestroyMenu(hMenu);
723}
724
726{
727 HMENU hMenu;
728 HMENU hViewMenu;
729
730 hMenu = GetMenu(hMainWnd);
731 hViewMenu = GetSubMenu(hMenu, 2);
732
735
737}
738
740{
743 int i;
744 HWND* hWndArray;
745 int nWndCount;
746
748 nWndCount = 0;
749
751 memset(&item, 0, sizeof(LV_ITEM));
753 item.iItem = i;
754 item.stateMask = (UINT)-1;
756
757 if (item.state & LVIS_SELECTED) {
758 pAPLI = (LPAPPLICATION_PAGE_LIST_ITEM)item.lParam;
759 if (pAPLI) {
760 hWndArray[nWndCount] = pAPLI->hWnd;
761 nWndCount++;
762 }
763 }
764 }
765
766 TileWindows(NULL, dwMode, NULL, nWndCount, hWndArray);
767 HeapFree(GetProcessHeap(), 0, hWndArray);
768}
769
771{
774 int i;
775
777 memset(&item, 0, sizeof(LV_ITEM));
779 item.iItem = i;
780 item.stateMask = (UINT)-1;
782 if (item.state & LVIS_SELECTED) {
783 pAPLI = (LPAPPLICATION_PAGE_LIST_ITEM)item.lParam;
784 if (pAPLI) {
786 }
787 }
788 }
789}
790
792{
795 int i;
796
798 memset(&item, 0, sizeof(LV_ITEM));
800 item.iItem = i;
801 item.stateMask = (UINT)-1;
803 if (item.state & LVIS_SELECTED) {
804 pAPLI = (LPAPPLICATION_PAGE_LIST_ITEM)item.lParam;
805 if (pAPLI) {
807 }
808 }
809 }
810}
811
813{
816 int i;
817 HWND* hWndArray;
818 int nWndCount;
819
821 nWndCount = 0;
822
824 memset(&item, 0, sizeof(LV_ITEM));
826 item.iItem = i;
827 item.stateMask = (UINT)-1;
829 if (item.state & LVIS_SELECTED) {
830 pAPLI = (LPAPPLICATION_PAGE_LIST_ITEM)item.lParam;
831 if (pAPLI) {
832 hWndArray[nWndCount] = pAPLI->hWnd;
833 nWndCount++;
834 }
835 }
836 }
837 CascadeWindows(NULL, 0, NULL, nWndCount, hWndArray);
838 HeapFree(GetProcessHeap(), 0, hWndArray);
839}
840
842{
845 int i;
846
848 memset(&item, 0, sizeof(LV_ITEM));
850 item.iItem = i;
851 item.stateMask = (UINT)-1;
853 if (item.state & LVIS_SELECTED) {
854 pAPLI = (LPAPPLICATION_PAGE_LIST_ITEM)item.lParam;
855 break;
856 }
857 }
858 if (pAPLI) {
860 }
861}
862
864{
867 int i;
868
870 memset(&item, 0, sizeof(LV_ITEM));
872 item.iItem = i;
873 item.stateMask = (UINT)-1;
875
876 if (item.state & LVIS_SELECTED) {
877 pAPLI = (LPAPPLICATION_PAGE_LIST_ITEM)item.lParam;
878 break;
879 }
880 }
881 if (pAPLI) {
885 }
886}
887
889{
892 int i;
893
894 /* Trick: on Windows, pressing the CTRL key forces the task to be ended */
895 BOOL ForceEndTask = !!(GetKeyState(VK_CONTROL) & 0x8000);
896
898 memset(&item, 0, sizeof(LV_ITEM));
900 item.iItem = i;
901 item.stateMask = (UINT)-1;
903 if (item.state & LVIS_SELECTED) {
904 pAPLI = (LPAPPLICATION_PAGE_LIST_ITEM)item.lParam;
905 if (pAPLI) {
906 EndTask(pAPLI->hWnd, 0, ForceEndTask);
907 }
908 }
909 }
910}
911
913{
916 int i;
917
919 memset(&item, 0, sizeof(LV_ITEM));
921 item.iItem = i;
922 item.stateMask = (UINT)-1;
924 if (item.state & LVIS_SELECTED) {
925 pAPLI = (LPAPPLICATION_PAGE_LIST_ITEM)item.lParam;
926 break;
927 }
928 }
929 if (pAPLI) {
930 DWORD dwProcessId;
931
932 GetWindowThreadProcessId(pAPLI->hWnd, &dwProcessId);
933 /*
934 * Switch to the process tab
935 */
937 /*
938 * Select the process item in the list
939 */
940 i = ProcGetIndexByProcessId(dwProcessId);
941 if (i != -1)
942 {
944 i,
948 i,
949 FALSE);
950 }
951 }
952}
953
954int CALLBACK ApplicationPageCompareFunc(LPARAM lParam1, LPARAM lParam2, LPARAM lParamSort)
955{
958
959 if (bSortAscending) {
960 Param1 = (LPAPPLICATION_PAGE_LIST_ITEM)lParam1;
961 Param2 = (LPAPPLICATION_PAGE_LIST_ITEM)lParam2;
962 } else {
963 Param1 = (LPAPPLICATION_PAGE_LIST_ITEM)lParam2;
964 Param2 = (LPAPPLICATION_PAGE_LIST_ITEM)lParam1;
965 }
966 return wcscmp(Param1->szTitle, Param2->szTitle);
967}
void RefreshApplicationPage(void)
Definition: applpage.c:241
void ApplicationPage_OnEndTask(void)
Definition: applpage.c:888
HWND hApplicationPage
Definition: applpage.c:35
HWND hApplicationPageEndTaskButton
Definition: applpage.c:37
static DWORD dwApplicationThread
Definition: applpage.c:58
DWORD WINAPI ApplicationPageRefreshThread(void *lpParameter)
Definition: applpage.c:266
static HANDLE hApplicationThread
Definition: applpage.c:57
BOOL CALLBACK EnumWindowsProc(HWND hWnd, LPARAM lParam)
Definition: applpage.c:350
void ApplicationPage_OnWindowsCascade(void)
Definition: applpage.c:812
void ApplicationPage_OnWindowsBringToFront(void)
Definition: applpage.c:841
BOOL noApps
Definition: applpage.c:44
struct APPLICATION_PAGE_LIST_ITEM * LPAPPLICATION_PAGE_LIST_ITEM
HWND hApplicationPageNewTaskButton
Definition: applpage.c:39
void ApplicationPageOnNotify(WPARAM wParam, LPARAM lParam)
Definition: applpage.c:561
void UpdateApplicationListControlViewSetting(void)
Definition: applpage.c:250
static int nApplicationPageWidth
Definition: applpage.c:40
void ApplicationPage_OnWindowsMinimize(void)
Definition: applpage.c:770
void AddOrUpdateHwnd(HWND hWnd, WCHAR *szTitle, HICON hIcon, BOOL bHung)
Definition: applpage.c:414
HWND hApplicationPageSwitchToButton
Definition: applpage.c:38
#define GET_ICON(type)
int CALLBACK ApplicationPageCompareFunc(LPARAM lParam1, LPARAM lParam2, LPARAM lParamSort)
Definition: applpage.c:954
void ApplicationPage_OnView(DWORD dwMode)
Definition: applpage.c:725
void ApplicationPageShowContextMenu2(void)
Definition: applpage.c:676
void ApplicationPage_OnWindowsTile(DWORD dwMode)
Definition: applpage.c:739
void ApplicationPageShowContextMenu1(void)
Definition: applpage.c:658
INT_PTR CALLBACK ApplicationPageWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam)
Definition: applpage.c:104
BOOL bApplicationPageSelectionMade
Definition: applpage.c:45
void AppPageCleanup(void)
Definition: applpage.c:86
static int nApplicationPageHeight
Definition: applpage.c:41
HWND hApplicationPageListCtrl
Definition: applpage.c:36
void ApplicationPage_OnGotoProcess(void)
Definition: applpage.c:912
void ApplicationPageUpdate(void)
Definition: applpage.c:504
void ApplicationPage_OnSwitchTo(void)
Definition: applpage.c:863
void ApplicationPage_OnWindowsMaximize(void)
Definition: applpage.c:791
static BOOL bSortAscending
Definition: applpage.c:42
int ProcGetIndexByProcessId(DWORD dwProcessId)
Definition: procpage.c:82
#define msg(x)
Definition: auth_time.c:54
HWND hWnd
Definition: settings.c:17
#define ID_VIEW_LARGE
Definition: resource.h:33
#define ID_VIEW_SMALL
Definition: resource.h:34
#define ID_VIEW_DETAILS
Definition: resource.h:36
INT GetSystemColorDepth()
Definition: misc.cpp:321
#define ID_FILE_NEW
Definition: resource.h:40
#define ID_APPLICATION_PAGE_SWITCHTO
Definition: resource.h:165
#define IDR_APPLICATION_PAGE_CONTEXT2
Definition: resource.h:21
#define IDS_TAB_TASK
Definition: resource.h:200
#define ID_WINDOWS_MINIMIZE
Definition: resource.h:151
#define IDS_NOT_RESPONDING
Definition: resource.h:258
#define IDS_TAB_STATUS
Definition: resource.h:201
#define ID_WINDOWS_MAXIMIZE
Definition: resource.h:152
#define IDS_RUNNING
Definition: resource.h:259
#define IDI_WINDOWSM
Definition: resource.h:19
#define IDC_ENDTASK
Definition: resource.h:31
#define ID_WINDOWS_BRINGTOFRONT
Definition: resource.h:154
#define IDC_SWITCHTO
Definition: resource.h:32
#define ID_WINDOWS_TILEHORIZONTALLY
Definition: resource.h:149
#define IDC_APPLIST
Definition: resource.h:35
#define IDC_NEWTASK
Definition: resource.h:33
#define IDR_APPLICATION_PAGE_CONTEXT1
Definition: resource.h:20
#define ID_WINDOWS_TILEVERTICALLY
Definition: resource.h:150
#define IDI_WINDOW
Definition: resource.h:18
#define ID_WINDOWS_CASCADE
Definition: resource.h:153
WPARAM wParam
Definition: combotst.c:138
LPARAM lParam
Definition: combotst.c:139
#define NULL
Definition: types.h:112
#define TRUE
Definition: types.h:120
#define FALSE
Definition: types.h:117
BOOL WINAPI ImageList_Remove(HIMAGELIST himl, INT i)
Definition: imagelist.c:2568
INT WINAPI ImageList_ReplaceIcon(HIMAGELIST himl, INT nIndex, HICON hIcon)
Definition: imagelist.c:2779
HIMAGELIST WINAPI ImageList_Create(INT cx, INT cy, UINT flags, INT cInitial, INT cGrow)
Definition: imagelist.c:804
#define GetProcessHeap()
Definition: compat.h:736
int(* FARPROC)()
Definition: compat.h:36
HANDLE HWND
Definition: compat.h:19
#define GetProcAddress(x, y)
Definition: compat.h:753
#define HeapAlloc
Definition: compat.h:733
#define HeapFree(x, y, z)
Definition: compat.h:735
#define CALLBACK
Definition: compat.h:35
#define FAR
Definition: zlib.h:34
HMODULE WINAPI GetModuleHandleW(LPCWSTR lpModuleName)
Definition: loader.c:838
HANDLE WINAPI DECLSPEC_HOTPATCH CreateThread(IN LPSECURITY_ATTRIBUTES lpThreadAttributes, IN DWORD dwStackSize, IN LPTHREAD_START_ROUTINE lpStartAddress, IN LPVOID lpParameter, IN DWORD dwCreationFlags, OUT LPDWORD lpThreadId)
Definition: thread.c:137
unsigned int(__cdecl typeof(jpeg_read_scanlines))(struct jpeg_decompress_struct *
Definition: typeof.h:31
#define pt(x, y)
Definition: drawing.c:79
HINSTANCE hInst
Definition: dxdiag.c:13
void ProcessPage_OnEndProcess(void)
Definition: endproc.c:30
BOOL WINAPI EndTask(HWND hWnd, BOOL fShutDown, BOOL fForce)
Definition: exit.c:207
unsigned int BOOL
Definition: ntddk_ex.h:94
unsigned long DWORD
Definition: ntddk_ex.h:95
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
Definition: glfuncs.h:248
_CRTIMP size_t __cdecl wcslen(_In_z_ const wchar_t *_Str)
if(dx< 0)
Definition: linetemp.h:194
TCHAR szTitle[MAX_LOADSTRING]
Definition: magnifier.c:35
HWND hMainWnd
Definition: magnifier.c:32
static HICON
Definition: imagelist.c:84
static const CLSID *static CLSID *static const GUID VARIANT VARIANT *static IServiceProvider DWORD *static HMENU
Definition: ordinal.c:60
static ATOM item
Definition: dde.c:856
HWND hTabWnd
Definition: msconfig.c:22
HICON hIcon
Definition: msconfig.c:44
__int3264 LONG_PTR
Definition: mstsclib_h.h:276
unsigned int UINT
Definition: ndis.h:50
#define L(x)
Definition: ntvdm.h:50
#define LOWORD(l)
Definition: pedump.c:82
HWND hProcessPageListCtrl
Definition: procpage.c:43
#define ILC_COLOR4
Definition: commctrl.h:354
#define LVSIL_SMALL
Definition: commctrl.h:2299
_Out_opt_ int _Out_opt_ int * cy
Definition: commctrl.h:586
#define ListView_InsertItem(hwnd, pitem)
Definition: commctrl.h:2408
#define ListView_SetItemState(hwndLV, i, data, mask)
Definition: commctrl.h:2673
#define TabCtrl_GetCurSel(hwnd)
Definition: commctrl.h:4063
#define LVS_ICON
Definition: commctrl.h:2261
#define ListView_InsertColumn(hwnd, iCol, pcol)
Definition: commctrl.h:2636
#define NM_DBLCLK
Definition: commctrl.h:131
#define ILC_COLOR16
Definition: commctrl.h:356
#define LVIF_STATE
Definition: commctrl.h:2312
#define ListView_SetImageList(hwnd, himl, iImageList)
Definition: commctrl.h:2304
#define ILC_COLOR8
Definition: commctrl.h:355
#define LVNI_SELECTED
Definition: commctrl.h:2424
#define ListView_GetHeader(hwnd)
Definition: commctrl.h:2651
#define LVS_REPORT
Definition: commctrl.h:2262
#define LVS_SMALLICON
Definition: commctrl.h:2263
#define LVN_GETDISPINFO
Definition: commctrl.h:3160
#define LVCF_WIDTH
Definition: commctrl.h:2587
#define LVNI_FOCUSED
Definition: commctrl.h:2423
#define LV_DISPINFO
Definition: commctrl.h:3170
#define ListView_GetImageList(hwnd, iImageList)
Definition: commctrl.h:2296
_Out_opt_ int * cx
Definition: commctrl.h:585
#define ILC_COLOR32
Definition: commctrl.h:358
#define ListView_GetNextItem(hwnd, i, flags)
Definition: commctrl.h:2434
#define LPSTR_TEXTCALLBACK
Definition: commctrl.h:2383
#define ListView_GetItemCount(hwnd)
Definition: commctrl.h:2307
#define ListView_SortItems(hwndLV, _pfnCompare, _lPrm)
Definition: commctrl.h:2703
#define HDN_ITEMCLICK
Definition: commctrl.h:868
#define LVIS_SELECTED
Definition: commctrl.h:2319
#define ListView_GetSelectedCount(hwndLV)
Definition: commctrl.h:2709
#define ListView_RedrawItems(hwndLV, iFirst, iLast)
Definition: commctrl.h:2525
#define LVIF_PARAM
Definition: commctrl.h:2311
#define LV_ITEM
Definition: commctrl.h:2337
#define ListView_DeleteAllItems(hwnd)
Definition: commctrl.h:2414
#define LVIF_TEXT
Definition: commctrl.h:2309
#define ListView_SetItem(hwnd, pitem)
Definition: commctrl.h:2401
#define ImageList_AddIcon(himl, hicon)
Definition: commctrl.h:415
#define NM_RCLICK
Definition: commctrl.h:133
#define ILC_MASK
Definition: commctrl.h:351
#define ListView_DeleteItem(hwnd, i)
Definition: commctrl.h:2411
#define LVN_KEYDOWN
Definition: commctrl.h:3184
#define LVIF_IMAGE
Definition: commctrl.h:2310
#define LVN_ITEMCHANGED
Definition: commctrl.h:3131
#define LVCF_TEXT
Definition: commctrl.h:2588
#define ILC_COLOR24
Definition: commctrl.h:357
#define LVIS_FOCUSED
Definition: commctrl.h:2318
#define ListView_GetItem(hwnd, pitem)
Definition: commctrl.h:2394
#define ListView_EnsureVisible(hwndLV, i, fPartialOK)
Definition: commctrl.h:2519
#define LVS_LIST
Definition: commctrl.h:2264
#define TabCtrl_SetCurFocus(hwnd, i)
Definition: commctrl.h:4102
#define ILC_COLOR
Definition: commctrl.h:352
#define LV_COLUMN
Definition: commctrl.h:2547
#define LVSIL_NORMAL
Definition: commctrl.h:2298
#define WM_NOTIFY
Definition: richedit.h:61
_Check_return_ _CRTIMP int __cdecl _wcsicmp(_In_z_ const wchar_t *_Str1, _In_z_ const wchar_t *_Str2)
_CRTIMP wchar_t *__cdecl wcscpy(_Out_writes_z_(_String_length_(_Source)+1) wchar_t *_Dest, _In_z_ const wchar_t *_Source)
_CRTIMP wchar_t *__cdecl wcsncpy(wchar_t *_Dest, const wchar_t *_Source, size_t _Count)
_Check_return_ _CRTIMP int __cdecl wcscmp(_In_z_ const wchar_t *_Str1, _In_z_ const wchar_t *_Str2)
#define memset(x, y, z)
Definition: compat.h:39
DWORD dmBitsPerPel
Definition: wingdi.h:1595
WORD dmDriverExtra
Definition: wingdi.h:1569
WORD dmSize
Definition: wingdi.h:1568
Definition: tftpd.h:60
UINT code
Definition: winuser.h:3149
HWND hwndFrom
Definition: winuser.h:3147
LONG right
Definition: windef.h:308
LONG bottom
Definition: windef.h:309
LONG top
Definition: windef.h:307
LONG left
Definition: windef.h:306
DWORD EndLocalThread(HANDLE *hThread, DWORD dwThread)
Definition: taskmgr.c:1181
TASKMANAGER_SETTINGS TaskManagerSettings
Definition: taskmgr.c:52
#define ICON_BIG
Definition: tnclass.cpp:51
#define ICON_SMALL
Definition: tnclass.cpp:48
#define GetWindowLongPtr
Definition: treelist.c:73
TW_UINT32 TW_UINT16 TW_UINT16 TW_MEMREF pData
Definition: twain.h:1830
TW_UINT32 TW_UINT16 TW_UINT16 MSG
Definition: twain.h:1829
int32_t INT_PTR
Definition: typedefs.h:64
int32_t INT
Definition: typedefs.h:58
#define __stdcall
Definition: typedefs.h:25
#define HIWORD(l)
Definition: typedefs.h:247
VOID WINAPI SwitchToThisWindow(HWND hwnd, BOOL fAltTab)
Definition: window.c:82
BOOL WINAPI IsHungAppWindow(HWND hwnd)
Definition: window.c:1876
int WINAPI GetWindowTextW(HWND hWnd, LPWSTR lpString, int nMaxCount)
Definition: window.c:1412
DWORD WINAPI GetWindowThreadProcessId(HWND hWnd, PDWORD lpdwProcessId)
LONG_PTR LPARAM
Definition: windef.h:208
LONG_PTR LRESULT
Definition: windef.h:209
UINT_PTR WPARAM
Definition: windef.h:207
#define WINAPI
Definition: msvc.h:6
DEVMODEA DEVMODE
Definition: wingdi.h:4418
#define GW_OWNER
Definition: winuser.h:761
#define MAKEWPARAM(l, h)
Definition: winuser.h:3999
BOOL WINAPI IsWindow(_In_opt_ HWND)
#define SWP_NOACTIVATE
Definition: winuser.h:1232
#define MF_BYCOMMAND
Definition: winuser.h:202
#define GetWindowLongPtrW
Definition: winuser.h:4819
BOOL WINAPI SetMenuDefaultItem(_In_ HMENU, _In_ UINT, _In_ UINT)
BOOL WINAPI GetWindowRect(_In_ HWND, _Out_ LPRECT)
int WINAPI LoadStringW(_In_opt_ HINSTANCE hInstance, _In_ UINT uID, _Out_writes_to_(cchBufferMax, return+1) LPWSTR lpBuffer, _In_ int cchBufferMax)
#define SW_MINIMIZE
Definition: winuser.h:770
BOOL WINAPI SetWindowPos(_In_ HWND, _In_opt_ HWND, _In_ int, _In_ int, _In_ int, _In_ int, _In_ UINT)
#define WM_SIZE
Definition: winuser.h:1601
WORD WINAPI CascadeWindows(_In_opt_ HWND hwndParent, _In_ UINT wHow, _In_opt_ CONST RECT *lpRect, _In_ UINT cKids, _In_reads_opt_(cKids) const HWND FAR *lpKids)
#define SWP_NOMOVE
Definition: winuser.h:1234
#define WM_COMMAND
Definition: winuser.h:1730
#define VK_CONTROL
Definition: winuser.h:2193
BOOL WINAPI GetCursorPos(_Out_ LPPOINT)
Definition: cursoricon.c:2639
#define WS_EX_TOOLWINDOW
Definition: winuser.h:404
#define SWP_NOSIZE
Definition: winuser.h:1235
#define SIZE_MINIMIZED
Definition: winuser.h:2496
#define WM_INITDIALOG
Definition: winuser.h:1729
#define PostThreadMessage
Definition: winuser.h:5823
int WINAPI MapWindowPoints(_In_opt_ HWND hWndFrom, _In_opt_ HWND hWndTo, _Inout_updates_(cPoints) LPPOINT lpPoints, _In_ UINT cPoints)
#define GCL_HICONSM
Definition: winuser.h:662
HWND WINAPI GetDlgItem(_In_opt_ HWND, _In_ int)
#define TPM_TOPALIGN
Definition: winuser.h:2373
BOOL WINAPI SetWindowTextW(_In_ HWND, _In_opt_ LPCWSTR)
BOOL WINAPI ShowWindowAsync(_In_ HWND, _In_ int)
#define GetMessage
Definition: winuser.h:5780
WORD WINAPI TileWindows(_In_opt_ HWND hwndParent, _In_ UINT wHow, _In_opt_ CONST RECT *lpRect, _In_ UINT cKids, _In_reads_opt_(cKids) const HWND FAR *lpKids)
BOOL WINAPI GetClientRect(_In_ HWND, _Out_ LPRECT)
#define ENUM_CURRENT_SETTINGS
Definition: winuser.h:179
HMENU WINAPI GetSubMenu(_In_ HMENU, _In_ int)
BOOL WINAPI EnumWindows(_In_ WNDENUMPROC lpEnumFunc, _In_ LPARAM lParam)
#define MF_ENABLED
Definition: winuser.h:128
#define WM_TIMER
Definition: winuser.h:1732
#define TPM_LEFTALIGN
Definition: winuser.h:2367
struct tagNMHDR * LPNMHDR
BOOL WINAPI EnableWindow(_In_ HWND, _In_ BOOL)
#define TPM_LEFTBUTTON
Definition: winuser.h:2369
BOOL WINAPI CheckMenuRadioItem(_In_ HMENU, _In_ UINT, _In_ UINT, _In_ UINT, _In_ UINT)
HWND WINAPI GetParent(_In_ HWND)
#define GetClassLongPtrW
Definition: winuser.h:4554
BOOL WINAPI DestroyMenu(_In_ HMENU)
HWND WINAPI GetWindow(_In_ HWND, _In_ UINT)
HICON WINAPI LoadIconW(_In_opt_ HINSTANCE, _In_ LPCWSTR)
Definition: cursoricon.c:2044
#define SWP_NOOWNERZORDER
Definition: winuser.h:1239
BOOL WINAPI TrackPopupMenu(_In_ HMENU, _In_ UINT, _In_ int, _In_ int, _Reserved_ int, _In_ HWND, _Reserved_ LPCRECT)
#define VK_DELETE
Definition: winuser.h:2223
#define WM_DESTROY
Definition: winuser.h:1599
#define WM_KEYDOWN
Definition: winuser.h:1705
BOOL WINAPI InvalidateRect(_In_opt_ HWND, _In_opt_ LPCRECT, _In_ BOOL)
#define MAKEINTRESOURCEW(i)
Definition: winuser.h:582
HMENU WINAPI LoadMenuW(_In_opt_ HINSTANCE, _In_ LPCWSTR)
#define SWP_NOZORDER
Definition: winuser.h:1237
#define SW_MAXIMIZE
Definition: winuser.h:766
#define SetWindowLongPtrW
Definition: winuser.h:5336
#define GCL_HICON
Definition: winuser.h:661
#define GWL_STYLE
Definition: winuser.h:846
BOOL WINAPI IsWindowVisible(_In_ HWND)
BOOL WINAPI EnableMenuItem(_In_ HMENU, _In_ UINT, _In_ UINT)
LRESULT WINAPI SendMessageW(_In_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
HMENU WINAPI GetMenu(_In_ HWND)
SHORT WINAPI GetKeyState(_In_ int)
#define GWL_EXSTYLE
Definition: winuser.h:845
#define MF_GRAYED
Definition: winuser.h:129
#define MF_DISABLED
Definition: winuser.h:130
__wchar_t WCHAR
Definition: xmlstorage.h:180
WCHAR * LPWSTR
Definition: xmlstorage.h:184