OWLNext    7.0
Borland's Object Windows Library for the modern age
Loading...
Searching...
No Matches
shelwapi.cpp
Go to the documentation of this file.
1//----------------------------------------------------------------------------
2// ObjectWindows
3// Copyright (c) 1995, 1996 by Borland International, All Rights Reserved
4//
5/// \file
6/// Implementations of Windows light-weight utility APIs:
7/// TSHReg, TSHPath
8//----------------------------------------------------------------------------
9#include <owl/pch.h>
10#include <owl/defs.h>
11#include <owl/shelwapi.h>
12#include <owl/module.h>
13
14namespace owl {
15
16////////////////////////////////////////////////////////////////////
17//
18// class TSHReg
19// ~~~~~ ~~~~~~
20// delay loading SHLWAPI.DLL
21 static const tchar shellStr[] = _T("SHLWAPI.DLL");
22
23 static const char DuplicateKeyStr[] = "SHRegDuplicateHKey";
24# if defined(UNICODE)
25 static const char DeleteEmptyKeyStr[] = "SHDeleteEmptyKeyW";
26 static const char DeleteKeyStr[] = "SHDeleteKeyW";
27 static const char DeleteValueStr[] = "SHDeleteValueW";
28 static const char GetValueStr[] = "SHGetValueW";
29 static const char SetValueStr[] = "SHSetValueW";
30 static const char QueryValueExStr[] = "SHQueryValueExW";
31 static const char EnumKeyExStr[] = "SHEnumKeyExW";
32 static const char EnumValueStr[] = "SHEnumValueW";
33 static const char QueryInfoKeyStr[] = "SHQueryInfoKeyW";
34 static const char CopyKeyStr[] = "SHCopyKeyW";
35 static const char RegGetPathStr[] = "SHRegGetPathW";
36 static const char RegSetPathStr[] = "SHRegSetPathW";
37# else
38 static const char DeleteEmptyKeyStr[] = "SHDeleteEmptyKeyA";
39 static const char DeleteKeyStr[] = "SHDeleteKeyA";
40 static const char DeleteValueStr[] = "SHDeleteValueA";
41 static const char GetValueStr[] = "SHGetValueA";
42 static const char SetValueStr[] = "SHSetValueA";
43 static const char QueryValueExStr[] = "SHQueryValueExA";
44 static const char EnumKeyExStr[] = "SHEnumKeyExA";
45 static const char EnumValueStr[] = "SHEnumValueA";
46 static const char QueryInfoKeyStr[] = "SHQueryInfoKeyA";
47 static const char CopyKeyStr[] = "SHCopyKeyA";
48 static const char RegGetPathStr[] = "SHRegGetPathA";
49 static const char RegSetPathStr[] = "SHRegSetPathA";
50# endif
51
52
53//
54// Returns TModule object wrapping the handle of the SHLWAPI.DLL module
55//
56TModule&
58{
59 static TModule shellModule(shellStr, true, true, false);
60 return shellModule;
61}
62
70
78
79HKEY
81{
83 duplicateKey(GetModule(), DuplicateKeyStr);
84 return duplicateKey(hkey);
85}
86
94
102
103DWORD
110
111DWORD
118
119LONG
126
127LONG
134
135LONG
142
143// recursive key copy
144DWORD
151
152// Getting and setting file system paths with environment variables
153DWORD
160
161DWORD
168
169////////////////////////////////////////////////////////////////////
170//
171// class TSHPath
172// ~~~~~ ~~~~~~
173
174# if defined(UNICODE)
175 static const char AddBackslashStr[] = "PathAddBackslashW";
176 static const char AddExtensionStr[] = "PathAddExtensionW";
177 static const char AppendStr[] = "PathAppendW";
178 static const char BuildRootStr[] = "PathBuildRootW";
179 static const char CanonicalizeStr[] = "PathCanonicalizeW";
180 static const char CombineStr[] = "PathCombineW";
181 static const char CompactPathStr[] = "PathCompactPathW";
182 static const char CompactPathExStr[] = "PathCompactPathExW";
183 static const char CommonPrefixStr[] = "PathCommonPrefixW";
184 static const char FileExistsStr[] = "PathFileExistsW";
185 static const char FindExtensionStr[] = "PathFindExtensionW";
186 static const char FindFileNameStr[] = "PathFindFileNameW";
187 static const char FindNextComponentStr[] = "PathFindNextComponentW";
188 static const char FindOnPathStr[] = "PathFindOnPathW";
189 static const char GetArgsStr[] = "PathGetArgsW";
190 static const char FindSuffixArrayStr[] = "PathFindSuffixArrayW";
191 static const char IsLFNFileSpecStr[] = "PathIsLFNFileSpecW";
192 static const char GetCharTypeStr[] = "PathGetCharTypeW";
193 static const char GetDriveNumberStr[] = "PathGetDriveNumberW";
194 static const char IsDirectoryStr[] = "PathIsDirectoryW";
195 static const char IsDirectoryEmptyStr[] = "PathIsDirectoryEmptyW";
196 static const char IsFileSpecStr[] = "PathIsFileSpecW";
197 static const char IsPrefixStr[] = "PathIsPrefixW";
198 static const char IsRelativeStr[] = "PathIsRelativeW";
199 static const char IsRootStr[] = "PathIsRootW";
200 static const char IsSameRootStr[] = "PathIsSameRootW";
201 static const char IsUNCStr[] = "PathIsUNCW";
202 static const char IsNetworkPathStr[] = "PathIsNetworkPathW";
203 static const char IsUNCServerStr[] = "PathIsUNCServerW";
204 static const char IsUNCServerShareStr[] = "PathIsUNCServerShareW";
205 static const char IsContentTypeStr[] = "PathIsContentTypeW";
206 static const char IsURLStr[] = "PathIsURLW";
207 static const char MakePrettyStr[] = "PathMakePrettyW";
208 static const char MatchSpecStr[] = "PathMatchSpecW";
209 static const char ParseIconLocationStr[] = "PathParseIconLocationW";
210 static const char QuoteSpacesStr[] = "PathQuoteSpacesW";
211 static const char RelativePathToStr[] = "PathRelativePathToW";
212 static const char RemoveArgsStr[] = "PathRemoveArgsW";
213 static const char RemoveBackslashStr[] = "PathRemoveBackslashW";
214 static const char RemoveBlanksStr[] = "PathRemoveBlanksW";
215 static const char RemoveExtensionStr[] = "PathRemoveExtensionW";
216 static const char RemoveFileSpecStr[] = "PathRemoveFileSpecW";
217 static const char RenameExtensionStr[] = "PathRenameExtensionW";
218 static const char SearchAndQualifyStr[] = "PathSearchAndQualifyW";
219 static const char SetDlgItemPathStr[] = "PathSetDlgItemPathW";
220 static const char SkipRootStr[] = "PathSkipRootW";
221 static const char StripPathStr[] = "PathStripPathW";
222 static const char StripToRootStr[] = "PathStripToRootW";
223 static const char UnquoteSpacesStr[] = "PathUnquoteSpacesW";
224 static const char MakeSystemFolderStr[] = "PathMakeSystemFolderW";
225 static const char UnmakeSystemFolderStr[] = "PathUnmakeSystemFolderW";
226 static const char IsSystemFolderStr[] = "PathIsSystemFolderW";
227 static const char UndecorateStr[] = "PathUndecorateW";
228 static const char UnExpandEnvStringsStr[] = "PathUnExpandEnvStringsW";
229 static const char UnExpandEnvStringsForUserStr[] = "PathUnExpandEnvStringsForUserW";
230# else
231 static const char AddBackslashStr[] = "PathAddBackslashA";
232 static const char AddExtensionStr[] = "PathAddExtensionA";
233 static const char AppendStr[] = "PathAppendA";
234 static const char BuildRootStr[] = "PathBuildRootA";
235 static const char CanonicalizeStr[] = "PathCanonicalizeA";
236 static const char CombineStr[] = "PathCombineA";
237 static const char CompactPathStr[] = "PathCompactPathA";
238 static const char CompactPathExStr[] = "PathCompactPathExA";
239 static const char CommonPrefixStr[] = "PathCommonPrefixA";
240 static const char FileExistsStr[] = "PathFileExistsA";
241 static const char FindExtensionStr[] = "PathFindExtensionA";
242 static const char FindFileNameStr[] = "PathFindFileNameA";
243 static const char FindNextComponentStr[] = "PathFindNextComponentA";
244 static const char FindOnPathStr[] = "PathFindOnPathA";
245 static const char GetArgsStr[] = "PathGetArgsA";
246 static const char FindSuffixArrayStr[] = "PathFindSuffixArrayA";
247 static const char IsLFNFileSpecStr[] = "PathIsLFNFileSpecA";
248 static const char GetCharTypeStr[] = "PathGetCharTypeA";
249 static const char GetDriveNumberStr[] = "PathGetDriveNumberA";
250 static const char IsDirectoryStr[] = "PathIsDirectoryA";
251 static const char IsDirectoryEmptyStr[] = "PathIsDirectoryEmptyA";
252 static const char IsFileSpecStr[] = "PathIsFileSpecA";
253 static const char IsPrefixStr[] = "PathIsPrefixA";
254 static const char IsRelativeStr[] = "PathIsRelativeA";
255 static const char IsRootStr[] = "PathIsRootA";
256 static const char IsSameRootStr[] = "PathIsSameRootA";
257 static const char IsUNCStr[] = "PathIsUNCA";
258 static const char IsNetworkPathStr[] = "PathIsNetworkPathA";
259 static const char IsUNCServerStr[] = "PathIsUNCServerA";
260 static const char IsUNCServerShareStr[] = "PathIsUNCServerShareA";
261 static const char IsContentTypeStr[] = "PathIsContentTypeA";
262 static const char IsURLStr[] = "PathIsURLA";
263 static const char MakePrettyStr[] = "PathMakePrettyA";
264 static const char MatchSpecStr[] = "PathMatchSpecA";
265 static const char ParseIconLocationStr[] = "PathParseIconLocationA";
266 static const char QuoteSpacesStr[] = "PathQuoteSpacesA";
267 static const char RelativePathToStr[] = "PathRelativePathToA";
268 static const char RemoveArgsStr[] = "PathRemoveArgsA";
269 static const char RemoveBackslashStr[] = "PathRemoveBackslashA";
270 static const char RemoveBlanksStr[] = "PathRemoveBlanksA";
271 static const char RemoveExtensionStr[] = "PathRemoveExtensionA";
272 static const char RemoveFileSpecStr[] = "PathRemoveFileSpecA";
273 static const char RenameExtensionStr[] = "PathRenameExtensionA";
274 static const char SearchAndQualifyStr[] = "PathSearchAndQualifyA";
275 static const char SetDlgItemPathStr[] = "PathSetDlgItemPathA";
276 static const char SkipRootStr[] = "PathSkipRootA";
277 static const char StripPathStr[] = "PathStripPathA";
278 static const char StripToRootStr[] = "PathStripToRootA";
279 static const char UnquoteSpacesStr[] = "PathUnquoteSpacesA";
280 static const char MakeSystemFolderStr[] = "PathMakeSystemFolderA";
281 static const char UnmakeSystemFolderStr[] = "PathUnmakeSystemFolderA";
282 static const char IsSystemFolderStr[] = "PathIsSystemFolderA";
283 static const char UndecorateStr[] = "PathUndecorateA";
284 static const char UnExpandEnvStringsStr[] = "PathUnExpandEnvStringsA";
285 static const char UnExpandEnvStringsForUserStr[] = "PathUnExpandEnvStringsForUserA";
286# endif
287
288
289//
290// Returns TModule object wrapping the handle of the SHLWAPI.DLL module
291//
292TModule&
294{
295 static TModule shellModule(shellStr, true, true, false);
296 return shellModule;
297}
298
299LPTSTR
306
307BOOL
314
315BOOL
322
323LPTSTR
330
331BOOL
338
339LPTSTR
346
347BOOL
354
355BOOL
362
363int
370
371BOOL
373{
375 fileExists(GetModule(), FileExistsStr);
376 return fileExists(pszPath);
377}
378
379LPTSTR
386
387LPTSTR
394
395LPTSTR
402
403BOOL
410
411LPTSTR
413{
415 getArgs(GetModule(), GetArgsStr);
416 return getArgs(pszPath);
417}
418
426
427BOOL
434
435UINT
437{
439 getCharType(GetModule(), GetCharTypeStr);
440 return getCharType(ch);
441}
442
443int
450
451BOOL
458
459BOOL
466
467BOOL
469{
471 isFileSpec(GetModule(), IsFileSpecStr);
472 return isFileSpec(pszPath);
473}
474
475BOOL
482
483BOOL
485{
487 isRelative(GetModule(), IsRelativeStr);
488 return isRelative(pszPath);
489}
490
491BOOL
493{
495 isRoot(GetModule(), IsRootStr);
496 return isRoot(pszPath);
497}
498
499BOOL
506
507BOOL
509{
511 isUNC(GetModule(), IsUNCStr);
512 return isUNC(pszPath);
513}
514
515BOOL
522
523BOOL
530
531BOOL
538
539BOOL
546
547BOOL
549{
551 isURL(GetModule(), IsURLStr);
552 return isURL(pszPath);
553}
554
555BOOL
557{
559 makePretty(GetModule(), MakePrettyStr);
560 return makePretty(pszPath);
561}
562
563BOOL
570
571int
578
579void
581{
583 quoteSpaces(GetModule(), QuoteSpacesStr);
585}
586
587BOOL
594
595void
602
603LPTSTR
610
611void
618
619void
626
627BOOL
634
635BOOL
642
643BOOL
650
651void
658
659LPTSTR
661{
663 skipRoot(GetModule(), SkipRootStr);
664 return skipRoot(pszPath);
665}
666
667void
674
675BOOL
677{
679 stripToRoot(GetModule(), StripToRootStr);
680 return stripToRoot(pszPath);
681}
682
683void
690
691BOOL
698
699BOOL
706
707BOOL
714
715void
722
723
724BOOL
731
732BOOL
739
740} // OWL namespace
741/* ========================================================================== */
742
ObjectWindows dynamic-link libraries (DLLs) construct an instance of TModule, which acts as an object...
Definition module.h:75
static BOOL UnExpandEnvStrings(LPCTSTR pszPath, TCHAR *pszBuf, UINT cchBuf)
Takes a fully qualified path, and replaces several folder names with their associated environment str...
Definition shelwapi.cpp:725
static BOOL IsSystemFolder(LPCTSTR pszPath, DWORD dwAttrb)
Determines if an existing folder contains the attributes that make it a system folder.
Definition shelwapi.cpp:708
static BOOL IsPrefix(LPCTSTR pszPrefix, LPCTSTR pszPath)
Searches a path to determine if it contains a valid prefix of the type passed by pszPrefix.
Definition shelwapi.cpp:476
static void RemoveBlanks(TCHAR *pszPath)
Removes all leading and trailing spaces from a string.
Definition shelwapi.cpp:612
static BOOL FindOnPath(TCHAR *pszPath, LPCTSTR *ppszOtherDirs)
Searches for a file.
Definition shelwapi.cpp:404
static BOOL StripToRoot(TCHAR *pszPath)
Removes all parts of the path except for the root information.
Definition shelwapi.cpp:676
static BOOL RelativePathTo(TCHAR *pszPath, LPCTSTR pszFrom, DWORD dwAttrFrom, LPCTSTR pszTo, DWORD dwAttrTo)
Creates a relative path from one file or folder to another.
Definition shelwapi.cpp:588
static TCHAR * FindExtension(LPCTSTR pszPath)
Searches a path for an extension.
Definition shelwapi.cpp:380
static BOOL IsLFNFileSpec(LPCTSTR lpName)
Determines whether or not a file name is in long format.
Definition shelwapi.cpp:428
static BOOL IsNetworkPath(LPCTSTR pszPath)
Determines whether a path string represents a network resource.
Definition shelwapi.cpp:516
static TCHAR * FindNextComponent(LPCTSTR pszPath)
Parses a path for the next path component.
Definition shelwapi.cpp:396
static int ParseIconLocation(TCHAR *pszIconFile)
Parses a file location string containing a file location and icon index, and returns separate values.
Definition shelwapi.cpp:572
static void SetDlgItemPath(HWND hDlg, int id, LPCTSTR pszPath)
Sets the text of a child control in a window or dialog box, using PathCompactPath to make sure the pa...
Definition shelwapi.cpp:652
static BOOL MatchSpec(LPCTSTR pszFile, LPCTSTR pszSpec)
Searches a string using a DOS wild card match type.
Definition shelwapi.cpp:564
static BOOL IsUNCServer(LPCTSTR pszPath)
Determines if a string is a valid UNC (universal naming convention) for a server path only.
Definition shelwapi.cpp:524
static void RemoveArgs(TCHAR *pszPath)
Removes any arguments from a given path.
Definition shelwapi.cpp:596
static BOOL AddExtension(TCHAR *pszPath, LPCTSTR pszExt)
Adds a file extension to a path string.
Definition shelwapi.cpp:308
static void RemoveExtension(TCHAR *pszPath)
Removes the file extension from a path, if there is one.
Definition shelwapi.cpp:620
static BOOL UnExpandEnvStringsForUser(HANDLE hToken, LPCTSTR pszPath, TCHAR *pszBuf, UINT cchBuf)
Definition shelwapi.cpp:733
static int GetDriveNumber(LPCTSTR pszPath)
Searches a path for a drive letter within the range of 'A' to 'Z' and returns the corresponding drive...
Definition shelwapi.cpp:444
static void QuoteSpaces(TCHAR *lpsz)
Searches a path for spaces.
Definition shelwapi.cpp:580
static int CommonPrefix(LPCTSTR pszFile1, LPCTSTR pszFile2, TCHAR *achPath)
Compares two paths to determine if they share a common prefix.
Definition shelwapi.cpp:364
static void UnquoteSpaces(TCHAR *lpsz)
Removes quotes from the beginning and end of a path.
Definition shelwapi.cpp:684
static TModule & GetModule()
Definition shelwapi.cpp:293
static void Undecorate(TCHAR *pszPath)
Removes the decoration from a path string.
Definition shelwapi.cpp:716
static TCHAR * SkipRoot(LPCTSTR pszPath)
Parses a path, ignoring the drive letter or UNC server/share path parts.
Definition shelwapi.cpp:660
static TCHAR * BuildRoot(TCHAR *pszRoot, int iDrive)
Creates a root path from a given drive number.
Definition shelwapi.cpp:324
static BOOL MakePretty(TCHAR *pszPath)
Converts a path to all lowercase characters to give the path a consistent appearance.
Definition shelwapi.cpp:556
static BOOL Append(TCHAR *pszPath, LPCTSTR pMore)
Appends one path to the end of another.
Definition shelwapi.cpp:316
static BOOL IsDirectoryEmpty(LPCTSTR pszPath)
Determines whether or not a specified path is an empty directory.
Definition shelwapi.cpp:460
static void StripPath(TCHAR *pszPath)
Removes the path portion of a fully qualified path and file.
Definition shelwapi.cpp:668
static TCHAR * AddBackslash(TCHAR *pszPath)
Adds a backslash to the end of a string to create the correct syntax for a path.
Definition shelwapi.cpp:300
static BOOL IsRoot(LPCTSTR pszPath)
Parses a path to determine if it is a directory root.
Definition shelwapi.cpp:492
static BOOL IsContentType(LPCTSTR pszPath, LPCTSTR pszContentType)
Determines if a file's registered content type matches the specified content type.
Definition shelwapi.cpp:540
static BOOL IsRelative(LPCTSTR pszPath)
Searches a path and determines if it is relative.
Definition shelwapi.cpp:484
static BOOL RemoveFileSpec(TCHAR *pszPath)
Removes the trailing file name and backslash from a path, if it has them.
Definition shelwapi.cpp:628
static BOOL IsFileSpec(LPCTSTR pszPath)
Searches a path for any path delimiting characters (for example, ':' or '\' ).
Definition shelwapi.cpp:468
static TCHAR * GetArgs(LPCTSTR pszPath)
Finds the command line arguments within a given path.
Definition shelwapi.cpp:412
static BOOL Canonicalize(TCHAR *pszBuf, LPCTSTR pszPath)
Canonicalizes a path.
Definition shelwapi.cpp:332
static BOOL CompactPath(HDC hDC, TCHAR *pszPath, UINT dx)
Truncates a file path to fit within a given pixel width by replacing path components with ellipses.
Definition shelwapi.cpp:348
static BOOL IsURL(LPCTSTR pszPath)
Tests a given string to determine if it conforms to a valid URL format.
Definition shelwapi.cpp:548
static BOOL IsUNCServerShare(LPCTSTR pszPath)
Determines if a string is a valid universal naming convention (UNC) share path, \\server\share.
Definition shelwapi.cpp:532
static BOOL IsUNC(LPCTSTR pszPath)
Determines if the string is a valid UNC (universal naming convention) for a server and share path.
Definition shelwapi.cpp:508
static UINT GetCharType(tchar ch)
Determines the type of character with respect to a path.
Definition shelwapi.cpp:436
static BOOL IsDirectory(LPCTSTR pszPath)
Verifies that a path is a valid directory.
Definition shelwapi.cpp:452
static LPCTSTR FindSuffixArray(LPCTSTR pszPath, const LPCTSTR *apszSuffix, int iArraySize)
Determines if a given file name has one of a list of suffixes.
Definition shelwapi.cpp:420
static TCHAR * FindFileName(LPCTSTR pszPath)
Searches a path for a file name.
Definition shelwapi.cpp:388
static BOOL UnmakeSystemFolder(LPCTSTR pszPath)
Removes the attributes from a folder that make it a system folder.
Definition shelwapi.cpp:700
static BOOL FileExists(LPCTSTR pszPath)
Determines whether a path to a file system object such as a file or directory is valid.
Definition shelwapi.cpp:372
static TCHAR * Combine(TCHAR *pszDest, LPCTSTR pszDir, LPCTSTR pszFile)
Concatenates two strings that represent properly formed paths into one path, as well as any relative ...
Definition shelwapi.cpp:340
static BOOL MakeSystemFolder(LPCTSTR pszPath)
Gives an existing folder the proper attributes to become a system folder.
Definition shelwapi.cpp:692
static TCHAR * RemoveBackslash(TCHAR *pszPath)
Removes the trailing backslash from a given path.
Definition shelwapi.cpp:604
static BOOL SearchAndQualify(LPCTSTR pszPath, TCHAR *pszBuf, UINT cchBuf)
Determines if a given path is correctly formatted and fully qualified.
Definition shelwapi.cpp:644
static BOOL RenameExtension(TCHAR *pszPath, LPCTSTR pszExt)
Replaces the extension of a file name with a new extension.
Definition shelwapi.cpp:636
static BOOL IsSameRoot(LPCTSTR pszPath1, LPCTSTR pszPath2)
Compares two paths to determine if they have a common root component.
Definition shelwapi.cpp:500
static BOOL CompactPathEx(TCHAR *pszOut, LPCTSTR pszSrc, UINT cchMax, DWORD dwFlags)
Definition shelwapi.cpp:356
static DWORD DeleteKey(HKEY hkey, LPCTSTR pszSubKey)
DeleteKey mimics RegDeleteKey as it behaves on Win95 - deletes a subkey and all its values and descen...
Definition shelwapi.cpp:72
static LONG QueryInfoKey(HKEY hkey, LPDWORD pcSubKeys, LPDWORD pcchMaxSubKeyLen, LPDWORD pcValues, LPDWORD pcchMaxValueNameLen)
Retrieves information about a specified registry key.
Definition shelwapi.cpp:136
static DWORD SetValue(HKEY hkey, LPCTSTR pszSubKey, LPCTSTR pszValue, DWORD dwType, LPCVOID pvData, DWORD cbData)
Definition shelwapi.cpp:104
static DWORD CopyKey(HKEY hkeySrc, LPCTSTR szSrcSubKey, HKEY hkeyDest, DWORD fReserved)
Recursively copies the subkeys and values of the source subkey to the destination key.
Definition shelwapi.cpp:145
static DWORD QueryValueEx(HKEY hkey, LPCTSTR pszValue, LPDWORD pdwReserved, LPDWORD pdwType, LPVOID pvData, LPDWORD pcbData)
This functions work just like RegQueryValueEx, except if the data type is REG_EXPAND_SZ,...
Definition shelwapi.cpp:112
static DWORD DeleteEmptyKey(HKEY hkey, LPCTSTR pszSubKey)
DeleteEmptyKey mimics RegDeleteKey as it behaves on NT - delete the subkey only if it does not contai...
Definition shelwapi.cpp:64
static HKEY DuplicateKey(HKEY hkey)
Duplicates a registry key's HKEY handle.
Definition shelwapi.cpp:80
static DWORD DeleteValue(HKEY hkey, LPCTSTR pszSubKey, LPCTSTR pszValue)
These functions open the key, get/set/delete the value, then close the key.
Definition shelwapi.cpp:88
static LONG EnumKeyEx(HKEY hkey, DWORD dwIndex, TCHAR *pszName, LPDWORD pcchName)
Enumerates the subkeys of the specified open registry key.
Definition shelwapi.cpp:120
static DWORD GetValue(HKEY hkey, LPCTSTR pszSubKey, LPCTSTR pszValue, LPDWORD pdwType, LPVOID pvData, LPDWORD pcbData)
Definition shelwapi.cpp:96
static LONG EnumValue(HKEY hkey, DWORD dwIndex, TCHAR *pszValueName, LPDWORD pcchValueName, LPDWORD pdwType, LPVOID pvData, LPDWORD pcbData)
Enumerates the values of the specified open registry key.
Definition shelwapi.cpp:128
static DWORD RegGetPath(HKEY hkey, LPCTSTR pcszSubKey, LPCTSTR pcszValue, TCHAR *pszPath, DWORD dwFlags)
Retrieves a file path from the registry, expanding environment variables as needed.
Definition shelwapi.cpp:154
static TModule & GetModule()
Definition shelwapi.cpp:57
static DWORD RegSetPath(HKEY hkey, LPCTSTR pcszSubKey, LPCTSTR pcszValue, LPCTSTR pcszPath, DWORD dwFlags)
Takes a file path, replaces folder names with environment strings, and places the resulting string in...
Definition shelwapi.cpp:162
#define _T(x)
Definition cygwin.h:51
Definition of class TModule.
Object Windows Library (OWLNext Core)
Definition animctrl.h:22
char tchar
Definition defs.h:77
General definitions used by all ObjectWindows programs.
Definitions of Windows light-weight utility APIs: TSHReg, TSHPath.