Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
17056908
Commit
17056908
authored
Apr 03, 2019
by
Vijay Kiran Kamuju
Committed by
Alexandre Julliard
Apr 04, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
taskmgr: Use StrFormatKBSizeW/StrFormatByteSizeW to show memory usage.
Signed-off-by:
Vijay Kiran Kamuju
<
infyquest@gmail.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
f0db9c4b
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
4 deletions
+6
-4
Makefile.in
programs/taskmgr/Makefile.in
+1
-1
graph.c
programs/taskmgr/graph.c
+5
-3
No files found.
programs/taskmgr/Makefile.in
View file @
17056908
MODULE
=
taskmgr.exe
APPMODE
=
-mwindows
-mno-cygwin
IMPORTS
=
shell32 comctl32 user32 gdi32 advapi32
IMPORTS
=
shell32
shlwapi
comctl32 user32 gdi32 advapi32
C_SRCS
=
\
about.c
\
...
...
programs/taskmgr/graph.c
View file @
17056908
...
...
@@ -26,6 +26,7 @@
#include <windows.h>
#include <commctrl.h>
#include <shlwapi.h>
#include <winnt.h>
#include "taskmgr.h"
...
...
@@ -239,8 +240,6 @@ static void Graph_DrawMemUsageGraph(HDC hDC, HWND hWnd)
/* Top bars that are "unused", i.e. are dark green, representing free memory */
int
i
;
static
const
WCHAR
wszFormat
[]
=
{
'%'
,
'd'
,
'K'
,
0
};
/*
* Get the client area rectangle
*/
...
...
@@ -257,7 +256,10 @@ static void Graph_DrawMemUsageGraph(HDC hDC, HWND hWnd)
CommitChargeTotal
=
(
ULONGLONG
)
PerfDataGetCommitChargeTotalK
();
CommitChargeLimit
=
(
ULONGLONG
)
PerfDataGetCommitChargeLimitK
();
swprintf
(
Text
,
wszFormat
,
(
int
)
CommitChargeTotal
);
if
(
CommitChargeTotal
<
1024
)
StrFormatKBSizeW
(
CommitChargeTotal
,
Text
,
ARRAY_SIZE
(
Text
));
else
StrFormatByteSizeW
(
CommitChargeTotal
,
Text
,
ARRAY_SIZE
(
Text
));
/*
* Draw the font text onto the graph
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment