VersionInfo.h (0377c12b) VersionInfo.h (9742fdb4)
1/* $NetBSD: VersionInfo.h,v 1.2 2018/08/12 13:02:30 christos Exp $ */
1/* $NetBSD: VersionInfo.h,v 1.3 2020/05/24 19:46:20 christos Exp $ */
2
2
3// VersionInfo.h: interface for the CVersionInfo class.
4//
5//////////////////////////////////////////////////////////////////////
3/* VersionInfo.h: interface for the CVersionInfo class. */
4/* */
5/*//////////////////////////////////////////////////////////////////// */
6
7#if !defined(AFX_VERSIONINFO_H__F82E9FF3_5298_11D4_AB87_00C04F789BA0__INCLUDED_)
8#define AFX_VERSIONINFO_H__F82E9FF3_5298_11D4_AB87_00C04F789BA0__INCLUDED_
9
10#if _MSC_VER > 1000
11#pragma once
6
7#if !defined(AFX_VERSIONINFO_H__F82E9FF3_5298_11D4_AB87_00C04F789BA0__INCLUDED_)
8#define AFX_VERSIONINFO_H__F82E9FF3_5298_11D4_AB87_00C04F789BA0__INCLUDED_
9
10#if _MSC_VER > 1000
11#pragma once
12#endif // _MSC_VER > 1000
12#endif /* _MSC_VER > 1000 */
13
13
14class CVersionInfo
15{
16public:
14class CVersionInfo {
15 public:
17 CVersionInfo(CString filename);
18 virtual ~CVersionInfo();
16 CVersionInfo(CString filename);
17 virtual ~CVersionInfo();
19 BOOL IsValid() {return m_isValid;}
20 DWORD GetStatus() {return m_status;}
18 BOOL
19 IsValid() {
20 return (m_isValid);
21 }
22 DWORD
23 GetStatus() { return (m_status); }
21
24
22 BOOL CopyFileCheckVersion(CVersionInfo &originalFile);
23 BOOL CopyFileNoVersion(CVersionInfo &originalFile);
25 BOOL
26 CopyFileCheckVersion(CVersionInfo &originalFile);
27 BOOL
28 CopyFileNoVersion(CVersionInfo &originalFile);
24
29
25 const CString &GetFilename() {return m_filename;}
30 const CString &
31 GetFilename() {
32 return (m_filename);
33 }
26
34
27 // Extract the elements of the file's string info block
28 CString GetFileVersionString();
29 CString GetProductVersionString();
30 CString GetComments();
31 CString GetFileDescription();
32 CString GetInternalName();
33 CString GetLegalCopyright();
34 CString GetLegalTrademarks();
35 CString GetOriginalFileName();
36 CString GetProductName();
37 CString GetSpecialBuildString();
38 CString GetPrivateBuildString();
39 CString GetCompanyName();
35 /* Extract the elements of the file's string info block */
36 CString
37 GetFileVersionString();
38 CString
39 GetProductVersionString();
40 CString
41 GetComments();
42 CString
43 GetFileDescription();
44 CString
45 GetInternalName();
46 CString
47 GetLegalCopyright();
48 CString
49 GetLegalTrademarks();
50 CString
51 GetOriginalFileName();
52 CString
53 GetProductName();
54 CString
55 GetSpecialBuildString();
56 CString
57 GetPrivateBuildString();
58 CString
59 GetCompanyName();
40
60
61 /* Extract the elements of the file's VS_FIXEDFILEINFO block */
62 _int64
63 GetFileVersion();
64 _int64
65 GetProductVersion();
66 _int64
67 GetFileDate();
41
68
42 // Extract the elements of the file's VS_FIXEDFILEINFO block
43 _int64 GetFileVersion();
44 _int64 GetProductVersion();
45 _int64 GetFileDate();
69 DWORD
70 GetFileFlagMask();
71 DWORD
72 GetFileFlags();
73 DWORD
74 GetFileOS();
75 DWORD
76 GetFileType();
77 DWORD
78 GetFileSubType();
46
79
47 DWORD GetFileFlagMask();
48 DWORD GetFileFlags();
49 DWORD GetFileOS();
50 DWORD GetFileType();
51 DWORD GetFileSubType();
52
53private:
80 private:
54 CString m_filename;
55 BOOL m_isValid;
56 LPVOID m_versionInfo;
57 VS_FIXEDFILEINFO *m_fixedInfo;
58 DWORD m_codePage;
59 DWORD m_status;
60
81 CString m_filename;
82 BOOL m_isValid;
83 LPVOID m_versionInfo;
84 VS_FIXEDFILEINFO *m_fixedInfo;
85 DWORD m_codePage;
86 DWORD m_status;
87
61 CString QueryStringValue(CString value);
88 CString
89 QueryStringValue(CString value);
62};
63
90};
91
64#endif // !defined(AFX_VERSIONINFO_H__F82E9FF3_5298_11D4_AB87_00C04F789BA0__INCLUDED_)
92#endif /* !defined(AFX_VERSIONINFO_H__F82E9FF3_5298_11D4_AB87_00C04F789BA0__INCLUDED_) \
93 */