1 |
|
---|
2 | /***********************************************************************
|
---|
3 |
|
---|
4 | $Id: fm3dll.h 1444 2009-07-22 23:24:23Z gyoung $
|
---|
5 |
|
---|
6 | Common definitions
|
---|
7 |
|
---|
8 | Copyright (c) 1993-98 M. Kimes
|
---|
9 | Copyright (c) 2001, 2008 Steven H. Levine
|
---|
10 |
|
---|
11 | 12 Feb 03 SHL Add CBLIST_TO_EASIZE
|
---|
12 | 11 Jun 03 SHL Add JFS and FAT32 support
|
---|
13 | 06 Jan 04 SHL Drop hundfmt
|
---|
14 | 01 Aug 04 SHL Optimze strippers
|
---|
15 | 01 Aug 04 SHL Drop avv local functions
|
---|
16 | 23 May 05 SHL Split datamin to datamin.h
|
---|
17 | 24 May 05 SHL Rework Win_Error usage
|
---|
18 | 25 May 05 SHL Require VAC 3.65
|
---|
19 | 25 May 05 SHL Rename comnam to szCommonName
|
---|
20 | 25 May 05 SHL Rework for FillInRecordFromFFB
|
---|
21 | 25 May 05 SHL Add CommaFmtULL CommaFmtUL
|
---|
22 | 28 May 05 SHL Drop local functions
|
---|
23 | 06 Jun 05 SHL Use QWL_USER
|
---|
24 | 11 Aug 05 SHL Renames
|
---|
25 | 29 May 06 SHL Rework EditArchiverDefinition
|
---|
26 | 16 Jun 06 SHL ARC_TYPE: support non-string signatures
|
---|
27 | 26 Jun 06 SHL ARC_TYPE: support preserving comments
|
---|
28 | 28 Jun 06 SHL DIRCNRDATA: drop unused
|
---|
29 | 05 Jul 06 SHL Support Hide not selected
|
---|
30 | 13 Jul 06 SHL Add Runtime_Error
|
---|
31 | 22 Jul 06 SHL Add memory.c functions
|
---|
32 | 26 Jul 06 SHL Add strips.c functions
|
---|
33 | 26 Jul 06 SHL Add more error.c functions
|
---|
34 | 29 Jul 06 SHL Add xfgets, xfgets_bstripcr
|
---|
35 | 22 Oct 06 GKY Add NDFS32 support
|
---|
36 | 03 Nov 06 SHL Renames
|
---|
37 | 17 Jan 07 SHL Resize extractdir
|
---|
38 | 17 Feb 07 GKY Add more file system types
|
---|
39 | 17 Feb 07 GKY Add SelectDriveIcon to streamline update.c
|
---|
40 | 18 Mar 07 GKY Add MM import typedefines for fix for files misindentified as multimedia
|
---|
41 | 30 Mar 07 GKY Defined golbals for removing GetPString for window class names
|
---|
42 | 06 Apr 07 GKY Work around PM DragInfo and DrgFreeDISH limits NumItemsToUnhilite & DeleteDragitemStrHandles
|
---|
43 | 06 Apr 07 GKY Add some error checking in drag/drop
|
---|
44 | 19 Apr 07 SHL Rework DeleteDragitemStrHandles to be FreeDragInfoData
|
---|
45 | 19 Apr 07 SHL Add DbgMsg. Sync with AcceptOneDrop GetOneDrop mods.
|
---|
46 | 21 Apr 07 GKY Find FM2Utils by path or utils directory eliminate fAddUtils global
|
---|
47 | 23 Apr 07 SHL Add Win_Error_NoMsgBox
|
---|
48 | 12 May 07 SHL Add ulItemsToUnHilite to DIRCNRDATA, pass to Unhilite as arg
|
---|
49 | 05 Jun 07 SHL Update for OpenWatcom
|
---|
50 | 10 Jun 07 GKY Add CheckPmDrgLimit including IsFm2Window as part of work around PM drag limit
|
---|
51 | 16 Jun 07 GKY Add CheckPmDrgLimit including IsFm2Window as part of work around PM drag limit
|
---|
52 | 16 Jun 07 SHL Update more for OpenWatcom
|
---|
53 | 22 Jul 07 GKY Update CNRITEM to optimize RAM usage
|
---|
54 | 23 Jul 07 SHL More CNRITEM updates (ticket#24)
|
---|
55 | 01 Aug 07 SHL More CNRITEM and ARCITEM updates (ticket#24)
|
---|
56 | 14 Aug 07 SHL Add GetMSecTimer
|
---|
57 | 14 Aug 07 SHL Delete obsoletes
|
---|
58 | 16 Aug 07 SHL Update for ticket# 109 - status update
|
---|
59 | 18 Aug 07 SHL Update for ticket# 31 - states length
|
---|
60 | 19 Aug 07 SHL Move FILESTOGET_MIN/MAX here
|
---|
61 | 19 Aug 07 SHL Update SaveDirCnrState return
|
---|
62 | 21 Aug 07 GKY Make Subject column in dircnr sizable and movable from the right to the left pane
|
---|
63 | 01 Sep 07 GKY Add xDosSetPathInfo to fix case where FS3 buffer crosses 64k boundary
|
---|
64 | 04 Nov 07 GKY Add pszFmtFileSize to CNRITEM to display large file sizes
|
---|
65 | 10 Nov 07 GKY Add ThousandSeparator variable for file sizes NLS tseparator.
|
---|
66 | 22 Nov 07 GKY Use CopyPresParams in CheckMenu to fix presparam inconsistencies in menus
|
---|
67 | 17 Dec 07 GKY Add variables for using WPURLDEFAULTSETTINGS as the fall back for ftphttprun
|
---|
68 | 29 Dec 07 GKY Add remove_first_occurence_of_character
|
---|
69 | 30 Dec 07 GKY Change TestDates to TestFDates can compare by filename or FDATE/FTIME data
|
---|
70 | 30 Dec 07 GKY Add TestCDates to compare CNRITEMs by CDATE/CTIME data
|
---|
71 | 04 Jan 08 SHL Allow standalone usage
|
---|
72 | 05 Jan 08 SHL Move comp.c definitions to comp.h
|
---|
73 | 05 Jan 08 SHL Move dircnr.c definitions to dircnr.h
|
---|
74 | 05 Jan 08 SHL Move makelist.c definitions to makelist.h
|
---|
75 | 05 Jan 08 SHL Move error.c definitions to errutil.h
|
---|
76 | 05 Jan 08 SHL Move string.c definitions to strutil.h
|
---|
77 | 10 Jan 08 SHL Add UM_FIRSTTIME
|
---|
78 | 12 Jan 08 SHL Localize SpecialSelect to comp.c
|
---|
79 | 14 Feb 08 SHL Refactor CfgDlgProc to notebook.h
|
---|
80 | 29 Feb 08 GKY Refactor global command line variables to notebook.h
|
---|
81 | 22 Jun 08 GKY Changed some variable types to fix compiler warnings
|
---|
82 | 11 Jul 08 JBS Ticket 230: Simplified code and eliminated some local variables by incorporating
|
---|
83 | all the details view settings (both the global variables and those in the
|
---|
84 | DIRCNRDATA struct) into a new struct: DETAILS_SETTINGS.
|
---|
85 | 16 JUL 08 GKY Use TMP directory for temp files
|
---|
86 | 19 Jul 08 GKY Replace save_dir2(dir) with pFM2SaveDirectory and use MakeTempName; Remove LISTTEMPROOT
|
---|
87 | xx Sep 08 JBS Ticket 187 (Refactor fm2dll.h): All function declarations and data
|
---|
88 | definitions/declarations moved to other include files.
|
---|
89 | 25 Dec 08 GKY Add code to allow write verify to be turned off on a per drive basis
|
---|
90 | 25 Dec 08 GKY Add DRIVE_RSCANNED flag to monitor for the first recursive drive scan per session
|
---|
91 | to prevent duplicate directory names in tree following a copy before initial scan.
|
---|
92 | 22 Jul 09 GKY Drivebar enhancements add refresh removable, rescan all drives, drive button
|
---|
93 | loads drive root directory in directory container or expands drive tree
|
---|
94 | and rescans drive in tree container depending on container focus, greyed out
|
---|
95 | inappropriate menu context choices
|
---|
96 |
|
---|
97 | ***********************************************************************/
|
---|
98 |
|
---|
99 | #if !defined(FM3DLL_H)
|
---|
100 |
|
---|
101 | #define FM3DLL_H
|
---|
102 |
|
---|
103 | #include <stdio.h> // FILE
|
---|
104 | // #include <time.h> // time_t
|
---|
105 |
|
---|
106 | #if !defined(OS2_INCLUDED)
|
---|
107 | #define INCL_WINSTDDRAG
|
---|
108 | #define INCL_WINSTDCNR
|
---|
109 | #define INCL_WINPROGRAMLIST
|
---|
110 | #define INCL_WINHELP
|
---|
111 | #define INCL_LONGLONG // 05 Jan 08 SHL fixme to be gone eventually
|
---|
112 | #include <os2.h>
|
---|
113 | #else
|
---|
114 | #if !defined(INCL_WINSTDDRAG)
|
---|
115 | #error INCL_WINSTDDRAG required
|
---|
116 | #endif
|
---|
117 | #if !defined(INCL_WINSTDCNR)
|
---|
118 | #error INCL_WINSTDCNR required
|
---|
119 | #endif
|
---|
120 | #if !defined(INCL_WINPROGRAMLIST)
|
---|
121 | #error INCL_WINPROGRAMLIST required
|
---|
122 | #endif
|
---|
123 | #if !defined(INCL_WINHELP)
|
---|
124 | #error INCL_WINHELP required
|
---|
125 | #endif
|
---|
126 | #if !defined(INCL_LONGLONG)
|
---|
127 | #error INCL_LONGLONG required
|
---|
128 | #endif
|
---|
129 | #endif // OS2_INCLUDED
|
---|
130 |
|
---|
131 | #define DIR_SPLITBAR_OFFSET 18 * 12 /* Pixel offset of details splitbar */
|
---|
132 |
|
---|
133 | #define ALLATTRS (FILE_NORMAL | FILE_DIRECTORY | FILE_ARCHIVED |\
|
---|
134 | FILE_HIDDEN | FILE_READONLY | FILE_SYSTEM)
|
---|
135 | //#define LISTTEMPROOT "$FM2LI$T"
|
---|
136 |
|
---|
137 | #define DRIVE_REMOVABLE 0x00000001
|
---|
138 | #define DRIVE_NOTWRITEABLE 0x00000002
|
---|
139 | #define DRIVE_IGNORE 0x00000004
|
---|
140 | #define DRIVE_CDROM 0x00000008
|
---|
141 | #define DRIVE_NOLONGNAMES 0x00000010
|
---|
142 | #define DRIVE_REMOTE 0x00000020
|
---|
143 | #define DRIVE_BOOT 0x00000040
|
---|
144 | #define DRIVE_INVALID 0x00000080
|
---|
145 | #define DRIVE_NOPRESCAN 0x00000100
|
---|
146 | #define DRIVE_ZIPSTREAM 0x00000200
|
---|
147 | #define DRIVE_NOLOADICONS 0x00000400
|
---|
148 | #define DRIVE_NOLOADSUBJS 0x00000800
|
---|
149 | #define DRIVE_NOLOADLONGS 0x00001000
|
---|
150 | #define DRIVE_SLOW 0x00002000
|
---|
151 | #define DRIVE_INCLUDEFILES 0x00004000
|
---|
152 | #define DRIVE_VIRTUAL 0x00008000
|
---|
153 | #define DRIVE_NOSTATS 0x00010000
|
---|
154 | #define DRIVE_RAMDISK 0x00020000
|
---|
155 | #define DRIVE_WRITEVERIFYOFF 0x00040000
|
---|
156 | #define DRIVE_RSCANNED 0x00080000
|
---|
157 | #define DRIVE_LOCALHD 0x00200000
|
---|
158 | #define DRIVE_NOEASUPPORT 0x00400000
|
---|
159 |
|
---|
160 | #define SORT_FIRSTEXTENSION 0x00000001
|
---|
161 | #define SORT_LASTEXTENSION 0x00000002
|
---|
162 | #define SORT_SIZE 0x00000004
|
---|
163 | #define SORT_EASIZE 0x00000008
|
---|
164 | #define SORT_LWDATE 0x00000010
|
---|
165 | #define SORT_LADATE 0x00000020
|
---|
166 | #define SORT_CRDATE 0x00000040
|
---|
167 | #define SORT_DIRSFIRST 0x00000080
|
---|
168 | #define SORT_DIRSLAST 0x00000100
|
---|
169 | #define SORT_FILENAME 0x00000200
|
---|
170 | #define SORT_REVERSE 0x00000400
|
---|
171 | #define SORT_PATHNAME 0x00000800
|
---|
172 | #define SORT_NOSORT 0x00001000
|
---|
173 | #define SORT_SUBJECT 0x00002000
|
---|
174 |
|
---|
175 |
|
---|
176 | #define RECFLAGS_ENV 0x00000001
|
---|
177 | #define RECFLAGS_NODRAG 0x00000002
|
---|
178 | #define RECFLAGS_NODROP 0x00000004
|
---|
179 | #define RECFLAGS_UNDERENV 0x00000008
|
---|
180 |
|
---|
181 | #define COPY 0
|
---|
182 | #define MOVE 1
|
---|
183 | #define WPSCOPY 2
|
---|
184 | #define WPSMOVE 4
|
---|
185 |
|
---|
186 | #define FILESTOGET_MIN 256
|
---|
187 | #define FILESTOGET_MAX 4096
|
---|
188 |
|
---|
189 | #define priority_idle() DosSetPriority(PRTYS_THREAD,PRTYC_IDLETIME,30L,0L)
|
---|
190 | #define priority_normal() DosSetPriority(PRTYS_THREAD,PRTYC_REGULAR,0L,0L)
|
---|
191 | // #define priority_tweaked() DosSetPriority(PRTYS_THREAD,PRTYC_REGULAR,1L,0L) // Unused, 13 Sep 08 JBS
|
---|
192 | #define priority_bumped() DosSetPriority(PRTYS_THREAD,PRTYC_REGULAR,3L,0L)
|
---|
193 | // #define priority_critical() DosSetPriority(PRTYS_THREAD,PRTYC_FOREGROUNDSERVER,2L,0L) // Unused, 13 Sep 08 JBS
|
---|
194 | // #define priority_max() DosSetPriority(PRTYS_THREAD,PRTYC_FOREGROUNDSERVER,31L,0L) // Unused, 13 Sep 08 JBS
|
---|
195 |
|
---|
196 | #define INSTDATA(h) WinQueryWindowPtr((h),QWL_USER)
|
---|
197 | // #define RGBFROMPARTS(r,g,b) (((r) * 65536) + ((g) * 256) + (b)) // Unused, 13 Sep 08 JBS
|
---|
198 | #define SysVal(value) WinQuerySysValue(HWND_DESKTOP, (value))
|
---|
199 |
|
---|
200 |
|
---|
201 | #endif // FM3DLL_H
|
---|