mirror of
https://github.com/reactos/reactos
synced 2025-10-06 16:32:42 +02:00
Compare commits
220 Commits
Workaround
...
ntos/KiWri
Author | SHA1 | Date | |
---|---|---|---|
|
fb0752b5f5 | ||
|
db47b59b11 | ||
|
23ad93627b | ||
|
2f380814d3 | ||
|
80eb313eed | ||
|
00983aa86f | ||
|
79f281e74f | ||
|
00f4a0f89b | ||
|
dd53e7f79e | ||
|
18fc5a1391 | ||
|
3b8cfa42c1 | ||
|
5022a451df | ||
|
9a0ff8b21b | ||
|
1b564c1ba8 | ||
|
111c8cc62a | ||
|
2f805d7a02 | ||
|
a3899d8151 | ||
|
94a650cdf7 | ||
|
1519a676bd | ||
|
4089e90890 | ||
|
f669426bf4 | ||
|
52719b52ae | ||
|
182f353b2f | ||
|
ff7bf747bf | ||
|
ecf4001e6f | ||
|
9aa299bea4 | ||
|
2ec3a199af | ||
|
208dfd22c6 | ||
|
8d7eca9482 | ||
|
ac3ecb2b2d | ||
|
774b3a6e1d | ||
|
1e6e5529c6 | ||
|
7efab12e6f | ||
|
125f94d8ab | ||
|
4750cbe55b | ||
|
3022d74beb | ||
|
7093412f4e | ||
|
b0dd4ba09c | ||
|
1890ad20f8 | ||
|
72bd9ef29a | ||
|
98b26cc24a | ||
|
0679260073 | ||
|
dca5194279 | ||
|
91fadeb6c3 | ||
|
5dbf87e2c1 | ||
|
32fad87a08 | ||
|
4965d6a8ac | ||
|
3660920b7f | ||
|
7afcd2a8b7 | ||
|
d66ad21ee0 | ||
|
87cd66a577 | ||
|
769462faaa | ||
|
13657fdb5b | ||
|
190782c3e0 | ||
|
aa4fac61c8 | ||
|
cc8ec38a87 | ||
|
c5325f5016 | ||
|
81d845fb2c | ||
|
467dec4d16 | ||
|
21b3382f31 | ||
|
090d563488 | ||
|
cfde03ec9b | ||
|
177cbd81af | ||
|
b6562a664b | ||
|
c7eba0c5c7 | ||
|
a444572c3e | ||
|
70422cda51 | ||
|
97e7efc020 | ||
|
49c40a2941 | ||
|
2e8f4e2c24 | ||
|
f9bedd5ca5 | ||
|
0cd7e2cfb0 | ||
|
db9768f25d | ||
|
c302dbcc96 | ||
|
421dd31d49 | ||
|
982cf2be5e | ||
|
d69a80fad7 | ||
|
457642cc4a | ||
|
be7d79768e | ||
|
35ca454cab | ||
|
c1b8c4f96f | ||
|
151ba9ee8f | ||
|
0c6423da8d | ||
|
48beb0433e | ||
|
5ec739bf2e | ||
|
6ab81dcc31 | ||
|
0b8acaac31 | ||
|
08d575adf9 | ||
|
5821136dfa | ||
|
a7a504a466 | ||
|
367e4877f1 | ||
|
776c660542 | ||
|
e01c32f3bd | ||
|
762a9f00bb | ||
|
738ff9dc04 | ||
|
684072fe12 | ||
|
9563c07146 | ||
|
c930c8c464 | ||
|
aee5cbdfe3 | ||
|
9ab89bd8fa | ||
|
5c47607ab2 | ||
|
5b633d64f1 | ||
|
6a4dbedd1e | ||
|
01cd8472c7 | ||
|
f81c82f5fa | ||
|
fce48c3014 | ||
|
5abc69f31d | ||
|
ad50a00020 | ||
|
c37af4cfca | ||
|
0fc0d9ebb1 | ||
|
0016d65532 | ||
|
9292cad39a | ||
|
c1369e8c41 | ||
|
8c9f250587 | ||
|
f222c2155d | ||
|
185225a5fc | ||
|
74599f6c97 | ||
|
d7db8c9c80 | ||
|
b9b765038e | ||
|
e7a9e7ca3d | ||
|
818842de06 | ||
|
1b2eeb23e0 | ||
|
11d11f93ee | ||
|
7b5e004dd6 | ||
|
9ecd5fb6fe | ||
|
ecb2293d6d | ||
|
1b63247b81 | ||
|
4a5fdb9a3a | ||
|
5d30831fb8 | ||
|
35ed79f2d4 | ||
|
05d71fa69b | ||
|
c35bb8dd73 | ||
|
88d9285bd0 | ||
|
cfcc8d85b2 | ||
|
ffa81857c2 | ||
|
49a55a099e | ||
|
7a9c744b70 | ||
|
6c7d2a2e25 | ||
|
386fccd02c | ||
|
6a95219ed3 | ||
|
59f0ec1fdf | ||
|
5fb6fad175 | ||
|
564be44f45 | ||
|
b931c51937 | ||
|
61ee431169 | ||
|
2ffc6d281b | ||
|
56e7afe56c | ||
|
27bb510282 | ||
|
7dc7b866b1 | ||
|
7f49ae633b | ||
|
d769f5675d | ||
|
dba4efbcae | ||
|
4bc97ad145 | ||
|
4a1877d0f6 | ||
|
19c1f5661f | ||
|
2e47094764 | ||
|
8e2d1b358c | ||
|
787f81f3f5 | ||
|
ddf55b3772 | ||
|
7c61e5769f | ||
|
9da45923b3 | ||
|
57fa5a22de | ||
|
9a093ecbe9 | ||
|
bcedb5314c | ||
|
c6b134123b | ||
|
96aa1eee17 | ||
|
75c0dc0cd8 | ||
|
8e53386de9 | ||
|
8d80203d65 | ||
|
135a9a95b8 | ||
|
e6302ccd70 | ||
|
656a5dcc1f | ||
|
5c505d9a9b | ||
|
f37138ce91 | ||
|
c71845ee8c | ||
|
bc62c17a7f | ||
|
275c40d26d | ||
|
b45debb93a | ||
|
14f8f7e3bd | ||
|
029e53ddb5 | ||
|
0089017d54 | ||
|
5af47c9baf | ||
|
5461abeeba | ||
|
bdda5b93d7 | ||
|
6dccccc2a3 | ||
|
245513e7ec | ||
|
1786a68256 | ||
|
0898bd371d | ||
|
f844296b0a | ||
|
acbadb9fba | ||
|
d1d300b44b | ||
|
115cf65ebf | ||
|
13894e2da0 | ||
|
b728d330c2 | ||
|
02acdae022 | ||
|
cf96d9175f | ||
|
118940ed9a | ||
|
5c8d677356 | ||
|
84f3a2b1d1 | ||
|
fc6330a01a | ||
|
4a0f0ddbd7 | ||
|
a8cd1eac1d | ||
|
c6853581c5 | ||
|
4d605ec26f | ||
|
7c23a2e38e | ||
|
ccf1e97aa1 | ||
|
6988b4e2c4 | ||
|
afb96acfdd | ||
|
9c5efed7da | ||
|
606e996e1f | ||
|
e36c669d97 | ||
|
da5192e622 | ||
|
f1a66daeeb | ||
|
c3505bb4f6 | ||
|
abb04ec321 | ||
|
6b9122b5f5 | ||
|
a86055a037 | ||
|
7f248437e8 | ||
|
9a55c931f8 | ||
|
556cc8a7b2 |
19
.cursor/coding-style.json
Normal file
19
.cursor/coding-style.json
Normal file
@@ -0,0 +1,19 @@
|
||||
{
|
||||
"indentation": {
|
||||
"type": "spaces",
|
||||
"size": 4
|
||||
},
|
||||
"lineLength": 100,
|
||||
"braceStyle": "allman",
|
||||
"namingConventions": {
|
||||
"functions": {
|
||||
"public": "PascalCase",
|
||||
"private": "_PascalCase"
|
||||
},
|
||||
"variables": {
|
||||
"local": "camelCase",
|
||||
"global": "PascalCase",
|
||||
"constants": "UPPER_CASE"
|
||||
}
|
||||
}
|
||||
}
|
52
.cursor/editor.json
Normal file
52
.cursor/editor.json
Normal file
@@ -0,0 +1,52 @@
|
||||
{
|
||||
"editor": {
|
||||
"defaultFormatter": null
|
||||
},
|
||||
"[c,cpp]": {
|
||||
"editor": {
|
||||
"tabSize": 4,
|
||||
"insertSpaces": true,
|
||||
"detectIndentation": false,
|
||||
"trimAutoWhitespace": true,
|
||||
"formatOnSave": false,
|
||||
"formatOnType": true,
|
||||
"defaultFormatter": "clang-format",
|
||||
"rulers": [100],
|
||||
"wordWrap": "off"
|
||||
}
|
||||
},
|
||||
"files": {
|
||||
"associations": {
|
||||
"*.c": "c",
|
||||
"*.h": "c",
|
||||
"*.cpp": "cpp",
|
||||
"*.hpp": "cpp"
|
||||
},
|
||||
"encoding": "utf8",
|
||||
"trimTrailingWhitespace": true,
|
||||
"insertFinalNewline": true,
|
||||
"exclude": {
|
||||
"**/.git": true,
|
||||
"compile_commands.json": true,
|
||||
"output-*": true,
|
||||
"modules/optional": true,
|
||||
"modules/3rdparty": true,
|
||||
"modules/bootcd_extras": true,
|
||||
"modules/livecd_extras": true,
|
||||
"modules/hybridcd_extras": true,
|
||||
"modules/[Aa][Hh][Kk]_[Tt]ests": true,
|
||||
".cache": true,
|
||||
".cproject": true,
|
||||
".DS_Store": true,
|
||||
".project": true,
|
||||
".settings": true,
|
||||
".vscode": true,
|
||||
"sdk/tools/winesync/winesync.cfg": true,
|
||||
"**/build": true,
|
||||
"**/obj": true,
|
||||
"**/bin": true,
|
||||
"**/*.o": true,
|
||||
"**/*.obj": true
|
||||
}
|
||||
}
|
||||
}
|
46
.cursor/settings.json
Normal file
46
.cursor/settings.json
Normal file
@@ -0,0 +1,46 @@
|
||||
{
|
||||
"projectType": "reactos",
|
||||
"language": {
|
||||
"c": {
|
||||
"standard": "c99",
|
||||
"warnings": ["all", "error", "pedantic", "unused"],
|
||||
"formatter": "clang-format",
|
||||
"linter": "clang-tidy"
|
||||
},
|
||||
"cpp": {
|
||||
"standard": "c++11",
|
||||
"warnings": ["all", "error", "pedantic", "unused"],
|
||||
"formatter": "clang-format",
|
||||
"linter": "clang-tidy"
|
||||
}
|
||||
},
|
||||
"codingStyle": "reactos",
|
||||
"formatOnSave": false,
|
||||
"lintOnSave": false,
|
||||
"paths": {
|
||||
"source": [
|
||||
"base",
|
||||
"boot",
|
||||
"dll",
|
||||
"drivers",
|
||||
"hal",
|
||||
"ntoskrnl",
|
||||
"subsystems",
|
||||
"win32ss"
|
||||
],
|
||||
"include": [
|
||||
"sdk/include"
|
||||
],
|
||||
"docs": [
|
||||
"**/*.md",
|
||||
"media/doc/*.md",
|
||||
"media/doc/*.txt"
|
||||
],
|
||||
"tests": [
|
||||
"modules/rostests"
|
||||
],
|
||||
"build": [
|
||||
"output-*"
|
||||
]
|
||||
}
|
||||
}
|
3
.gitattributes
vendored
3
.gitattributes
vendored
@@ -30,6 +30,9 @@
|
||||
*.TXT text
|
||||
*.y text
|
||||
|
||||
# Files with these extensions must always have LF (Unix) line endings.
|
||||
*.sh text eol=lf
|
||||
|
||||
# Files with these extensions end up in the built ReactOS system, so they
|
||||
# need to have CRLF line endings.
|
||||
*.bat text eol=crlf
|
||||
|
5
.github/PULL_REQUEST_TEMPLATE.md
vendored
5
.github/PULL_REQUEST_TEMPLATE.md
vendored
@@ -17,3 +17,8 @@ _Use a TODO when your pull request is Work in Progress._
|
||||
|
||||
- [ ]
|
||||
- [ ]
|
||||
|
||||
## Testbot runs (Filled in by Devs)
|
||||
|
||||
- [ ] KVM x86:
|
||||
- [ ] KVM x64:
|
2
.gitignore
vendored
2
.gitignore
vendored
@@ -13,3 +13,5 @@ modules/[Aa][Hh][Kk]_[Tt]ests
|
||||
.settings
|
||||
.vscode
|
||||
sdk/tools/winesync/winesync.cfg
|
||||
.cursor/cache/
|
||||
.cursor/logs/
|
||||
|
@@ -68,6 +68,9 @@ include(sdk/cmake/config.cmake)
|
||||
# Compiler flags handling
|
||||
include(sdk/cmake/compilerflags.cmake)
|
||||
|
||||
# set_wine_module function
|
||||
include(sdk/cmake/set_wine_module.cmake)
|
||||
|
||||
add_definitions(
|
||||
-D__REACTOS__
|
||||
# swprintf without count argument is used in most of the codebase
|
||||
@@ -157,7 +160,10 @@ if(NOT CMAKE_CROSSCOMPILING)
|
||||
|
||||
set(NATIVE_TARGETS asmpp bin2c widl gendib cabman fatten hpp isohybrid mkhive mkisofs obj2bin spec2def geninc mkshelllink utf16le xml2sdb)
|
||||
if(NOT MSVC)
|
||||
list(APPEND NATIVE_TARGETS rsym pefixup)
|
||||
list(APPEND NATIVE_TARGETS pefixup)
|
||||
if (ARCH STREQUAL "i386")
|
||||
list(APPEND NATIVE_TARGETS rsym)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
install(TARGETS ${NATIVE_TARGETS})
|
||||
|
156
CODEOWNERS
156
CODEOWNERS
@@ -116,6 +116,20 @@
|
||||
# S: Abandoned
|
||||
/ntoskrnl/cache/
|
||||
|
||||
# Client/Server Runtime Subsystem
|
||||
# M: HBelusca, Hermès Bélusca-Maïto
|
||||
# S: Maintained
|
||||
/sdk/include/reactos/subsys/csr/ @HBelusca
|
||||
/subsystems/csr/ @HBelusca
|
||||
/win32ss/user/ntuser/csr.* @HBelusca
|
||||
|
||||
# Clipboard Viewer
|
||||
# M: HBelusca, Hermès Bélusca-Maïto
|
||||
# R: Mondgestein, Ricardo Hanke
|
||||
# S: Maintained
|
||||
/base/applications/clipbrd/ @HBelusca
|
||||
/base/applications/cmdutils/clip/ @HBelusca
|
||||
|
||||
# CMake Build Scripts
|
||||
# M:
|
||||
# R: learn-more, learn_more, Mark Jansen
|
||||
@@ -124,6 +138,56 @@
|
||||
/sdk/cmake/
|
||||
*.cmake
|
||||
|
||||
# Command-line Utilities
|
||||
# M: HBelusca, Hermès Bélusca-Maïto
|
||||
# S: Maintained
|
||||
/base/applications/cmdutils/attrib/ @HBelusca
|
||||
/base/applications/cmdutils/chcp/ @HBelusca
|
||||
/base/applications/cmdutils/doskey/ @HBelusca
|
||||
/base/applications/cmdutils/eventcreate/ @HBelusca
|
||||
/base/applications/cmdutils/find/ @HBelusca
|
||||
/base/applications/cmdutils/help/ @HBelusca
|
||||
/base/applications/cmdutils/mode/ @HBelusca
|
||||
/base/applications/cmdutils/more/ @HBelusca
|
||||
/base/applications/cmdutils/taskkill/ @HBelusca
|
||||
/base/applications/cmdutils/timeout/ @HBelusca
|
||||
/sdk/lib/conutils/ @HBelusca
|
||||
|
||||
# Command-line Prompt Interpreter
|
||||
# M: HBelusca, Hermès Bélusca-Maïto
|
||||
# S: Maintained
|
||||
/base/shell/cmd/ @HBelusca
|
||||
|
||||
# Console Client/Server Subsystem, Terminal Emulator / Text-Mode
|
||||
# M: HBelusca, Hermès Bélusca-Maïto
|
||||
# S: Maintained
|
||||
/dll/cpl/console/ @HBelusca
|
||||
/dll/win32/kernel32/client/console/ @HBelusca
|
||||
/dll/win32/kernel32/include/console.h @HBelusca
|
||||
/drivers/base/condrv/ @HBelusca
|
||||
/drivers/setup/blue/ @HBelusca
|
||||
/modules/rostests/winetests/kernel32/console.c @HBelusca
|
||||
/sdk/include/reactos/drivers/condrv/ @HBelusca
|
||||
/sdk/include/reactos/drivers/blue/ @HBelusca
|
||||
/sdk/include/reactos/subsys/win/conmsg.h @HBelusca
|
||||
/sdk/include/reactos/subsys/win/console.h @HBelusca
|
||||
/win32ss/user/ntuser/console.c @HBelusca
|
||||
/win32ss/user/winsrv/concfg/ @HBelusca
|
||||
/win32ss/user/winsrv/consrv/ @HBelusca
|
||||
|
||||
# Event Log Subsystem
|
||||
# M: HBelusca, Hermès Bélusca-Maïto
|
||||
# M: EricKohl, ekohl, Eric Kohl
|
||||
# S: Maintained
|
||||
/base/services/eventlog/ @EricKohl @HBelusca
|
||||
/dll/win32/advapi32/service/eventlog.c @EricKohl @HBelusca
|
||||
/sdk/lib/evtlib/ @HBelusca
|
||||
|
||||
# Event Log Viewer
|
||||
# M: HBelusca, Hermès Bélusca-Maïto
|
||||
# S: Maintained
|
||||
/base/applications/mscutils/eventvwr/ @HBelusca
|
||||
|
||||
# File Patch API
|
||||
# M: learn-more, learn_more, Mark Jansen
|
||||
# S: Maintained
|
||||
@@ -139,7 +203,7 @@
|
||||
# Filesystem Filter Manager
|
||||
# M: gedmurphy, Ged, Ged Murphy
|
||||
# S: Maintained
|
||||
/drivers/filters/fltmgr/ @gedmurphy
|
||||
/drivers/filters/fltmgr/ @gedmurphy
|
||||
|
||||
# File Systems Run Time Library
|
||||
# M: HeisSpiter, Heis Spiter, Pierre Schweitzer
|
||||
@@ -150,11 +214,13 @@
|
||||
/sdk/lib/drivers/ntoskrnl_vista/fsrtl.c @HeisSpiter
|
||||
|
||||
# Freeloader
|
||||
# M:
|
||||
# M: HBelusca, Hermès Bélusca-Maïto
|
||||
# R: tkreuzer, ThePhysicist, Timo Kreuzer
|
||||
# R: Extravert-ir, extravert34, Victor Perevertkin
|
||||
# S: Maintained
|
||||
/boot/freeldr/freeldr/ @tkreuzer @Extravert-ir
|
||||
/boot/freeldr/freeldr/ @HBelusca @tkreuzer @Extravert-ir
|
||||
/boot/rtl/ @HBelusca
|
||||
/ntoskrnl/config/cmboot.c @HBelusca
|
||||
|
||||
# HAL / APIC
|
||||
# M: tkreuzer, ThePhysicist, Timo Kreuzer
|
||||
@@ -187,6 +253,12 @@
|
||||
# S: Maintained
|
||||
/drivers/storage/mountmgr/ @HeisSpiter
|
||||
|
||||
# MSConfig
|
||||
# M: HBelusca, Hermès Bélusca-Maïto
|
||||
# S: Maintained
|
||||
/base/applications/msconfig/ @HBelusca
|
||||
/base/applications/msconfig_new/ @HBelusca
|
||||
|
||||
# Network Drivers
|
||||
# M:
|
||||
# R: ThFabba, Thomas Faber
|
||||
@@ -215,11 +287,29 @@
|
||||
# S: Maintained
|
||||
/dll/ntdll/ @HeisSpiter @learn-more @ThFabba @tkreuzer
|
||||
|
||||
# NT Virtual DOS Machine
|
||||
# M: HBelusca, Hermès Bélusca-Maïto
|
||||
# R: reactos573, aandrejevic, Aleksandar Andrejevic
|
||||
# S: Maintained
|
||||
/dll/win32/kernel32/client/vdm.c @reactos573 @HBelusca
|
||||
/dll/win32/kernel32/include/vdm.h @reactos573 @HBelusca
|
||||
/sdk/include/reactos/subsys/win/vdm.h @reactos573 @HBelusca
|
||||
/ntoskrnl/vdm @reactos573 @HBelusca
|
||||
/sdk/include/reactos/libs/fast486/ @reactos573 @HBelusca
|
||||
/sdk/lib/fast486/ @reactos573 @HBelusca
|
||||
/subsystems/mvdm/ @reactos573 @HBelusca
|
||||
/subsystems/win/basesrv/vdm.* @reactos573 @HBelusca
|
||||
|
||||
# Printing
|
||||
# M: ColinFinck, Colin Finck
|
||||
# S: Maintained
|
||||
/win32ss/printing/ @ColinFinck
|
||||
|
||||
# Program Manager
|
||||
# M: HBelusca, Hermès Bélusca-Maïto
|
||||
# S: Maintained
|
||||
/base/shell/progman/ @HBelusca
|
||||
|
||||
# ReactOS API Tests
|
||||
# M:
|
||||
# R: learn-more, learn_more, Mark Jansen
|
||||
@@ -232,7 +322,25 @@
|
||||
# S: Maintained
|
||||
/modules/rostests/kmtests/ @ThFabba
|
||||
|
||||
# ROS internals tools
|
||||
# ReactOS Setup
|
||||
# M: HBelusca, Hermès Bélusca-Maïto
|
||||
# R: EricKohl, ekohl, Eric Kohl
|
||||
# S: Maintained
|
||||
/base/setup/ @HBelusca
|
||||
/base/system/winlogon/setup.c @EricKohl
|
||||
/dll/win32/setupapi/
|
||||
/dll/win32/syssetup/ @EricKohl
|
||||
/drivers/setup/ @HBelusca
|
||||
/sdk/include/reactos/libs/syssetup/ @EricKohl
|
||||
|
||||
# ReactOS miscellaneous tools
|
||||
# M:
|
||||
# R: HBelusca, Hermès Bélusca-Maïto
|
||||
# S: Maintained
|
||||
/modules/rosapps/applications/cmdutils/cat/ @HBelusca
|
||||
/modules/rosapps/applications/sysutils/utils/partinfo/ @HBelusca
|
||||
|
||||
# ReactOS internals tools
|
||||
# M: HeisSpiter, Heis Spiter, Pierre Schweitzer
|
||||
# S: Maintained
|
||||
/modules/rosapps/applications/rosinternals/ @HeisSpiter
|
||||
@@ -252,15 +360,26 @@
|
||||
/modules/rostests/kmtests/ntos_se/ @GeoB99
|
||||
/ntoskrnl/se/ @GeoB99
|
||||
|
||||
# Session Manager Subsystem
|
||||
# M: HBelusca, Hermès Bélusca-Maïto
|
||||
# S: Maintained
|
||||
/base/system/smss/ @HBelusca
|
||||
/sdk/include/reactos/subsys/sm/ @HBelusca
|
||||
/sdk/lib/smlib/ @HBelusca
|
||||
|
||||
# Shell
|
||||
# M:
|
||||
# R: learn-more, learn_more, Mark Jansen
|
||||
# R: yagoulas, Giannis Adamopoulos
|
||||
# R: HBelusca, Hermès Bélusca-Maïto
|
||||
# S: Maintained
|
||||
/base/shell/explorer/ @learn-more @yagoulas
|
||||
/base/shell/rshell/ @learn-more @yagoulas
|
||||
/dll/win32/browseui/ @learn-more @yagoulas
|
||||
/dll/win32/shell32/ @learn-more @yagoulas
|
||||
/dll/win32/shell32/CShellLink.* @HBelusca
|
||||
/dll/win32/shell32/CUserNotification.* @HBelusca
|
||||
/dll/win32/shell32/systray.cpp @HBelusca
|
||||
|
||||
# Shell Extensions
|
||||
# M:
|
||||
@@ -311,8 +430,30 @@
|
||||
|
||||
# Win32 file functions
|
||||
# M: HeisSpiter, Heis Spiter, Pierre Schweitzer
|
||||
# R: HBelusca, Hermès Bélusca-Maïto
|
||||
# S: Maintained
|
||||
/dll/win32/kernel32/client/file/ @HeisSpiter
|
||||
/dll/win32/kernel32/client/file/ @HeisSpiter
|
||||
/dll/win32/kernel32/client/file/find.c @HBelusca
|
||||
|
||||
# Win32 Subsystem - User Server
|
||||
# M:
|
||||
# R: HBelusca, Hermès Bélusca-Maïto
|
||||
# S: Maintained
|
||||
/win32ss/user/winsrv/
|
||||
/win32ss/user/winsrv/usersrv/harderror.c @HBelusca
|
||||
|
||||
# Win32 Subsystem Shutdown
|
||||
# M: HBelusca, Hermès Bélusca-Maïto
|
||||
# R: EricKohl, ekohl, Eric Kohl
|
||||
# S: Maintained
|
||||
/base/system/winlogon/sas.c @EricKohl @HBelusca
|
||||
/base/system/winlogon/shutdown.c @EricKohl @HBelusca
|
||||
/dll/win32/advapi32/misc/shutdown.c @EricKohl
|
||||
/dll/win32/msgina/shutdown.c @EricKohl @HBelusca
|
||||
/win32ss/user/ntuser/shutdown.* @HBelusca
|
||||
/win32ss/user/user32/misc/exit.c @HBelusca
|
||||
/win32ss/user/winsrv/consrv/shutdown.c @HBelusca
|
||||
/win32ss/user/winsrv/usersrv/shutdown.c @HBelusca
|
||||
|
||||
# Windows Network File Systems functions
|
||||
# M: HeisSpiter, Heis Spiter, Pierre Schweitzer
|
||||
@@ -338,6 +479,11 @@
|
||||
amd64/ @tkreuzer
|
||||
/boot/freeldr/freeldr/arch/realmode/amd64.S @tkreuzer
|
||||
|
||||
# Wine DirectX
|
||||
# M: DarkFire01, The_DarkFire_, Justin Miller
|
||||
# S: Upstream
|
||||
/dll/directx/wine/ @DarkFire01
|
||||
|
||||
# Translations
|
||||
# This is the list of translation teams in ReactOS GitHub organization.
|
||||
# If you want to be part of one - hit us at https://chat.reactos.org/
|
||||
|
356
CODING_STYLE.md
Normal file
356
CODING_STYLE.md
Normal file
@@ -0,0 +1,356 @@
|
||||
# Coding Style
|
||||
|
||||
This article describes general coding style guidelines, which should be used for new ReactOS code. These guidelines apply exclusively to C and C++ source files. The Members of ReactOS agreed on this document in the October 2013 meeting.
|
||||
|
||||
As much existing ReactOS code as possible should be converted to this style unless there are reasons against doing this (like if the code is going to be rewritten from scratch in the near future). See [Notes on reformatting existing code](#notes-on-reformatting-existing-code) for more details.
|
||||
|
||||
Code synchronized with other sources (like Wine) must not be rewritten. [3rd Party Files.txt](https://github.com/reactos/reactos/blob/master/media/doc/3rd%20Party%20Files.txt) and [WINESYNC.txt](https://github.com/reactos/reactos/blob/master/media/doc/WINESYNC.txt) files can be used for tracking synchronized files.
|
||||
|
||||
## File Structure
|
||||
|
||||
1. Every ReactOS source code file should include a file header like this:
|
||||
|
||||
```
|
||||
/*
|
||||
* PROJECT: ReactOS Kernel
|
||||
* LICENSE: GPL-2.0-or-later (https://spdx.org/licenses/GPL-2.0-or-later)
|
||||
* PURPOSE: Does cool things like Memory Management
|
||||
* COPYRIGHT: Copyright 2017 Arno Nymous <abc@mailaddress.com>
|
||||
* Copyright 2017 Mike Blablabla <mike@blabla.com>
|
||||
*/
|
||||
```
|
||||
|
||||
Please use SPDX license identifiers available at https://spdx.org/licenses.
|
||||
This makes our source file parseable by licensing tools!
|
||||
|
||||
You should add yourself to the `COPYRIGHT` section of a file if you did a major contribution to it and could take responsibility for the whole file or a part of it. Not more than 3 people shall be in that list for each file.
|
||||
|
||||
`FILE` line of the old header should be removed.
|
||||
|
||||
2. [Doxygen](https://doxygen.reactos.org/) documentation generator is used for ReactOS codebase, so use a proper header for functions, see [API Documentation](https://reactos.org/wiki/Documentation_Guidelines#API_Documentation) for details.
|
||||
|
||||
## Indentation and line width
|
||||
|
||||
1. Line width must be at most **100 characters**.
|
||||
2. Do not add a space or tab at the end of any line.
|
||||
3. Indent with **4 spaces**, don't use tabs!
|
||||
4. Indent both a case label and the case statement of a switch statement.
|
||||
|
||||
**Right:**
|
||||
```c
|
||||
switch (Condition)
|
||||
{
|
||||
case 1:
|
||||
DoSomething();
|
||||
break;
|
||||
|
||||
case 2:
|
||||
{
|
||||
DoMany();
|
||||
ManyMore();
|
||||
OtherThings();
|
||||
break;
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
**Wrong:**
|
||||
```c
|
||||
switch(Condition)
|
||||
{
|
||||
case 1:
|
||||
DoSomething();
|
||||
break;
|
||||
case 2:
|
||||
DoMany();
|
||||
ManyMore();
|
||||
OtherThings();
|
||||
break;
|
||||
}
|
||||
```
|
||||
|
||||
5. When a function call does not fit onto a line, align arguments like this:
|
||||
```c
|
||||
FunctionCall(arg1,
|
||||
arg2,
|
||||
arg3);
|
||||
```
|
||||
|
||||
6. Function headers should have this format (preserving the order as in the example):
|
||||
```c
|
||||
static // scope identifier
|
||||
CODE_SEG("PAGE") // section placement
|
||||
// other attributes
|
||||
BOOLEAN // return type
|
||||
FASTCALL // calling convention
|
||||
IsOdd(
|
||||
_In_ UINT32 Number);
|
||||
```
|
||||
|
||||
## Spacing
|
||||
|
||||
1. Do not use spaces around unary operators.
|
||||
**Right:** `i++;`
|
||||
**Wrong:** `i ++;`
|
||||
|
||||
2. Place spaces around binary and ternary operators.
|
||||
**Right:** `a = b + c;`
|
||||
**Wrong:** `a=b+c;`
|
||||
|
||||
3. Do not place spaces before comma and semicolon.
|
||||
|
||||
**Right:**
|
||||
```c
|
||||
for (int i = 0; i < 5; i++)
|
||||
DoSomething();
|
||||
|
||||
func1(a, b);
|
||||
```
|
||||
|
||||
**Wrong:**
|
||||
```c
|
||||
for (int i = 0; i < 5 ; i++)
|
||||
DoSomething();
|
||||
|
||||
func1(a , b) ;
|
||||
```
|
||||
|
||||
4. Place spaces between control statements and their parentheses.
|
||||
|
||||
**Right:**
|
||||
```c
|
||||
if (Condition)
|
||||
DoSomething();
|
||||
```
|
||||
|
||||
**Wrong:**
|
||||
```c
|
||||
if(Condition)
|
||||
DoSomething();
|
||||
```
|
||||
|
||||
5. Do not place spaces between a function and its parentheses, or between a parenthesis and its content.
|
||||
|
||||
**Right:**
|
||||
```c
|
||||
func(a, b);
|
||||
```
|
||||
|
||||
**Wrong:**
|
||||
```c
|
||||
func (a, b);
|
||||
func( a, b );
|
||||
```
|
||||
|
||||
## Line breaking
|
||||
|
||||
1. Each statement should get its own line.
|
||||
|
||||
**Right:**
|
||||
```c
|
||||
x++;
|
||||
y++;
|
||||
|
||||
if (Condition)
|
||||
DoSomething();
|
||||
```
|
||||
|
||||
**Wrong:**
|
||||
```c
|
||||
x++; y++;
|
||||
|
||||
if (Condition) DoSomething();
|
||||
```
|
||||
|
||||
## Braces
|
||||
|
||||
1. Always put braces (`{` and `}`) on their own lines.
|
||||
2. One-line control clauses may use braces, but this is not a requirement. An exception are one-line control clauses including additional comments.
|
||||
|
||||
**Right:**
|
||||
```c
|
||||
if (Condition)
|
||||
DoSomething();
|
||||
|
||||
if (Condition)
|
||||
{
|
||||
DoSomething();
|
||||
}
|
||||
|
||||
if (Condition)
|
||||
{
|
||||
// This is a comment
|
||||
DoSomething();
|
||||
}
|
||||
|
||||
if (A_Very || (Very && Long || Condition) &&
|
||||
On_Many && Lines)
|
||||
{
|
||||
DoSomething();
|
||||
}
|
||||
|
||||
if (Condition)
|
||||
DoSomething();
|
||||
else
|
||||
DoSomethingElse();
|
||||
|
||||
if (Condition)
|
||||
{
|
||||
DoSomething();
|
||||
}
|
||||
else
|
||||
{
|
||||
DoSomethingElse();
|
||||
YetAnother();
|
||||
}
|
||||
```
|
||||
|
||||
**Wrong:**
|
||||
```c
|
||||
if (Condition) {
|
||||
DoSomething();
|
||||
}
|
||||
|
||||
if (Condition)
|
||||
// This is a comment
|
||||
DoSomething();
|
||||
|
||||
if (A_Very || (Very && Long || Condition) &&
|
||||
On_Many && Lines)
|
||||
DoSomething();
|
||||
|
||||
if (Condition)
|
||||
DoSomething();
|
||||
else {
|
||||
DoSomethingElse();
|
||||
YetAnother();
|
||||
}
|
||||
```
|
||||
|
||||
## Control structures
|
||||
|
||||
1. Don't use inverse logic in control clauses.
|
||||
**Right:** `if (i == 1)`
|
||||
**Wrong:** `if (1 == i)`
|
||||
|
||||
2. Avoid too many levels of cascaded control structures. Prefer a "linear style" over a "tree style". Use `goto` when it helps to make the code cleaner (e.g. for cleanup paths).
|
||||
|
||||
**Right:**
|
||||
```c
|
||||
if (!func1())
|
||||
return;
|
||||
|
||||
i = func2();
|
||||
if (i == 0)
|
||||
return;
|
||||
|
||||
j = func3();
|
||||
if (j == 1)
|
||||
return;
|
||||
...
|
||||
```
|
||||
|
||||
**Wrong:**
|
||||
```c
|
||||
if (func1())
|
||||
{
|
||||
i = func2();
|
||||
if (func2())
|
||||
{
|
||||
j = func3();
|
||||
if (func3())
|
||||
{
|
||||
...
|
||||
}
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
## Naming
|
||||
|
||||
1. Capitalize names of variables and functions. Hungarian Notation may be used when developing for Win32, but it is not required. If you don't use it, the first letter of a name must be a capital too (no lowerCamelCase). Do not use underscores as separators either.
|
||||
|
||||
**Right:**
|
||||
```c
|
||||
PLIST_ENTRY FirstEntry;
|
||||
VOID NTAPI IopDeleteIoCompletion(PVOID ObjectBody);
|
||||
PWSTR pwszTest;
|
||||
```
|
||||
|
||||
**Wrong:**
|
||||
```c
|
||||
PLIST_ENTRY first_entry;
|
||||
VOID NTAPI iop_delete_io_completion(PVOID objectBody);
|
||||
PWSTR pwsztest;
|
||||
```
|
||||
|
||||
2. Avoid abbreviating function and variable names, use descriptive verbs where possible.
|
||||
|
||||
3. Precede boolean values with meaningful verbs like "is" and "did" if possible and if it fits the usage.
|
||||
|
||||
**Right:**
|
||||
```c
|
||||
BOOLEAN IsValid;
|
||||
BOOLEAN DidSendData;
|
||||
```
|
||||
|
||||
**Wrong:**
|
||||
```c
|
||||
BOOLEAN Valid;
|
||||
BOOLEAN SentData;
|
||||
```
|
||||
|
||||
## Commenting
|
||||
|
||||
1. Avoid line-wasting comments, which could fit into a single line.
|
||||
|
||||
**Right:**
|
||||
```c
|
||||
// This is a one-line comment
|
||||
|
||||
/* This is a C-style comment */
|
||||
|
||||
// This is a comment over multiple lines.
|
||||
// We don't define any strict rules for it.
|
||||
```
|
||||
|
||||
**Wrong:**
|
||||
```c
|
||||
//
|
||||
// This comment wastes two lines
|
||||
//
|
||||
```
|
||||
|
||||
## Null, false and 0
|
||||
|
||||
1. The null pointer should be written as `NULL`. In the rare case that your environment recommends a different null pointer (e.g. C++11 `nullptr`), you may use this one of course. Just don't use the value `0`.
|
||||
|
||||
2. Win32/NT Boolean values should be written as `TRUE` and `FALSE`. In the rare case that you use C/C++ `bool` variables, you should write them as `true` and `false`.
|
||||
|
||||
3. When you need to terminate ANSI or OEM string, or check for its terminator, use `ANSI_NULL`. If the string is Unicode or Wide string, use `UNICODE_NULL`.
|
||||
|
||||
## Notes on reformatting existing code
|
||||
|
||||
- Never totally reformat a file and put a code change into it. Do this in separate commits.
|
||||
- If a commit only consists of formatting changes, say this clearly in the commit message by preceding it with *[FORMATTING]*.
|
||||
|
||||
## Other points
|
||||
|
||||
- Do not use `LARGE_INTEGER`/`ULARGE_INTEGER` unless needed for using APIs. Use `INT64`/`UINT64` instead
|
||||
- Use `#pragma once` instead of guard defines in headers
|
||||
- Don't specify a calling convention for a function unless required (usually for APIs or exported symbols)
|
||||
|
||||
## Using an automatic code style tool
|
||||
|
||||
TO BE ADDED BY User:Zefklop
|
||||
|
||||
## Points deliberately left out
|
||||
|
||||
Additional ideas were suggested during the discussion of this document, but a consensus couldn't be reached on them. Therefore we refrain from enforcing any rules on these points:
|
||||
|
||||
- TO BE ADDED BY User:Hbelusca
|
||||
|
||||
## See also
|
||||
|
||||
- [Kernel Coding Style](https://reactos.org/wiki/Kernel_Coding_Style)
|
||||
- [GNU Indent](https://reactos.org/wiki/GNU_Indent)
|
@@ -7,8 +7,8 @@
|
||||
---
|
||||
|
||||
<p align=center>
|
||||
<a href="https://reactos.org/project-news/reactos-0414-released/">
|
||||
<img alt="ReactOS 0.4.14 Release" src="https://img.shields.io/badge/release-0.4.14-0688CB.svg"></a>
|
||||
<a href="https://reactos.org/project-news/reactos-0415-released/">
|
||||
<img alt="ReactOS 0.4.15 Release" src="https://img.shields.io/badge/release-0.4.15-0688CB.svg"></a>
|
||||
<a href="https://reactos.org/download/">
|
||||
<img alt="Download ReactOS" src="https://img.shields.io/badge/download-latest-0688CB.svg"></a>
|
||||
<a href="https://sourceforge.net/projects/reactos/">
|
||||
|
@@ -3,6 +3,7 @@ add_subdirectory(atactl)
|
||||
add_subdirectory(cacls)
|
||||
add_subdirectory(calc)
|
||||
add_subdirectory(charmap)
|
||||
add_subdirectory(cleanmgr)
|
||||
add_subdirectory(clipbrd)
|
||||
add_subdirectory(cmdutils)
|
||||
add_subdirectory(control)
|
||||
|
9
base/applications/cleanmgr/CMakeLists.txt
Normal file
9
base/applications/cleanmgr/CMakeLists.txt
Normal file
@@ -0,0 +1,9 @@
|
||||
|
||||
project(cleanmgr)
|
||||
|
||||
# The main application
|
||||
add_subdirectory(cleanmgr)
|
||||
|
||||
# Cleanup handlers
|
||||
#add_subdirectory(dataclen) # Data Driven Cleaner
|
||||
|
212
base/applications/cleanmgr/cleanmgr/CCleanupHandler.cpp
Normal file
212
base/applications/cleanmgr/cleanmgr/CCleanupHandler.cpp
Normal file
@@ -0,0 +1,212 @@
|
||||
/*
|
||||
* PROJECT: ReactOS Disk Cleanup
|
||||
* LICENSE: MIT (https://spdx.org/licenses/MIT)
|
||||
* PURPOSE: CCleanupHandler implementation
|
||||
* COPYRIGHT: Copyright 2023-2025 Mark Jansen <mark.jansen@reactos.org>
|
||||
*/
|
||||
|
||||
#include "cleanmgr.h"
|
||||
|
||||
|
||||
CCleanupHandler::CCleanupHandler(CRegKey &subKey, const CStringW &keyName, const GUID &guid)
|
||||
: hSubKey(subKey)
|
||||
, KeyName(keyName)
|
||||
, Guid(guid)
|
||||
, dwFlags(0)
|
||||
, Priority(0)
|
||||
, StateFlags(0)
|
||||
, SpaceUsed(0)
|
||||
, ShowHandler(true)
|
||||
, hIcon(NULL)
|
||||
{
|
||||
}
|
||||
|
||||
CCleanupHandler::~CCleanupHandler()
|
||||
{
|
||||
Deactivate();
|
||||
::DestroyIcon(hIcon);
|
||||
}
|
||||
|
||||
void
|
||||
CCleanupHandler::Deactivate()
|
||||
{
|
||||
if (Handler)
|
||||
{
|
||||
DWORD dwFlags = 0;
|
||||
Handler->Deactivate(&dwFlags);
|
||||
if (dwFlags & EVCF_REMOVEFROMLIST)
|
||||
UNIMPLEMENTED_DBGBREAK();
|
||||
}
|
||||
}
|
||||
|
||||
bool
|
||||
CCleanupHandler::Initialize(LPCWSTR pcwszVolume)
|
||||
{
|
||||
if (FAILED_UNEXPECTEDLY(
|
||||
::CoCreateInstance(Guid, NULL, CLSCTX_INPROC_SERVER, IID_PPV_ARG(IEmptyVolumeCache, &Handler))))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
DWORD dwSize = sizeof(Priority);
|
||||
if (hSubKey.QueryBinaryValue(L"Priority", &Priority, &dwSize) != ERROR_SUCCESS)
|
||||
{
|
||||
if (hSubKey.QueryDWORDValue(L"Priority", Priority) != ERROR_SUCCESS)
|
||||
Priority = 200;
|
||||
}
|
||||
|
||||
dwSize = sizeof(StateFlags);
|
||||
if (hSubKey.QueryDWORDValue(L"StateFlags", StateFlags) != ERROR_SUCCESS)
|
||||
StateFlags = 0;
|
||||
|
||||
WCHAR PathBuffer[MAX_PATH] = {};
|
||||
ULONG nChars = _countof(PathBuffer);
|
||||
if (hSubKey.QueryStringValue(L"IconPath", PathBuffer, &nChars) != ERROR_SUCCESS)
|
||||
{
|
||||
CStringW Tmp;
|
||||
WCHAR GuidStr[50] = {};
|
||||
if (StringFromGUID2(Guid, GuidStr, _countof(GuidStr)))
|
||||
{
|
||||
Tmp.Format(L"CLSID\\%s\\DefaultIcon", GuidStr);
|
||||
CRegKey clsid;
|
||||
nChars = _countof(PathBuffer);
|
||||
if (clsid.Open(HKEY_CLASSES_ROOT, Tmp, KEY_READ) != ERROR_SUCCESS ||
|
||||
clsid.QueryStringValue(NULL, PathBuffer, &nChars) != ERROR_SUCCESS)
|
||||
{
|
||||
PathBuffer[0] = UNICODE_NULL;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (!PathBuffer[0])
|
||||
StringCchCopyW(PathBuffer, _countof(PathBuffer), L"%systemroot%\\system32\\shell32.dll");
|
||||
|
||||
int Index = 0;
|
||||
WCHAR *ptr = wcschr(PathBuffer, L',');
|
||||
if (ptr)
|
||||
{
|
||||
*ptr++ = UNICODE_NULL;
|
||||
Index = wcstol(ptr, NULL, 10);
|
||||
}
|
||||
HICON Large, Small;
|
||||
UINT Result = ExtractIconExW(PathBuffer, Index, &Large, &Small, 1);
|
||||
if (Result < 1)
|
||||
Result = ExtractIconExW(L"%systemroot%\\system32\\shell32.dll", 0, &Large, &Small, 1);
|
||||
if (Result >= 1)
|
||||
{
|
||||
hIcon = Small;
|
||||
if (!hIcon)
|
||||
{
|
||||
hIcon = Large;
|
||||
}
|
||||
else
|
||||
{
|
||||
::DestroyIcon(Large);
|
||||
}
|
||||
}
|
||||
|
||||
// These options should come from the command line
|
||||
// dwFlags |= EVCF_SETTINGSMODE;
|
||||
// dwFlags |= EVCF_OUTOFDISKSPACE;
|
||||
|
||||
CComPtr<IEmptyVolumeCache2> spHandler2;
|
||||
HRESULT hr = Handler->QueryInterface(IID_PPV_ARG(IEmptyVolumeCache2, &spHandler2));
|
||||
if (SUCCEEDED(hr))
|
||||
{
|
||||
hr = spHandler2->InitializeEx(
|
||||
hSubKey, pcwszVolume, KeyName, &wszDisplayName, &wszDescription, &wszBtnText, &dwFlags);
|
||||
if (FAILED_UNEXPECTEDLY(hr))
|
||||
return false;
|
||||
|
||||
// No files to clean will return S_FALSE;
|
||||
if (hr != S_OK)
|
||||
return false;
|
||||
}
|
||||
else
|
||||
{
|
||||
// Observed behavior:
|
||||
// When Initialize is called, wszDescription is actually pointing to data
|
||||
// wszDescription.AllocateBytes(0x400u);
|
||||
hr = Handler->Initialize(hSubKey, pcwszVolume, &wszDisplayName, &wszDescription, &dwFlags);
|
||||
if (FAILED_UNEXPECTEDLY(hr))
|
||||
return false;
|
||||
|
||||
// No files to clean will return S_FALSE;
|
||||
if (hr != S_OK)
|
||||
return false;
|
||||
|
||||
CComPtr<IPropertyBag> spBag;
|
||||
WCHAR GuidStr[50] = {};
|
||||
nChars = _countof(GuidStr);
|
||||
if (hSubKey.QueryStringValue(L"PropertyBag", GuidStr, &nChars) == ERROR_SUCCESS)
|
||||
{
|
||||
GUID guid = {};
|
||||
if (!FAILED_UNEXPECTEDLY(CLSIDFromString(GuidStr, &guid)))
|
||||
{
|
||||
FAILED_UNEXPECTEDLY(
|
||||
CoCreateInstance(guid, NULL, CLSCTX_INPROC_SERVER, IID_PPV_ARG(IPropertyBag, &spBag)));
|
||||
}
|
||||
}
|
||||
ReadProperty(L"Display", spBag, wszDisplayName);
|
||||
ReadProperty(L"Description", spBag, wszDescription);
|
||||
|
||||
if (dwFlags & EVCF_HASSETTINGS)
|
||||
{
|
||||
ReadProperty(L"AdvancedButtonText", spBag, wszBtnText);
|
||||
}
|
||||
}
|
||||
|
||||
if ((dwFlags & EVCF_ENABLEBYDEFAULT) && !(StateFlags & HANDLER_STATE_SELECTED))
|
||||
{
|
||||
StateFlags |= HANDLER_STATE_SELECTED;
|
||||
}
|
||||
|
||||
// For convenience
|
||||
if (!wszDisplayName)
|
||||
SHStrDupW(KeyName, &wszDisplayName);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void
|
||||
CCleanupHandler::ReadProperty(LPCWSTR Name, IPropertyBag *pBag, CComHeapPtr<WCHAR> &storage)
|
||||
{
|
||||
if (storage)
|
||||
return;
|
||||
|
||||
if (pBag)
|
||||
{
|
||||
CComVariant tmp;
|
||||
tmp.vt = VT_BSTR;
|
||||
HRESULT hr = pBag->Read(Name, &tmp, NULL);
|
||||
if (!FAILED_UNEXPECTEDLY(hr) && tmp.vt == VT_BSTR)
|
||||
{
|
||||
SHStrDupW(tmp.bstrVal, &storage);
|
||||
}
|
||||
}
|
||||
|
||||
if (!storage)
|
||||
{
|
||||
WCHAR TmpStr[0x200] = {};
|
||||
DWORD dwSize = _countof(TmpStr);
|
||||
|
||||
if (hSubKey.QueryStringValue(Name, TmpStr, &dwSize) == ERROR_SUCCESS)
|
||||
{
|
||||
WCHAR ResolvedStr[0x200] = {};
|
||||
SHLoadIndirectString(TmpStr, ResolvedStr, _countof(ResolvedStr), NULL);
|
||||
SHStrDupW(ResolvedStr, &storage);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
BOOL
|
||||
CCleanupHandler::HasSettings() const
|
||||
{
|
||||
return !!(dwFlags & EVCF_HASSETTINGS);
|
||||
}
|
||||
|
||||
BOOL
|
||||
CCleanupHandler::DontShowIfZero() const
|
||||
{
|
||||
return !!(dwFlags & EVCF_DONTSHOWIFZERO);
|
||||
}
|
||||
|
48
base/applications/cleanmgr/cleanmgr/CCleanupHandler.hpp
Normal file
48
base/applications/cleanmgr/cleanmgr/CCleanupHandler.hpp
Normal file
@@ -0,0 +1,48 @@
|
||||
/*
|
||||
* PROJECT: ReactOS Disk Cleanup
|
||||
* LICENSE: MIT (https://spdx.org/licenses/MIT)
|
||||
* PURPOSE: CCleanupHandler definition
|
||||
* COPYRIGHT: Copyright 2023-2025 Mark Jansen <mark.jansen@reactos.org>
|
||||
*/
|
||||
|
||||
#define HANDLER_STATE_SELECTED 1
|
||||
|
||||
|
||||
struct CCleanupHandler
|
||||
{
|
||||
CCleanupHandler(CRegKey &subKey, const CStringW &keyName, const GUID &guid);
|
||||
~CCleanupHandler();
|
||||
|
||||
void Deactivate();
|
||||
|
||||
bool
|
||||
Initialize(LPCWSTR pcwszVolume);
|
||||
|
||||
void
|
||||
ReadProperty(LPCWSTR Name, IPropertyBag *pBag, CComHeapPtr<WCHAR> &storage);
|
||||
|
||||
BOOL
|
||||
HasSettings() const;
|
||||
|
||||
BOOL
|
||||
DontShowIfZero() const;
|
||||
|
||||
CRegKey hSubKey;
|
||||
CStringW KeyName;
|
||||
GUID Guid;
|
||||
|
||||
CComHeapPtr<WCHAR> wszDisplayName;
|
||||
CComHeapPtr<WCHAR> wszDescription;
|
||||
CComHeapPtr<WCHAR> wszBtnText;
|
||||
|
||||
CStringW IconPath;
|
||||
DWORD dwFlags;
|
||||
DWORD Priority;
|
||||
DWORD StateFlags;
|
||||
|
||||
CComPtr<IEmptyVolumeCache> Handler;
|
||||
DWORDLONG SpaceUsed;
|
||||
bool ShowHandler;
|
||||
HICON hIcon;
|
||||
};
|
||||
|
163
base/applications/cleanmgr/cleanmgr/CCleanupHandlerList.cpp
Normal file
163
base/applications/cleanmgr/cleanmgr/CCleanupHandlerList.cpp
Normal file
@@ -0,0 +1,163 @@
|
||||
/*
|
||||
* PROJECT: ReactOS Disk Cleanup
|
||||
* LICENSE: MIT (https://spdx.org/licenses/MIT)
|
||||
* PURPOSE: CCleanupHandlerList implementation
|
||||
* COPYRIGHT: Copyright 2023-2025 Mark Jansen <mark.jansen@reactos.org>
|
||||
*/
|
||||
|
||||
#include "cleanmgr.h"
|
||||
|
||||
void CCleanupHandlerList::LoadHandlers(WCHAR Drive)
|
||||
{
|
||||
m_DriveStr.Format(L"%c:", Drive);
|
||||
|
||||
CRegKey VolumeCaches;
|
||||
if (VolumeCaches.Open(HKEY_LOCAL_MACHINE, L"Software\\Microsoft\\Windows\\CurrentVersion\\Explorer\\VolumeCaches", KEY_READ) != ERROR_SUCCESS)
|
||||
return;
|
||||
|
||||
LONG ItemIndex = 0;
|
||||
WCHAR szKeyName[MAX_PATH];
|
||||
|
||||
WCHAR wszVolume[] = { Drive, L':', L'\\', UNICODE_NULL };
|
||||
|
||||
while (TRUE)
|
||||
{
|
||||
DWORD dwSize = _countof(szKeyName);
|
||||
if (VolumeCaches.EnumKey(ItemIndex++, szKeyName, &dwSize) != ERROR_SUCCESS)
|
||||
{
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
CRegKey hSubKey;
|
||||
if (hSubKey.Open(VolumeCaches, szKeyName, KEY_READ) == ERROR_SUCCESS)
|
||||
{
|
||||
WCHAR GuidStr[50] = {};
|
||||
dwSize = _countof(GuidStr);
|
||||
if (hSubKey.QueryStringValue(NULL, GuidStr, &dwSize) != ERROR_SUCCESS)
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
GUID guid = {};
|
||||
if (FAILED_UNEXPECTEDLY(CLSIDFromString(GuidStr, &guid)))
|
||||
continue;
|
||||
|
||||
CCleanupHandler* handler = new CCleanupHandler(hSubKey, szKeyName, guid);
|
||||
|
||||
if (!handler->Initialize(wszVolume))
|
||||
{
|
||||
delete handler;
|
||||
continue;
|
||||
}
|
||||
|
||||
m_Handlers.AddTail(handler);
|
||||
}
|
||||
}
|
||||
|
||||
// Sort handlers
|
||||
BOOL fChanged = m_Handlers.GetCount() > 0;
|
||||
while (fChanged)
|
||||
{
|
||||
fChanged = FALSE;
|
||||
|
||||
for (size_t n = 0; n < m_Handlers.GetCount() - 1; n++)
|
||||
{
|
||||
POSITION leftPos = m_Handlers.FindIndex(n);
|
||||
POSITION rightPos = m_Handlers.FindIndex(n+1);
|
||||
CCleanupHandler* left = m_Handlers.GetAt(leftPos);
|
||||
CCleanupHandler* right = m_Handlers.GetAt(rightPos);
|
||||
|
||||
if (right->Priority < left->Priority)
|
||||
{
|
||||
m_Handlers.SwapElements(leftPos, rightPos);
|
||||
fChanged = TRUE;
|
||||
}
|
||||
else if (right->Priority == left->Priority)
|
||||
{
|
||||
CStringW leftStr(left->wszDisplayName);
|
||||
if (leftStr.Compare(right->wszDisplayName) > 0)
|
||||
{
|
||||
m_Handlers.SwapElements(leftPos, rightPos);
|
||||
fChanged = TRUE;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
DWORDLONG
|
||||
CCleanupHandlerList::ScanDrive(IEmptyVolumeCacheCallBack *picb)
|
||||
{
|
||||
CProgressDlg progress;
|
||||
CString Caption;
|
||||
Caption.Format(IDS_CALCULATING, m_DriveStr.GetString());
|
||||
CStringW Title(MAKEINTRESOURCE(IDS_DISK_CLEANUP));
|
||||
progress.Start((DWORD)m_Handlers.GetCount(), Title, Caption);
|
||||
int ItemIndex = 0;
|
||||
DWORDLONG TotalSpaceUsed = 0;
|
||||
ForEach(
|
||||
[&](CCleanupHandler *current)
|
||||
{
|
||||
Caption.Format(IDS_SCANNING, current->wszDisplayName.m_pData);
|
||||
progress.Step(++ItemIndex, Caption);
|
||||
|
||||
HRESULT hr = current->Handler->GetSpaceUsed(¤t->SpaceUsed, picb);
|
||||
|
||||
if (FAILED_UNEXPECTEDLY(hr))
|
||||
{
|
||||
current->ShowHandler = false;
|
||||
current->StateFlags &= ~HANDLER_STATE_SELECTED;
|
||||
return;
|
||||
}
|
||||
|
||||
if (current->SpaceUsed == 0 && current->DontShowIfZero())
|
||||
{
|
||||
current->ShowHandler = false;
|
||||
current->StateFlags &= ~HANDLER_STATE_SELECTED;
|
||||
}
|
||||
TotalSpaceUsed += current->SpaceUsed;
|
||||
});
|
||||
progress.Stop();
|
||||
|
||||
return TotalSpaceUsed;
|
||||
}
|
||||
|
||||
void
|
||||
CCleanupHandlerList::ExecuteCleanup(IEmptyVolumeCacheCallBack *picb)
|
||||
{
|
||||
CProgressDlg progress;
|
||||
CString Caption;
|
||||
Caption.Format(IDS_CLEANING_CAPTION, m_DriveStr.GetString());
|
||||
|
||||
DWORD TotalSelected = 0;
|
||||
ForEach(
|
||||
[&](CCleanupHandler *current)
|
||||
{
|
||||
if (current->StateFlags & HANDLER_STATE_SELECTED)
|
||||
TotalSelected++;
|
||||
});
|
||||
|
||||
CStringW Title(MAKEINTRESOURCE(IDS_DISK_CLEANUP));
|
||||
progress.Start(TotalSelected, Title, Caption);
|
||||
int ItemIndex = 0;
|
||||
ForEach(
|
||||
[&](CCleanupHandler *current)
|
||||
{
|
||||
if (!(current->StateFlags & HANDLER_STATE_SELECTED))
|
||||
return;
|
||||
|
||||
Caption.Format(IDS_CLEANING, current->wszDisplayName.m_pData);
|
||||
progress.Step(++ItemIndex, Caption);
|
||||
|
||||
// If there is nothing to clean, we might get STG_E_NOMOREFILES
|
||||
if (current->SpaceUsed > 0)
|
||||
{
|
||||
HRESULT hr = current->Handler->Purge(-1, picb);
|
||||
if (FAILED_UNEXPECTEDLY(hr))
|
||||
return;
|
||||
}
|
||||
});
|
||||
progress.Stop();
|
||||
}
|
31
base/applications/cleanmgr/cleanmgr/CCleanupHandlerList.hpp
Normal file
31
base/applications/cleanmgr/cleanmgr/CCleanupHandlerList.hpp
Normal file
@@ -0,0 +1,31 @@
|
||||
/*
|
||||
* PROJECT: ReactOS Disk Cleanup
|
||||
* LICENSE: MIT (https://spdx.org/licenses/MIT)
|
||||
* PURPOSE: CCleanupHandlerList definition
|
||||
* COPYRIGHT: Copyright 2023-2025 Mark Jansen <mark.jansen@reactos.org>
|
||||
*/
|
||||
|
||||
|
||||
class CCleanupHandlerList
|
||||
{
|
||||
private:
|
||||
CAtlList<CCleanupHandler *> m_Handlers;
|
||||
CStringW m_DriveStr;
|
||||
|
||||
public:
|
||||
|
||||
void LoadHandlers(WCHAR Drive);
|
||||
DWORDLONG ScanDrive(IEmptyVolumeCacheCallBack* picb);
|
||||
void ExecuteCleanup(IEmptyVolumeCacheCallBack *picb);
|
||||
|
||||
template<typename Fn>
|
||||
void ForEach(Fn callback)
|
||||
{
|
||||
for (POSITION it = m_Handlers.GetHeadPosition(); it; m_Handlers.GetNext(it))
|
||||
{
|
||||
CCleanupHandler *current = m_Handlers.GetAt(it);
|
||||
|
||||
callback(current);
|
||||
}
|
||||
}
|
||||
};
|
@@ -0,0 +1,54 @@
|
||||
/*
|
||||
* PROJECT: ReactOS Disk Cleanup
|
||||
* LICENSE: MIT (https://spdx.org/licenses/MIT)
|
||||
* PURPOSE: CEmptyVolumeCacheCallBack definition / implementation
|
||||
* COPYRIGHT: Copyright 2023-2025 Mark Jansen <mark.jansen@reactos.org>
|
||||
*/
|
||||
|
||||
|
||||
// We don't really use this, but some windows handlers crash without it
|
||||
struct CEmptyVolumeCacheCallBack
|
||||
: public IEmptyVolumeCacheCallBack
|
||||
{
|
||||
|
||||
STDMETHOD_(ULONG, AddRef)() throw()
|
||||
{
|
||||
return 2;
|
||||
}
|
||||
STDMETHOD_(ULONG, Release)() throw()
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
STDMETHOD(QueryInterface)(
|
||||
REFIID riid,
|
||||
_COM_Outptr_ void** ppvObject) throw()
|
||||
{
|
||||
if (riid == IID_IUnknown || riid == IID_IEmptyVolumeCacheCallBack)
|
||||
{
|
||||
*ppvObject = (IUnknown*)this;
|
||||
return S_OK;
|
||||
}
|
||||
*ppvObject = NULL;
|
||||
return E_NOINTERFACE;
|
||||
}
|
||||
|
||||
|
||||
STDMETHODIMP ScanProgress(
|
||||
_In_ DWORDLONG dwlSpaceUsed,
|
||||
_In_ DWORD dwFlags,
|
||||
_In_ LPCWSTR pcwszStatus) override
|
||||
{
|
||||
DPRINT("dwlSpaceUsed: %lld, dwFlags: %x\n", dwlSpaceUsed, dwFlags);
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
STDMETHODIMP PurgeProgress(
|
||||
_In_ DWORDLONG dwlSpaceFreed,
|
||||
_In_ DWORDLONG dwlSpaceToFree,
|
||||
_In_ DWORD dwFlags,
|
||||
_In_ LPCWSTR pcwszStatus) override
|
||||
{
|
||||
DPRINT("dwlSpaceFreed: %lld, dwlSpaceToFree: %lld, dwFlags: %x\n", dwlSpaceFreed, dwlSpaceToFree, dwFlags);
|
||||
return S_OK;
|
||||
}
|
||||
};
|
19
base/applications/cleanmgr/cleanmgr/CMakeLists.txt
Normal file
19
base/applications/cleanmgr/cleanmgr/CMakeLists.txt
Normal file
@@ -0,0 +1,19 @@
|
||||
|
||||
add_executable(cleanmgr
|
||||
cleanmgr.cpp
|
||||
cleanmgr.h
|
||||
cleanmgr.rc
|
||||
resource.h
|
||||
CEmptyVolumeCacheCallBack.hpp
|
||||
CProgressDlg.hpp
|
||||
CSelectDriveDlg.cpp
|
||||
CCleanupHandler.cpp
|
||||
CCleanupHandler.hpp
|
||||
CCleanupHandlerList.cpp
|
||||
CCleanupHandlerList.hpp
|
||||
)
|
||||
set_module_type(cleanmgr win32gui UNICODE)
|
||||
target_link_libraries(cleanmgr uuid cpprt atl_classes)
|
||||
add_importlibs(cleanmgr shlwapi oleaut32 ole32 shell32 comctl32 user32 advapi32 msvcrt kernel32 ntdll)
|
||||
add_dependencies(cleanmgr psdk)
|
||||
add_cd_file(TARGET cleanmgr DESTINATION reactos/system32 FOR all)
|
50
base/applications/cleanmgr/cleanmgr/CProgressDlg.hpp
Normal file
50
base/applications/cleanmgr/cleanmgr/CProgressDlg.hpp
Normal file
@@ -0,0 +1,50 @@
|
||||
/*
|
||||
* PROJECT: ReactOS Disk Cleanup
|
||||
* LICENSE: MIT (https://spdx.org/licenses/MIT)
|
||||
* PURPOSE: Progress dialog implementation
|
||||
* COPYRIGHT: Copyright 2023-2025 Mark Jansen <mark.jansen@reactos.org>
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
class CProgressDlg
|
||||
{
|
||||
CComPtr<IProgressDialog> m_spProgress;
|
||||
DWORD m_dwTotal = 0;
|
||||
public:
|
||||
|
||||
~CProgressDlg()
|
||||
{
|
||||
Stop();
|
||||
}
|
||||
|
||||
|
||||
void Start(DWORD dwTotalSteps, LPCWSTR Title, LPCWSTR Text)
|
||||
{
|
||||
HRESULT hr = CoCreateInstance(CLSID_ProgressDialog, NULL, CLSCTX_INPROC, IID_PPV_ARG(IProgressDialog, &m_spProgress));
|
||||
if (FAILED_UNEXPECTEDLY(hr))
|
||||
return;
|
||||
|
||||
m_dwTotal = dwTotalSteps;
|
||||
|
||||
m_spProgress->SetTitle(Title);
|
||||
m_spProgress->SetLine(2, Text, TRUE, NULL);
|
||||
m_spProgress->StartProgressDialog(NULL, NULL, PROGDLG_NOMINIMIZE, NULL);
|
||||
m_spProgress->SetProgress(0, m_dwTotal);
|
||||
}
|
||||
|
||||
void Step(DWORD dwProgress, LPCWSTR Text)
|
||||
{
|
||||
m_spProgress->SetProgress(dwProgress, m_dwTotal);
|
||||
m_spProgress->SetLine(1, Text, TRUE, NULL);
|
||||
}
|
||||
|
||||
void Stop()
|
||||
{
|
||||
if (m_spProgress)
|
||||
{
|
||||
m_spProgress->StopProgressDialog();
|
||||
m_spProgress.Release();
|
||||
}
|
||||
}
|
||||
};
|
80
base/applications/cleanmgr/cleanmgr/CSelectDriveDlg.cpp
Normal file
80
base/applications/cleanmgr/cleanmgr/CSelectDriveDlg.cpp
Normal file
@@ -0,0 +1,80 @@
|
||||
/*
|
||||
* PROJECT: ReactOS Disk Cleanup
|
||||
* LICENSE: MIT (https://spdx.org/licenses/MIT)
|
||||
* PURPOSE: Drive selection dialog
|
||||
* COPYRIGHT: Copyright 2023-2025 Mark Jansen <mark.jansen@reactos.org>
|
||||
*/
|
||||
|
||||
#include "cleanmgr.h"
|
||||
|
||||
class CSelectDriveDlg : public CDialogImpl<CSelectDriveDlg>
|
||||
{
|
||||
public:
|
||||
enum { IDD = IDD_SELECTDRIVE };
|
||||
|
||||
BEGIN_MSG_MAP(CSelectDriveDlg)
|
||||
MESSAGE_HANDLER(WM_INITDIALOG, OnInitDialog)
|
||||
COMMAND_ID_HANDLER(IDOK, OnEndDialog)
|
||||
COMMAND_ID_HANDLER(IDCANCEL, OnEndDialog)
|
||||
END_MSG_MAP()
|
||||
|
||||
CSelectDriveDlg()
|
||||
:m_SelectedDrive(UNICODE_NULL)
|
||||
{
|
||||
}
|
||||
|
||||
LRESULT OnInitDialog(UINT, WPARAM, LPARAM, BOOL&)
|
||||
{
|
||||
// Try to find an existing instance of this dialog
|
||||
WCHAR buf[300];
|
||||
GetWindowTextW(buf, _countof(buf));
|
||||
for (HWND hNext = NULL, hFind; (hFind = ::FindWindowExW(NULL, hNext, NULL, buf)) != NULL; hNext = hFind)
|
||||
{
|
||||
if (hFind != *this && ::IsWindowVisible(hFind))
|
||||
{
|
||||
::SetForegroundWindow(hFind);
|
||||
EndDialog(IDCANCEL);
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
|
||||
CWindow cbo = GetDlgItem(IDC_DRIVES);
|
||||
WCHAR VolumeNameBuffer[MAX_PATH + 1];
|
||||
CStringW Tmp;
|
||||
for (WCHAR Drive = 'A'; Drive <= 'Z'; ++Drive)
|
||||
{
|
||||
WCHAR RootPathName[] = { Drive,':','\\',0 };
|
||||
UINT Type = GetDriveTypeW(RootPathName);
|
||||
if (Type == DRIVE_FIXED)
|
||||
{
|
||||
GetVolumeInformationW(RootPathName, VolumeNameBuffer, _countof(VolumeNameBuffer), 0, 0, 0, 0, 0);
|
||||
Tmp.Format(L"%s (%.2s)", VolumeNameBuffer, RootPathName);
|
||||
|
||||
int index = (int)cbo.SendMessage(CB_ADDSTRING, NULL, (LPARAM)Tmp.GetString());
|
||||
cbo.SendMessage(CB_SETITEMDATA, index, Drive);
|
||||
}
|
||||
}
|
||||
cbo.SendMessage(CB_SETCURSEL, 0);
|
||||
return 1;
|
||||
}
|
||||
LRESULT OnEndDialog(WORD, WORD wID, HWND, BOOL&)
|
||||
{
|
||||
CWindow cbo = GetDlgItem(IDC_DRIVES);
|
||||
m_SelectedDrive = (WCHAR)cbo.SendMessage(CB_GETITEMDATA, cbo.SendMessage(CB_GETCURSEL));
|
||||
EndDialog(wID);
|
||||
return 0;
|
||||
}
|
||||
|
||||
WCHAR m_SelectedDrive;
|
||||
};
|
||||
|
||||
|
||||
void
|
||||
SelectDrive(WCHAR &Drive)
|
||||
{
|
||||
CSelectDriveDlg dlgSelectDrive;
|
||||
if (dlgSelectDrive.DoModal() == IDOK)
|
||||
{
|
||||
Drive = dlgSelectDrive.m_SelectedDrive;
|
||||
}
|
||||
}
|
328
base/applications/cleanmgr/cleanmgr/cleanmgr.cpp
Normal file
328
base/applications/cleanmgr/cleanmgr/cleanmgr.cpp
Normal file
@@ -0,0 +1,328 @@
|
||||
/*
|
||||
* PROJECT: ReactOS Disk Cleanup
|
||||
* LICENSE: MIT (https://spdx.org/licenses/MIT)
|
||||
* PURPOSE: Disk cleanup entrypoint
|
||||
* COPYRIGHT: Copyright 2023-2025 Mark Jansen <mark.jansen@reactos.org>
|
||||
*/
|
||||
|
||||
#include "cleanmgr.h"
|
||||
|
||||
// for listview with extend style LVS_EX_CHECKBOXES, State image 1 is the unchecked box, and state image 2 is the
|
||||
// checked box. see this: https://docs.microsoft.com/en-us/windows/win32/controls/extended-list-view-styles
|
||||
#define STATEIMAGETOINDEX(x) (((x)&LVIS_STATEIMAGEMASK) >> 12)
|
||||
#define STATEIMAGE_UNCHECKED 1
|
||||
#define STATEIMAGE_CHECKED 2
|
||||
|
||||
|
||||
struct CCleanMgrProperties :
|
||||
public CPropertyPageImpl<CCleanMgrProperties>
|
||||
{
|
||||
enum { IDD = IDD_PROPERTIES_MAIN };
|
||||
CWindow m_HandlerListControl;
|
||||
WCHAR m_Drive;
|
||||
DWORDLONG m_TotalSpaceUsed;
|
||||
CCleanupHandlerList* m_HandlerList;
|
||||
bool m_IgnoreChanges = true;
|
||||
|
||||
|
||||
CCleanMgrProperties(WCHAR Drive, DWORDLONG TotalSpaceUsed, CCleanupHandlerList *handlerList)
|
||||
: m_Drive(Drive)
|
||||
, m_TotalSpaceUsed(TotalSpaceUsed)
|
||||
, m_HandlerList(handlerList)
|
||||
{
|
||||
}
|
||||
|
||||
int OnApply()
|
||||
{
|
||||
CStringW Title(MAKEINTRESOURCE(IDS_DISK_CLEANUP));
|
||||
CStringW Text(MAKEINTRESOURCE(IDS_CONFIRM_DELETE));
|
||||
|
||||
if (MessageBoxW(Text, Title, MB_YESNO | MB_ICONQUESTION) != IDYES)
|
||||
return PSNRET_INVALID;
|
||||
|
||||
return PSNRET_NOERROR;
|
||||
}
|
||||
|
||||
LRESULT OnInitDialog(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled)
|
||||
{
|
||||
HICON hIcon = (HICON)::LoadImageW(
|
||||
_AtlBaseModule.GetResourceInstance(), MAKEINTRESOURCEW(IDI_CLEANMGR), IMAGE_ICON, 0, 0,
|
||||
LR_DEFAULTSIZE | LR_SHARED);
|
||||
SendDlgItemMessage(IDC_DISKICON, STM_SETICON, (WPARAM)hIcon);
|
||||
|
||||
m_HandlerListControl = GetDlgItem(IDC_HANDLERLIST);
|
||||
RECT rc;
|
||||
m_HandlerListControl.GetClientRect(&rc);
|
||||
rc.right -= GetSystemMetrics(SM_CXVSCROLL);
|
||||
|
||||
LV_COLUMN column = {};
|
||||
column.mask = LVCF_FMT | LVCF_WIDTH;
|
||||
column.fmt = LVCFMT_LEFT;
|
||||
column.cx = rc.right * 80 / 100;
|
||||
ListView_InsertColumn(m_HandlerListControl, 0, &column);
|
||||
column.fmt = LVCFMT_RIGHT;
|
||||
column.cx = rc.right * 20 / 100;
|
||||
|
||||
ListView_InsertColumn(m_HandlerListControl, 1, &column);
|
||||
HIMAGELIST hImagelist = ImageList_Create(16, 16, ILC_MASK | ILC_COLOR32, 1, 1);
|
||||
ListView_SetImageList(m_HandlerListControl, hImagelist, LVSIL_SMALL);
|
||||
|
||||
ListView_SetExtendedListViewStyleEx(m_HandlerListControl, LVS_EX_CHECKBOXES | LVS_EX_FULLROWSELECT, LVS_EX_CHECKBOXES | LVS_EX_FULLROWSELECT);
|
||||
|
||||
m_HandlerList->ForEach(
|
||||
[&](CCleanupHandler *current)
|
||||
{
|
||||
if (!current->ShowHandler)
|
||||
return;
|
||||
|
||||
LV_ITEM item = {};
|
||||
item.mask = LVIF_TEXT | LVIF_IMAGE | LVIF_PARAM;
|
||||
item.lParam = (LPARAM)current;
|
||||
item.pszText = (LPWSTR)current->wszDisplayName;
|
||||
item.iItem = ListView_GetItemCount(m_HandlerListControl);
|
||||
item.iImage = ImageList_AddIcon(hImagelist, current->hIcon);
|
||||
item.iItem = ListView_InsertItem(m_HandlerListControl, &item);
|
||||
ListView_SetCheckState(
|
||||
m_HandlerListControl, item.iItem, !!(current->StateFlags & HANDLER_STATE_SELECTED));
|
||||
|
||||
item.mask = LVIF_TEXT;
|
||||
WCHAR ByteSize[100] = {};
|
||||
StrFormatByteSizeW(current->SpaceUsed, ByteSize, _countof(ByteSize));
|
||||
ListView_SetItemText(m_HandlerListControl, item.iItem, 1, ByteSize);
|
||||
});
|
||||
|
||||
// Now we should start responding to changes
|
||||
m_IgnoreChanges = false;
|
||||
|
||||
// Select the first item
|
||||
ListView_SetItemState(m_HandlerListControl, 0, LVIS_SELECTED | LVIS_FOCUSED, LVIS_SELECTED | LVIS_FOCUSED);
|
||||
|
||||
UpdateSpaceUsed();
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
CCleanupHandler* GetHandler(int Index)
|
||||
{
|
||||
LVITEMW item = {};
|
||||
item.iItem = Index;
|
||||
if (item.iItem >= 0)
|
||||
{
|
||||
item.mask = LVIF_PARAM;
|
||||
ListView_GetItem(m_HandlerListControl, &item);
|
||||
return (CCleanupHandler*)item.lParam;
|
||||
}
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
|
||||
LRESULT OnDetails(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled)
|
||||
{
|
||||
CCleanupHandler *handler = GetHandler(ListView_GetNextItem(m_HandlerListControl, -1, LVIS_FOCUSED));
|
||||
if (handler)
|
||||
{
|
||||
handler->Handler->ShowProperties(m_hWnd);
|
||||
}
|
||||
return 0L;
|
||||
}
|
||||
|
||||
LRESULT OnHandlerItemchanged(int idCtrl, LPNMHDR pnmh, BOOL& bHandled)
|
||||
{
|
||||
if (idCtrl == IDC_HANDLERLIST)
|
||||
{
|
||||
// We are still initializing, don't respond to changes just yet!
|
||||
if (m_IgnoreChanges)
|
||||
return 0L;
|
||||
|
||||
LPNMLISTVIEW pnic = (LPNMLISTVIEW)pnmh;
|
||||
|
||||
// We only care about state changes
|
||||
if (!(pnic->uChanged & LVIF_STATE))
|
||||
return 0L;
|
||||
|
||||
|
||||
INT ItemIndex = pnic->iItem;
|
||||
if (ItemIndex == -1 || ItemIndex >= ListView_GetItemCount(pnic->hdr.hwndFrom))
|
||||
{
|
||||
return 0L;
|
||||
}
|
||||
|
||||
bool GotSelected = (pnic->uNewState & LVIS_SELECTED) && !(pnic->uOldState & LVIS_SELECTED);
|
||||
if (GotSelected)
|
||||
{
|
||||
CWindow DetailsButton = GetDlgItem(IDC_DETAILS);
|
||||
CCleanupHandler* handler = (CCleanupHandler*)pnic->lParam;
|
||||
|
||||
SetDlgItemText(IDC_DESCRIPTION, handler->wszDescription ? handler->wszDescription : L"");
|
||||
if (handler->HasSettings())
|
||||
{
|
||||
DetailsButton.ShowWindow(SW_SHOW);
|
||||
DetailsButton.SetWindowText(handler->wszBtnText);
|
||||
}
|
||||
else
|
||||
{
|
||||
DetailsButton.ShowWindow(SW_HIDE);
|
||||
}
|
||||
}
|
||||
|
||||
int iOldState = STATEIMAGETOINDEX(pnic->uOldState);
|
||||
int iNewState = STATEIMAGETOINDEX(pnic->uNewState);
|
||||
|
||||
if ((iOldState ^ iNewState) == (STATEIMAGE_UNCHECKED ^ STATEIMAGE_CHECKED))
|
||||
{
|
||||
CCleanupHandler* handler = (CCleanupHandler*)pnic->lParam;
|
||||
if (iNewState == STATEIMAGE_CHECKED)
|
||||
handler->StateFlags |= HANDLER_STATE_SELECTED;
|
||||
else
|
||||
handler->StateFlags &= ~HANDLER_STATE_SELECTED;
|
||||
UpdateSpaceUsed();
|
||||
}
|
||||
}
|
||||
return 0L;
|
||||
}
|
||||
|
||||
void UpdateSpaceUsed()
|
||||
{
|
||||
CStringW tmp;
|
||||
WCHAR ByteSize[100];
|
||||
StrFormatByteSizeW(m_TotalSpaceUsed, ByteSize, _countof(ByteSize));
|
||||
|
||||
tmp.Format(IDS_TOTAL_CLEANABLE_CAPTION, ByteSize, m_Drive);
|
||||
SetDlgItemText(IDC_TOTAL_CLEANABLE, tmp);
|
||||
|
||||
DWORDLONG SelectedGained = 0;
|
||||
|
||||
m_HandlerList->ForEach(
|
||||
[&](CCleanupHandler *current)
|
||||
{
|
||||
if (current->StateFlags & HANDLER_STATE_SELECTED)
|
||||
{
|
||||
SelectedGained += current->SpaceUsed;
|
||||
}
|
||||
});
|
||||
|
||||
StrFormatByteSizeW(SelectedGained, ByteSize, _countof(ByteSize));
|
||||
SetDlgItemText(IDC_SELECTED_GAINED, ByteSize);
|
||||
}
|
||||
|
||||
BEGIN_MSG_MAP(CCleanMgrProperties)
|
||||
MESSAGE_HANDLER(WM_INITDIALOG, OnInitDialog)
|
||||
COMMAND_ID_HANDLER(IDC_DETAILS, OnDetails)
|
||||
NOTIFY_HANDLER(IDC_HANDLERLIST, LVN_ITEMCHANGED, OnHandlerItemchanged)
|
||||
CHAIN_MSG_MAP(CPropertyPageImpl<CCleanMgrProperties>) // Allow the default handler to call 'OnApply' etc
|
||||
END_MSG_MAP()
|
||||
};
|
||||
|
||||
|
||||
|
||||
class CCleanMgrModule : public ATL::CAtlExeModuleT< CCleanMgrModule >
|
||||
{
|
||||
public:
|
||||
WCHAR m_Drive = UNICODE_NULL;
|
||||
|
||||
bool ParseCommandLine(
|
||||
_In_z_ LPCTSTR lpCmdLine,
|
||||
_Out_ HRESULT* pnRetCode) throw()
|
||||
{
|
||||
int argc = 0;
|
||||
CLocalPtr<LPWSTR> argv(CommandLineToArgvW(lpCmdLine, &argc));
|
||||
|
||||
for (int n = 1; n < argc; ++n)
|
||||
{
|
||||
if ((argv[n][0] == '/' || argv[n][0] == '-') && towlower(argv[n][1]) == 'd')
|
||||
{
|
||||
if (iswalpha(argv[n][2]))
|
||||
{
|
||||
m_Drive = towupper(argv[n][2]);
|
||||
continue;
|
||||
}
|
||||
if ((n + 1) < argc)
|
||||
{
|
||||
m_Drive = towupper(argv[n + 1][0]);
|
||||
++n;
|
||||
continue;
|
||||
}
|
||||
}
|
||||
}
|
||||
*pnRetCode = S_OK;
|
||||
return true;
|
||||
}
|
||||
|
||||
static inline UINT GetWindowProcessId(_In_ HWND hWnd)
|
||||
{
|
||||
DWORD pid;
|
||||
return GetWindowThreadProcessId(hWnd, &pid) ? pid : 0;
|
||||
}
|
||||
|
||||
static BOOL CALLBACK EnumSingleInstanceCallback(_In_ HWND hWnd, _In_ LPARAM lParam)
|
||||
{
|
||||
if (::IsWindowVisible(hWnd) && (LPARAM)GetWindowProcessId(hWnd) == lParam)
|
||||
{
|
||||
::SetForegroundWindow(hWnd);
|
||||
return FALSE;
|
||||
}
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
HRESULT Run(_In_ int nShowCmd) throw()
|
||||
{
|
||||
if (m_Drive == UNICODE_NULL)
|
||||
{
|
||||
SelectDrive(m_Drive);
|
||||
}
|
||||
|
||||
if (m_Drive == UNICODE_NULL)
|
||||
return E_FAIL;
|
||||
|
||||
CStringW Title;
|
||||
Title.Format(IDS_PROPERTIES_MAIN_TITLE, m_Drive);
|
||||
|
||||
HWND hWndInstance = ::CreateWindowExW(WS_EX_TOOLWINDOW, WC_STATIC, Title, 0, 0, 0, 0, 0, NULL, NULL, NULL, NULL);
|
||||
for (HWND hNext = NULL, hFind; (hFind = ::FindWindowExW(NULL, hNext, WC_STATIC, Title)) != NULL; hNext = hFind)
|
||||
{
|
||||
if (hFind != hWndInstance)
|
||||
{
|
||||
::EnumWindows(EnumSingleInstanceCallback, GetWindowProcessId(hFind));
|
||||
return S_FALSE;
|
||||
}
|
||||
}
|
||||
|
||||
CCleanupHandlerList Handlers;
|
||||
CEmptyVolumeCacheCallBack CacheCallBack;
|
||||
|
||||
Handlers.LoadHandlers(m_Drive);
|
||||
DWORDLONG TotalSpaceUsed = Handlers.ScanDrive(&CacheCallBack);
|
||||
|
||||
CCleanMgrProperties cleanMgr(m_Drive, TotalSpaceUsed, &Handlers);
|
||||
HPROPSHEETPAGE hpsp[1] = { cleanMgr.Create() };
|
||||
|
||||
PROPSHEETHEADERW psh = { };
|
||||
psh.dwSize = sizeof(psh);
|
||||
psh.dwFlags = PSH_NOAPPLYNOW | PSH_USEICONID | PSH_NOCONTEXTHELP;
|
||||
psh.hInstance = _AtlBaseModule.GetResourceInstance();
|
||||
psh.pszIcon = MAKEINTRESOURCEW(IDI_CLEANMGR);
|
||||
psh.pszCaption = Title;
|
||||
psh.nPages = _countof(hpsp);
|
||||
psh.phpage = hpsp;
|
||||
|
||||
if (PropertySheetW(&psh) >= 1)
|
||||
{
|
||||
::DestroyWindow(hWndInstance); // Allow new "cleanmgr /D" without waiting for these handlers
|
||||
Handlers.ExecuteCleanup(&CacheCallBack);
|
||||
}
|
||||
else
|
||||
{
|
||||
::DestroyWindow(hWndInstance);
|
||||
}
|
||||
return S_OK;
|
||||
}
|
||||
};
|
||||
|
||||
CCleanMgrModule _AtlModule;
|
||||
|
||||
|
||||
|
||||
extern "C" int WINAPI wWinMain(HINSTANCE /*hInstance*/, HINSTANCE /*hPrevInstance*/,
|
||||
LPWSTR /*lpCmdLine*/, int nShowCmd)
|
||||
{
|
||||
return _AtlModule.WinMain(nShowCmd);
|
||||
}
|
66
base/applications/cleanmgr/cleanmgr/cleanmgr.h
Normal file
66
base/applications/cleanmgr/cleanmgr/cleanmgr.h
Normal file
@@ -0,0 +1,66 @@
|
||||
/*
|
||||
* PROJECT: ReactOS Disk Cleanup
|
||||
* LICENSE: MIT (https://spdx.org/licenses/MIT)
|
||||
* PURPOSE: Main header file
|
||||
* COPYRIGHT: Copyright 2023-2025 Mark Jansen <mark.jansen@reactos.org>
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#ifndef STRICT
|
||||
#define STRICT
|
||||
#endif
|
||||
|
||||
#define _ATL_APARTMENT_THREADED
|
||||
#define _ATL_NO_AUTOMATIC_NAMESPACE
|
||||
#define _ATL_CSTRING_EXPLICIT_CONSTRUCTORS // some CString constructors will be explicit
|
||||
#define ATL_NO_ASSERT_ON_DESTROY_NONEXISTENT_WINDOW
|
||||
|
||||
#define _FORCENAMELESSUNION
|
||||
|
||||
#include <ndk/rtlfuncs.h>
|
||||
#include <windef.h>
|
||||
#include <winbase.h>
|
||||
#include <shlobj.h>
|
||||
#include <shlwapi.h>
|
||||
|
||||
|
||||
#include <atlbase.h>
|
||||
#include <atlcom.h>
|
||||
#include <atlstr.h>
|
||||
#include <strsafe.h>
|
||||
#include <emptyvc.h>
|
||||
#include <atlcoll.h>
|
||||
|
||||
|
||||
using namespace ATL;
|
||||
|
||||
#define NDEBUG
|
||||
#include <reactos/debug.h>
|
||||
#include <reactos/shellutils.h>
|
||||
#include <ui/rosdlgs.h>
|
||||
|
||||
|
||||
template <class T> class CLocalPtr
|
||||
: public CHeapPtr<T, CLocalAllocator>
|
||||
{
|
||||
public:
|
||||
CLocalPtr() throw()
|
||||
{
|
||||
}
|
||||
|
||||
explicit CLocalPtr(_In_ T* pData) throw() :
|
||||
CHeapPtr<T, CLocalAllocator>(pData)
|
||||
{
|
||||
}
|
||||
};
|
||||
|
||||
#include "resource.h"
|
||||
#include "CProgressDlg.hpp"
|
||||
#include "CCleanupHandler.hpp"
|
||||
#include "CCleanupHandlerList.hpp"
|
||||
#include "CEmptyVolumeCacheCallBack.hpp"
|
||||
|
||||
// CSelectDriveDlg.cpp
|
||||
void
|
||||
SelectDrive(WCHAR &Drive);
|
64
base/applications/cleanmgr/cleanmgr/cleanmgr.rc
Normal file
64
base/applications/cleanmgr/cleanmgr/cleanmgr.rc
Normal file
@@ -0,0 +1,64 @@
|
||||
/*
|
||||
* PROJECT: ReactOS Disk Cleanup
|
||||
* LICENSE: MIT (https://spdx.org/licenses/MIT)
|
||||
* PURPOSE: Resources
|
||||
* COPYRIGHT: Copyright 2023-2025 Mark Jansen <mark.jansen@reactos.org>
|
||||
*/
|
||||
|
||||
#include <windef.h>
|
||||
#include <winuser.h>
|
||||
#include <commctrl.h>
|
||||
#include "resource.h"
|
||||
|
||||
#define REACTOS_STR_FILE_DESCRIPTION "ReactOS Disk Cleanup"
|
||||
#define REACTOS_STR_INTERNAL_NAME "cleanmgr"
|
||||
#define REACTOS_STR_ORIGINAL_FILENAME "cleanmgr.exe"
|
||||
#include <reactos/version.rc>
|
||||
|
||||
#include <reactos/manifest_exe.rc>
|
||||
|
||||
IDI_CLEANMGR ICON "resources/cleanmgr.ico"
|
||||
|
||||
#pragma code_page(65001)
|
||||
|
||||
LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
|
||||
|
||||
STRINGTABLE
|
||||
BEGIN
|
||||
IDS_PROPERTIES_MAIN_TITLE "Disk Cleanup for (%c:)"
|
||||
IDS_TOTAL_CLEANABLE_CAPTION "You can use Disk Cleanup to free up to %s of disk space on (%c:)."
|
||||
IDS_DISK_CLEANUP "Disk Cleanup"
|
||||
IDS_CONFIRM_DELETE "Are you sure you want to delete these files permanently?"
|
||||
IDS_CALCULATING "Disk Cleanup is calculating how much space can be gained on (%s)."
|
||||
IDS_SCANNING "Scanning: %s"
|
||||
IDS_CLEANING_CAPTION "Disk Cleanup is cleaning up files on %s."
|
||||
IDS_CLEANING "Cleaning: %s"
|
||||
END
|
||||
|
||||
IDD_PROPERTIES_MAIN DIALOGEX 0, 0, 235, 215
|
||||
STYLE DS_SETFONT | DS_FIXEDSYS | DS_CENTER | WS_CHILD | WS_DISABLED | WS_CAPTION
|
||||
CAPTION "Disk Cleanup"
|
||||
FONT 8, "MS Shell Dlg", 400, 0, 0x0
|
||||
BEGIN
|
||||
CONTROL "",IDC_DISKICON,"Static",SS_ICON,6,6,20,20
|
||||
LTEXT "You can use Disk Cleanup to free up to 0.0MB of disk space on drive C.",IDC_TOTAL_CLEANABLE,36,6,192,18
|
||||
LTEXT "Files to delete:",IDC_STATIC,6,30,222,8
|
||||
CONTROL "",IDC_HANDLERLIST,"SysListView32",LVS_REPORT | LVS_SINGLESEL | LVS_SHOWSELALWAYS | LVS_NOCOLUMNHEADER | WS_BORDER | WS_TABSTOP,6,42,222,66
|
||||
LTEXT "Total amount of disk space gained:",IDC_STATIC,6,114,144,8
|
||||
RTEXT "",IDC_SELECTED_GAINED,156,114,73,8
|
||||
GROUPBOX "Description",IDC_STATIC,6,126,222,84
|
||||
LTEXT "",IDC_DESCRIPTION,12,138,210,54
|
||||
PUSHBUTTON "Details...",IDC_DETAILS,150,192,74,14
|
||||
END
|
||||
|
||||
IDD_SELECTDRIVE DIALOGEX 0, 0, 177, 74
|
||||
STYLE DS_SETFONT | DS_MODALFRAME | DS_FIXEDSYS | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU
|
||||
CAPTION "Disk Cleanup - Select Drive"
|
||||
FONT 8, "MS Shell Dlg", 400, 0, 0x1
|
||||
BEGIN
|
||||
DEFPUSHBUTTON "OK",IDOK,30,48,50,14
|
||||
PUSHBUTTON "E&xit",IDCANCEL,96,48,50,14
|
||||
LTEXT "Select the drive to clean up.",IDC_STATIC,12,6,150,8
|
||||
COMBOBOX IDC_DRIVES,12,24,150,90,CBS_DROPDOWNLIST | CBS_HASSTRINGS | CBS_NOINTEGRALHEIGHT | WS_VSCROLL | WS_TABSTOP
|
||||
END
|
||||
|
30
base/applications/cleanmgr/cleanmgr/resource.h
Normal file
30
base/applications/cleanmgr/cleanmgr/resource.h
Normal file
@@ -0,0 +1,30 @@
|
||||
/*
|
||||
* PROJECT: ReactOS Disk Cleanup
|
||||
* LICENSE: MIT (https://spdx.org/licenses/MIT)
|
||||
* PURPOSE: Resource definitions
|
||||
* COPYRIGHT: Copyright 2023-2025 Mark Jansen <mark.jansen@reactos.org>
|
||||
*/
|
||||
|
||||
#define IDC_STATIC -1
|
||||
|
||||
#define IDI_CLEANMGR 100
|
||||
|
||||
#define IDD_PROPERTIES_MAIN 200
|
||||
#define IDC_DISKICON 201
|
||||
#define IDC_TOTAL_CLEANABLE 202
|
||||
#define IDC_HANDLERLIST 203
|
||||
#define IDC_SELECTED_GAINED 204
|
||||
#define IDC_DESCRIPTION 205
|
||||
#define IDC_DETAILS 206
|
||||
|
||||
#define IDD_SELECTDRIVE 220
|
||||
#define IDC_DRIVES 221
|
||||
|
||||
#define IDS_PROPERTIES_MAIN_TITLE 1000
|
||||
#define IDS_TOTAL_CLEANABLE_CAPTION 1001
|
||||
#define IDS_DISK_CLEANUP 1002
|
||||
#define IDS_CONFIRM_DELETE 1003
|
||||
#define IDS_CALCULATING 1004
|
||||
#define IDS_SCANNING 1005
|
||||
#define IDS_CLEANING_CAPTION 1006
|
||||
#define IDS_CLEANING 1007
|
BIN
base/applications/cleanmgr/cleanmgr/resources/cleanmgr.ico
Normal file
BIN
base/applications/cleanmgr/cleanmgr/resources/cleanmgr.ico
Normal file
Binary file not shown.
After Width: | Height: | Size: 58 KiB |
@@ -2,12 +2,14 @@
|
||||
include_directories(${REACTOS_SOURCE_DIR}/sdk/lib/conutils)
|
||||
|
||||
list(APPEND SOURCE
|
||||
certutil.c
|
||||
asn.cpp
|
||||
certutil.cpp
|
||||
hashfile.cpp
|
||||
precomp.h)
|
||||
|
||||
add_executable(certutil ${SOURCE})
|
||||
set_module_type(certutil win32cui UNICODE)
|
||||
target_link_libraries(certutil conutils ${PSEH_LIB})
|
||||
add_importlibs(certutil advapi32 msvcrt kernel32)
|
||||
add_importlibs(certutil crypt32 advapi32 msvcrt kernel32)
|
||||
add_pch(certutil precomp.h SOURCE)
|
||||
add_cd_file(TARGET certutil DESTINATION reactos/system32 FOR all)
|
||||
|
508
base/applications/cmdutils/certutil/asn.cpp
Normal file
508
base/applications/cmdutils/certutil/asn.cpp
Normal file
@@ -0,0 +1,508 @@
|
||||
/*
|
||||
* PROJECT: ReactOS certutil
|
||||
* LICENSE: MIT (https://spdx.org/licenses/MIT)
|
||||
* PURPOSE: CertUtil asn implementation
|
||||
* COPYRIGHT: Copyright 2020 Mark Jansen (mark.jansen@reactos.org)
|
||||
*
|
||||
* NOTES:
|
||||
* To keep it simple, Tag and Class are combined in one identifier
|
||||
* See for more details:
|
||||
* https://en.wikipedia.org/wiki/X.690#BER_encoding
|
||||
* https://www.strozhevsky.com/free_docs/asn1_by_simple_words.pdf
|
||||
* http://mikk.net/~chris/asn1.pdf
|
||||
*
|
||||
* And for a test suite:
|
||||
* https://github.com/YuryStrozhevsky/asn1-test-suite
|
||||
*/
|
||||
|
||||
#include "precomp.h"
|
||||
#include <math.h>
|
||||
#include <wincrypt.h>
|
||||
#include <stdlib.h>
|
||||
|
||||
|
||||
#define ASN_TAG_IS_CONSTRUCTED 0x20
|
||||
|
||||
|
||||
#define ASN_TAG_BITSTRING 0x03
|
||||
#define ASN_TAG_OCTET_STRING 0x04
|
||||
#define ASN_TAG_OBJECT_ID 0x06
|
||||
|
||||
#define ASN_TAG_SEQUENCE_RAW 0x10
|
||||
#define ASN_TAG_SET_RAW 0x11
|
||||
|
||||
#define ASN_TAG_SEQUENCE 0x30
|
||||
#define ASN_TAG_SET 0x31
|
||||
|
||||
|
||||
#define ASN_TAG_CONTEXT_SPECIFIC 0x80
|
||||
#define ASN_TAG_CONTEXT_SPECIFIC_N(n) (ASN_TAG_CONTEXT_SPECIFIC | (n))
|
||||
|
||||
#define ASN_TAG_OPTIONAL 0xA0
|
||||
#define ASN_TAG_OPTIONAL_N(n) (ASN_TAG_OPTIONAL | (n))
|
||||
|
||||
/* NOTE: These names are not the names listed in f.e. the wikipedia pages,
|
||||
they are made to look like MS's names for this */
|
||||
LPCWSTR TagToName(DWORD dwTag)
|
||||
{
|
||||
switch (dwTag)
|
||||
{
|
||||
case 0x0: return L"EOC";
|
||||
case 0x1: return L"BOOL";
|
||||
case 0x2: return L"INTEGER";
|
||||
case ASN_TAG_BITSTRING: return L"BIT_STRING";
|
||||
case ASN_TAG_OCTET_STRING: return L"OCTET_STRING";
|
||||
case 0x5: return L"NULL";
|
||||
case ASN_TAG_OBJECT_ID: return L"OBJECT_ID";
|
||||
case 0x7: return L"Object Descriptor";
|
||||
case 0x8: return L"EXTERNAL";
|
||||
case 0x9: return L"REAL";
|
||||
case 0xA: return L"ENUMERATED";
|
||||
case 0xB: return L"EMBEDDED PDV";
|
||||
case 0xC: return L"UTF8String";
|
||||
case 0xD: return L"RELATIVE-OID";
|
||||
case 0xE: return L"TIME";
|
||||
case 0xF: return L"Reserved";
|
||||
case ASN_TAG_SEQUENCE_RAW: __debugbreak(); return L"SEQUENCE_RAW";
|
||||
case ASN_TAG_SET_RAW: __debugbreak(); return L"SET_RAW";
|
||||
case 0x12: return L"NumericString";
|
||||
case 0x13: return L"PRINTABLE_STRING";
|
||||
case 0x14: return L"T61String";
|
||||
case 0x15: return L"VideotexString";
|
||||
case 0x16: return L"IA5String";
|
||||
case 0x17: return L"UTC_TIME";
|
||||
case 0x18: return L"GeneralizedTime";
|
||||
case 0x19: return L"GraphicString";
|
||||
case 0x1A: return L"VisibleString";
|
||||
case 0x1B: return L"GeneralString";
|
||||
case 0x1C: return L"UniversalString";
|
||||
case 0x1D: return L"CHARACTER STRING";
|
||||
case 0x1E: return L"BMPString";
|
||||
case 0x1F: return L"DATE";
|
||||
case 0x20: return L"CONSTRUCTED";
|
||||
|
||||
case ASN_TAG_SEQUENCE: return L"SEQUENCE";
|
||||
case ASN_TAG_SET: return L"SET";
|
||||
|
||||
|
||||
case ASN_TAG_CONTEXT_SPECIFIC_N(0): return L"CONTEXT_SPECIFIC[0]";
|
||||
case ASN_TAG_CONTEXT_SPECIFIC_N(1): return L"CONTEXT_SPECIFIC[1]";
|
||||
case ASN_TAG_CONTEXT_SPECIFIC_N(2): return L"CONTEXT_SPECIFIC[2]";
|
||||
case ASN_TAG_CONTEXT_SPECIFIC_N(3): return L"CONTEXT_SPECIFIC[3]";
|
||||
case ASN_TAG_CONTEXT_SPECIFIC_N(4): return L"CONTEXT_SPECIFIC[4]";
|
||||
case ASN_TAG_CONTEXT_SPECIFIC_N(5): return L"CONTEXT_SPECIFIC[5]";
|
||||
case ASN_TAG_CONTEXT_SPECIFIC_N(6): return L"CONTEXT_SPECIFIC[6]";
|
||||
case ASN_TAG_CONTEXT_SPECIFIC_N(7): return L"CONTEXT_SPECIFIC[7]";
|
||||
case ASN_TAG_CONTEXT_SPECIFIC_N(8): return L"CONTEXT_SPECIFIC[8]";
|
||||
case ASN_TAG_CONTEXT_SPECIFIC_N(9): return L"CONTEXT_SPECIFIC[9]";
|
||||
/* Experiments show that Windows' certutil only goes up to 9 */
|
||||
|
||||
|
||||
case ASN_TAG_OPTIONAL_N(0): return L"OPTIONAL[0]";
|
||||
case ASN_TAG_OPTIONAL_N(1): return L"OPTIONAL[1]";
|
||||
case ASN_TAG_OPTIONAL_N(2): return L"OPTIONAL[2]";
|
||||
case ASN_TAG_OPTIONAL_N(3): return L"OPTIONAL[3]";
|
||||
case ASN_TAG_OPTIONAL_N(4): return L"OPTIONAL[4]";
|
||||
case ASN_TAG_OPTIONAL_N(5): return L"OPTIONAL[5]";
|
||||
case ASN_TAG_OPTIONAL_N(6): return L"OPTIONAL[6]";
|
||||
case ASN_TAG_OPTIONAL_N(7): return L"OPTIONAL[7]";
|
||||
case ASN_TAG_OPTIONAL_N(8): return L"OPTIONAL[8]";
|
||||
case ASN_TAG_OPTIONAL_N(9): return L"OPTIONAL[9]";
|
||||
/* Experiments show that Windows' certutil only goes up to 9 */
|
||||
|
||||
default:
|
||||
return L"???";
|
||||
}
|
||||
}
|
||||
|
||||
BOOL Move(DWORD dwLen, PBYTE& pData, DWORD& dwSize)
|
||||
{
|
||||
if (dwSize < dwLen)
|
||||
return FALSE;
|
||||
|
||||
pData += dwLen;
|
||||
dwSize -= dwLen;
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
BOOL ParseTag(PBYTE& pData, DWORD& dwSize, DWORD& dwTagAndClass)
|
||||
{
|
||||
if (dwSize == 0)
|
||||
return FALSE;
|
||||
|
||||
/* Is this a long form? */
|
||||
if ((pData[0] & 0x1f) != 0x1f)
|
||||
{
|
||||
/* No, so extract the tag and class (in one identifier) */
|
||||
dwTagAndClass = pData[0];
|
||||
return Move(1, pData, dwSize);
|
||||
}
|
||||
|
||||
DWORD dwClass = (pData[0] & 0xE0) >> 5;
|
||||
dwTagAndClass = 0;
|
||||
DWORD n;
|
||||
for (n = 1; n < dwSize; ++n)
|
||||
{
|
||||
dwTagAndClass <<= 7;
|
||||
dwTagAndClass |= (pData[n] & 0x7f);
|
||||
|
||||
if (!(pData[n] & 0x80))
|
||||
{
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
Move(n, pData, dwSize);
|
||||
|
||||
/* Any number bigger than this, we shift data out! */
|
||||
if (n > 4)
|
||||
return FALSE;
|
||||
|
||||
/* Just drop this in the hightest bits*/
|
||||
dwTagAndClass |= (dwClass << (32-3));
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
BOOL ParseLength(PBYTE& pData, DWORD& dwSize, DWORD& dwLength)
|
||||
{
|
||||
if (dwSize == 0)
|
||||
return FALSE;
|
||||
|
||||
if (!(pData[0] & 0x80))
|
||||
{
|
||||
dwLength = pData[0];
|
||||
return Move(1, pData, dwSize);
|
||||
}
|
||||
|
||||
DWORD dwBytes = pData[0] & 0x7f;
|
||||
if (dwBytes == 0 || dwBytes > 8 || dwBytes + 1 > dwSize)
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
dwLength = 0;
|
||||
for (DWORD n = 0; n < dwBytes; ++n)
|
||||
{
|
||||
dwLength <<= 8;
|
||||
dwLength += pData[1 + n];
|
||||
}
|
||||
|
||||
return Move(dwBytes + 1, pData, dwSize);
|
||||
}
|
||||
|
||||
|
||||
DWORD HexDump(PBYTE pRoot, PBYTE pData, DWORD dwSize, PWSTR wszPrefix)
|
||||
{
|
||||
while (TRUE)
|
||||
{
|
||||
SIZE_T Address = pData - pRoot;
|
||||
ConPrintf(StdOut, L"%04x: ", Address);
|
||||
ConPuts(StdOut, wszPrefix);
|
||||
|
||||
for (DWORD n = 0; n < min(dwSize, 0x10); ++n)
|
||||
{
|
||||
ConPrintf(StdOut, L"%02x ", pData[n]);
|
||||
}
|
||||
|
||||
if (dwSize <= 0x10)
|
||||
break;
|
||||
|
||||
Move(0x10, pData, dwSize);
|
||||
ConPuts(StdOut, L"\n");
|
||||
}
|
||||
|
||||
return 3 * dwSize;
|
||||
}
|
||||
|
||||
void PrintTag(PBYTE pRoot, PBYTE pHeader, DWORD dwTag, DWORD dwTagLength, PBYTE pData, PWSTR wszPrefix)
|
||||
{
|
||||
DWORD dwRemainder = HexDump(pRoot, pHeader, pData - pHeader, wszPrefix);
|
||||
|
||||
LPCWSTR wszTag = TagToName(dwTag);
|
||||
DWORD dwPadding = dwRemainder + wcslen(wszPrefix);
|
||||
while (dwPadding > 50)
|
||||
dwPadding -= 50;
|
||||
ConPrintf(StdOut, L"%*s; %s (%x Bytes)\n", 50 - dwPadding, L"", wszTag, dwTagLength);
|
||||
}
|
||||
|
||||
struct OID_NAMES
|
||||
{
|
||||
CHAR* Oid;
|
||||
LPCWSTR Names[20];
|
||||
DWORD NumberOfNames;
|
||||
};
|
||||
|
||||
BOOL WINAPI CryptOIDEnumCallback(_In_ PCCRYPT_OID_INFO pInfo, _Inout_opt_ void *pvArg)
|
||||
{
|
||||
OID_NAMES* Names = (OID_NAMES*)pvArg;
|
||||
|
||||
if (pInfo && pInfo->pszOID && !_stricmp(pInfo->pszOID, Names->Oid))
|
||||
{
|
||||
if (Names->NumberOfNames < RTL_NUMBER_OF(Names->Names))
|
||||
{
|
||||
for (DWORD n = 0; n < Names->NumberOfNames; ++n)
|
||||
{
|
||||
// We already have this..
|
||||
if (!_wcsicmp(Names->Names[n], pInfo->pwszName))
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
Names->Names[Names->NumberOfNames++] = pInfo->pwszName;
|
||||
}
|
||||
}
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
void PrintOID(PBYTE pRoot, PBYTE pHeader, PBYTE pData, DWORD dwSize, PWSTR wszPrefix)
|
||||
{
|
||||
/* CryptFindOIDInfo expects the OID to be in ANSI.. */
|
||||
CHAR szOID[250];
|
||||
CHAR* ptr = szOID;
|
||||
size_t cchRemaining = RTL_NUMBER_OF(szOID);
|
||||
|
||||
/* CryptFindOIDInfo just returns the first, we want multiple */
|
||||
OID_NAMES Names = {0};
|
||||
|
||||
if (dwSize == 0)
|
||||
return;
|
||||
|
||||
DWORD dwValue = 0, count = 0;
|
||||
for (DWORD n = 0; n < dwSize; ++n)
|
||||
{
|
||||
dwValue <<= 7;
|
||||
dwValue |= pData[n] & 0x7f;
|
||||
|
||||
if (pData[n] & 0x80)
|
||||
{
|
||||
if (++count >= 4)
|
||||
break;
|
||||
continue;
|
||||
}
|
||||
count = 0;
|
||||
|
||||
/* First & second octet have a special encoding */
|
||||
if (ptr == szOID)
|
||||
{
|
||||
DWORD id1 = dwValue / 40;
|
||||
DWORD id2 = dwValue % 40;
|
||||
|
||||
/* The first one can only be 0, 1 or 2, so handle special case: tc24.ber */
|
||||
if (id1 > 2)
|
||||
{
|
||||
id2 += (id1 - 2) * 40;
|
||||
id1 = 2;
|
||||
}
|
||||
StringCchPrintfExA(ptr, cchRemaining, &ptr, &cchRemaining, 0, "%d.%d", id1, id2);
|
||||
}
|
||||
else
|
||||
{
|
||||
StringCchPrintfExA(ptr, cchRemaining, &ptr, &cchRemaining, 0, ".%d", dwValue);
|
||||
}
|
||||
|
||||
dwValue = 0;
|
||||
}
|
||||
|
||||
if (dwValue || count)
|
||||
{
|
||||
/* We cannot format this, so just add abort */
|
||||
return;
|
||||
}
|
||||
|
||||
SIZE_T Address = pData - pRoot;
|
||||
/* Pad with spaces instead of printing the address again */
|
||||
DWORD addrDigits = (DWORD)log10((double)Address) + 1;
|
||||
ConPrintf(StdOut, L"%*s ", max(addrDigits, 4), L"");
|
||||
ConPrintf(StdOut, L"%s; %S", wszPrefix, szOID);
|
||||
|
||||
Names.Oid = szOID;
|
||||
|
||||
/* The order does not match a naive call with '0'... */
|
||||
CryptEnumOIDInfo(0, 0, &Names, CryptOIDEnumCallback);
|
||||
|
||||
for (DWORD n = 0; n < Names.NumberOfNames; ++n)
|
||||
{
|
||||
if (n == 0)
|
||||
ConPrintf(StdOut, L" %s", Names.Names[n]);
|
||||
else if (n == 1)
|
||||
ConPrintf(StdOut, L" (%s", Names.Names[n]);
|
||||
else
|
||||
ConPrintf(StdOut, L" / %s", Names.Names[n]);
|
||||
}
|
||||
|
||||
ConPrintf(StdOut, L"%s\n", Names.NumberOfNames > 1 ? L")" : L"");
|
||||
}
|
||||
|
||||
|
||||
BOOL ParseAsn(PBYTE pRoot, PBYTE pData, DWORD dwSize, PWSTR wszPrefix, BOOL fPrint)
|
||||
{
|
||||
while (dwSize)
|
||||
{
|
||||
PBYTE pHeader = pData;
|
||||
DWORD dwTagAndClass;
|
||||
|
||||
if (!ParseTag(pData, dwSize, dwTagAndClass))
|
||||
{
|
||||
if (fPrint)
|
||||
ConPrintf(StdOut, L"CertUtil: -asn command failed to parse tag near 0x%x\n", pHeader - pRoot);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
DWORD dwTagLength;
|
||||
if (!ParseLength(pData, dwSize, dwTagLength))
|
||||
{
|
||||
if (fPrint)
|
||||
ConPrintf(StdOut, L"CertUtil: -asn command failed to parse tag length near 0x%x\n", pHeader - pRoot);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
if (dwTagLength > dwSize)
|
||||
{
|
||||
if (fPrint)
|
||||
ConPrintf(StdOut, L"CertUtil: -asn command malformed tag length near 0x%x\n", pHeader - pRoot);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
|
||||
if (fPrint)
|
||||
PrintTag(pRoot, pHeader, dwTagAndClass, dwTagLength, pData, wszPrefix);
|
||||
|
||||
size_t len = wcslen(wszPrefix);
|
||||
StringCchCatW(wszPrefix, MAX_PATH, dwTagLength != dwSize ? L"| " : L" ");
|
||||
|
||||
if (dwTagAndClass & ASN_TAG_IS_CONSTRUCTED)
|
||||
{
|
||||
if (!ParseAsn(pRoot, pData, dwTagLength, wszPrefix, fPrint))
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (fPrint)
|
||||
{
|
||||
/* Special case for a bit string / octet string */
|
||||
if ((dwTagAndClass == ASN_TAG_BITSTRING || dwTagAndClass == ASN_TAG_OCTET_STRING) && dwTagLength)
|
||||
{
|
||||
if (dwTagAndClass == ASN_TAG_BITSTRING)
|
||||
{
|
||||
/* First, we print the 'unused bits' field of the bit string */
|
||||
HexDump(pRoot, pData, 1, wszPrefix);
|
||||
ConPuts(StdOut, L"\n");
|
||||
|
||||
/* Move past it */
|
||||
Move(1, pData, dwSize);
|
||||
dwTagLength--;
|
||||
}
|
||||
|
||||
/* Do we have any data left? */
|
||||
if (dwTagLength)
|
||||
{
|
||||
/* Try to parse this as ASN */
|
||||
if (ParseAsn(pRoot, pData, dwTagLength, wszPrefix, FALSE))
|
||||
{
|
||||
/* We succeeded, this _could_ be ASN, so display it as if it is */
|
||||
if (!ParseAsn(pRoot, pData, dwTagLength, wszPrefix, TRUE))
|
||||
{
|
||||
/* Uhhh, did someone edit the data? */
|
||||
ConPrintf(StdOut, L"CertUtil: -asn command unexpected failure parsing tag near 0x%x\n", pData - pRoot);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
/* Move past what we just parsed */
|
||||
Move(dwTagLength, pData, dwSize);
|
||||
/* Lie about this so that we don't also print a hexdump */
|
||||
dwTagLength = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* Is there any data (left) to print? */
|
||||
if (dwTagLength)
|
||||
{
|
||||
HexDump(pRoot, pData, dwTagLength, wszPrefix);
|
||||
ConPuts(StdOut, L"\n");
|
||||
|
||||
StringCchCatW(wszPrefix, MAX_PATH, L" ");
|
||||
|
||||
/* Do we have additional formatters? */
|
||||
switch (dwTagAndClass)
|
||||
{
|
||||
case ASN_TAG_OBJECT_ID:
|
||||
PrintOID(pRoot, pHeader, pData, dwTagLength, wszPrefix);
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
wszPrefix[len] = '\0';
|
||||
|
||||
if (!Move(dwTagLength, pData, dwSize))
|
||||
{
|
||||
/* This should not be possible, it was checked before! */
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
|
||||
BOOL asn_dump(LPCWSTR Filename)
|
||||
{
|
||||
HANDLE hFile = CreateFileW(Filename, GENERIC_READ, FILE_SHARE_READ, NULL,
|
||||
OPEN_EXISTING, FILE_FLAG_SEQUENTIAL_SCAN, NULL);
|
||||
|
||||
if (hFile == INVALID_HANDLE_VALUE)
|
||||
{
|
||||
ConPrintf(StdOut, L"CertUtil: -asn command failed to open: %d\n", GetLastError());
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
DWORD dwSize = GetFileSize(hFile, NULL);
|
||||
if (dwSize == INVALID_FILE_SIZE)
|
||||
{
|
||||
ConPrintf(StdOut, L"CertUtil: -asn command failed to get file size: %d\n", GetLastError());
|
||||
CloseHandle(hFile);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
if (dwSize == 0)
|
||||
{
|
||||
ConPrintf(StdOut, L"CertUtil: -asn command got an empty file\n");
|
||||
CloseHandle(hFile);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
PBYTE pData = (PBYTE)LocalAlloc(0, dwSize);
|
||||
if (!pData)
|
||||
{
|
||||
ConPrintf(StdOut, L"CertUtil: -asn command failed to allocate: %d\n", GetLastError());
|
||||
CloseHandle(hFile);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
DWORD cbRead;
|
||||
BOOL fRead = ReadFile(hFile, pData, dwSize, &cbRead, NULL);
|
||||
DWORD dwErr = GetLastError();
|
||||
CloseHandle(hFile);
|
||||
|
||||
if (!fRead || cbRead != dwSize)
|
||||
{
|
||||
ConPrintf(StdOut, L"CertUtil: -asn command failed to read: %d\n", dwErr);
|
||||
LocalFree(pData);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
WCHAR Buffer[MAX_PATH] = {0};
|
||||
BOOL fSucceeded = ParseAsn(pData, pData, dwSize, Buffer, TRUE);
|
||||
|
||||
LocalFree(pData);
|
||||
return fSucceeded;
|
||||
}
|
||||
|
107
base/applications/cmdutils/certutil/certutil.cpp
Normal file
107
base/applications/cmdutils/certutil/certutil.cpp
Normal file
@@ -0,0 +1,107 @@
|
||||
/*
|
||||
* PROJECT: ReactOS certutil
|
||||
* LICENSE: MIT (https://spdx.org/licenses/MIT)
|
||||
* PURPOSE: CertUtil commandline handling
|
||||
* COPYRIGHT: Copyright 2020 Mark Jansen (mark.jansen@reactos.org)
|
||||
*
|
||||
* Note: Only -hashfile and -asn are implemented for now, the rest is not present!
|
||||
*/
|
||||
|
||||
#include "precomp.h"
|
||||
#include <wincrypt.h>
|
||||
#include <stdlib.h>
|
||||
|
||||
typedef struct
|
||||
{
|
||||
LPCWSTR Name;
|
||||
BOOL (*pfn)(LPCWSTR Filename);
|
||||
} Verb;
|
||||
|
||||
|
||||
Verb verbs[] = {
|
||||
{ L"hashfile", hash_file },
|
||||
{ L"asn", asn_dump },
|
||||
};
|
||||
|
||||
static void print_usage()
|
||||
{
|
||||
ConPuts(StdOut, L"Verbs:\n");
|
||||
ConPuts(StdOut, L" -hashfile -- Display cryptographic hash over a file\n");
|
||||
ConPuts(StdOut, L" -asn -- Display ASN.1 encoding of a file\n");
|
||||
ConPuts(StdOut, L"\n");
|
||||
ConPuts(StdOut, L"CertUtil -? -- Display a list of all verbs\n");
|
||||
ConPuts(StdOut, L"CertUtil -hashfile -? -- Display help text for the 'hashfile' verb\n");
|
||||
}
|
||||
|
||||
|
||||
Verb* MatchVerb(LPCWSTR arg)
|
||||
{
|
||||
if (arg[0] != '-' && arg[0] != '/')
|
||||
return NULL;
|
||||
|
||||
for (size_t n = 0; n < RTL_NUMBER_OF(verbs); ++n)
|
||||
{
|
||||
if (!_wcsicmp(verbs[n].Name, arg + 1))
|
||||
{
|
||||
return verbs + n;
|
||||
}
|
||||
}
|
||||
|
||||
return NULL;
|
||||
}
|
||||
|
||||
int wmain(int argc, WCHAR *argv[])
|
||||
{
|
||||
int n;
|
||||
|
||||
/* Initialize the Console Standard Streams */
|
||||
ConInitStdStreams();
|
||||
|
||||
if (argc == 1) /* i.e. no commandline arguments given */
|
||||
{
|
||||
print_usage();
|
||||
return EXIT_SUCCESS;
|
||||
}
|
||||
|
||||
for (n = 1; n < argc; ++n)
|
||||
{
|
||||
if (!_wcsicmp(argv[n], L"-?"))
|
||||
{
|
||||
print_usage();
|
||||
return EXIT_SUCCESS;
|
||||
}
|
||||
|
||||
Verb* verb = MatchVerb(argv[n]);
|
||||
|
||||
if (verb)
|
||||
{
|
||||
if (argc != 3)
|
||||
{
|
||||
ConPrintf(StdOut, L"CertUtil: -%s expected 1 argument, got %d\n", verb->Name, argc - 2);
|
||||
return EXIT_FAILURE;
|
||||
}
|
||||
|
||||
if (!_wcsicmp(argv[n+1], L"-?"))
|
||||
{
|
||||
print_usage();
|
||||
return EXIT_SUCCESS;
|
||||
}
|
||||
|
||||
if (!verb->pfn(argv[n+1]))
|
||||
{
|
||||
/* The verb prints the failure */
|
||||
return EXIT_FAILURE;
|
||||
}
|
||||
|
||||
ConPrintf(StdOut, L"CertUtil: -%s command completed successfully\n", verb->Name);
|
||||
return EXIT_SUCCESS;
|
||||
}
|
||||
else
|
||||
{
|
||||
ConPrintf(StdOut, L"CertUtil: Unknown verb: %s\n", argv[n]);
|
||||
return EXIT_FAILURE;
|
||||
}
|
||||
}
|
||||
|
||||
return EXIT_SUCCESS;
|
||||
}
|
@@ -1,10 +1,8 @@
|
||||
/*
|
||||
* PROJECT: ReactOS certutil
|
||||
* LICENSE: GPL-2.0-or-later (https://spdx.org/licenses/GPL-2.0-or-later)
|
||||
* PURPOSE: CertUtil stub
|
||||
* LICENSE: MIT (https://spdx.org/licenses/MIT)
|
||||
* PURPOSE: CertUtil hashfile implementation
|
||||
* COPYRIGHT: Copyright 2020 Mark Jansen (mark.jansen@reactos.org)
|
||||
*
|
||||
* Note: Only -hashfile is implemented for now, the rest is not present!
|
||||
*/
|
||||
|
||||
#include "precomp.h"
|
||||
@@ -12,7 +10,7 @@
|
||||
#include <stdlib.h>
|
||||
|
||||
|
||||
static BOOL hash_file(LPCWSTR Filename)
|
||||
BOOL hash_file(LPCWSTR Filename)
|
||||
{
|
||||
HCRYPTPROV hProv;
|
||||
BOOL bSuccess = FALSE;
|
||||
@@ -87,69 +85,3 @@ static BOOL hash_file(LPCWSTR Filename)
|
||||
return bSuccess;
|
||||
}
|
||||
|
||||
|
||||
static void print_usage()
|
||||
{
|
||||
ConPuts(StdOut, L"Verbs:\n");
|
||||
ConPuts(StdOut, L" -hashfile -- Display cryptographic hash over a file\n");
|
||||
ConPuts(StdOut, L"\n");
|
||||
ConPuts(StdOut, L"CertUtil -? -- Display a list of all verbs\n");
|
||||
ConPuts(StdOut, L"CertUtil -hashfile -? -- Display help text for the 'hashfile' verb\n");
|
||||
}
|
||||
|
||||
int wmain(int argc, WCHAR *argv[])
|
||||
{
|
||||
int n;
|
||||
|
||||
/* Initialize the Console Standard Streams */
|
||||
ConInitStdStreams();
|
||||
|
||||
if (argc == 1) /* i.e. no commandline arguments given */
|
||||
{
|
||||
print_usage();
|
||||
return EXIT_SUCCESS;
|
||||
}
|
||||
|
||||
for (n = 1; n < argc; ++n)
|
||||
{
|
||||
if (!_wcsicmp(argv[n], L"-?"))
|
||||
{
|
||||
print_usage();
|
||||
return EXIT_SUCCESS;
|
||||
}
|
||||
else if (!_wcsicmp(argv[n], L"-hashfile"))
|
||||
{
|
||||
if (argc == 3)
|
||||
{
|
||||
if (!_wcsicmp(argv[n+1], L"-?"))
|
||||
{
|
||||
print_usage();
|
||||
return EXIT_SUCCESS;
|
||||
}
|
||||
else
|
||||
{
|
||||
if (!hash_file(argv[n+1]))
|
||||
{
|
||||
/* hash_file prints the failure itself */
|
||||
return EXIT_FAILURE;
|
||||
}
|
||||
|
||||
ConPuts(StdOut, L"CertUtil: -hashfile command completed successfully\n");
|
||||
return EXIT_SUCCESS;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
ConPrintf(StdOut, L"CertUtil: -hashfile expected 1 argument, got %d\n", argc - 2);
|
||||
return EXIT_FAILURE;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
ConPrintf(StdOut, L"CertUtil: Unknown verb: %s\n", argv[n]);
|
||||
return EXIT_FAILURE;
|
||||
}
|
||||
}
|
||||
|
||||
return EXIT_SUCCESS;
|
||||
}
|
@@ -7,10 +7,14 @@
|
||||
|
||||
#include <windef.h>
|
||||
#include <winbase.h>
|
||||
#include <winreg.h>
|
||||
#include <winuser.h>
|
||||
#include <strsafe.h>
|
||||
|
||||
#include <conutils.h>
|
||||
|
||||
|
||||
BOOL hash_file(LPCWSTR Filename);
|
||||
BOOL asn_dump(LPCWSTR Filename);
|
||||
|
||||
|
||||
|
||||
#endif /* __CERTUTIL_PRECOMP_H */
|
||||
|
@@ -1,5 +1,5 @@
|
||||
|
||||
add_definitions(-DCSCRIPT_BUILD -D__WINESRC__)
|
||||
add_definitions(-DCSCRIPT_BUILD)
|
||||
set(wscript_folder ${REACTOS_SOURCE_DIR}/base/applications/cmdutils/wscript)
|
||||
include_directories(${wscript_folder})
|
||||
|
||||
@@ -20,3 +20,4 @@ add_importlibs(cscript shell32 oleaut32 ole32 advapi32 user32 msvcrt kernel32 nt
|
||||
add_dependencies(cscript stdole2 cscript_idlheader)
|
||||
add_pch(cscript ${wscript_folder}/precomp.h SOURCE)
|
||||
add_cd_file(TARGET cscript DESTINATION reactos/system32 FOR all)
|
||||
set_wine_module_FIXME(cscript) # CORE-5743: No ARRAY_SIZE macro
|
||||
|
@@ -2,40 +2,40 @@ LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL
|
||||
|
||||
STRINGTABLE
|
||||
BEGIN
|
||||
IDS_USAGE "Compares two files or sets of files and displays the differences between\n\
|
||||
them.\n\
|
||||
IDS_USAGE "Compare deux fichiers ou un ensemble de fichiers et affiche les différences\n\
|
||||
entre eux.\n\
|
||||
\n\
|
||||
FC [/A] [/C] [/L] [/LBn] [/N] [/OFF[LINE]] [/T] [/U] [/W] [/nnnn]\n\
|
||||
[drive1:][path1]filename1 [drive2:][path2]filename2\n\
|
||||
FC /B [drive1:][path1]filename1 [drive2:][path2]filename2\n\
|
||||
\n\
|
||||
/A Displays only first and last lines for each set of differences.\n\
|
||||
/B Performs a binary comparison.\n\
|
||||
/C Disregards the case of letters.\n\
|
||||
/L Compares files as ASCII text.\n\
|
||||
/LBn Sets the maximum consecutive mismatches to the specified\n\
|
||||
number of lines (default: 100).\n\
|
||||
/N Displays the line numbers on an ASCII comparison.\n\
|
||||
/OFF[LINE] Doesn't skip files with offline attribute set.\n\
|
||||
/T Doesn't expand tabs to spaces (default: expand).\n\
|
||||
/U Compare files as UNICODE text files.\n\
|
||||
/W Compresses white space (tabs and spaces) for comparison.\n\
|
||||
/nnnn Specifies the number of consecutive lines that must match\n\
|
||||
after a mismatch (default: 2).\n\
|
||||
/A Affiche uniquement la première et la dernière ligne pour chaque ensemble de différences.\n\
|
||||
/B Effectue une comparaison binaire.\n\
|
||||
/C Ne tient pas compte de la casse des lettres.\n\
|
||||
/L Compare les fichiers sous forme de texte ASCII.\n\
|
||||
/LBn Définit le nombre maximal de différences consécutives\n\
|
||||
au nombre de lignes spécifié (par défaut : 100).\n\
|
||||
/N Affiche les numéros de ligne sur une comparaison ASCII.\n\
|
||||
/OFF[LINE] N'ignore pas les fichiers ayant l'attribut hors-ligne.\n\
|
||||
/T Ne transforme pas les tabulations en espaces (par défaut : transformer).\n\
|
||||
/U Compare les fichiers en tant que fichiers texte UNICODE.\n\
|
||||
/W Compresse les espaces blancs (tabulations et espaces) pour la comparaison.\n\
|
||||
/nnnn Spécifie le nombre de lignes consécutives qui doivent correspondre\n\
|
||||
après une différence (par défaut : 2).\n\
|
||||
[drive1:][path1]filename1\n\
|
||||
Specifies the first file or set of files to compare.\n\
|
||||
Spécifie le premier fichier ou ensemble de fichiers à comparer.\n\
|
||||
[drive2:][path2]filename2\n\
|
||||
Specifies the second file or set of files to compare.\n"
|
||||
IDS_NO_DIFFERENCE "FC: no differences encountered\n"
|
||||
IDS_LONGER_THAN "FC: %ls longer than %ls\n"
|
||||
IDS_COMPARING "Comparing files %ls and %ls\n"
|
||||
IDS_OUT_OF_MEMORY "FC: Out of memory\n"
|
||||
IDS_CANNOT_READ "FC: cannot read from %ls\n"
|
||||
IDS_INVALID_SWITCH "FC: Invalid Switch\n"
|
||||
IDS_CANNOT_OPEN "FC: cannot open %ls - No such file or folder\n"
|
||||
IDS_NEEDS_FILES "FC: Insufficient number of file specifications\n"
|
||||
IDS_CANT_USE_WILDCARD "Wildcard ('*' and '?') are not supported yet\n"
|
||||
IDS_DIFFERENT "FC: File %ls and %ls are different\n"
|
||||
IDS_TOO_LARGE "FC: File %ls too large\n"
|
||||
IDS_RESYNC_FAILED "Resync failed. Files are too different.\n"
|
||||
Spécifie le second fichier ou ensemble de fichiers à comparer.\n"
|
||||
IDS_NO_DIFFERENCE "FC: Aucune différence constatée\n"
|
||||
IDS_LONGER_THAN "FC: %ls plus grand que %ls\n"
|
||||
IDS_COMPARING "Compare les fichiers %ls et %ls\n"
|
||||
IDS_OUT_OF_MEMORY "FC: Dépassement de mémoire\n"
|
||||
IDS_CANNOT_READ "FC: Ne peut pas lire depuis %ls\n"
|
||||
IDS_INVALID_SWITCH "FC: Option invalide\n"
|
||||
IDS_CANNOT_OPEN "FC: Ne peut pas ouvrir %ls - Fichier ou répertoire inexistant\n"
|
||||
IDS_NEEDS_FILES "FC: Nombre insuffisant de fichiers spécifiés\n"
|
||||
IDS_CANT_USE_WILDCARD "Les caractères joker ('*' et '?') ne sont pas encore supportés\n"
|
||||
IDS_DIFFERENT "FC: Les fichiers %ls et %ls sont différents\n"
|
||||
IDS_TOO_LARGE "FC: Fichier %ls trop grand\n"
|
||||
IDS_RESYNC_FAILED "La resynchronisation a échoué. Les fichiers sont trop différents.\n"
|
||||
END
|
||||
|
@@ -2,9 +2,9 @@
|
||||
remove_definitions(-D_WIN32_WINNT=0x502)
|
||||
add_definitions(-D_WIN32_WINNT=0x600)
|
||||
|
||||
add_definitions(-D__WINESRC__)
|
||||
add_executable(reg add.c copy.c delete.c export.c import.c query.c reg.c reg.rc)
|
||||
set_module_type(reg win32cui UNICODE)
|
||||
target_link_libraries(reg wine oldnames)
|
||||
add_importlibs(reg advapi32 advapi32_vista user32 msvcrt kernel32 ntdll)
|
||||
add_cd_file(TARGET reg DESTINATION reactos/system32 FOR all)
|
||||
set_wine_module_FIXME(reg) # CORE-5743: No ARRAY_SIZE macro
|
||||
|
@@ -1,7 +1,7 @@
|
||||
|
||||
add_definitions(-D__WINESRC__)
|
||||
add_executable(taskkill taskkill.c taskkill.rc)
|
||||
target_link_libraries(taskkill wine)
|
||||
set_module_type(taskkill win32cui UNICODE)
|
||||
add_importlibs(taskkill psapi user32 msvcrt kernel32 ntdll)
|
||||
add_importlibs(taskkill user32 msvcrt kernel32 ntdll)
|
||||
add_cd_file(TARGET taskkill DESTINATION reactos/system32 FOR all)
|
||||
set_wine_module_FIXME(taskkill) # CORE-5743: No ARRAY_SIZE macro
|
||||
|
@@ -2,7 +2,7 @@ LANGUAGE LANG_GERMAN, SUBLANG_NEUTRAL
|
||||
|
||||
STRINGTABLE
|
||||
{
|
||||
STRING_USAGE, "Usage: taskkill [/?] [/f] [/im Prozess Name | /pid Prozess ID]\n"
|
||||
STRING_USAGE, "Usage: taskkill [/?] [/f] [/im Prozess Name | /pid Prozess ID] [/t]\n"
|
||||
STRING_INVALID_OPTION, "Fehler: Unbekannte oder ungülige Kommandozeilenoption angegeben.\n"
|
||||
STRING_INVALID_PARAM, "Fehler: Ungültiger Kommandozeilenparameter angegeben.\n"
|
||||
STRING_MISSING_OPTION, "Fehler: Eine der Optionen /im oder /pid muss angegeben werden.\n"
|
||||
@@ -16,6 +16,10 @@ STRINGTABLE
|
||||
STRING_ENUM_FAILED, "Fehler: Prozessliste kann nicht aufgebaut werden.\n"
|
||||
STRING_TERMINATE_FAILED, "Fehler: Prozess ""%1"" kann nicht beendet werden.\n"
|
||||
STRING_SELF_TERMINATION, "Fehler: Der Prozess kann sich nicht selbst beenden.\n"
|
||||
// STRING_CLOSE_CHILD, "Sent termination signal to process with PID %1!u!, child of PID %2!u!.\n"
|
||||
STRING_CLOSE_CHILD, "Close message sent to top-level windows of process with PID %1!u!, child of PID %2!u!.\n"
|
||||
STRING_TERM_CHILD, "The process with PID %1!u! (child process of PID %2!u!) has been terminated.\n"
|
||||
STRING_TERM_CHILD_FAILED, "Error: Unable to terminate process with PID %1!u!, child of PID %2!u!.\n"
|
||||
STRING_PARAM_TOO_MUCH, "Error: Invalid syntax. '%1' option is not allowed more than '%2!d!' time(s).\n"
|
||||
STRING_INVALID_SYNTAX, "Error: Invalid syntax.\n"
|
||||
}
|
||||
|
@@ -2,7 +2,7 @@ LANGUAGE LANG_ENGLISH, SUBLANG_DEFAULT
|
||||
|
||||
STRINGTABLE
|
||||
{
|
||||
STRING_USAGE, "Usage: taskkill [/?] [/f] [/im ProcessName | /pid ProcessID]\n"
|
||||
STRING_USAGE, "Usage: taskkill [/?] [/f] [/im ProcessName | /pid ProcessID] [/t]\n"
|
||||
STRING_INVALID_OPTION, "Error: Unknown or invalid command line option specified.\n"
|
||||
STRING_INVALID_PARAM, "Error: Invalid command line parameter specified.\n"
|
||||
STRING_MISSING_OPTION, "Error: One of options /im or /pid must be specified.\n"
|
||||
@@ -10,12 +10,16 @@ STRINGTABLE
|
||||
STRING_MUTUAL_EXCLUSIVE, "Error: Options /im and /pid are mutually exclusive.\n"
|
||||
STRING_CLOSE_PID_SEARCH, "Close message sent to top-level windows of process with PID %1!u!.\n"
|
||||
STRING_CLOSE_PROC_SRCH, "Close message sent to top-level windows of process ""%1"" with PID %2!u!.\n"
|
||||
STRING_TERM_PID_SEARCH, "Process with PID %1!u! was forcibly terminated.\n"
|
||||
STRING_TERM_PROC_SEARCH, "Process ""%1"" with PID %2!u! was forcibly terminated.\n"
|
||||
STRING_TERM_PID_SEARCH, "The process with PID %1!u! has been terminated.\n"
|
||||
STRING_TERM_PROC_SEARCH, "The process ""%1"" with PID %2!u! has been terminated.\n"
|
||||
STRING_SEARCH_FAILED, "Error: Could not find process ""%1"".\n"
|
||||
STRING_ENUM_FAILED, "Error: Unable to enumerate the process list.\n"
|
||||
STRING_TERMINATE_FAILED, "Error: Unable to terminate process ""%1"".\n"
|
||||
STRING_SELF_TERMINATION, "Error: Process self-termination is not permitted.\n"
|
||||
// STRING_CLOSE_CHILD, "Sent termination signal to process with PID %1!u!, child of PID %2!u!.\n"
|
||||
STRING_CLOSE_CHILD, "Close message sent to top-level windows of process with PID %1!u!, child of PID %2!u!.\n"
|
||||
STRING_TERM_CHILD, "The process with PID %1!u! (child process of PID %2!u!) has been terminated.\n"
|
||||
STRING_TERM_CHILD_FAILED, "Error: Unable to terminate process with PID %1!u!, child of PID %2!u!.\n"
|
||||
STRING_PARAM_TOO_MUCH, "Error: Invalid syntax. '%1' option is not allowed more than '%2!d!' time(s).\n"
|
||||
STRING_INVALID_SYNTAX, "Error: Invalid syntax.\n"
|
||||
}
|
||||
|
@@ -9,7 +9,7 @@ LANGUAGE LANG_ITALIAN, SUBLANG_NEUTRAL
|
||||
|
||||
STRINGTABLE
|
||||
{
|
||||
STRING_USAGE, "Uso: taskkill [/?] [/f] [/im NomeProcesso | /pid IDProcesso]\n"
|
||||
STRING_USAGE, "Uso: taskkill [/?] [/f] [/im NomeProcesso | /pid IDProcesso] [/t]\n"
|
||||
STRING_INVALID_OPTION, "Errore: L'opzione specificata è invalida o sconosciuta.\n"
|
||||
STRING_INVALID_PARAM, "Errore: Il parametro di comando a riga è invalido.\n"
|
||||
STRING_MISSING_OPTION, "Errore: Specifica una delle opzioni /im oppure /pid.\n"
|
||||
@@ -23,6 +23,10 @@ STRINGTABLE
|
||||
STRING_ENUM_FAILED, "Errore: Impossibile enumerare la lista dei processi.\n"
|
||||
STRING_TERMINATE_FAILED, "Errore: Impossibile terminare il processo ""%1"".\n"
|
||||
STRING_SELF_TERMINATION, "Errore: L'auto-terminazione non è consentita.\n"
|
||||
// STRING_CLOSE_CHILD, "Sent termination signal to process with PID %1!u!, child of PID %2!u!.\n"
|
||||
STRING_CLOSE_CHILD, "Close message sent to top-level windows of process with PID %1!u!, child of PID %2!u!.\n"
|
||||
STRING_TERM_CHILD, "The process with PID %1!u! (child process of PID %2!u!) has been terminated.\n"
|
||||
STRING_TERM_CHILD_FAILED, "Error: Unable to terminate process with PID %1!u!, child of PID %2!u!.\n"
|
||||
STRING_PARAM_TOO_MUCH, "Error: Invalid syntax. '%1' option is not allowed more than '%2!d!' time(s).\n"
|
||||
STRING_INVALID_SYNTAX, "Error: Invalid syntax.\n"
|
||||
}
|
||||
|
@@ -9,7 +9,7 @@ LANGUAGE LANG_POLISH, SUBLANG_DEFAULT
|
||||
|
||||
STRINGTABLE
|
||||
{
|
||||
STRING_USAGE, "Sposób użycia: taskkill [/?] [/f] [/im nazwa_procesu | /pid id_procesu]\n"
|
||||
STRING_USAGE, "Sposób użycia: taskkill [/?] [/f] [/im nazwa_procesu | /pid id_procesu] [/t]\n"
|
||||
STRING_INVALID_OPTION, "Błąd: Określono nieznaną lub nieprawidłową opcję.\n"
|
||||
STRING_INVALID_PARAM, "Błąd: Nieprawidłowy parametr.\n"
|
||||
STRING_MISSING_OPTION, "Błąd: Nie określono opcji /im ani /pid.\n"
|
||||
@@ -23,6 +23,10 @@ STRINGTABLE
|
||||
STRING_ENUM_FAILED, "Błąd: Nie można wyliczyć listy procesów.\n"
|
||||
STRING_TERMINATE_FAILED, "Błąd: Nie można zakończyć procesu ""%1"".\n"
|
||||
STRING_SELF_TERMINATION, "Błąd: Proces nie może zakończyć sam siebie.\n"
|
||||
// STRING_CLOSE_CHILD, "Sent termination signal to process with PID %1!u!, child of PID %2!u!.\n"
|
||||
STRING_CLOSE_CHILD, "Close message sent to top-level windows of process with PID %1!u!, child of PID %2!u!.\n"
|
||||
STRING_TERM_CHILD, "The process with PID %1!u! (child process of PID %2!u!) has been terminated.\n"
|
||||
STRING_TERM_CHILD_FAILED, "Error: Unable to terminate process with PID %1!u!, child of PID %2!u!.\n"
|
||||
STRING_PARAM_TOO_MUCH, "Błąd: Nieprawidłowa składnia. Opcja '%1' nie jest dozwolona więcej niż '%2!d!' razy.\n"
|
||||
STRING_INVALID_SYNTAX, "Błąd: Nieprawidłowa składnia.\n"
|
||||
}
|
||||
|
@@ -10,7 +10,7 @@ LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL
|
||||
|
||||
STRINGTABLE
|
||||
{
|
||||
STRING_USAGE, "Utilizare: taskkill [/?] [/f] [/im NumeProces | /pid IdProces]\n"
|
||||
STRING_USAGE, "Utilizare: taskkill [/?] [/f] [/im NumeProces | /pid IdProces] [/t]\n"
|
||||
STRING_INVALID_OPTION, "Eroare: Opțiune specificată nevalidă sau necunoscută.\n"
|
||||
STRING_INVALID_PARAM, "Eroare: Parametrul de comandă specificat este nevalid.\n"
|
||||
STRING_MISSING_OPTION, "Eroare: Trebuie specificată una dintre opțiunile /im sau /pid.\n"
|
||||
@@ -24,6 +24,10 @@ STRINGTABLE
|
||||
STRING_ENUM_FAILED, "Eroare: Nu se poate enumera lista de procese.\n"
|
||||
STRING_TERMINATE_FAILED, "Eroare: Procesul «%1» nu poate fi oprit.\n"
|
||||
STRING_SELF_TERMINATION, "Eroare: Auto-terminarea nu este permisă.\n"
|
||||
// STRING_CLOSE_CHILD, "Sent termination signal to process with PID %1!u!, child of PID %2!u!.\n"
|
||||
STRING_CLOSE_CHILD, "Close message sent to top-level windows of process with PID %1!u!, child of PID %2!u!.\n"
|
||||
STRING_TERM_CHILD, "The process with PID %1!u! (child process of PID %2!u!) has been terminated.\n"
|
||||
STRING_TERM_CHILD_FAILED, "Error: Unable to terminate process with PID %1!u!, child of PID %2!u!.\n"
|
||||
STRING_PARAM_TOO_MUCH, "Eroare: Sintaxă nevalidă. Opțiunea '%1' nu este permisă mai mult de '%2!d!' dată(dăți).\n"
|
||||
STRING_INVALID_SYNTAX, "Eroare: Sintaxă nevalidă.\n"
|
||||
}
|
||||
|
@@ -4,7 +4,7 @@ LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT
|
||||
|
||||
STRINGTABLE
|
||||
{
|
||||
STRING_USAGE, "Использование: TASKKILL [/F] [/IM <образ> | /PID <процесс>]\n"
|
||||
STRING_USAGE, "Использование: TASKKILL [/F] [/IM <образ> | /PID <процесс>] [/t]\n"
|
||||
STRING_INVALID_OPTION, "Ошибка: Указаны неверные параметры командной строки.\n"
|
||||
STRING_INVALID_PARAM, "Ошибка: Указаны неверные параметры командной строки.\n"
|
||||
STRING_MISSING_OPTION, "Ошибка: Должен быть указан параметр /im или /pid.\n"
|
||||
@@ -18,6 +18,10 @@ STRINGTABLE
|
||||
STRING_ENUM_FAILED, "Ошибка: Не удается получить список процессов.\n"
|
||||
STRING_TERMINATE_FAILED, "Ошибка: Не удается завершить процесс ""%1"".\n"
|
||||
STRING_SELF_TERMINATION, "Ошибка: Процесс не может завершить сам себя.\n"
|
||||
// STRING_CLOSE_CHILD, "Sent termination signal to process with PID %1!u!, child of PID %2!u!.\n"
|
||||
STRING_CLOSE_CHILD, "Close message sent to top-level windows of process with PID %1!u!, child of PID %2!u!.\n"
|
||||
STRING_TERM_CHILD, "The process with PID %1!u! (child process of PID %2!u!) has been terminated.\n"
|
||||
STRING_TERM_CHILD_FAILED, "Error: Unable to terminate process with PID %1!u!, child of PID %2!u!.\n"
|
||||
STRING_PARAM_TOO_MUCH, "Ошибка: Неверный синтаксис. Нельзя использовать опцию '%1' больше '%2!d!' раз(а).\n"
|
||||
STRING_INVALID_SYNTAX, "Ошибка: Неверный синтаксис.\n"
|
||||
}
|
||||
|
@@ -6,7 +6,7 @@ LANGUAGE LANG_ALBANIAN, SUBLANG_NEUTRAL
|
||||
|
||||
STRINGTABLE
|
||||
{
|
||||
STRING_USAGE, "Usage: taskkill [/?] [/f] [/im ProcessName | /pid ProcessID]\n"
|
||||
STRING_USAGE, "Usage: taskkill [/?] [/f] [/im ProcessName | /pid ProcessID] [/t]\n"
|
||||
STRING_INVALID_OPTION, "Gabim: Panjohur ose i pavlefshëm opsioni linjes komandes i specifikuar.\n"
|
||||
STRING_INVALID_PARAM, "Gabim: Pavlefshëm parametri i specifikuar ne linjen e komandes.\n"
|
||||
STRING_MISSING_OPTION, "Gabim: Njera nga opsionet /im ose /pid duhet te specifikohet.\n"
|
||||
@@ -20,6 +20,10 @@ STRINGTABLE
|
||||
STRING_ENUM_FAILED, "Gabim: Në pamundësi për të numëruar listën proceseve.\n"
|
||||
STRING_TERMINATE_FAILED, "Gabim: Pamundur mbyllja e proceseve ""%1"".\n"
|
||||
STRING_SELF_TERMINATION, "Gabim: Procesi vetë-përfundimi nuk është i lejuar.\n"
|
||||
// STRING_CLOSE_CHILD, "Sent termination signal to process with PID %1!u!, child of PID %2!u!.\n"
|
||||
STRING_CLOSE_CHILD, "Close message sent to top-level windows of process with PID %1!u!, child of PID %2!u!.\n"
|
||||
STRING_TERM_CHILD, "The process with PID %1!u! (child process of PID %2!u!) has been terminated.\n"
|
||||
STRING_TERM_CHILD_FAILED, "Error: Unable to terminate process with PID %1!u!, child of PID %2!u!.\n"
|
||||
STRING_PARAM_TOO_MUCH, "Error: Invalid syntax. '%1' option is not allowed more than '%2!d!' time(s).\n"
|
||||
STRING_INVALID_SYNTAX, "Error: Invalid syntax.\n"
|
||||
}
|
||||
|
@@ -4,7 +4,7 @@ LANGUAGE LANG_TURKISH, SUBLANG_NEUTRAL
|
||||
|
||||
STRINGTABLE
|
||||
{
|
||||
STRING_USAGE, "Kullanım: taskkill [/?] [/f] [/im işlem adı | /pid işlem kimliği]\n"
|
||||
STRING_USAGE, "Kullanım: taskkill [/?] [/f] [/im işlem adı | /pid işlem kimliği] [/t]\n"
|
||||
STRING_INVALID_OPTION, "Hata: Bilinmeyen veya geçersiz komut satırı seçeneği belirtildi.\n"
|
||||
STRING_INVALID_PARAM, "Hata: Geçersiz komut satırı değişkeni belirtildi.\n"
|
||||
STRING_MISSING_OPTION, "Hata: /im ve /pid seçeneklerinden biri belirtilmeli.\n"
|
||||
@@ -18,6 +18,10 @@ STRINGTABLE
|
||||
STRING_ENUM_FAILED, "Hata: İşlem numaralandırılamıyor.\n"
|
||||
STRING_TERMINATE_FAILED, "Hata: ""%1"" işlemi sonlandırılamıyor.\n"
|
||||
STRING_SELF_TERMINATION, "Hata: İşlemi kendi kendine sonlandırmaya izin verilmedi.\n"
|
||||
// STRING_CLOSE_CHILD, "Sent termination signal to process with PID %1!u!, child of PID %2!u!.\n"
|
||||
STRING_CLOSE_CHILD, "Close message sent to top-level windows of process with PID %1!u!, child of PID %2!u!.\n"
|
||||
STRING_TERM_CHILD, "The process with PID %1!u! (child process of PID %2!u!) has been terminated.\n"
|
||||
STRING_TERM_CHILD_FAILED, "Error: Unable to terminate process with PID %1!u!, child of PID %2!u!.\n"
|
||||
STRING_PARAM_TOO_MUCH, "Hata: Geçersiz sözdizimi. '%1' seçeneğine '%2!d!'den fazla kez izin verilmiyor..\n"
|
||||
STRING_INVALID_SYNTAX, "Hata: Geçersiz sözdizimi.\n"
|
||||
}
|
||||
|
@@ -7,7 +7,7 @@ LANGUAGE LANG_CHINESE, SUBLANG_CHINESE_SIMPLIFIED
|
||||
|
||||
STRINGTABLE
|
||||
{
|
||||
STRING_USAGE, "用法:taskkill [/?] [/f] [/im 进程名称 | /pid 进程 ID]\n"
|
||||
STRING_USAGE, "用法:taskkill [/?] [/f] [/im 进程名称 | /pid 进程 ID] [/t]\n"
|
||||
STRING_INVALID_OPTION, "错误:指定了未知或无效的命令行选项。\n"
|
||||
STRING_INVALID_PARAM, "错误:指定了无效的命令行参数。\n"
|
||||
STRING_MISSING_OPTION, "错误:必须指定选项 /im 或 /pid。\n"
|
||||
@@ -21,6 +21,10 @@ STRINGTABLE
|
||||
STRING_ENUM_FAILED, "错误:无法枚举进程列表。\n"
|
||||
STRING_TERMINATE_FAILED, "错误:无法终止进程“%1”。\n"
|
||||
STRING_SELF_TERMINATION, "错误:不允许终止自身。\n"
|
||||
// STRING_CLOSE_CHILD, "Sent termination signal to process with PID %1!u!, child of PID %2!u!.\n"
|
||||
STRING_CLOSE_CHILD, "Close message sent to top-level windows of process with PID %1!u!, child of PID %2!u!.\n"
|
||||
STRING_TERM_CHILD, "The process with PID %1!u! (child process of PID %2!u!) has been terminated.\n"
|
||||
STRING_TERM_CHILD_FAILED, "Error: Unable to terminate process with PID %1!u!, child of PID %2!u!.\n"
|
||||
STRING_PARAM_TOO_MUCH, "错误:无效语法。选项“%1”不允许超过“%2!d!”次。\n"
|
||||
STRING_INVALID_SYNTAX, "错误:无效语法。\n"
|
||||
}
|
||||
|
@@ -11,7 +11,7 @@ LANGUAGE LANG_CHINESE, SUBLANG_CHINESE_TRADITIONAL
|
||||
|
||||
STRINGTABLE
|
||||
{
|
||||
STRING_USAGE, "用法: taskkill [/?] [/f] [/im 處理程序名稱 | /pid PID]\n"
|
||||
STRING_USAGE, "用法: taskkill [/?] [/f] [/im 處理程序名稱 | /pid PID] [/t]\n"
|
||||
STRING_INVALID_OPTION, "錯誤: 指定了不明或不正確的命令列選項。\n"
|
||||
STRING_INVALID_PARAM, "錯誤: 指定了不正確的命令列參數。\n"
|
||||
STRING_MISSING_OPTION, "錯誤: 必須指定選項 /im 或 /pid 的其中之一。\n"
|
||||
@@ -25,6 +25,10 @@ STRINGTABLE
|
||||
STRING_ENUM_FAILED, "錯誤: 無法列舉處理程序清單。\n"
|
||||
STRING_TERMINATE_FAILED, "錯誤: 無法終止處理程序 '%1'。\n"
|
||||
STRING_SELF_TERMINATION, "錯誤: 處理程序不允許自我終止。\n"
|
||||
// STRING_CLOSE_CHILD, "Sent termination signal to process with PID %1!u!, child of PID %2!u!.\n"
|
||||
STRING_CLOSE_CHILD, "Close message sent to top-level windows of process with PID %1!u!, child of PID %2!u!.\n"
|
||||
STRING_TERM_CHILD, "The process with PID %1!u! (child process of PID %2!u!) has been terminated.\n"
|
||||
STRING_TERM_CHILD_FAILED, "Error: Unable to terminate process with PID %1!u!, child of PID %2!u!.\n"
|
||||
STRING_PARAM_TOO_MUCH, "錯誤: 無效的語法。'%1' 選項不允許超過 '%2!d!' 次。\n"
|
||||
STRING_INVALID_SYNTAX, "錯誤: 無效的語法。\n"
|
||||
}
|
||||
|
File diff suppressed because it is too large
Load Diff
@@ -35,6 +35,8 @@
|
||||
#define STRING_ENUM_FAILED 112
|
||||
#define STRING_TERMINATE_FAILED 113
|
||||
#define STRING_SELF_TERMINATION 114
|
||||
#define STRING_PARAM_TOO_MUCH 115
|
||||
#define STRING_INVALID_SYNTAX 116
|
||||
|
||||
#define STRING_CLOSE_CHILD 115
|
||||
#define STRING_TERM_CHILD 116
|
||||
#define STRING_TERM_CHILD_FAILED 117
|
||||
#define STRING_PARAM_TOO_MUCH 118
|
||||
#define STRING_INVALID_SYNTAX 119
|
||||
|
@@ -1,7 +1,7 @@
|
||||
|
||||
add_definitions(-D__WINESRC__)
|
||||
add_executable(wmic main.c wmic.rc)
|
||||
target_link_libraries(wmic wine)
|
||||
set_module_type(wmic win32cui UNICODE)
|
||||
add_importlibs(wmic oleaut32 ole32 user32 msvcrt kernel32 ntdll)
|
||||
add_cd_file(TARGET wmic DESTINATION reactos/system32/wbem FOR all)
|
||||
set_wine_module_FIXME(wmic) # CORE-5743: No ARRAY_SIZE macro
|
||||
|
@@ -1,6 +1,4 @@
|
||||
|
||||
add_definitions(-D__WINESRC__)
|
||||
|
||||
list(APPEND SOURCE
|
||||
arguments.c
|
||||
host.c
|
||||
@@ -18,3 +16,4 @@ add_importlibs(wscript shell32 oleaut32 ole32 user32 advapi32 msvcrt kernel32 nt
|
||||
add_dependencies(wscript stdole2 wscript_idlheader)
|
||||
add_pch(wscript precomp.h SOURCE)
|
||||
add_cd_file(TARGET wscript DESTINATION reactos/system32 FOR all)
|
||||
set_wine_module_FIXME(wscript) # CORE-5743: No ARRAY_SIZE macro
|
||||
|
@@ -1,7 +1,7 @@
|
||||
|
||||
add_definitions(-D__WINESRC__)
|
||||
add_executable(xcopy xcopy.c xcopy.rc)
|
||||
target_link_libraries(xcopy wine)
|
||||
set_module_type(xcopy win32cui UNICODE)
|
||||
add_importlibs(xcopy shell32 user32 msvcrt kernel32 ntdll)
|
||||
add_cd_file(TARGET xcopy DESTINATION reactos/system32 FOR all)
|
||||
set_wine_module_FIXME(xcopy) # CORE-5743: No ARRAY_SIZE macro
|
||||
|
@@ -50,7 +50,7 @@ où :\n\
|
||||
[/A] Copie uniquement les fichiers qui ont l'attribut archive défini\n\
|
||||
[/M] Copie uniquement les fichiers qui ont l'attribut archive défini ; supprime\n\
|
||||
\tensuite l'attribut\n\
|
||||
[/K] Copy file attributes, without this attributes are not preserved.\n\
|
||||
[/K] Copie les attributs de fichiers. Sans ce paramètre les attributs ne sont pas conservés.\n\
|
||||
[/D | /D:m-d-y] Copie uniquement les nouveaux fichiers, ou ceux modifiés après la date spécifiée.\n\
|
||||
\t\tSi aucune date n'est spécifiée, copie uniquement lorsque le fichier de destination est plus ancien\n\
|
||||
\t\tque le fichier source\n\n"
|
||||
|
@@ -40,6 +40,9 @@
|
||||
#ifdef LANGUAGE_IT_IT
|
||||
#include "lang/it-IT.rc"
|
||||
#endif
|
||||
#ifdef LANGUAGE_JA_JP
|
||||
#include "lang/ja-JP.rc"
|
||||
#endif
|
||||
#ifdef LANGUAGE_PL_PL
|
||||
#include "lang/pl-PL.rc"
|
||||
#endif
|
||||
|
7
base/applications/drwtsn32/lang/ja-JP.rc
Normal file
7
base/applications/drwtsn32/lang/ja-JP.rc
Normal file
@@ -0,0 +1,7 @@
|
||||
LANGUAGE LANG_JAPANESE, SUBLANG_DEFAULT
|
||||
|
||||
STRINGTABLE
|
||||
BEGIN
|
||||
IDS_APP_TITLE "ReactOS クラッシュレポーター"
|
||||
IDS_USER_ALERT_MESSAGE "アプリケーション %ls がクラッシュしました。このクラッシュに関する情報は次の場所に保存されました:\n\n%ls"
|
||||
END
|
@@ -3,7 +3,7 @@
|
||||
* LICENSE: GPL-2.0-or-later (https://spdx.org/licenses/GPL-2.0-or-later)
|
||||
* PURPOSE: Romanian resource file
|
||||
* TRANSLATORS: Copyright 2011-2019 Ștefan Fulea <stefan.fulea@mail.com>
|
||||
* Copyright 2023 Andrei Miloiu <miloiuandrei@gmail.com>
|
||||
* Copyright 2023-2025 Andrei Miloiu <miloiuandrei@gmail.com>
|
||||
*/
|
||||
|
||||
LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL
|
||||
@@ -11,22 +11,22 @@ LANGUAGE LANG_ROMANIAN, SUBLANG_NEUTRAL
|
||||
IDD_MAIN_DIALOG DIALOGEX 0, 0, 478, 280
|
||||
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_POPUP |
|
||||
WS_CLIPSIBLINGS | WS_CLIPCHILDREN | WS_CAPTION | WS_SYSMENU
|
||||
CAPTION "Diagnostic ReactX"
|
||||
CAPTION "Instrument de diagnosticare ReactX"
|
||||
FONT 8, "MS Shell Dlg"
|
||||
BEGIN
|
||||
CONTROL "Tab1", IDC_TAB_CONTROL, "SysTabControl32", WS_TABSTOP, 2, 2, 474, 250
|
||||
PUSHBUTTON "&Manual…", IDC_BUTTON_HELP, 2, 260, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP | WS_DISABLED
|
||||
DEFPUSHBUTTON "&Următorul compartiment", IDC_BUTTON_NEXT, 187, 260, 120, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP
|
||||
PUSHBUTTON "S&alvare informații…", IDC_BUTTON_SAVE_INFO, 311, 260, 110, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP | WS_DISABLED
|
||||
PUSHBUTTON "Î&nchide", IDC_BUTTON_EXIT, 425, 260, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP
|
||||
PUSHBUTTON "&Ajutor", IDC_BUTTON_HELP, 2, 260, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP | WS_DISABLED
|
||||
DEFPUSHBUTTON "&Pagina următoare", IDC_BUTTON_NEXT, 187, 260, 120, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP
|
||||
PUSHBUTTON "&Salvare a tuturor informațiilor…", IDC_BUTTON_SAVE_INFO, 311, 260, 110, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP | WS_DISABLED
|
||||
PUSHBUTTON "Î&nchidere", IDC_BUTTON_EXIT, 425, 260, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP
|
||||
END
|
||||
|
||||
IDD_SYSTEM_DIALOG DIALOGEX 0, 0, 462, 220
|
||||
STYLE DS_SHELLFONT | DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN
|
||||
FONT 8, "MS Shell Dlg"
|
||||
BEGIN
|
||||
LTEXT "Acest instrument oferă informații detaliate despre componentele ReactX și drivere instalate în sistem.", IDC_STATIC, 5, 0, 443, 17
|
||||
LTEXT "Dacă aveți la cunoștință careva probleme la o anumită categorie, mergeți la compartimentul corespunzător de mai sus. Altfel, puteți utiliza butonul „Următorul compartiment” de mai jos pentru a trece secvențial prin fiecare categorie.", IDC_STATIC, 5, 15, 443, 25
|
||||
LTEXT "Acest instrument raportează informații detaliate despre componentele ReactX și driverele instalate pe sistem.", IDC_STATIC, 5, 0, 443, 17
|
||||
LTEXT "Dacă întâmpinați o problemă cu ReactX și știți ce este, atunci faceți clic pe fila corespunzătoare de mai sus. Dacă nu, puteți face clic pe butonul ""Pagina următoare"" de mai jos pentru a vizita fiecare pagină în succesiune.", IDC_STATIC, 5, 15, 443, 25
|
||||
GROUPBOX "Informații despre sistem", IDC_STATIC, 5, 35, 452, 150, SS_RIGHT
|
||||
LTEXT "Data/Ora curentă:", IDC_STATIC, 70, 50, 80, 10, SS_RIGHT
|
||||
LTEXT "Numele calculatorului:", IDC_STATIC, 70, 60, 80, 10, SS_RIGHT
|
||||
@@ -60,11 +60,11 @@ BEGIN
|
||||
GROUPBOX "Dispozitiv", IDC_STATIC, 5, 0, 250, 95
|
||||
RTEXT "Nume:", IDC_STATIC, 20, 10, 70, 10
|
||||
RTEXT "Producător:", IDC_STATIC, 20, 20, 70, 10
|
||||
RTEXT "Tipul cipului:", IDC_STATIC, 20, 30, 70, 10
|
||||
RTEXT "Tipul CDA:", IDC_STATIC, 20, 40, 70, 10
|
||||
RTEXT "Memorie aprox.:", IDC_STATIC, 20, 50, 70, 10
|
||||
RTEXT "Afișare curentă:", IDC_STATIC, 20, 60, 70, 10
|
||||
RTEXT "Ecran:", IDC_STATIC, 20, 70, 70, 10
|
||||
RTEXT "Tipul chip-ului:", IDC_STATIC, 20, 30, 70, 10
|
||||
RTEXT "Tipul DAC:", IDC_STATIC, 20, 40, 70, 10
|
||||
RTEXT "Mem. tot. aprox.:", IDC_STATIC, 20, 50, 70, 10
|
||||
RTEXT "Mod afișare curentă:", IDC_STATIC, 20, 60, 70, 10
|
||||
RTEXT "Monitor:", IDC_STATIC, 20, 70, 70, 10
|
||||
EDITTEXT IDC_STATIC_ADAPTER_ID, 95, 10, 150, 10, ES_LEFT | ES_READONLY | NOT WS_BORDER | NOT WS_TABSTOP | ES_AUTOHSCROLL
|
||||
EDITTEXT IDC_STATIC_ADAPTER_VENDOR, 95, 20, 150, 10, ES_LEFT | ES_READONLY | NOT WS_BORDER | NOT WS_TABSTOP | ES_AUTOHSCROLL
|
||||
EDITTEXT IDC_STATIC_ADAPTER_CHIP, 95, 30, 150, 10, ES_LEFT | ES_READONLY | NOT WS_BORDER | NOT WS_TABSTOP | ES_AUTOHSCROLL
|
||||
@@ -73,10 +73,10 @@ BEGIN
|
||||
EDITTEXT IDC_STATIC_ADAPTER_MODE, 95, 60, 150, 10, ES_LEFT | ES_READONLY | NOT WS_BORDER | NOT WS_TABSTOP | ES_AUTOHSCROLL
|
||||
EDITTEXT IDC_STATIC_ADAPTER_MONITOR, 95, 70, 150, 10, ES_LEFT | ES_READONLY | NOT WS_BORDER | NOT WS_TABSTOP | ES_AUTOHSCROLL
|
||||
GROUPBOX "Driver", IDC_STATIC, 260, 0, 197, 95
|
||||
RTEXT "Driver primar:", IDC_STATIC, 275, 10, 55, 10
|
||||
RTEXT "Driver principal:", IDC_STATIC, 275, 10, 55, 10
|
||||
RTEXT "Versiune:", IDC_STATIC, 275, 20, 55, 10
|
||||
RTEXT "Dată:", IDC_STATIC, 275, 30, 55, 10
|
||||
RTEXT "Semnăt. WHQL:", IDC_STATIC, 275, 40, 55, 10
|
||||
RTEXT "Logo WHQL:", IDC_STATIC, 275, 40, 55, 10
|
||||
RTEXT "Mini-VDD:", IDC_STATIC, 275, 50, 55, 10
|
||||
RTEXT "VDD:", IDC_STATIC, 275, 60, 55, 10
|
||||
RTEXT "Versiune DDI:", IDC_STATIC, 275, 70, 55, 10
|
||||
@@ -87,18 +87,18 @@ BEGIN
|
||||
EDITTEXT IDC_STATIC_ADAPTER_MINIVDD, 335, 50, 120, 10, ES_LEFT | ES_READONLY | NOT WS_BORDER | NOT WS_TABSTOP | ES_AUTOHSCROLL
|
||||
EDITTEXT IDC_STATIC_ADAPTER_VDD, 335, 60, 120, 10, ES_LEFT | ES_READONLY | NOT WS_BORDER | NOT WS_TABSTOP | ES_AUTOHSCROLL
|
||||
EDITTEXT IDC_STATIC_ADAPTER_DDI, 335, 70, 120, 10, ES_LEFT | ES_READONLY | NOT WS_BORDER | NOT WS_TABSTOP | ES_AUTOHSCROLL
|
||||
GROUPBOX "Funcționalități ReactX", IDC_STATIC, 5, 97, 452, 70
|
||||
GROUPBOX "Caracteristici ReactX", IDC_STATIC, 5, 97, 452, 70
|
||||
RTEXT "Accelerare DirectDraw:", IDC_STATIC, 15, 115, 110, 12
|
||||
RTEXT "Accelerare Direct3D:", IDC_STATIC, 15, 130, 110, 12
|
||||
RTEXT "Accelerare Textură AGP:", IDC_STATIC, 15, 145, 110, 12
|
||||
RTEXT "Accelerare a texturilor AGP:", IDC_STATIC, 15, 145, 110, 12
|
||||
LTEXT "", IDC_STATIC_DDSTATE, 130, 115, 40, 10
|
||||
LTEXT "", IDC_STATIC_D3DSTATE, 130, 130, 40, 10
|
||||
LTEXT "", IDC_STATIC_AGPSTATE, 130, 145, 40, 10
|
||||
PUSHBUTTON "Activează", IDC_BUTTON_DDRAW, 170, 112, 60, 14, WS_DISABLED
|
||||
PUSHBUTTON "Activează", IDC_BUTTON_D3D, 170, 128, 60, 14, WS_DISABLED
|
||||
PUSHBUTTON "Activează", IDC_BUTTON_AGP, 170, 144, 60, 14, WS_DISABLED
|
||||
PUSHBUTTON "Testează DirectDraw", IDC_BUTTON_TESTDD, 250, 112, 80, 14
|
||||
PUSHBUTTON "Testează Direct3D", IDC_BUTTON_TEST3D, 250, 128, 80, 14
|
||||
PUSHBUTTON "Activare", IDC_BUTTON_DDRAW, 170, 112, 60, 14, WS_DISABLED
|
||||
PUSHBUTTON "Activare", IDC_BUTTON_D3D, 170, 128, 60, 14, WS_DISABLED
|
||||
PUSHBUTTON "Activare", IDC_BUTTON_AGP, 170, 144, 60, 14, WS_DISABLED
|
||||
PUSHBUTTON "Testare DirectDraw", IDC_BUTTON_TESTDD, 250, 112, 80, 14
|
||||
PUSHBUTTON "Testare Direct3D", IDC_BUTTON_TEST3D, 250, 128, 80, 14
|
||||
GROUPBOX "Note", IDC_STATIC, 5, 170, 452, 50
|
||||
EDITTEXT IDC_TEXT_INFO, 15, 182, 432, 30, ES_LEFT | WS_BORDER | ES_READONLY | WS_TABSTOP
|
||||
END
|
||||
@@ -124,7 +124,7 @@ BEGIN
|
||||
RTEXT "Nume:", IDC_STATIC, 275, 10, 55, 10
|
||||
RTEXT "Versiune:", IDC_STATIC, 275, 20, 55, 10
|
||||
RTEXT "Dată:", IDC_STATIC, 275, 30, 55, 10
|
||||
RTEXT "Semnătură WHQL:", IDC_STATIC, 275, 40, 55, 10
|
||||
RTEXT "Logo WHQL:", IDC_STATIC, 275, 40, 55, 10
|
||||
RTEXT "Alte fișiere:", IDC_STATIC, 275, 50, 55, 10
|
||||
RTEXT "Furnizor:", IDC_STATIC, 275, 60, 55, 10
|
||||
EDITTEXT IDC_STATIC_DSOUND_DRIVER, 335, 10, 100, 10, ES_LEFT | ES_READONLY | NOT WS_BORDER | NOT WS_TABSTOP | ES_AUTOHSCROLL
|
||||
@@ -133,10 +133,10 @@ BEGIN
|
||||
EDITTEXT IDC_STATIC_DSOUND_LOGO, 335, 40, 100, 10, ES_LEFT | ES_READONLY | NOT WS_BORDER | NOT WS_TABSTOP | ES_AUTOHSCROLL
|
||||
EDITTEXT IDC_STATIC_DSOUND_FILES, 335, 50, 100, 10, ES_LEFT | ES_READONLY | NOT WS_BORDER | NOT WS_TABSTOP | ES_AUTOHSCROLL
|
||||
EDITTEXT IDC_STATIC_ADAPTER_PROVIDER, 335, 60, 100, 10, ES_LEFT | ES_READONLY | NOT WS_BORDER | NOT WS_TABSTOP | ES_AUTOHSCROLL
|
||||
GROUPBOX "Funcționalități ReactX", IDC_STATIC, 5, 97, 452, 70
|
||||
GROUPBOX "Caracteristici ReactX", IDC_STATIC, 5, 97, 452, 70
|
||||
CONTROL "", IDC_SLIDER_DSOUND, "msctls_trackbar32", TBS_BOTTOM | TBS_AUTOTICKS | WS_TABSTOP, 110, 125, 80, 17
|
||||
RTEXT "Echipament de sunet\nNivel de accelerare::", IDC_STATIC, 10, 125, 90, 20, WS_DISABLED
|
||||
PUSHBUTTON "Testează DirectSound", IDC_BUTTON_TESTDSOUND, 270, 125, 80, 14, WS_DISABLED
|
||||
RTEXT "Hardware de sunet\nNivel de accelerare:", IDC_STATIC, 10, 125, 90, 20, WS_DISABLED
|
||||
PUSHBUTTON "Testare DirectSound", IDC_BUTTON_TESTDSOUND, 270, 125, 80, 14, WS_DISABLED
|
||||
GROUPBOX "Note", IDC_STATIC, 5, 170, 452, 50
|
||||
EDITTEXT IDC_TEXT_DSOUNDINFO, 15, 182, 432, 30, ES_LEFT | WS_BORDER | ES_READONLY | WS_TABSTOP
|
||||
END
|
||||
@@ -148,13 +148,13 @@ BEGIN
|
||||
RTEXT "Colecție de MIDI DLS generală:", IDC_STATIC, 0, 0, 100, 10
|
||||
EDITTEXT IDC_MIDI_DLS_COLLECTION, 105, 0, 250, 10, ES_LEFT | ES_READONLY | NOT WS_BORDER | NOT WS_TABSTOP | ES_AUTOHSCROLL
|
||||
GROUPBOX "Porturi de muzică", IDC_STATIC, 5, 10, 452, 85
|
||||
GROUPBOX "Funcționalități ReactX", IDC_STATIC, 5, 97, 452, 70
|
||||
GROUPBOX "Caracteristici ReactX", IDC_STATIC, 5, 97, 452, 70
|
||||
LTEXT "Port de accelerare implicit:", IDC_STATIC, 15, 120, 95, 17
|
||||
LTEXT "", IDC_STATIC_DEFAULT_PORT_ACCELERATION, 115, 120, 50, 10
|
||||
PUSHBUTTON "Dezactivează", IDC_BUTTON_DISABLEDMUSIC, 75, 135, 80, 14, WS_DISABLED
|
||||
LTEXT "Testare utilizare port:", IDC_STATIC, 180, 105, 100, 10
|
||||
LISTBOX IDC_DMUSIC_TEST_LIST, 180, 115, 180, 45, LBS_NOINTEGRALHEIGHT | LBS_EXTENDEDSEL | WS_VSCROLL | WS_TABSTOP
|
||||
PUSHBUTTON "Testează DirectMusic", IDC_BUTTON_TESTDMUSIC, 370, 145, 80, 14, WS_DISABLED
|
||||
PUSHBUTTON "Testare DirectMusic", IDC_BUTTON_TESTDMUSIC, 370, 145, 80, 14, WS_DISABLED
|
||||
GROUPBOX "Note", IDC_STATIC, 5, 170, 452, 50
|
||||
EDITTEXT IDC_MUSIC_NOTES, 15, 182, 432, 30, ES_LEFT | WS_BORDER | ES_READONLY | WS_TABSTOP
|
||||
END
|
||||
@@ -176,12 +176,12 @@ IDD_NETWORK_DIALOG DIALOGEX 0, 0, 462, 220
|
||||
STYLE DS_SHELLFONT | DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN
|
||||
FONT 8, "MS Shell Dlg"
|
||||
BEGIN
|
||||
GROUPBOX "Furnizori înregistrați de servicii DirectPlay", IDC_STATIC, 5, 0, 452, 75
|
||||
GROUPBOX "Furnizori de servicii DirectPlay înregistrați", IDC_STATIC, 5, 0, 452, 75
|
||||
CONTROL "", IDC_LIST_PROVIDER, "SysListView32", LVS_REPORT | WS_CHILD | WS_BORDER | WS_TABSTOP, 15, 12, 432, 55
|
||||
GROUPBOX "Aplicații înregistrate pentru DirectPlay", IDC_STATIC, 5, 77, 452, 55
|
||||
GROUPBOX "Funcționalități ReactX", IDC_STATIC, 5, 133, 452, 35
|
||||
GROUPBOX "Aplicații Lobbyable DirectPlay înregistrate", IDC_STATIC, 5, 77, 452, 55
|
||||
GROUPBOX "Caracteristici ReactX", IDC_STATIC, 5, 133, 452, 35
|
||||
PUSHBUTTON "Opțiuni de voce DirectPlay", IDC_BUTTON_VOICE_OPTIONS, 10, 145, 90, 14, WS_DISABLED
|
||||
PUSHBUTTON "Testează DirectPlay", IDC_BUTTON_TESTDPLAY, 130, 145, 80, 14, WS_DISABLED
|
||||
PUSHBUTTON "Testare DirectPlay", IDC_BUTTON_TESTDPLAY, 130, 145, 80, 14, WS_DISABLED
|
||||
GROUPBOX "Note", IDC_STATIC, 5, 170, 452, 50
|
||||
EDITTEXT IDC_NETWORK_NOTES, 15, 182, 432, 30, ES_LEFT | WS_BORDER | ES_READONLY | WS_TABSTOP
|
||||
END
|
||||
@@ -190,73 +190,73 @@ IDD_HELP_DIALOG DIALOGEX 0, 0, 462, 220
|
||||
STYLE DS_SHELLFONT | DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN
|
||||
FONT 8, "MS Shell Dlg"
|
||||
BEGIN
|
||||
LTEXT "Încă nu ați găsit informația necesară? Iată câteva lucruri suplimentare pe care le puteți face:", IDC_STATIC, 5, 0, 300, 10
|
||||
LTEXT "Încă nu găsiți informațiile pe care le căutați? Iată câteva lucruri suplimentare pe care le puteți face:", IDC_STATIC, 5, 0, 300, 10
|
||||
PUSHBUTTON "Informații de sistem", IDC_BUTTON_SYSINFO, 5, 20, 80, 14, WS_DISABLED
|
||||
LTEXT "Afișează informații suplimantare de sistem", IDC_STATIC, 90, 23, 300, 10
|
||||
PUSHBUTTON "Ajustează rata de împrospătare", IDC_BUTTON_DDRAW_REFRESH, 5, 40, 80, 14, WS_DISABLED
|
||||
LTEXT "Ajustează rata de împrospătare pentru DirectDraw", IDC_STATIC, 90, 43, 300, 10
|
||||
LTEXT "Afișează informații suplimentare de sistem", IDC_STATIC, 90, 23, 300, 10
|
||||
PUSHBUTTON "Ajust. rata de împrosp.", IDC_BUTTON_DDRAW_REFRESH, 5, 40, 80, 14, WS_DISABLED
|
||||
LTEXT "Ignoră rata de reîmprospătare pentru DirectDraw", IDC_STATIC, 90, 43, 300, 10
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
BEGIN
|
||||
IDS_MAIN_DIALOG "Diagnostic ReactX"
|
||||
IDS_MAIN_DIALOG "Instrument de diagnosticare ReactX"
|
||||
IDS_SYSTEM_DIALOG "Sistem"
|
||||
IDS_DISPLAY_DIALOG "Ecran"
|
||||
IDS_DISPLAY_DIALOG "Afișaj"
|
||||
IDS_SOUND_DIALOG "Sunet"
|
||||
IDS_MUSIC_DIALOG "Muzică"
|
||||
IDS_INPUT_DIALOG "Intrări"
|
||||
IDS_INPUT_DIALOG "Intrare"
|
||||
IDS_NETWORK_DIALOG "Rețea"
|
||||
IDS_HELP_DIALOG "Asistență"
|
||||
IDS_FORMAT_MB "%I64u Mo memorie"
|
||||
IDS_FORMAT_SWAP "%I64u Mo utilizată, %I64u Mo disponibilă"
|
||||
IDS_FORMAT_UNIPROC "%s (%u procesor)"
|
||||
IDS_FORMAT_MPPROC "%s (%u procesoare)"
|
||||
IDS_VERSION_UNKNOWN "Versiune neidentificată"
|
||||
IDS_HELP_DIALOG "Ajutor"
|
||||
IDS_FORMAT_MB "%I64uMB de RAM"
|
||||
IDS_FORMAT_SWAP "%I64u (de) MB folosit (folosiți), %I64u (de) MB disponibil(i)"
|
||||
IDS_FORMAT_UNIPROC "%s (%u CPU)"
|
||||
IDS_FORMAT_MPPROC "%s (%u CPUs)"
|
||||
IDS_VERSION_UNKNOWN "Versiune necunoscută"
|
||||
IDS_DEVICE_STATUS_ATTACHED "Conectat"
|
||||
IDS_DEVICE_STATUS_MISSING "Deconectat"
|
||||
IDS_DEVICE_STATUS_UNKNOWN "Neidentificat"
|
||||
IDS_DEVICE_NAME "Nume dispozitiv"
|
||||
IDS_DEVICE_STATUS_UNKNOWN "Necunoscut"
|
||||
IDS_DEVICE_NAME "Numele dispozitivului"
|
||||
IDS_DEVICE_STATUS "Stare"
|
||||
IDS_DEVICE_CONTROLLER "ID controlor"
|
||||
IDS_DEVICE_MANUFACTURER "ID producător"
|
||||
IDS_DEVICE_PRODUCT "ID produs"
|
||||
IDS_DEVICE_FORCEFEEDBACK "Forțează reacția driverului"
|
||||
IDS_DEVICE_CONTROLLER "ID controller-ului"
|
||||
IDS_DEVICE_MANUFACTURER "ID-ul producătorului"
|
||||
IDS_DEVICE_PRODUCT "ID-ul produsului"
|
||||
IDS_DEVICE_FORCEFEEDBACK "Forțare a driverului de feedback"
|
||||
IDS_NOT_APPLICABLE "n/a"
|
||||
IDS_OPTION_YES "Da"
|
||||
IDS_DIRECTPLAY_COL_NAME1 "Nume"
|
||||
IDS_DIRECTPLAY_COL_NAME2 "Registru"
|
||||
IDS_DIRECTPLAY_COL_NAME3 "Fișier"
|
||||
IDS_DIRECTPLAY_COL_NAME4 "Versiune"
|
||||
IDS_DIRECTPLAY8_MODEMSP "Furnizor de serviciu Modem-DirectPlay8"
|
||||
IDS_DIRECTPLAY8_SERIALSP "Furnizor de serviciu Serial-DirectPlay8"
|
||||
IDS_DIRECTPLAY8_IPXSP "Furnizor de serviciu IPX-DirectPlay8"
|
||||
IDS_DIRECTPLAY8_TCPSP "Furnizor de serviciu TCP/IP-DirectPlay8"
|
||||
IDS_DIRECTPLAY8_MODEMSP "Furnizor de servicii de modem DirectPlay8"
|
||||
IDS_DIRECTPLAY8_SERIALSP "Furnizor de servicii seriale DirectPlay8"
|
||||
IDS_DIRECTPLAY8_IPXSP "Furnizor de servicii DirectPlay8 IPX"
|
||||
IDS_DIRECTPLAY8_TCPSP "DirectPlay8 TCP/IP Service Provider"
|
||||
IDS_DIRECTPLAY_TCPCONN "Conexiune de Internet TCP/IP pentru DirectPlay"
|
||||
IDS_DIRECTPLAY_IPXCONN "Conexiune IPX pentru DirectPlay"
|
||||
IDS_DIRECTPLAY_MODEMCONN "Conexiune Modem pentru DirectPlay"
|
||||
IDS_DIRECTPLAY_SERIALCONN "Conexiune Serială pentru DirectPlay"
|
||||
IDS_REG_SUCCESS "Î&nchide"
|
||||
IDS_DIRECTPLAY_MODEMCONN "Conexiune de modem pentru DirectPlay"
|
||||
IDS_DIRECTPLAY_SERIALCONN "Conexiune serială pentru DirectPlay"
|
||||
IDS_REG_SUCCESS "OK"
|
||||
IDS_REG_FAIL "Eroare"
|
||||
IDS_DDTEST_ERROR "Testul a eșuat!"
|
||||
IDS_DDTEST_DESCRIPTION "Urmează testele de interfață DirectDraw. Continuați?"
|
||||
IDS_DDPRIMARY_DESCRIPTION "Testul următor va utiliza DirectDraw pentru a desena dreptunghiuri albe și negre pe suprafața primară. Continuați?"
|
||||
IDS_DDPRIMARY_RESULT "Dreptunghiurile albe și negre au fost vizibile?"
|
||||
IDS_DDOFFSCREEN_DESCRIPTION "Testul următor va utiliza DirectDraw pentru desenarea unui dreptunghi alb în mișcare utilizând o memorie tampon din afara ecranului. Continuați?"
|
||||
IDS_DDOFFSCREEN_RESULT "Dreptunghiul alb în mișcare a fost vizibil?"
|
||||
IDS_DDFULLSCREEN_DESCRIPTION "Testul următor va utiliza DirectDraw pentru desenarea unui dreptunghi alb în mișcare utilizând tot ecranul. Continuați?"
|
||||
IDS_DDFULLSCREEN_RESULT "Pe ecranul complet, dreptunghiul alb în mișcare a fost vizibil?"
|
||||
IDS_FORMAT_ADAPTER_MEM "%u Mo"
|
||||
IDS_FORMAT_ADAPTER_MODE "%d x %d (%u biți)(%uHz)"
|
||||
IDS_DDTEST_ERROR "Testul de randare DirectDraw a eșuat.\nVă rugăm să consultați notele pentru mai multe informații."
|
||||
IDS_DDTEST_DESCRIPTION "Acesta va porni testarea interfeței DirectDraw. Doriți să continuați?"
|
||||
IDS_DDPRIMARY_DESCRIPTION "Acest test va folosi DirectDraw pentru a desena pe suprafața principală.\nAr trebui desenate dreptunghiuri alb-negru. Doriți să continuați?"
|
||||
IDS_DDPRIMARY_RESULT "Ați văzut dreptunghiuri alb-negru?"
|
||||
IDS_DDOFFSCREEN_DESCRIPTION "Acest test va folosi DirectDraw pentru a desena un tampon în afara ecranului. Ar trebui desenat un dreptunghi alb în mișcare. Doriți să continuați?"
|
||||
IDS_DDOFFSCREEN_RESULT "Ați văzut dreptunghi alb în mișcare?"
|
||||
IDS_DDFULLSCREEN_DESCRIPTION "Acest test va folosi DirectDraw pentru a desena în modul ecran complet. Ar trebui desenat un dreptunghi alb în mișcare. Doriți să continuați?"
|
||||
IDS_DDFULLSCREEN_RESULT "Ați văzut dreptunghi alb în mișcare în modul ecran complet?"
|
||||
IDS_FORMAT_ADAPTER_MEM "%u (de) MB"
|
||||
IDS_FORMAT_ADAPTER_MODE "%d x %d (%u (de) biți)(%uHz)"
|
||||
IDS_OPTION_NO "Nu"
|
||||
IDS_D3DTEST_DESCRIPTION "Urmează testul de interfață Direct3D. Continuați?"
|
||||
IDS_D3DTEST_D3Dx "Testul următor va utiliza interfața Direct3D %u cu accelerare de echipament fizic."
|
||||
IDS_OS_VERSION "%s %s (%d.%d, Build %d)"
|
||||
IDS_D3DTEST_DESCRIPTION "Acesta va porni testarea interfeței Direct3D. Doriți să continuați?"
|
||||
IDS_D3DTEST_D3Dx "Acest test va folosi interfața Direct3D %u accelerată hardware."
|
||||
IDS_OS_VERSION "%s %s (%d.%d, Subversiunea %d)"
|
||||
IDS_DMUSIC_DESC "Descriere"
|
||||
IDS_DMUSIC_TYPE "Tip"
|
||||
IDS_DMUSIC_KERNEL "Mod nucleu"
|
||||
IDS_DMUSIC_IO "In/Ex"
|
||||
IDS_DMUSIC_DLS "DLS de suport"
|
||||
IDS_DMUSIC_KERNEL "Modul nucleu"
|
||||
IDS_DMUSIC_IO "I/E"
|
||||
IDS_DMUSIC_DLS "Suportă DLS"
|
||||
IDS_DMUSIC_EXT "Extern"
|
||||
IDS_DMUSIC_PORT "Port implicit"
|
||||
IDS_DDDISABLE_MSG "Accelerările fizice DirectDraw vor fi dezactivate pentru toate dispozitivele.\nDoriți să continuați?\n"
|
||||
IDS_DDDISABLE_MSG "Acesta va dezactiva toată accelerarea hardware pentru DirectDraw pe toate dispozitivele de afișare.\nDoriți să continuați?\n"
|
||||
END
|
||||
|
@@ -1,7 +1,7 @@
|
||||
|
||||
add_definitions(-D__WINESRC__)
|
||||
add_executable(extrac32 extrac32.c)
|
||||
target_link_libraries(extrac32 wine)
|
||||
set_module_type(extrac32 win32gui UNICODE)
|
||||
add_importlibs(extrac32 shell32 setupapi shlwapi user32 msvcrt kernel32 ntdll)
|
||||
add_cd_file(TARGET extrac32 DESTINATION reactos/system32 FOR all)
|
||||
set_wine_module_FIXME(extrac32) # CORE-5743: No ARRAY_SIZE macro
|
||||
|
@@ -40,6 +40,9 @@
|
||||
#ifdef LANGUAGE_IT_IT
|
||||
#include "lang/it-IT.rc"
|
||||
#endif
|
||||
#ifdef LANGUAGE_JA_JP
|
||||
#include "lang/ja-JP.rc"
|
||||
#endif
|
||||
#ifdef LANGUAGE_LT_LT
|
||||
#include "lang/lt-LT.rc"
|
||||
#endif
|
||||
|
13
base/applications/findstr/lang/ja-JP.rc
Normal file
13
base/applications/findstr/lang/ja-JP.rc
Normal file
@@ -0,0 +1,13 @@
|
||||
LANGUAGE LANG_JAPANESE, SUBLANG_DEFAULT
|
||||
|
||||
STRINGTABLE
|
||||
BEGIN
|
||||
IDS_USAGE "FINDSTR: 文字列を含むファイルのすべての行を出力します。\n\n\
|
||||
FIND [ /C ] [ /I ] [ /N ] [ /V ] ""文字列"" [ ファイル... ]\n\
|
||||
/C 文字列を含む行の個数を数えます\n\
|
||||
/I 大文字小文字を無視します\n\
|
||||
/N 表示される行に1から番号を付けます\n\
|
||||
/V 文字列を含まない行を出力します"
|
||||
IDS_NO_SUCH_FILE "FINDSTR: %s: そのようなファイルはありません\n"
|
||||
IDS_CANNOT_OPEN "FINDSTR: %s: ファイルが開けません\n"
|
||||
END
|
@@ -18,12 +18,12 @@ BEGIN
|
||||
IDS_ERROR_NOMEM "Mémoire insuffisante pour terminer l'opération."
|
||||
IDS_ERROR_NOFONT "Le fichier %1 n'est pas un fichier de polices valide."
|
||||
IDS_ERROR_NOCLASS "Impossible d'initialiser la classe de fenêtre."
|
||||
IDS_ERROR_ISINSTALLED "This font is already installed!"
|
||||
IDS_ERROR_FONTCPY "Failed to copy the font file!"
|
||||
IDS_ERROR_OPENKEY "Failed to open the fonts registry key!"
|
||||
IDS_ERROR_REGISTER "Failed to register the new font!"
|
||||
IDS_SUCCESS "Success"
|
||||
IDS_COMPLETED "Font installation completed."
|
||||
IDS_ERROR_ISINSTALLED "Cette police est déjà installée !"
|
||||
IDS_ERROR_FONTCPY "Échec lors de la copie du fichier police !"
|
||||
IDS_ERROR_OPENKEY "Échec lors de l'ouverture de la clé de registre de la police !"
|
||||
IDS_ERROR_REGISTER "Échec lors de l'enregistrement de la nouvelle police !"
|
||||
IDS_SUCCESS "Succès"
|
||||
IDS_COMPLETED "Installation de la police effectuée."
|
||||
IDS_FILTER_LIST "Toutes polices supportées (*.fon;*.fnt;*.ttf;*.ttc;*.otf;*.otc)\0*.fon;*.fnt;*.ttf;*.ttc;*.otf;*.otc\0\
|
||||
Fichier de polices (*.fon;*.fnt)\0*.fon;*.fnt\0\
|
||||
Fichier de polices TrueType (*.ttf)\0*.ttf\0\
|
||||
|
@@ -18,7 +18,7 @@ BEGIN
|
||||
END
|
||||
POPUP "&View"
|
||||
BEGIN
|
||||
MENUITEM "Single-Window &Mode", IDM_SWITCHVIEW
|
||||
MENUITEM "&Mode fenêtre unique", IDM_SWITCHVIEW
|
||||
END
|
||||
POPUP "Périp&hérique"
|
||||
BEGIN
|
||||
|
@@ -9,23 +9,23 @@ BEGIN
|
||||
MENUITEM SEPARATOR
|
||||
MENUITEM "終了(&E)", IDM_EXIT
|
||||
END
|
||||
POPUP "&Play"
|
||||
POPUP "再生(&P)"
|
||||
BEGIN
|
||||
MENUITEM "Play/&Pause\tCtrl+P", IDC_PLAY
|
||||
MENUITEM "St&op\tCtrl+S", IDC_STOP
|
||||
MENUITEM "再生/再開(&P)\tCtrl+P", IDC_PLAY
|
||||
MENUITEM "停止(&O)\tCtrl+S", IDC_STOP
|
||||
MENUITEM SEPARATOR
|
||||
MENUITEM "Repea&t\tCtrl+T", IDM_REPEAT
|
||||
MENUITEM "リピート(&T)\tCtrl+T", IDM_REPEAT
|
||||
END
|
||||
POPUP "&View"
|
||||
POPUP "表示(&V)"
|
||||
BEGIN
|
||||
MENUITEM "Single-Window &Mode", IDM_SWITCHVIEW
|
||||
MENUITEM "単一ウィンドウモード(&M)", IDM_SWITCHVIEW
|
||||
END
|
||||
POPUP "&Device"
|
||||
POPUP "デバイス(&D)"
|
||||
BEGIN
|
||||
MENUITEM SEPARATOR
|
||||
MENUITEM "&Properties", IDM_DEVPROPS
|
||||
MENUITEM "プロパティ(&P)", IDM_DEVPROPS
|
||||
MENUITEM SEPARATOR
|
||||
MENUITEM "&Volume Control", IDM_VOLUMECTL
|
||||
MENUITEM "音量調節(&V)", IDM_VOLUMECTL
|
||||
END
|
||||
POPUP "ヘルプ(&H)"
|
||||
BEGIN
|
||||
@@ -44,14 +44,14 @@ END
|
||||
|
||||
STRINGTABLE
|
||||
BEGIN
|
||||
IDS_MODE_UNKNOWN "Unknown"
|
||||
IDS_MODE_OPEN "Opened"
|
||||
IDS_MODE_STOP "Stopped"
|
||||
IDS_MODE_PLAY "Playing"
|
||||
IDS_MODE_PAUSE "Paused"
|
||||
IDS_MODE_RECORD "Recording"
|
||||
IDS_MODE_SEEK "Seeking"
|
||||
IDS_MODE_NOT_READY "Not ready"
|
||||
IDS_MODE_UNKNOWN "不明"
|
||||
IDS_MODE_OPEN "開きました"
|
||||
IDS_MODE_STOP "停止中"
|
||||
IDS_MODE_PLAY "再生中"
|
||||
IDS_MODE_PAUSE "一時停止中"
|
||||
IDS_MODE_RECORD "録音中"
|
||||
IDS_MODE_SEEK "シーク中"
|
||||
IDS_MODE_NOT_READY "準備ができていません"
|
||||
IDS_ALL_TYPES_FILTER "すべてのサポートされたファイル"
|
||||
IDS_TOOLTIP_PLAY "再生"
|
||||
IDS_TOOLTIP_STOP "停止"
|
||||
@@ -60,8 +60,8 @@ BEGIN
|
||||
IDS_TOOLTIP_SEEKBACK "後ろへシーク"
|
||||
IDS_TOOLTIP_SEEKFORW "前へシーク"
|
||||
IDS_TOOLTIP_FORWARD "前へスキップ"
|
||||
IDS_TOOLTIP_PAUSE "Pause"
|
||||
IDS_TOOLTIP_PAUSE "一時停止"
|
||||
IDS_APPTITLE "ReactOS マルチメディア プレーヤー"
|
||||
IDS_PLAY "再生"
|
||||
IDS_DEFAULTMCIERRMSG "No description is available for this error."
|
||||
IDS_DEFAULTMCIERRMSG "このエラーの説明はありません。"
|
||||
END
|
||||
|
171
base/applications/msconfig/lang/ja-JP.rc
Normal file
171
base/applications/msconfig/lang/ja-JP.rc
Normal file
@@ -0,0 +1,171 @@
|
||||
LANGUAGE LANG_JAPANESE, SUBLANG_DEFAULT
|
||||
|
||||
IDD_MSCONFIG_DIALOG DIALOGEX 0, 0, 378, 220
|
||||
STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_POPUP |
|
||||
WS_CLIPSIBLINGS | WS_CLIPCHILDREN | WS_CAPTION | WS_SYSMENU
|
||||
CAPTION "システム構成プログラム"
|
||||
FONT 9, "MS UI Gothic"
|
||||
BEGIN
|
||||
CONTROL "Tab1", IDC_TAB, "SysTabControl32", WS_TABSTOP, 2, 2, 374, 195
|
||||
DEFPUSHBUTTON "OK", IDOK, 211, 201, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP
|
||||
PUSHBUTTON "ヘルプ(&H)", IDC_BTN_HELP, 2, 201, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP
|
||||
PUSHBUTTON "キャンセル", IDCANCEL, 267, 201, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP
|
||||
PUSHBUTTON "適用", IDC_BTN_APPLY, 323, 201, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP
|
||||
END
|
||||
|
||||
IDD_STARTUP_PAGE DIALOGEX 0, 0, 362, 175
|
||||
STYLE DS_SHELLFONT | DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN
|
||||
FONT 9, "MS UI Gothic"
|
||||
BEGIN
|
||||
CONTROL "List3", IDC_STARTUP_LIST, "SysListView32", LVS_REPORT | LVS_SINGLESEL |
|
||||
LVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP, 2, 1, 360, 148
|
||||
PUSHBUTTON "すべて有効化(&A)", IDC_BTN_STARTUP_ACTIVATE, 223, 155, 66, 14
|
||||
PUSHBUTTON "すべて無効化(&D)", IDC_BTN_STARTUP_DEACTIVATE, 295, 155, 66, 14
|
||||
END
|
||||
|
||||
IDD_SYSTEM_PAGE DIALOGEX 0, 0, 362, 175
|
||||
STYLE DS_SHELLFONT | DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN
|
||||
FONT 9, "MS UI Gothic"
|
||||
BEGIN
|
||||
CONTROL "", IDC_SYSTEM_TREE, "SysTreeView32", TVS_HASBUTTONS | TVS_HASLINES |
|
||||
TVS_LINESATROOT | TVS_EDITLABELS | TVS_SHOWSELALWAYS | WS_CHILD |
|
||||
WS_VISIBLE | WS_BORDER | WS_TABSTOP, 2, 1, 280, 148
|
||||
PUSHBUTTON "上へ(&U)", IDC_BTN_SYSTEM_UP, 290, 5, 66, 14
|
||||
PUSHBUTTON "下へ(&D)", IDC_BTN_SYSTEM_DOWN, 290, 25, 66, 14
|
||||
PUSHBUTTON "有効化(&E)", IDC_BTN_SYSTEM_ENABLE, 290, 50, 66, 14
|
||||
PUSHBUTTON "無効化(&I)", IDC_BTN_SYSTEM_DISABLE, 290, 70, 66, 14
|
||||
PUSHBUTTON "検索(&F)", IDC_BTN_SYSTEM_FIND, 290, 95, 66, 14
|
||||
PUSHBUTTON "新規(&N)", IDC_BTN_SYSTEM_NEW, 290, 115, 66, 14
|
||||
PUSHBUTTON "編集(&T)", IDC_BTN_SYSTEM_EDIT, 290, 135, 66, 14
|
||||
PUSHBUTTON "すべて有効化(&B)", IDC_BTN_SYSTEM_ACTIVATE, 123, 155, 66, 14
|
||||
PUSHBUTTON "すべて無効化(&L)", IDC_BTN_SYSTEM_DEACTIVATE, 195, 155, 66, 14
|
||||
END
|
||||
|
||||
IDD_TOOLS_PAGE DIALOGEX 0, 0, 362, 175
|
||||
STYLE DS_SHELLFONT | DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN
|
||||
FONT 9, "MS UI Gothic"
|
||||
BEGIN
|
||||
CONTROL "List2", IDC_TOOLS_LIST, "SysListView32", LVS_REPORT | LVS_SINGLESEL |
|
||||
LVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP, 2, 1, 360, 134
|
||||
EDITTEXT IDC_TOOLS_CMDLINE, 1, 139, 360, 12, ES_READONLY
|
||||
PUSHBUTTON "実行(&R)", IDC_BTN_RUN, 311, 155, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP
|
||||
END
|
||||
|
||||
IDD_SERVICES_PAGE DIALOGEX 0, 0, 362, 175
|
||||
STYLE DS_SHELLFONT | DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN
|
||||
FONT 9, "MS UI Gothic"
|
||||
BEGIN
|
||||
CONTROL "List1", IDC_SERVICES_LIST, "SysListView32", LVS_REPORT | LVS_SINGLESEL |
|
||||
LVS_SHOWSELALWAYS | LVS_SORTASCENDING | WS_BORDER | WS_TABSTOP, 2, 1, 360, 148
|
||||
PUSHBUTTON "すべて有効化(&A)", IDC_BTN_SERVICES_ACTIVATE, 223, 155, 66, 14
|
||||
PUSHBUTTON "すべて無効化(&D)", IDC_BTN_SERVICES_DEACTIVATE, 295, 155, 66, 14
|
||||
END
|
||||
|
||||
IDD_GENERAL_PAGE DIALOGEX 0, 0, 362, 175
|
||||
STYLE DS_SHELLFONT | DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN
|
||||
FONT 9, "MS UI Gothic"
|
||||
BEGIN
|
||||
GROUPBOX "起動の種類の選択", -1, 10, 10, 340, 150, 0, WS_EX_TRANSPARENT
|
||||
CONTROL "通常起動(&N) - すべてのデバイスドライバとサービスを読み込む", IDC_CBX_NORMAL_START, "Button", 0x50010009, 20, 30, 260, 10
|
||||
CONTROL "診断的起動(&D) - 基本的なデバイスとサービスのみを読み込む", IDC_CBX_DIAGNOSTIC_START, "Button", 0x50010009, 20, 45, 260, 10
|
||||
CONTROL "選択的起動(&E)", IDC_CBX_SELECTIVE_STARTUP, "Button", 0x50010009, 20, 60, 260, 10
|
||||
AUTOCHECKBOX "ファイル SYSTEM.INI を処理(&R)", IDC_CBX_SYSTEM_INI, 30, 80, 260, 10
|
||||
AUTOCHECKBOX "システムサービスの読み込み(&L)", IDC_CBX_SYSTEM_SERVICE, 30, 95, 260, 10
|
||||
AUTOCHECKBOX "スタートアップ項目を読み込む(&O)", IDC_CBX_STARTUP_ITEM, 30, 110, 260, 10
|
||||
END
|
||||
|
||||
IDD_FREELDR_PAGE DIALOGEX 0, 0, 362, 175
|
||||
STYLE DS_SHELLFONT | DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN
|
||||
FONT 9, "MS UI Gothic"
|
||||
BEGIN
|
||||
LISTBOX IDC_LIST_BOX, 10, 10, 340, 50, WS_CHILD | WS_VISIBLE | WS_TABSTOP |
|
||||
LBS_NOINTEGRALHEIGHT | WS_VSCROLL | WS_HSCROLL
|
||||
PUSHBUTTON "すべての起動パスを確認する(&C)", IDC_BTN_CHECK_BOOT_PATH, 10, 65, 70, 12
|
||||
PUSHBUTTON "デフォルトにする(&S)", IDC_BTN_SET_DEFAULT_BOOT, 100, 65, 70, 12
|
||||
PUSHBUTTON "上へ(&U)", IDC_BTN_MOVE_UP_BOOT_OPTION, 190, 65, 70, 12
|
||||
PUSHBUTTON "下へ(&D)", IDC_BTN_MOVE_DOWN_BOOT_OPTION, 280, 65, 70, 12
|
||||
GROUPBOX "起動オプション", -1, 10, 80, 250, 90, 0, WS_EX_TRANSPARENT
|
||||
CHECKBOX "/SA&FEBOOT", IDC_CBX_SAFE_BOOT, 15, 90, 55, 10
|
||||
CHECKBOX "/&NOGUIBOOT", IDC_CBX_NO_GUI_BOOT, 15, 105, 60, 10
|
||||
CHECKBOX "/&BOOTLOG", IDC_CBX_BOOT_LOG, 15, 120, 50, 10
|
||||
CHECKBOX "/BAS&EVIDEO", IDC_CBX_BASE_VIDEO, 15, 135, 55, 10
|
||||
CHECKBOX "/S&OS", IDC_CBX_SOS, 15, 150, 50, 10
|
||||
PUSHBUTTON "詳細オプション(&V)...", IDC_BTN_ADVANCED_OPTIONS, 100, 150, 70, 12
|
||||
LTEXT "タイムアウト(&T):", -1, 280, 91, 30, 10
|
||||
EDITTEXT IDC_TXT_BOOT_TIMEOUT, 310, 90, 25, 12, ES_LEFT
|
||||
LTEXT "秒", -1, 340, 91, 15, 10
|
||||
END
|
||||
|
||||
IDD_FREELDR_ADVANCED_PAGE DIALOGEX 0, 0, 175, 175
|
||||
STYLE DS_SHELLFONT | DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN
|
||||
FONT 9, "MS UI Gothic"
|
||||
BEGIN
|
||||
CHECKBOX "/&MAXMEM=", IDC_CBX_MAX_MEM, 10, 10, 50, 10
|
||||
EDITTEXT IDC_TXT_MAX_MEM, 80, 10, 60, 12
|
||||
CONTROL "", IDC_SCR_MAX_MEM, "msctls_updown32", 0x50000000, 140, 10, 11, 11
|
||||
CHECKBOX "/&NUMPROC=", IDC_CBX_NUM_PROC, 10, 25, 50, 10
|
||||
COMBOBOX IDC_DRP_NUM_PROC, 80, 25, 60, 10, CBS_DROPDOWNLIST | CBS_SORT | WS_CHILD | WS_VISIBLE | WS_TABSTOP
|
||||
CHECKBOX "/&PCILOCK", IDC_CBX_PCI_LOCK, 10, 40, 50, 10
|
||||
CHECKBOX "/P&ROFILE", IDC_CBX_PROFILE, 10, 55, 50, 10
|
||||
CHECKBOX "/&IRQ", IDC_CBX_IRQ, 10, 70, 40, 12
|
||||
EDITTEXT IDC_TXT_IRQ, 80, 70, 60, 12, ES_LEFT
|
||||
CHECKBOX "/&DEBUG", IDC_CBX_DEBUG, 10, 85, 40, 10
|
||||
CHECKBOX "/D&EBUGPORT", IDC_CBX_DEBUG_PORT, 20, 100, 60, 10
|
||||
COMBOBOX IDC_DRP_DEBUG_PORT, 80, 100, 60, 10, CBS_DROPDOWNLIST | CBS_SORT | WS_CHILD | WS_VISIBLE | WS_TABSTOP
|
||||
CHECKBOX "/&BAUDRATE", IDC_CBX_BAUD_RATE, 20, 115, 50, 10
|
||||
COMBOBOX IDC_DRP_DRP_BAUD_RATE, 80, 115, 60, 10, CBS_DROPDOWNLIST | CBS_SORT | WS_CHILD | WS_VISIBLE | WS_TABSTOP
|
||||
CHECKBOX "/&CHANNEL", IDC_CBX_CHANNEL, 20, 130, 50, 10
|
||||
EDITTEXT IDC_TXT_CHANNEL, 80, 130, 60, 12, ES_LEFT
|
||||
CONTROL "", IDC_SCR_CHANNEL, "msctls_updown32", 0x50000000, 140, 130, 11, 11
|
||||
PUSHBUTTON "OK", IDC_OK, 20, 160, 50, 12
|
||||
PUSHBUTTON "キャンセル", IDC_CANCEL, 100, 160, 50, 12
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
BEGIN
|
||||
IDS_MSCONFIG "システム構成プログラム"
|
||||
IDS_TAB_GENERAL "一般"
|
||||
IDS_TAB_SYSTEM "SYSTEM.INI"
|
||||
IDS_TAB_FREELDR "FREELDR.INI"
|
||||
IDS_TAB_SERVICES "サービス"
|
||||
IDS_TAB_STARTUP "スタートアップ"
|
||||
IDS_TAB_TOOLS "ツール"
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
BEGIN
|
||||
IDS_SERVICES_COLUMN_SERVICE "サービス"
|
||||
IDS_SERVICES_COLUMN_REQ "必要"
|
||||
IDS_SERVICES_COLUMN_VENDOR "ベンダー"
|
||||
IDS_SERVICES_COLUMN_STATUS "状態"
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
BEGIN
|
||||
IDS_TOOLS_COLUMN_NAME "名前"
|
||||
IDS_TOOLS_COLUMN_DESCR "説明"
|
||||
IDS_TOOLS_CMD_NAME "コンソール"
|
||||
IDS_TOOLS_CMD_DESCR ""
|
||||
IDS_TOOLS_CMD_CMD "cmd.exe"
|
||||
IDS_TOOLS_INFO_NAME "バージョン"
|
||||
IDS_TOOLS_INFO_DESCR "バージョン情報を表示します。"
|
||||
IDS_TOOLS_INFO_CMD "winver.exe"
|
||||
IDS_TOOLS_REGEDIT_NAME "レジストリ エディタ"
|
||||
IDS_TOOLS_REGEDIT_DESCR "レジストリ エディタを開きます。"
|
||||
IDS_TOOLS_REGEDIT_CMD "regedit.exe"
|
||||
IDS_TOOLS_SYSDM_NAME "システムプロパティ"
|
||||
IDS_TOOLS_SYSDM_DESCR "このコンピューターに関する情報を表示します。"
|
||||
IDS_TOOLS_SYSDM_CMD "control.exe"
|
||||
IDS_TOOLS_SYSDM_PARAM "sysdm.cpl"
|
||||
IDS_STARTUP_COLUMN_ELEMENT "要素"
|
||||
IDS_STARTUP_COLUMN_CMD "コマンド"
|
||||
IDS_STARTUP_COLUMN_PATH "パス"
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
BEGIN
|
||||
IDS_SERVICES_STATUS_RUNNING "実行中"
|
||||
IDS_SERVICES_STATUS_STOPPED "停止"
|
||||
IDS_SERVICES_YES "はい"
|
||||
IDS_SERVICES_UNKNOWN "不明"
|
||||
END
|
@@ -54,6 +54,9 @@ IDI_APPICON ICON "res/msconfig.ico"
|
||||
#ifdef LANGUAGE_IT_IT
|
||||
#include "lang/it-IT.rc"
|
||||
#endif
|
||||
#ifdef LANGUAGE_JA_JP
|
||||
#include "lang/ja-JP.rc"
|
||||
#endif
|
||||
#ifdef LANGUAGE_KO_KR
|
||||
#include "lang/ko-KR.rc"
|
||||
#endif
|
||||
|
@@ -28,11 +28,11 @@ BEGIN
|
||||
CONTROL "Exécuter le fichier &WIN.INI", IDC_CBX_WIN_INI, "Button", BS_AUTO3STATE | WS_TABSTOP, 35, 98, 316, 10
|
||||
CONTROL "C&harger les services système", IDC_CBX_LOAD_SYSTEM_SERVICES, "Button", BS_AUTO3STATE | WS_TABSTOP, 35, 110, 316, 10
|
||||
CONTROL "&Charger les éléments de démarrage", IDC_CBX_LOAD_STARTUP_ITEMS, "Button", BS_AUTO3STATE | WS_TABSTOP, 35, 122, 316, 10
|
||||
CONTROL "&Utiliser la configuration de démarrage d’origine", IDC_CBX_USE_ORIGINAL_BOOTCFG, "Button", BS_AUTOCHECKBOX | WS_TABSTOP, 35, 134, 316, 10
|
||||
CONTROL "&Utiliser la configuration de démarrage d'origine", IDC_CBX_USE_ORIGINAL_BOOTCFG, "Button", BS_AUTOCHECKBOX | WS_TABSTOP, 35, 134, 316, 10
|
||||
PUSHBUTTON "Exéc&uter la restauration du système", IDC_BTN_SYSTEM_RESTORE_START, 146, 156, 124, 14
|
||||
PUSHBUTTON "E&xtraire le fichier...", IDC_BTN_FILE_EXTRACTION, 275, 156, 85, 14
|
||||
GROUPBOX "Sélection du mode de démarrage ", IDC_STATIC, 5, 5, 356, 145
|
||||
LTEXT "Charger tous les pilotes de périphériques et tous les services", IDC_STATIC, 25, 30, 322, 10
|
||||
LTEXT "Charger tous les pilotes de périphérique et tous les services", IDC_STATIC, 25, 30, 322, 10
|
||||
LTEXT "Charger seulement les pilotes de périphérique et les services de base", IDC_STATIC, 25, 58, 322, 10
|
||||
END
|
||||
|
||||
|
@@ -1978,6 +1978,7 @@ EnumEventsThread(IN LPVOID lpParameter)
|
||||
BOOL bResult = TRUE; /* Read succeeded */
|
||||
HANDLE hProcessHeap = GetProcessHeap();
|
||||
PSID pLastSid = NULL;
|
||||
INT nItems;
|
||||
|
||||
UINT uStep = 0, uStepAt = 0, uPos = 0;
|
||||
|
||||
@@ -1997,11 +1998,12 @@ EnumEventsThread(IN LPVOID lpParameter)
|
||||
SYSTEMTIME time;
|
||||
LVITEMW lviEventItem;
|
||||
|
||||
EnableEventDetailsButtons(hwndEventDetails, FALSE);
|
||||
|
||||
/* Save the current event log filter globally */
|
||||
EventLogFilter_AddRef(EventLogFilter);
|
||||
ActiveFilter = EventLogFilter;
|
||||
|
||||
|
||||
/** HACK!! **/
|
||||
EventLog = EventLogFilter->EventLogs[0];
|
||||
|
||||
@@ -2263,6 +2265,8 @@ Quit:
|
||||
/* All events loaded */
|
||||
|
||||
Cleanup:
|
||||
nItems = ListView_GetItemCount(hwndListView);
|
||||
EnableEventDetailsButtons(hwndEventDetails, (nItems > 0));
|
||||
|
||||
ShowWindow(hwndStatusProgress, SW_HIDE);
|
||||
SendMessageW(hwndListView, LVM_PROGRESS, 0, FALSE);
|
||||
@@ -3037,6 +3041,22 @@ InitInstance(HINSTANCE hInstance)
|
||||
HIMAGELIST hSmall;
|
||||
LVCOLUMNW lvc = {0};
|
||||
WCHAR szTemp[256];
|
||||
INT iColumn;
|
||||
static const struct
|
||||
{
|
||||
WORD width;
|
||||
WORD uID;
|
||||
} columnItems[] =
|
||||
{
|
||||
{ 90, IDS_COLUMNTYPE },
|
||||
{ 70, IDS_COLUMNDATE },
|
||||
{ 70, IDS_COLUMNTIME },
|
||||
{ 150, IDS_COLUMNSOURCE },
|
||||
{ 100, IDS_COLUMNCATEGORY },
|
||||
{ 60, IDS_COLUMNEVENT },
|
||||
{ 120, IDS_COLUMNUSER },
|
||||
{ 100, IDS_COLUMNCOMPUTER },
|
||||
};
|
||||
|
||||
/* Create the main window */
|
||||
rs = Settings.wpPos.rcNormalPosition;
|
||||
@@ -3180,69 +3200,13 @@ InitInstance(HINSTANCE hInstance)
|
||||
|
||||
/* Now set up the listview with its columns */
|
||||
lvc.mask = LVCF_TEXT | LVCF_WIDTH;
|
||||
lvc.cx = 90;
|
||||
LoadStringW(hInstance,
|
||||
IDS_COLUMNTYPE,
|
||||
szTemp,
|
||||
ARRAYSIZE(szTemp));
|
||||
lvc.pszText = szTemp;
|
||||
ListView_InsertColumn(hwndListView, 0, &lvc);
|
||||
|
||||
lvc.cx = 70;
|
||||
LoadStringW(hInstance,
|
||||
IDS_COLUMNDATE,
|
||||
szTemp,
|
||||
ARRAYSIZE(szTemp));
|
||||
lvc.pszText = szTemp;
|
||||
ListView_InsertColumn(hwndListView, 1, &lvc);
|
||||
|
||||
lvc.cx = 70;
|
||||
LoadStringW(hInstance,
|
||||
IDS_COLUMNTIME,
|
||||
szTemp,
|
||||
ARRAYSIZE(szTemp));
|
||||
lvc.pszText = szTemp;
|
||||
ListView_InsertColumn(hwndListView, 2, &lvc);
|
||||
|
||||
lvc.cx = 150;
|
||||
LoadStringW(hInstance,
|
||||
IDS_COLUMNSOURCE,
|
||||
szTemp,
|
||||
ARRAYSIZE(szTemp));
|
||||
lvc.pszText = szTemp;
|
||||
ListView_InsertColumn(hwndListView, 3, &lvc);
|
||||
|
||||
lvc.cx = 100;
|
||||
LoadStringW(hInstance,
|
||||
IDS_COLUMNCATEGORY,
|
||||
szTemp,
|
||||
ARRAYSIZE(szTemp));
|
||||
lvc.pszText = szTemp;
|
||||
ListView_InsertColumn(hwndListView, 4, &lvc);
|
||||
|
||||
lvc.cx = 60;
|
||||
LoadStringW(hInstance,
|
||||
IDS_COLUMNEVENT,
|
||||
szTemp,
|
||||
ARRAYSIZE(szTemp));
|
||||
lvc.pszText = szTemp;
|
||||
ListView_InsertColumn(hwndListView, 5, &lvc);
|
||||
|
||||
lvc.cx = 120;
|
||||
LoadStringW(hInstance,
|
||||
IDS_COLUMNUSER,
|
||||
szTemp,
|
||||
ARRAYSIZE(szTemp));
|
||||
lvc.pszText = szTemp;
|
||||
ListView_InsertColumn(hwndListView, 6, &lvc);
|
||||
|
||||
lvc.cx = 100;
|
||||
LoadStringW(hInstance,
|
||||
IDS_COLUMNCOMPUTER,
|
||||
szTemp,
|
||||
ARRAYSIZE(szTemp));
|
||||
lvc.pszText = szTemp;
|
||||
ListView_InsertColumn(hwndListView, 7, &lvc);
|
||||
for (iColumn = 0; iColumn < ARRAYSIZE(columnItems); ++iColumn)
|
||||
{
|
||||
lvc.cx = columnItems[iColumn].width;
|
||||
LoadStringW(hInstance, columnItems[iColumn].uID, szTemp, ARRAYSIZE(szTemp));
|
||||
ListView_InsertColumn(hwndListView, iColumn, &lvc);
|
||||
}
|
||||
|
||||
/* Initialize the save Dialog */
|
||||
ZeroMemory(&sfn, sizeof(sfn));
|
||||
|
@@ -792,6 +792,11 @@ EventDetailsCtrl(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
|
||||
pData->EventLogFilter = DetailInfo->EventLogFilter;
|
||||
pData->iEventItem = DetailInfo->iEventItem;
|
||||
}
|
||||
else
|
||||
{
|
||||
pData->iEventItem = -1;
|
||||
}
|
||||
|
||||
pData->bDisplayWords = FALSE;
|
||||
pData->hMonospaceFont = CreateMonospaceFont();
|
||||
|
||||
@@ -838,31 +843,26 @@ EventDetailsCtrl(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
|
||||
case IDC_NEXT:
|
||||
{
|
||||
BOOL bPrev = (LOWORD(wParam) == IDC_PREVIOUS);
|
||||
INT iItem, iSel;
|
||||
INT iItem, iSel, nItems = ListView_GetItemCount(hwndListView);
|
||||
WCHAR szText[200];
|
||||
|
||||
if (nItems <= 0) /* No items? */
|
||||
break;
|
||||
|
||||
/* Select the previous/next item from our current one */
|
||||
iItem = ListView_GetNextItem(hwndListView,
|
||||
pData->iEventItem,
|
||||
bPrev ? LVNI_ABOVE : LVNI_BELOW);
|
||||
if (iItem == -1)
|
||||
iItem = ListView_GetNextItem(hwndListView, -1, LVNI_ALL | LVNI_SELECTED);
|
||||
iItem = ListView_GetNextItem(hwndListView, iItem,
|
||||
(bPrev ? LVNI_ABOVE : LVNI_BELOW));
|
||||
if (iItem < 0 || iItem >= nItems)
|
||||
{
|
||||
// TODO: Localization.
|
||||
if (MessageBoxW(hDlg,
|
||||
bPrev
|
||||
? L"You have reached the beginning of the event log. Do you want to continue from the end?"
|
||||
: L"You have reached the end of the event log. Do you want to continue from the beginning?",
|
||||
szTitle,
|
||||
MB_YESNO | MB_ICONQUESTION)
|
||||
== IDNO)
|
||||
{
|
||||
LoadStringW(hInst,
|
||||
(bPrev ? IDS_CONTFROMEND : IDS_CONTFROMBEGINNING),
|
||||
szText, _countof(szText));
|
||||
if (MessageBoxW(hDlg, szText, szTitle, MB_YESNO | MB_ICONQUESTION) == IDNO)
|
||||
break;
|
||||
}
|
||||
|
||||
/* Determine from where to restart */
|
||||
if (bPrev)
|
||||
iItem = ListView_GetItemCount(hwndListView) - 1;
|
||||
else
|
||||
iItem = 0;
|
||||
iItem = (bPrev ? (nItems - 1) : 0);
|
||||
}
|
||||
|
||||
/*
|
||||
@@ -959,3 +959,11 @@ CreateEventDetailsCtrl(HINSTANCE hInstance,
|
||||
MAKEINTRESOURCEW(IDD_EVENTDETAILS_CTRL),
|
||||
hParentWnd, EventDetailsCtrl, lParam);
|
||||
}
|
||||
|
||||
VOID
|
||||
EnableEventDetailsButtons(HWND hWnd, BOOL bEnable)
|
||||
{
|
||||
EnableDlgItem(hWnd, IDC_PREVIOUS, bEnable);
|
||||
EnableDlgItem(hWnd, IDC_NEXT, bEnable);
|
||||
EnableDlgItem(hWnd, IDC_COPY, bEnable);
|
||||
}
|
||||
|
@@ -7,8 +7,7 @@
|
||||
* Copyright 2016-2022 Hermès Bélusca-Maïto <hermes.belusca-maito@reactos.org>
|
||||
*/
|
||||
|
||||
#ifndef _EVTDETCTL_H_
|
||||
#define _EVTDETCTL_H_
|
||||
#pragma once
|
||||
|
||||
/* Optional structure passed by pointer
|
||||
* as LPARAM to CreateEventDetailsCtrl() */
|
||||
@@ -26,4 +25,4 @@ CreateEventDetailsCtrl(HINSTANCE hInstance,
|
||||
HWND hParentWnd,
|
||||
LPARAM lParam);
|
||||
|
||||
#endif /* _EVTDETCTL_H_ */
|
||||
VOID EnableEventDetailsButtons(HWND hWnd, BOOL bEnable);
|
||||
|
@@ -167,6 +167,8 @@ BEGIN
|
||||
IDS_CLEAREVENTS_MSG "Do you want to save this event log before clearing it?"
|
||||
IDS_RESTOREDEFAULTS "Do you want to restore all settings for this log to their default values?"
|
||||
IDS_EVENTSTRINGIDNOTFOUND "Не е намерено описанието на събитие ( %lu ) в източник ( %s ). Възможно е местият компютър да няма нужните сведения в регистъра или DLL файловет, нужни за показване на съобщения от отдалечен компютър.\n\nThe following information is part of the event:\n\n"
|
||||
IDS_CONTFROMBEGINNING "You have reached the end of the event log. Do you want to continue from the beginning?"
|
||||
IDS_CONTFROMEND "You have reached the beginning of the event log. Do you want to continue from the end?"
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
|
@@ -167,6 +167,8 @@ BEGIN
|
||||
IDS_CLEAREVENTS_MSG "Chcete tento protokol před odstraněním uložit?"
|
||||
IDS_RESTOREDEFAULTS "Do you want to restore all settings for this log to their default values?"
|
||||
IDS_EVENTSTRINGIDNOTFOUND "Popis ID události ( %lu ) zdroj ( %s ) nebyl nalezen. Místní počítač neobsahuje potřebné informace v registru nebo chybí DLL soubory pro zobrazení zpráv ze vzdáleného počítače.\n\nThe following information is part of the event:\n\n"
|
||||
IDS_CONTFROMBEGINNING "You have reached the end of the event log. Do you want to continue from the beginning?"
|
||||
IDS_CONTFROMEND "You have reached the beginning of the event log. Do you want to continue from the end?"
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
|
@@ -168,6 +168,8 @@ BEGIN
|
||||
IDS_CLEAREVENTS_MSG "Möchten Sie dieses Protokoll vor dem Löschen speichern?"
|
||||
IDS_RESTOREDEFAULTS "Möchten Sie alle Einstellungen für dieses Protokoll wieder auf die Standardwerte zurücksetzen?"
|
||||
IDS_EVENTSTRINGIDNOTFOUND "Die Bezeichnung für die Ereignis-ID ( %lu ) in der Quelle ( %s ) kann nicht gefunden werden. Es könnte sein, dass der lokale Computer die notwendigen Registry Einträge oder Nachrichten DLLs, um Nachrichten entfernter Computer anzuzeigen, nicht besitzt.\n\nDas Ereignis enthält folgende Informationen:\n\n"
|
||||
IDS_CONTFROMBEGINNING "You have reached the end of the event log. Do you want to continue from the beginning?"
|
||||
IDS_CONTFROMEND "You have reached the beginning of the event log. Do you want to continue from the end?"
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
|
@@ -167,6 +167,8 @@ BEGIN
|
||||
IDS_CLEAREVENTS_MSG "Do you want to save this event log before clearing it?"
|
||||
IDS_RESTOREDEFAULTS "Do you want to restore all settings for this log to their default values?"
|
||||
IDS_EVENTSTRINGIDNOTFOUND "The description for Event ID ( %lu ) in Source ( %s ) cannot be found. The local computer may not have the necessary registry information or message DLL files to display messages from a remote computer.\n\nThe following information is part of the event:\n\n"
|
||||
IDS_CONTFROMBEGINNING "You have reached the end of the event log. Do you want to continue from the beginning?"
|
||||
IDS_CONTFROMEND "You have reached the beginning of the event log. Do you want to continue from the end?"
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
|
@@ -169,6 +169,8 @@ BEGIN
|
||||
IDS_CLEAREVENTS_MSG "Do you want to save this event log before clearing it?"
|
||||
IDS_RESTOREDEFAULTS "Do you want to restore all settings for this log to their default values?"
|
||||
IDS_EVENTSTRINGIDNOTFOUND "The description for Event ID ( %lu ) in Source ( %s ) cannot be found. The local computer may not have the necessary registry information or message DLL files to display messages from a remote computer.\n\nThe following information is part of the event:\n\n"
|
||||
IDS_CONTFROMBEGINNING "You have reached the end of the event log. Do you want to continue from the beginning?"
|
||||
IDS_CONTFROMEND "You have reached the beginning of the event log. Do you want to continue from the end?"
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
|
@@ -170,6 +170,8 @@ BEGIN
|
||||
IDS_CLEAREVENTS_MSG "¿Desea guardar este registro de eventos antes de borrarlo?"
|
||||
IDS_RESTOREDEFAULTS "Do you want to restore all settings for this log to their default values?"
|
||||
IDS_EVENTSTRINGIDNOTFOUND "No se pudo recuperar la descripción para el evento con ID ( %lu ) y origen ( %s ). El equipo local puede no tener la información necesaria en el registro o las DLLs necesarias para mostrar los mensajes de un equipo remoto.\n\nLa siguiente información es parte del evento:\n\n"
|
||||
IDS_CONTFROMBEGINNING "You have reached the end of the event log. Do you want to continue from the beginning?"
|
||||
IDS_CONTFROMEND "You have reached the beginning of the event log. Do you want to continue from the end?"
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
|
@@ -50,12 +50,12 @@ IDM_EVENTWR_CTX MENU
|
||||
BEGIN
|
||||
POPUP ""
|
||||
BEGIN
|
||||
MENUITEM "&Open Event Log...", IDM_OPEN_EVENTLOG
|
||||
MENUITEM "&Save Event Log as...", IDM_SAVE_EVENTLOG
|
||||
MENUITEM "&Ouvrir le journal d'événements...", IDM_OPEN_EVENTLOG
|
||||
MENUITEM "Enregistrer le journal d'événements &sous...", IDM_SAVE_EVENTLOG
|
||||
MENUITEM SEPARATOR
|
||||
MENUITEM "&Clear all Events", IDM_CLEAR_EVENTS
|
||||
MENUITEM "&Rename\tF2", IDM_RENAME_EVENTLOG
|
||||
MENUITEM "Log Se&ttings...", IDM_EVENTLOG_SETTINGS
|
||||
MENUITEM "&Effacer tous les événements", IDM_CLEAR_EVENTS
|
||||
MENUITEM "&Renommer\tF2", IDM_RENAME_EVENTLOG
|
||||
MENUITEM "&Paramètres du journal...", IDM_EVENTLOG_SETTINGS
|
||||
END
|
||||
END
|
||||
|
||||
@@ -168,6 +168,8 @@ BEGIN
|
||||
IDS_CLEAREVENTS_MSG "Voulez-vous enregistrer ce journal d'événements avant de l'effacer ?"
|
||||
IDS_RESTOREDEFAULTS "Voulez-vous vraiment réinitialiser tous les paramètres pour ce journal aux valeurs par défaut ?"
|
||||
IDS_EVENTSTRINGIDNOTFOUND "La description pour l'événement d'ID ( %lu ) dans la source ( %s ) ne peut être trouvée. L'ordinateur local pourrait ne pas avoir les informations registres nécessaires ou les fichiers DLL de message pour afficher les messages depuis un ordinateur distant.\n\nLes informations suivantes font partie de l'événement :\n\n"
|
||||
IDS_CONTFROMBEGINNING "You have reached the end of the event log. Do you want to continue from the beginning?"
|
||||
IDS_CONTFROMEND "You have reached the beginning of the event log. Do you want to continue from the end?"
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
|
@@ -167,6 +167,8 @@ BEGIN
|
||||
IDS_CLEAREVENTS_MSG "Do you want to save this event log before clearing it?"
|
||||
IDS_RESTOREDEFAULTS "Do you want to restore all settings for this log to their default values?"
|
||||
IDS_EVENTSTRINGIDNOTFOUND "The description for Event ID ( %lu ) in Source ( %s ) cannot be found. The local computer may not have the necessary registry information or message DLL files to display messages from a remote computer.\n\nThe following information is part of the event:\n\n"
|
||||
IDS_CONTFROMBEGINNING "You have reached the end of the event log. Do you want to continue from the beginning?"
|
||||
IDS_CONTFROMEND "You have reached the beginning of the event log. Do you want to continue from the end?"
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
|
@@ -168,6 +168,8 @@ BEGIN
|
||||
IDS_CLEAREVENTS_MSG "Do you want to save this event log before clearing it?"
|
||||
IDS_RESTOREDEFAULTS "Do you want to restore all settings for this log to their default values?"
|
||||
IDS_EVENTSTRINGIDNOTFOUND "La descrizione per l'ID evento ( %lu ) proveniente da ( %s ) non può essere trovata. Il computer locale potrebbe non avere le informazioni sul registry necessarie o i file DLL con i messaggi necessari per la visualizzazione da un computer remoto.\n\nThe following information is part of the event:\n\n"
|
||||
IDS_CONTFROMBEGINNING "You have reached the end of the event log. Do you want to continue from the beginning?"
|
||||
IDS_CONTFROMEND "You have reached the beginning of the event log. Do you want to continue from the end?"
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
|
@@ -168,6 +168,8 @@ BEGIN
|
||||
IDS_CLEAREVENTS_MSG "このイベントをクリアする前に保存したいですか?"
|
||||
IDS_RESTOREDEFAULTS "すべての設定をデフォルトに戻しますか?"
|
||||
IDS_EVENTSTRINGIDNOTFOUND "イベント ID (%lu) (ソース %s 内) に関する説明が見つかりませんでした。 リモート コンピュータからメッセージを表示するために必要なレジストリ情報またはメッセージ DLL ファイルがローカル コンピュータにない可能性があります。\n\n次の情報はイベントの一部です:\n\n"
|
||||
IDS_CONTFROMBEGINNING "イベント ログの最後に到達しました。最初から続けますか?"
|
||||
IDS_CONTFROMEND "イベント ログの先頭に到達しました。最後から続けますか?"
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
|
@@ -167,6 +167,8 @@ BEGIN
|
||||
IDS_CLEAREVENTS_MSG "Do you want to save this event log before clearing it?"
|
||||
IDS_RESTOREDEFAULTS "Do you want to restore all settings for this log to their default values?"
|
||||
IDS_EVENTSTRINGIDNOTFOUND "( %s ) 의 이벤트ID ( %lu ) 에 대한 설명을 찾을 수 없습니다. 로컬 컴퓨터가 원격 컴퓨터의 메세지를 표시하는데 필요한 레지스트리나 DLL 파일을 가지지 않고 있을수 있습니다.\n\nThe following information is part of the event:\n\n"
|
||||
IDS_CONTFROMBEGINNING "You have reached the end of the event log. Do you want to continue from the beginning?"
|
||||
IDS_CONTFROMEND "You have reached the beginning of the event log. Do you want to continue from the end?"
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
|
@@ -167,6 +167,8 @@ BEGIN
|
||||
IDS_CLEAREVENTS_MSG "Do you want to save this event log before clearing it?"
|
||||
IDS_RESTOREDEFAULTS "Do you want to restore all settings for this log to their default values?"
|
||||
IDS_EVENTSTRINGIDNOTFOUND "Beskrivelsen for Hendelse ID ( %lu ) i kilden ( %s ) kan ikke bli finnet. Lokale datamaskinen har ikke nødvendige register informasjon eller melding DLL filer for å vise melding fra en fjern datamaskin.\n\nThe following information is part of the event:\n\n"
|
||||
IDS_CONTFROMBEGINNING "You have reached the end of the event log. Do you want to continue from the beginning?"
|
||||
IDS_CONTFROMEND "You have reached the beginning of the event log. Do you want to continue from the end?"
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
|
@@ -170,6 +170,8 @@ BEGIN
|
||||
IDS_CLEAREVENTS_MSG "Czy chcesz zapisać dziennik zdarzeń przed czyszczeniem?"
|
||||
IDS_RESTOREDEFAULTS "Czy chcesz przywrócić wszystkie ustawienia tego dziennika do wartości domyślnych?"
|
||||
IDS_EVENTSTRINGIDNOTFOUND "Opis zdarzenia dla danego numeru ID ( %lu ) nie został odnaleziony w źródle ( %s ). Ten komputer może nie miec wystarczających informacji w rejestrze, albo bibliotek DLL, aby wyświetlić wiadomości z komputera zdalnego.\n\nThe following information is part of the event:\n\n"
|
||||
IDS_CONTFROMBEGINNING "You have reached the end of the event log. Do you want to continue from the beginning?"
|
||||
IDS_CONTFROMEND "You have reached the beginning of the event log. Do you want to continue from the end?"
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
|
@@ -167,6 +167,8 @@ BEGIN
|
||||
IDS_CLEAREVENTS_MSG "Do you want to save this event log before clearing it?"
|
||||
IDS_RESTOREDEFAULTS "Do you want to restore all settings for this log to their default values?"
|
||||
IDS_EVENTSTRINGIDNOTFOUND "A descrição para Event ID ( %lu ) em Fonte ( %s ) não foi encontrado. O computador local talvez não possua a informação de registro necessária ou mensagem de arquivos DLL para exibir mensagens de um computador remoto.\n\nThe following information is part of the event:\n\n"
|
||||
IDS_CONTFROMBEGINNING "You have reached the end of the event log. Do you want to continue from the beginning?"
|
||||
IDS_CONTFROMEND "You have reached the beginning of the event log. Do you want to continue from the end?"
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
|
@@ -167,6 +167,8 @@ BEGIN
|
||||
IDS_CLEAREVENTS_MSG "Deseja guardar este registo de eventos antes de limpar?"
|
||||
IDS_RESTOREDEFAULTS "Tem a certeza de que pretende repor todas definições deste registo para os valores predefinidos?"
|
||||
IDS_EVENTSTRINGIDNOTFOUND "A descrição do ID de Evento ( %lu ) na Origem ( %s ) não foi encontrado. O computador local talvez não possua a informação de registo necessária ou os ficheiros DLL necessárias para apresentar mensagens de um computador remoto.\n\nA informação seguinte é parte do evento:\n\n"
|
||||
IDS_CONTFROMBEGINNING "You have reached the end of the event log. Do you want to continue from the beginning?"
|
||||
IDS_CONTFROMEND "You have reached the beginning of the event log. Do you want to continue from the end?"
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
|
@@ -169,6 +169,8 @@ BEGIN
|
||||
IDS_CLEAREVENTS_MSG "Doriți să salvați acest jurnal de evenimente înainte de a-l închide?"
|
||||
IDS_RESTOREDEFAULTS "Doriți să restabiliți toate setările pentru acest jurnal la valorile lor implicite?"
|
||||
IDS_EVENTSTRINGIDNOTFOUND "Imposibil de găsit descrierea evenimentului cu ID-ul ( %lu ) în sursa ( %s ). Este posibil ca computerul local să nu aibă informațiile de registru necesare sau fișierele DLL de mesaje pentru a afișa mesaje de la un computer la distanță.\n\nUrmătoarele informații fac parte din eveniment:\n\n"
|
||||
IDS_CONTFROMBEGINNING "You have reached the end of the event log. Do you want to continue from the beginning?"
|
||||
IDS_CONTFROMEND "You have reached the beginning of the event log. Do you want to continue from the end?"
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
|
@@ -171,6 +171,8 @@ BEGIN
|
||||
IDS_CLEAREVENTS_MSG "Вы хотите сохранить журнал событий перед очисткой?"
|
||||
IDS_RESTOREDEFAULTS "Do you want to restore all settings for this log to their default values?"
|
||||
IDS_EVENTSTRINGIDNOTFOUND "Не найдено описание для события с кодом ( %lu ) в источнике ( %s ). Возможно, на локальном компьютере нет нужных данных в реестре или файлов DLL сообщений для отображения сообщений удаленного компьютера.\n\nСледующая информация часть события:\n\n"
|
||||
IDS_CONTFROMBEGINNING "You have reached the end of the event log. Do you want to continue from the beginning?"
|
||||
IDS_CONTFROMEND "You have reached the beginning of the event log. Do you want to continue from the end?"
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
|
@@ -167,6 +167,8 @@ BEGIN
|
||||
IDS_CLEAREVENTS_MSG "Do you want to save this event log before clearing it?"
|
||||
IDS_RESTOREDEFAULTS "Do you want to restore all settings for this log to their default values?"
|
||||
IDS_EVENTSTRINGIDNOTFOUND "Popis pre udalosť ID ( %lu ) zo zdroja ( %s ) nebol nájdený. The local computer may not have the necessary registry information or message DLL files to display messages from a remote computer.\n\nThe following information is part of the event:\n\n"
|
||||
IDS_CONTFROMBEGINNING "You have reached the end of the event log. Do you want to continue from the beginning?"
|
||||
IDS_CONTFROMEND "You have reached the beginning of the event log. Do you want to continue from the end?"
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
|
@@ -167,6 +167,8 @@ BEGIN
|
||||
IDS_CLEAREVENTS_MSG "Do you want to save this event log before clearing it?"
|
||||
IDS_RESTOREDEFAULTS "Do you want to restore all settings for this log to their default values?"
|
||||
IDS_EVENTSTRINGIDNOTFOUND "Përshkrimi për ngjarjet ID ( %lu ) në burim ( %s ) nuk gjindet. Kompjuter vendas mund të mos ketë informacionin e regjistrit te nevojshem ose mesazhin për dokumentat DLL për të shfaqur nga një kompjuter në distancë.\n\nThe following information is part of the event:\n\n"
|
||||
IDS_CONTFROMBEGINNING "You have reached the end of the event log. Do you want to continue from the beginning?"
|
||||
IDS_CONTFROMEND "You have reached the beginning of the event log. Do you want to continue from the end?"
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
|
@@ -167,6 +167,8 @@ BEGIN
|
||||
IDS_CLEAREVENTS_MSG "Do you want to save this event log before clearing it?"
|
||||
IDS_RESTOREDEFAULTS "Do you want to restore all settings for this log to their default values?"
|
||||
IDS_EVENTSTRINGIDNOTFOUND "Beskrivning av Händelse ID ( %lu ) i källan ( %s ) kan inte hittas. Lokal dator har inte nödvendig registerinformation eller meddelander DLL filer for å vise meddelander från en fjärr dator.\n\nThe following information is part of the event:\n\n"
|
||||
IDS_CONTFROMBEGINNING "You have reached the end of the event log. Do you want to continue from the beginning?"
|
||||
IDS_CONTFROMEND "You have reached the beginning of the event log. Do you want to continue from the end?"
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
|
@@ -168,6 +168,8 @@ BEGIN
|
||||
IDS_CLEAREVENTS_MSG "Silmeden önce bu olay kaydını kaydetmek ister misiniz?"
|
||||
IDS_RESTOREDEFAULTS "Bu günlük için tüm ayarları varsayılan değerlerine geri yüklemek istiyor musunuz?"
|
||||
IDS_EVENTSTRINGIDNOTFOUND "( %s ) kaynağındaki ( %lu ) olay kimliği için açıklama bulunamıyor. Yerel bilgisayarda, uzak bilgisayardan iletileri görüntülemesi için gerekli Kayıt Defteri bilgisi veya ileti DLL dosyaları olmayabilir.\n\nAşağıdaki bilgi olayın parçasıdır:\n\n"
|
||||
IDS_CONTFROMBEGINNING "You have reached the end of the event log. Do you want to continue from the beginning?"
|
||||
IDS_CONTFROMEND "You have reached the beginning of the event log. Do you want to continue from the end?"
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
|
@@ -169,6 +169,8 @@ BEGIN
|
||||
IDS_CLEAREVENTS_MSG "Do you want to save this event log before clearing it?"
|
||||
IDS_RESTOREDEFAULTS "Do you want to restore all settings for this log to their default values?"
|
||||
IDS_EVENTSTRINGIDNOTFOUND "Опис для Ідентифікатора події ( %lu ) за джерелом ( %s ) не знайдено. Локальний комп'ютер може не мати необхідної інформації в реєстрі чи DLL файлів повідомлень для відображення повідомлень, що надходять від віддаленого комп'ютера.\n\nThe following information is part of the event:\n\n"
|
||||
IDS_CONTFROMBEGINNING "You have reached the end of the event log. Do you want to continue from the beginning?"
|
||||
IDS_CONTFROMEND "You have reached the beginning of the event log. Do you want to continue from the end?"
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
|
@@ -169,6 +169,8 @@ BEGIN
|
||||
IDS_CLEAREVENTS_MSG "你想要在清除之前保存此事件日志吗?"
|
||||
IDS_RESTOREDEFAULTS "你想要将这个日志的所有设置恢复为默认值吗?"
|
||||
IDS_EVENTSTRINGIDNOTFOUND "无法找到来源(%s)中的事件 ID(%lu)的描述。本地计算机可能没有显示来自远程计算机的消息所必需的注册表信息或消息 DLL 文件。\n\n下面的信息是事件的一部分:\n\n"
|
||||
IDS_CONTFROMBEGINNING "You have reached the end of the event log. Do you want to continue from the beginning?"
|
||||
IDS_CONTFROMEND "You have reached the beginning of the event log. Do you want to continue from the end?"
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
|
@@ -168,6 +168,8 @@ BEGIN
|
||||
IDS_CLEAREVENTS_MSG "您想在清除之前儲存這個事件記錄嗎?"
|
||||
IDS_RESTOREDEFAULTS "您要將這個記錄的所有設定還原至預設值嗎?"
|
||||
IDS_EVENTSTRINGIDNOTFOUND "找不到來源(%s)中的事件 ID(%lu)的描述。本地電腦可能沒有顯示來自遠端電腦訊息所需的註冊表資訊或訊息 DLL 檔。\n\n下列資訊是部分事件:\n\n"
|
||||
IDS_CONTFROMBEGINNING "You have reached the end of the event log. Do you want to continue from the beginning?"
|
||||
IDS_CONTFROMEND "You have reached the beginning of the event log. Do you want to continue from the end?"
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
|
@@ -168,6 +168,8 @@ BEGIN
|
||||
IDS_CLEAREVENTS_MSG "您要在清除之前儲存此事件記錄嗎?"
|
||||
IDS_RESTOREDEFAULTS "您要這個記錄的所有設定還原至預設值嗎?"
|
||||
IDS_EVENTSTRINGIDNOTFOUND "找不到來源(%s)中的事件 ID(%lu)的描述。本地電腦可能沒有顯示來自遠端電腦消息所必需的註冊表資訊或消息 DLL 檔。\n\n下列資訊是部分事件︰\n\n"
|
||||
IDS_CONTFROMBEGINNING "You have reached the end of the event log. Do you want to continue from the beginning?"
|
||||
IDS_CONTFROMEND "You have reached the beginning of the event log. Do you want to continue from the end?"
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
|
@@ -105,6 +105,8 @@
|
||||
#define IDS_CLEAREVENTS_MSG 110
|
||||
#define IDS_EVENTSTRINGIDNOTFOUND 111
|
||||
#define IDS_RESTOREDEFAULTS 112
|
||||
#define IDS_CONTFROMBEGINNING 113
|
||||
#define IDS_CONTFROMEND 114
|
||||
|
||||
#define IDS_USAGE 120
|
||||
#define IDS_EVENTLOGFILE 121
|
||||
|
@@ -96,52 +96,52 @@ BEGIN
|
||||
END
|
||||
|
||||
IDD_LOGON DIALOGEX 6, 6, 253, 232
|
||||
CAPTION "Log On"
|
||||
FONT 8, "MS Shell Dlg", 0, 0
|
||||
CAPTION "ログオン"
|
||||
FONT 9, "MS UI Gothic", 0, 0
|
||||
STYLE DS_SHELLFONT | WS_BORDER | WS_VISIBLE | WS_DLGFRAME | WS_SYSMENU | WS_GROUP | WS_TABSTOP
|
||||
BEGIN
|
||||
LTEXT "Log on as:", IDC_STATIC, 7, 7, 238, 8
|
||||
AUTORADIOBUTTON "&Local System account", IDC_LOGON_SYSTEMACCOUNT, 7, 22, 238, 10, BS_TOP | BS_MULTILINE | WS_CHILD | WS_VISIBLE | WS_GROUP | WS_TABSTOP
|
||||
AUTORADIOBUTTON "&This account:", IDC_LOGON_THISACCOUNT, 7, 52, 60, 10, BS_TOP | BS_MULTILINE | WS_CHILD | WS_VISIBLE
|
||||
AUTOCHECKBOX "Allo&w service to interact with desktop", IDC_LOGON_INTERACTIVE, 18, 34, 227, 10, WS_CHILD | WS_VISIBLE | WS_GROUP | WS_TABSTOP | BS_TOP | BS_MULTILINE
|
||||
LTEXT "ログオン ユーザー:", IDC_STATIC, 7, 7, 238, 8
|
||||
AUTORADIOBUTTON "ローカル システム アカウント(&L)", IDC_LOGON_SYSTEMACCOUNT, 7, 22, 238, 10, BS_TOP | BS_MULTILINE | WS_CHILD | WS_VISIBLE | WS_GROUP | WS_TABSTOP
|
||||
AUTORADIOBUTTON "このアカウント(&T):", IDC_LOGON_THISACCOUNT, 7, 52, 60, 10, BS_TOP | BS_MULTILINE | WS_CHILD | WS_VISIBLE
|
||||
AUTOCHECKBOX "サービスがデスクトップと対話できるようにする(&W)", IDC_LOGON_INTERACTIVE, 18, 34, 227, 10, WS_CHILD | WS_VISIBLE | WS_GROUP | WS_TABSTOP | BS_TOP | BS_MULTILINE
|
||||
EDITTEXT IDC_LOGON_ACCOUNTNAME, 72, 50, 103, 14, ES_LEFT | ES_AUTOHSCROLL | WS_CHILD | WS_VISIBLE | WS_BORDER | WS_GROUP | WS_TABSTOP
|
||||
PUSHBUTTON "&Browse...", IDC_LOGON_SEARCH, 185, 50, 60, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP
|
||||
LTEXT "&Password:", IDC_LOGON_PW1TEXT, 18, 71, 33, 8, WS_CHILD | WS_VISIBLE | WS_DISABLED | WS_GROUP
|
||||
PUSHBUTTON "参照(&B)...", IDC_LOGON_SEARCH, 185, 50, 60, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP
|
||||
LTEXT "パスワード(&P):", IDC_LOGON_PW1TEXT, 18, 71, 33, 8, WS_CHILD | WS_VISIBLE | WS_DISABLED | WS_GROUP
|
||||
EDITTEXT IDC_LOGON_PASSWORD1, 72, 68, 104, 14, ES_LEFT | ES_PASSWORD | ES_AUTOHSCROLL | WS_CHILD | WS_VISIBLE | WS_BORDER | WS_TABSTOP
|
||||
LTEXT "&Confirm password:", IDC_LOGON_PW2TEXT, 18, 84, 47, 18, WS_CHILD | WS_VISIBLE | WS_DISABLED | WS_GROUP
|
||||
LTEXT "パスワードの確認(&C):", IDC_LOGON_PW2TEXT, 18, 84, 47, 18, WS_CHILD | WS_VISIBLE | WS_DISABLED | WS_GROUP
|
||||
EDITTEXT IDC_LOGON_PASSWORD2, 72, 86, 104, 14, ES_LEFT | ES_PASSWORD | ES_AUTOHSCROLL | WS_CHILD | WS_VISIBLE | WS_BORDER | WS_TABSTOP
|
||||
LTEXT "You can enable or disable this service for the hardware profiles listed below:", IDC_STATIC, 7, 114, 210, 8, WS_CHILD | WS_VISIBLE | WS_GROUP
|
||||
LTEXT "以下のハードウェア プロファイルに対してこのサービスを有効または無効にすることができます:", IDC_STATIC, 7, 114, 210, 8, WS_CHILD | WS_VISIBLE | WS_GROUP
|
||||
CONTROL "", IDC_LOGON_HWPROFILE, "SysListView32", LVS_REPORT | LVS_SINGLESEL | LVS_SHOWSELALWAYS | LVS_NOSORTHEADER | WS_CHILD | WS_VISIBLE | WS_BORDER | WS_GROUP | WS_TABSTOP, 7, 124, 238, 65
|
||||
PUSHBUTTON "&Enable", IDC_LOGON_HWENABLE, 116, 197, 60, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP | WS_DISABLED
|
||||
PUSHBUTTON "&Disable", IDC_LOGON_HWDISABLE, 185, 197, 60, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP | WS_DISABLED
|
||||
PUSHBUTTON "有効にする(&E)", IDC_LOGON_HWENABLE, 116, 197, 60, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP | WS_DISABLED
|
||||
PUSHBUTTON "無効にする(&D)", IDC_LOGON_HWDISABLE, 185, 197, 60, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP | WS_DISABLED
|
||||
END
|
||||
|
||||
IDD_RECOVERY DIALOGEX 6, 6, 253, 232
|
||||
CAPTION "Recovery"
|
||||
FONT 8, "MS Shell Dlg", 0, 0
|
||||
CAPTION "回復"
|
||||
FONT 9, "MS UI Gothic", 0, 0
|
||||
STYLE DS_SHELLFONT | WS_BORDER | WS_VISIBLE | WS_DLGFRAME | WS_SYSMENU | WS_GROUP | WS_TABSTOP
|
||||
BEGIN
|
||||
LTEXT "Select the computer's response if this service fails.", IDC_STATIC, 7, 7, 238, 8
|
||||
LTEXT "&First failure:", IDC_STATIC, 7, 24, 92, 8
|
||||
LTEXT "このサービスが失敗した場合のコンピュータの応答を選択します。", IDC_STATIC, 7, 7, 238, 8
|
||||
LTEXT "最初の失敗(&F):", IDC_STATIC, 7, 24, 92, 8
|
||||
COMBOBOX IDC_FIRST_FAILURE, 104, 22, 141, 147, WS_CHILD | WS_VISIBLE | WS_TABSTOP | CBS_DROPDOWNLIST
|
||||
LTEXT "&Second failure:", IDC_STATIC, 7, 41, 92, 8
|
||||
LTEXT "二番目の失敗(&S):", IDC_STATIC, 7, 41, 92, 8
|
||||
COMBOBOX IDC_SECOND_FAILURE, 104, 39, 141, 147, WS_CHILD | WS_VISIBLE | WS_TABSTOP | CBS_DROPDOWNLIST
|
||||
LTEXT "Subsequent failures:", IDC_STATIC, 7, 58, 92, 8
|
||||
LTEXT "その後の失敗:", IDC_STATIC, 7, 58, 92, 8
|
||||
COMBOBOX IDC_SUBSEQUENT_FAILURES, 104, 56, 141, 147, WS_CHILD | WS_VISIBLE | WS_TABSTOP | CBS_DROPDOWNLIST
|
||||
LTEXT "Reset fail c&ounter after:", IDC_STATIC, 7, 75, 72, 8
|
||||
LTEXT "失敗カウンタのリセット(&O):", IDC_STATIC, 7, 75, 72, 8
|
||||
EDITTEXT IDC_RESET_TIME, 104, 73, 40, 13, WS_CHILD | WS_VISIBLE | WS_BORDER | WS_TABSTOP | ES_LEFT | ES_AUTOHSCROLL | ES_NUMBER
|
||||
LTEXT "days", IDC_STATIC, 150, 75, 95, 8
|
||||
LTEXT "Restart ser&vice after:", IDC_RESTART_TEXT1, 7, 92, 92, 8
|
||||
LTEXT "日後", IDC_STATIC, 150, 75, 95, 8
|
||||
LTEXT "サービスの再開(&V):", IDC_RESTART_TEXT1, 7, 92, 92, 8
|
||||
EDITTEXT IDC_RESTART_TIME, 104, 90, 40, 13, WS_CHILD | WS_VISIBLE | WS_BORDER | WS_TABSTOP | ES_LEFT | ES_AUTOHSCROLL | ES_NUMBER
|
||||
LTEXT "minutes", IDC_RESTART_TEXT2, 150, 92, 95, 8
|
||||
GROUPBOX "Run program", IDC_RUN_GROUPBOX, 7, 108, 238, 80
|
||||
LTEXT "&Program:", IDC_RUN_TEXT1, 14, 121, 168, 8
|
||||
LTEXT "分後", IDC_RESTART_TEXT2, 150, 92, 95, 8
|
||||
GROUPBOX "プログラムを実行する", IDC_RUN_GROUPBOX, 7, 108, 238, 80
|
||||
LTEXT "プログラム(&P):", IDC_RUN_TEXT1, 14, 121, 168, 8
|
||||
EDITTEXT IDC_PROGRAM, 14, 131, 165, 14
|
||||
PUSHBUTTON "&Browse...", IDC_BROWSE_PROGRAM, 180, 131, 58, 14
|
||||
LTEXT "&Command line parameters:", IDC_RUN_TEXT2, 14, 155, 108, 8
|
||||
PUSHBUTTON "参照(&B)...", IDC_BROWSE_PROGRAM, 180, 131, 58, 14
|
||||
LTEXT "コマンドライン引数(&C):", IDC_RUN_TEXT2, 14, 155, 108, 8
|
||||
EDITTEXT IDC_PARAMETERS, 128, 152, 110, 14
|
||||
AUTOCHECKBOX "Append fail count to &end of command line (/fail=%1%)", IDC_ADD_FAILCOUNT, 14, 171, 219, 10, WS_CHILD | WS_VISIBLE | WS_TABSTOP | BS_TOP | BS_MULTILINE
|
||||
PUSHBUTTON "&Restart Computer Options...", IDC_RESTART_OPTIONS, 116, 197, 129, 14
|
||||
AUTOCHECKBOX "失敗回数をコマンドラインの末尾に追加する(&E) (/fail=%1%)", IDC_ADD_FAILCOUNT, 14, 171, 219, 10, WS_CHILD | WS_VISIBLE | WS_TABSTOP | BS_TOP | BS_MULTILINE
|
||||
PUSHBUTTON "コンピュータの再起動オプション(&R)...", IDC_RESTART_OPTIONS, 116, 197, 129, 14
|
||||
END
|
||||
|
||||
IDD_DLG_DEPEND DIALOGEX 6, 6, 253, 225
|
||||
@@ -324,14 +324,14 @@ END
|
||||
|
||||
STRINGTABLE
|
||||
BEGIN
|
||||
IDS_NO_ACTION "Take no action"
|
||||
IDS_RESTART_SERVICE "Restart the Service"
|
||||
IDS_RUN_PROGRAM "Run a Program"
|
||||
IDS_RESTART_COMPUTER "Restart the Computer"
|
||||
IDS_NO_ACTION "何もしない"
|
||||
IDS_RESTART_SERVICE "サービスを再起動する"
|
||||
IDS_RUN_PROGRAM "プログラムを実行する"
|
||||
IDS_RESTART_COMPUTER "コンピュータを再起動"
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
BEGIN
|
||||
IDS_NOT_SAME_PASSWORD "The Passwords are not the same!"
|
||||
IDS_INVALID_PASSWORD "Enter a valid Password!"
|
||||
IDS_NOT_SAME_PASSWORD "パスワードが同じではありません!"
|
||||
IDS_INVALID_PASSWORD "有効なパスワードを入力してください。"
|
||||
END
|
||||
|
@@ -16,16 +16,11 @@ CCanvasWindow::CCanvasWindow()
|
||||
, m_hitCanvasSizeBox(HIT_NONE)
|
||||
, m_ptOrig { -1, -1 }
|
||||
{
|
||||
m_ahbmCached[0] = m_ahbmCached[1] = NULL;
|
||||
m_rcResizing.SetRectEmpty();
|
||||
}
|
||||
|
||||
CCanvasWindow::~CCanvasWindow()
|
||||
{
|
||||
if (m_ahbmCached[0])
|
||||
::DeleteObject(m_ahbmCached[0]);
|
||||
if (m_ahbmCached[1])
|
||||
::DeleteObject(m_ahbmCached[1]);
|
||||
}
|
||||
|
||||
RECT CCanvasWindow::GetBaseRect()
|
||||
@@ -119,16 +114,30 @@ VOID CCanvasWindow::zoomTo(INT newZoom, LONG left, LONG top)
|
||||
Invalidate(TRUE);
|
||||
}
|
||||
|
||||
VOID CCanvasWindow::DoDraw(HDC hDC, RECT& rcClient, RECT& rcPaint)
|
||||
BOOL CCanvasWindow::DoDraw(HDC hDC, RECT& rcClient, RECT& rcPaint)
|
||||
{
|
||||
// This is the target area we have to draw on
|
||||
CRect rcCanvasDraw;
|
||||
rcCanvasDraw.IntersectRect(&rcClient, &rcPaint);
|
||||
|
||||
// Calculate image size
|
||||
CRect rcImage;
|
||||
GetImageRect(rcImage);
|
||||
SIZE sizeImage = { imageModel.GetWidth(), imageModel.GetHeight() };
|
||||
|
||||
// We use a memory bitmap to reduce flickering
|
||||
HBITMAP hbmCache1 = CreateDIBWithProperties(rcClient.right, rcClient.bottom);
|
||||
if (!hbmCache1)
|
||||
return FALSE; // Out of memory
|
||||
HBITMAP hbmCache2 = CreateDIBWithProperties(sizeImage.cx, sizeImage.cy);
|
||||
if (!hbmCache2)
|
||||
{
|
||||
::DeleteObject(hbmCache1);
|
||||
return FALSE; // Out of memory
|
||||
}
|
||||
|
||||
HDC hdcMem0 = ::CreateCompatibleDC(hDC);
|
||||
m_ahbmCached[0] = CachedBufferDIB(m_ahbmCached[0], rcClient.right, rcClient.bottom);
|
||||
HGDIOBJ hbm0Old = ::SelectObject(hdcMem0, m_ahbmCached[0]);
|
||||
HGDIOBJ hbm0Old = ::SelectObject(hdcMem0, hbmCache1);
|
||||
|
||||
// Fill the background on hdcMem0
|
||||
::FillRect(hdcMem0, &rcCanvasDraw, (HBRUSH)(COLOR_APPWORKSPACE + 1));
|
||||
@@ -138,11 +147,6 @@ VOID CCanvasWindow::DoDraw(HDC hDC, RECT& rcClient, RECT& rcPaint)
|
||||
if (!selectionModel.m_bShow && !::IsWindowVisible(textEditWindow))
|
||||
drawSizeBoxes(hdcMem0, &rcBase, FALSE, &rcCanvasDraw);
|
||||
|
||||
// Calculate image size
|
||||
CRect rcImage;
|
||||
GetImageRect(rcImage);
|
||||
SIZE sizeImage = { imageModel.GetWidth(), imageModel.GetHeight() };
|
||||
|
||||
// Calculate the target area on the image
|
||||
CRect rcImageDraw = rcCanvasDraw;
|
||||
CanvasToImage(rcImageDraw);
|
||||
@@ -154,8 +158,7 @@ VOID CCanvasWindow::DoDraw(HDC hDC, RECT& rcClient, RECT& rcPaint)
|
||||
|
||||
// hdcMem1 <-- imageModel
|
||||
HDC hdcMem1 = ::CreateCompatibleDC(hDC);
|
||||
m_ahbmCached[1] = CachedBufferDIB(m_ahbmCached[1], sizeImage.cx, sizeImage.cy);
|
||||
HGDIOBJ hbm1Old = ::SelectObject(hdcMem1, m_ahbmCached[1]);
|
||||
HGDIOBJ hbm1Old = ::SelectObject(hdcMem1, hbmCache2);
|
||||
::BitBlt(hdcMem1, rcImageDraw.left, rcImageDraw.top, rcImageDraw.Width(), rcImageDraw.Height(),
|
||||
imageModel.GetDC(), rcImageDraw.left, rcImageDraw.top, SRCCOPY);
|
||||
|
||||
@@ -208,6 +211,10 @@ VOID CCanvasWindow::DoDraw(HDC hDC, RECT& rcClient, RECT& rcPaint)
|
||||
// Clean up hdcMem0
|
||||
::SelectObject(hdcMem0, hbm0Old);
|
||||
::DeleteDC(hdcMem0);
|
||||
::DeleteObject(hbmCache2);
|
||||
::DeleteObject(hbmCache1);
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
VOID CCanvasWindow::updateScrollRange()
|
||||
@@ -691,9 +698,22 @@ LRESULT CCanvasWindow::OnPaint(UINT nMsg, WPARAM wParam, LPARAM lParam, BOOL& bH
|
||||
RECT rcClient;
|
||||
GetClientRect(&rcClient);
|
||||
|
||||
static BOOL s_bShowedOutOfMemory = FALSE; // Don't show "Out Of Memory" message multiple time
|
||||
|
||||
PAINTSTRUCT ps;
|
||||
HDC hDC = BeginPaint(&ps);
|
||||
DoDraw(hDC, rcClient, ps.rcPaint);
|
||||
|
||||
if (DoDraw(hDC, rcClient, ps.rcPaint))
|
||||
{
|
||||
s_bShowedOutOfMemory = FALSE;
|
||||
}
|
||||
else if (!s_bShowedOutOfMemory)
|
||||
{
|
||||
ShowOutOfMemory();
|
||||
s_bShowedOutOfMemory = TRUE;
|
||||
imageModel.ClearHistory(); // Reduce memory usage
|
||||
}
|
||||
|
||||
EndPaint(&ps);
|
||||
return 0;
|
||||
}
|
||||
|
@@ -57,12 +57,11 @@ public:
|
||||
protected:
|
||||
HITTEST m_hitCanvasSizeBox;
|
||||
POINT m_ptOrig; // The origin of drag start
|
||||
HBITMAP m_ahbmCached[2]; // The cached buffer bitmaps
|
||||
CRect m_rcResizing; // Resizing rectagle
|
||||
|
||||
HITTEST CanvasHitTest(POINT pt);
|
||||
RECT GetBaseRect();
|
||||
VOID DoDraw(HDC hDC, RECT& rcClient, RECT& rcPaint);
|
||||
BOOL DoDraw(HDC hDC, RECT& rcClient, RECT& rcPaint);
|
||||
VOID OnHVScroll(WPARAM wParam, INT fnBar);
|
||||
|
||||
LRESULT OnSize(UINT nMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled);
|
||||
|
@@ -230,6 +230,7 @@ HBITMAP InitializeImage(LPCWSTR name, LPWIN32_FIND_DATAW pFound, BOOL isFile)
|
||||
if (hBitmap == NULL)
|
||||
{
|
||||
ShowOutOfMemory();
|
||||
imageModel.ClearHistory();
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
@@ -130,6 +130,7 @@ void ImageModel::PushImageForUndo()
|
||||
if (hbm == NULL)
|
||||
{
|
||||
ShowOutOfMemory();
|
||||
ClearHistory();
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -143,6 +144,7 @@ void ImageModel::PushImageForUndo(HBITMAP hbm)
|
||||
if (hbm == NULL)
|
||||
{
|
||||
ShowOutOfMemory();
|
||||
ClearHistory();
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -201,6 +203,7 @@ void ImageModel::Crop(int nWidth, int nHeight, int nOffsetX, int nOffsetY)
|
||||
if (!hbmNew)
|
||||
{
|
||||
ShowOutOfMemory();
|
||||
ClearHistory();
|
||||
return;
|
||||
}
|
||||
|
||||
|
@@ -44,7 +44,7 @@ BEGIN
|
||||
MENUITEM "&Copier\tCtrl+C", IDM_EDITCOPY
|
||||
MENUITEM "C&oller\tCtrl+V", IDM_EDITPASTE
|
||||
MENUITEM SEPARATOR
|
||||
MENUITEM "Crop &selection", IDM_CROPSELECTION
|
||||
MENUITEM "Ro&gner la sélection", IDM_CROPSELECTION
|
||||
MENUITEM "&Effacer la sélection\tDel", IDM_EDITDELETESELECTION
|
||||
MENUITEM "&Inverser la sélection", IDM_EDITINVERTSELECTION
|
||||
MENUITEM "&Sélectionner tout\tCtrl+A", IDM_EDITSELECTALL
|
||||
@@ -110,7 +110,7 @@ BEGIN
|
||||
MENUITEM "&Copier\tCtrl+C", IDM_EDITCOPY
|
||||
MENUITEM "C&oller\tCtrl+V", IDM_EDITPASTE
|
||||
MENUITEM SEPARATOR
|
||||
MENUITEM "Crop &selection", IDM_CROPSELECTION
|
||||
MENUITEM "Ro&gner la sélection", IDM_CROPSELECTION
|
||||
MENUITEM "&Effacer la sélection\tDel", IDM_EDITDELETESELECTION
|
||||
MENUITEM "&Sélectionner tout\tCtrl+A", IDM_EDITSELECTALL
|
||||
MENUITEM SEPARATOR
|
||||
@@ -269,8 +269,8 @@ BEGIN
|
||||
IDS_UNDERLINE "Underline"
|
||||
IDS_VERTICAL "Vertical"
|
||||
IDS_PRINTRES "%d x %d pixel/cm"
|
||||
IDS_CANTPASTE "Failed to paste from the clipboard. The data format is either incorrect or not supported."
|
||||
IDS_SAVEERROR "Failed to save the bitmap to file:\n\n%s"
|
||||
IDS_CANTSENDMAIL "Failed to send a mail."
|
||||
IDS_LOSECOLOR "The color information will be lost in this operation. Are you sure to proceed?"
|
||||
IDS_CANTPASTE "Échec lors de la copie depuis le presse-papiers. Les données sont soit incorrectes soit non supportées."
|
||||
IDS_SAVEERROR "Échec lors de la sauvegarde dans le fichier :\n\n%s"
|
||||
IDS_CANTSENDMAIL "Échec lors de l'envoi d'un mail."
|
||||
IDS_LOSECOLOR "Les informations de couleurs vont être perdues dans cette opération. Êtes-vous sûr de continuer ?"
|
||||
END
|
||||
|
@@ -957,9 +957,14 @@ LRESULT CMainWindow::OnCommand(UINT nMsg, WPARAM wParam, LPARAM lParam, BOOL& bH
|
||||
HBITMAP hbmCopy = selectionModel.GetSelectionContents();
|
||||
HGLOBAL hGlobal = BitmapToClipboardDIB(hbmCopy);
|
||||
if (hGlobal)
|
||||
{
|
||||
::SetClipboardData(CF_DIB, hGlobal);
|
||||
}
|
||||
else
|
||||
{
|
||||
ShowOutOfMemory();
|
||||
imageModel.ClearHistory();
|
||||
}
|
||||
::DeleteObject(hbmCopy);
|
||||
}
|
||||
|
||||
@@ -1093,6 +1098,7 @@ LRESULT CMainWindow::OnCommand(UINT nMsg, WPARAM wParam, LPARAM lParam, BOOL& bH
|
||||
if (!hbmSelection)
|
||||
{
|
||||
ShowOutOfMemory();
|
||||
imageModel.ClearHistory();
|
||||
break;
|
||||
}
|
||||
SaveDIBToFile(hbmSelection, szFileName, FALSE);
|
||||
|
@@ -55,7 +55,7 @@ BEGIN
|
||||
IDS_HIGHCOLOR15 "32,768 Couleurs (15 bit)"
|
||||
IDS_HIGHCOLOR16 "65,536 Couleurs (16 bit)"
|
||||
IDS_HIGHCOLOR24 "16,777,216 Couleurs (24 bit)"
|
||||
IDS_HIGHCOLOR32 "Highest Quality (32 bit)"
|
||||
IDS_HIGHCOLOR32 "La plus haute qualité (32 bit)"
|
||||
IDS_PIXEL "%lux%lu Pixels"
|
||||
IDS_FULLSCREEN "Plein écran"
|
||||
IDS_BROWSESERVER "<Parcourir pour plus...>"
|
||||
|
@@ -32,7 +32,7 @@ Options :\n\
|
||||
IDS_CTRL_C "Ctrl-C\n"
|
||||
IDS_NO_RESOURCES "Ressources libres disponibles insuffisantes.\n"
|
||||
IDS_MISSING_ADDRESS "L'adresse IP doit être spécifiée.\n"
|
||||
IDS_MISSING_VALUE "Une valeur doit être spécifie pour l'option %s.\n"
|
||||
IDS_MISSING_VALUE "Une valeur doit être spécifiée pour l'option %s.\n"
|
||||
IDS_BAD_OPTION "Option incorrecte %s.\n"
|
||||
IDS_BAD_PARAMETER "Paramètre incorrect %s.\n"
|
||||
IDS_BAD_VALUE "Valeur incorrecte pour l'option %s, elle doit être entre %u et %u.\n"
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user