source: trunk/dll/fm3dll.h@ 729

Last change on this file since 729 was 697, checked in by Steven Levine, 18 years ago

More OpenWatcom compatibility updates

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 49.7 KB
RevLine 
[49]1
2/***********************************************************************
3
4 $Id: fm3dll.h 697 2007-06-17 03:59:25Z stevenhl $
5
6 Common definitions
7
8 Copyright (c) 1993-98 M. Kimes
[552]9 Copyright (c) 2001, 2007 Steven H. Levine
[49]10
[145]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
[165]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
[170]22 28 May 05 SHL Drop local functions
[205]23 06 Jun 05 SHL Use QWL_USER
[246]24 11 Aug 05 SHL Renames
[419]25 29 May 06 SHL Rework EditArchiverDefinition
[294]26 16 Jun 06 SHL ARC_TYPE: support non-string signatures
[311]27 26 Jun 06 SHL ARC_TYPE: support preserving comments
[320]28 28 Jun 06 SHL DIRCNRDATA: drop unused
29 05 Jul 06 SHL Support Hide not selected
[337]30 13 Jul 06 SHL Add Runtime_Error
31 22 Jul 06 SHL Add memory.c functions
[365]32 26 Jul 06 SHL Add strips.c functions
[381]33 26 Jul 06 SHL Add more error.c functions
[399]34 29 Jul 06 SHL Add xfgets, xfgets_bstripcr
[520]35 22 Oct 06 GKY Add NDFS32 support
36 03 Nov 06 SHL Renames
[549]37 17 Jan 07 SHL Resize extractdir
[552]38 17 Feb 07 GKY Add more file system types
[557]39 17 Feb 07 GKY Add SelectDriveIcon to streamline update.c
[570]40 18 Mar 07 GKY Add MM import typedefines for fix for files misindentified as multimedia
[593]41 30 Mar 07 GKY Defined golbals for removing GetPString for window class names
[618]42 06 Apr 07 GKY Work around PM DragInfo and DrgFreeDISH limits NumItemsToUnhilite & DeleteDragitemStrHandles
[603]43 06 Apr 07 GKY Add some error checking in drag/drop
[618]44 19 Apr 07 SHL Rework DeleteDragitemStrHandles to be FreeDragInfoData
45 19 Apr 07 SHL Add DbgMsg. Sync with AcceptOneDrop GetOneDrop mods.
[627]46 21 Apr 07 GKY Find FM2Utils by path or utils directory eliminate fAddUtils global
[636]47 23 Apr 07 SHL Add Win_Error_NoMsgBox
[672]48 12 May 07 SHL Add ulItemsToUnHilite to DIRCNRDATA, pass to Unhilite as arg
[689]49 05 Jun 07 SHL Update for OpenWatcom
[688]50 10 Jun 07 GKY Add CheckPmDrgLimit including IsFm2Window as part of work around PM drag limit
[696]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
[49]53
54***********************************************************************/
55
[689]56#if defined(__IBMC__)
[165]57#if __IBMC__ != 430
58#error VAC365 required for long long support
59#endif
60#if !defined(_LONG_LONG)
61#error Long long support not enabled
62#endif
[689]63#endif
[165]64
[2]65#ifdef DEFINE_GLOBALS
[551]66#pragma data_seg(GLOBAL1)
[2]67#endif
68
69#define PP_MAX PP_MENUDISABLEBGNDCOLORINDEX
70#define PP_MAXBUF 384
71
72#ifndef MM_PORTHOLEINIT
[551]73#define MM_PORTHOLEINIT 0x01fb
[2]74#endif
75#ifndef MS_POPUP
[551]76#define MS_POPUP 0x00000010L
[2]77#endif
78#ifndef CCS_MINIICONS
[551]79#define CCS_MINIICONS 0x0800
[2]80#endif
81#ifndef CRA_SOURCE
[551]82#define CRA_SOURCE 0x00004000
[2]83#endif
84#ifndef CV_EXACTMATCH
[551]85#define CV_EXACTMATCH 0x10000000
[2]86#endif
87#ifndef CBN_SETFOCUS
[551]88#define CBN_SETFOCUS 20
[2]89#endif
90#ifndef CBN_KILLFOCUS
[551]91#define CBN_KILLFOCUS 21
[2]92#endif
93#ifndef CN_VERIFYEDIT
[551]94#define CN_VERIFYEDIT 134
[2]95#endif
96#ifndef CN_PICKUP
[551]97#define CN_PICKUP 135
[2]98#endif
99#ifndef CN_DROPNOTIFY
[551]100#define CN_DROPNOTIFY 136
[2]101#endif
102#ifndef CN_GRIDRESIZED
[551]103#define CN_GRIDRESIZED 137
[2]104#endif
105#ifndef BKS_MERLINSTYLE
[551]106#define BKS_MERLINSTYLE 0x0800
[2]107#endif
[697]108
109// PMBITMAP_INCLUDED - IBM Toolkit
110// INCL_GPIBITMAPS - OpenWatcom Toolkit
111#if !defined(PMBITMAP_INCLUDED) && !defined(INCL_GPIBITMAPS)
[551]112typedef struct _RGB2 /* rgb2 */
113{
114 BYTE bBlue; /* Blue component of the color definition */
115 BYTE bGreen; /* Green component of the color definition */
116 BYTE bRed; /* Red component of the color definition */
117 BYTE fcOptions; /* Reserved, must be zero */
118}
119RGB2;
120typedef RGB2 *PRGB2;
[2]121#endif
122
123 /**************************************************/
124 /* Lazy Drag API's. */
125 /**************************************************/
[551]126BOOL APIENTRY DrgLazyDrag(HWND hwndSource,
127 PDRAGINFO pdinfo,
128 PDRAGIMAGE pdimg, ULONG cdimg, PVOID pRsvd);
[2]129
[551]130BOOL APIENTRY DrgCancelLazyDrag(VOID);
[2]131
[551]132BOOL APIENTRY DrgLazyDrop(HWND hwndTarget,
133 ULONG ulOperation, PPOINTL pptlDrop);
[2]134
[551]135PDRAGINFO APIENTRY DrgQueryDraginfoPtr(PDRAGINFO pRsvd);
[2]136
[551]137PDRAGINFO APIENTRY DrgQueryDraginfoPtrFromHwnd(HWND hwndSource);
[2]138
[551]139PDRAGINFO APIENTRY DrgQueryDraginfoPtrFromDragitem(PDRAGITEM pditem);
[2]140
[551]141ULONG APIENTRY DrgQueryDragStatus(VOID);
[2]142
[551]143PDRAGINFO APIENTRY DrgReallocDraginfo(PDRAGINFO pdinfoOld, ULONG cditem);
144
[2]145 /* Drag Status Flags */
[551]146#define DGS_DRAGINPROGRESS 0x0001 /* Standard Drag in Progress. */
147#define DGS_LAZYDRAGINPROGRESS 0x0002 /* Lazy Drag in Progress. */
[2]148
[311]149#define LINES_PER_ARCSIG 21 // Lines in each archiver.bb2 definition
[2]150#define CON_COLS 6
[672]151#define INSTDATA(h) WinQueryWindowPtr((h),QWL_USER)
[551]152#define DIR_SPLITBAR_OFFSET 18 * 12 /* Pixel offset of details splitbar */
153#define CONTAINER_COLUMNS 13 /* Number of columns in details view */
[2]154#define RGBFROMPARTS(r,g,b) (((r) * 65536) + ((g) * 256) + (b))
155#define EXTRA_RECORD_BYTES2 (sizeof(CNRITEM) - sizeof(MINIRECORDCORE))
156#define EXTRA_RECORD_BYTES (EXTRA_RECORD_BYTES2 + (CCHMAXPATHCOMP - 1))
157#define EXTRA_ARCRECORD_BYTES (sizeof(ARCITEM) - sizeof(MINIRECORDCORE))
158#define ALLATTRS (FILE_NORMAL | FILE_DIRECTORY | FILE_ARCHIVED |\
[636]159 FILE_HIDDEN | FILE_READONLY | FILE_SYSTEM)
[2]160#define LISTTEMPROOT "$FM2LI$T."
161
[18]162#include "fm3dll2.h" // SHL
[2]163
164#define UM_PAINT (WM_USER)
165#define UM_SETUP (WM_USER + 1)
166#define UM_RESCAN (WM_USER + 2)
167#define UM_INITIALSIZE (WM_USER + 3)
168#define UM_CONTROL (WM_USER + 4)
169#define UM_COMMAND (WM_USER + 5)
170#define UM_SIZE (WM_USER + 6)
171#define UM_FOCUSME (WM_USER + 7)
172#define UM_FIXEDITNAME (WM_USER + 8)
173#define UM_UPDATERECORD (WM_USER + 9)
174#define UM_SETDIR (WM_USER + 10)
175#define UM_CONTAINER_FILLED (WM_USER + 11)
176#define UM_STRETCH (WM_USER + 12)
177#define UM_LOADFILE (WM_USER + 13)
178#define UM_MOUSEMOVE (WM_USER + 14)
179#define UM_ENTER (WM_USER + 15)
180#define UM_CLOSE (WM_USER + 16)
181#define UM_ACTION (WM_USER + 17)
182#define UM_MASSACTION (WM_USER + 18)
183#define UM_UPDATERECORDLIST (WM_USER + 19)
184#define UM_FILESMENU (WM_USER + 20)
185#define UM_SELECT (WM_USER + 21)
186#define UM_VIEWSMENU (WM_USER + 22)
187#define UM_CONTAINERHWND (WM_USER + 23)
188#define UM_OPENWINDOWFORME (WM_USER + 24)
189#define UM_FOLDUP (WM_USER + 25)
190#define UM_INITMENU (WM_USER + 26)
191#define UM_COMPARE (WM_USER + 27)
192#define UM_EXPAND (WM_USER + 28)
193#define UM_REPLACEFOCUS (WM_USER + 29)
194#define UM_UNDO (WM_USER + 30)
195#define UM_RENDER (WM_USER + 31)
196#define UM_BUTTON2DOWN (WM_USER + 32)
197#define UM_BUTTON2UP (WM_USER + 33)
198#define UM_COLLECTFROMFILE (WM_USER + 34)
199#define UM_TIMER (WM_USER + 35)
200#define UM_HELPON (WM_USER + 36)
201#define UM_SETUP2 (WM_USER + 37)
202#define UM_SETUP3 (WM_USER + 38)
203#define UM_CONTEXTMENU (WM_USER + 39)
204#define UM_FILLUSERLIST (WM_USER + 40)
205#define UM_CONTAINERDIR (WM_USER + 41)
206#define UM_SETUP4 (WM_USER + 42)
207#define UM_FILLSETUPLIST (WM_USER + 43)
208#define UM_ARRANGEICONS (WM_USER + 44)
209#define UM_SETUP5 (WM_USER + 45)
210#define UM_NOTIFY (WM_USER + 46)
211#define UM_INSERTRECORD (WM_USER + 47)
212#define UM_ADDTOMENU (WM_USER + 48)
213#define UM_COLLECT (WM_USER + 49)
214#define UM_RESTOREDC (WM_USER + 50)
215#define UM_MINIMIZE (WM_USER + 51)
216#define UM_MAXIMIZE (WM_USER + 52)
217#define UM_BUTTON1MOTIONSTART (WM_USER + 53)
218#define UM_SETUP6 (WM_USER + 54)
219#define UM_FILLBUTTONLIST (WM_USER + 55)
220#define UM_SETUSERLISTNAME (WM_USER + 56)
221#define UM_FILTER (WM_USER + 57)
222#define UM_SORTRECORD (WM_USER + 58)
223#define UM_SIZE2 (WM_USER + 59)
224#define UM_RESTORE (WM_USER + 60)
225#define UM_TOPDIR (WM_USER + 61)
226#define UM_SHOWME (WM_USER + 62)
227#define UM_RESCAN2 (WM_USER + 63)
[246]228#define UM_BUILDDRIVEBAR (WM_USER + 64)
[2]229#define UM_THREADUSE (WM_USER + 65)
230#define UM_DRIVECMD (WM_USER + 66)
231#define UM_ADVISEFOCUS (WM_USER + 67)
232#define UM_FIXCNRMLE (WM_USER + 68)
233#define UM_FLESH (WM_USER + 69)
234#define UM_FILLCMDLIST (WM_USER + 70)
235#define UM_CLICKED (WM_USER + 71)
236#define UM_CLICKED3 (WM_USER + 72)
[320]237#define UM_HIDENOTSELECTED (WM_USER + 73)
[2]238
[551]239typedef struct
240{
[2]241 USHORT size;
242 USHORT dummy;
[551]243 CHAR szCurrentPath1[CCHMAXPATH];
244 CHAR szCurrentPath2[CCHMAXPATH];
245}
246WALK2;
[2]247
[551]248typedef struct LINKDIRS
249{
250 CHAR *path;
[2]251 struct LINKDIRS *next;
[551]252}
253LINKDIRS;
[2]254
[551]255typedef struct
256{
257 USHORT size;
258 USHORT numcolors;
259 USHORT flags;
260 USHORT currentcolor;
261 ULONG prompt;
262 long *colors;
263 ULONG descriptions;
264 long *origs;
265}
266COLORS;
[2]267
[551]268typedef struct LINKCMDS
269{
270 CHAR *cl;
271 CHAR *title;
272 ULONG flags;
[2]273 struct LINKCMDS *next;
274 struct LINKCMDS *prev;
[551]275}
276LINKCMDS;
[2]277
[551]278typedef struct
279{
280 CHAR szMask[CCHMAXPATH];
281 CHAR szMaskCopy[CCHMAXPATH];
[2]282 CHAR *pszMasks[26];
283 ULONG attrFile;
284 ULONG antiattr;
[551]285 BOOL fNoAttribs;
286 BOOL fShowDirs;
287 BOOL fNoDirs;
288 BOOL fIsTree;
289 BOOL fIsSeeAll;
290 BOOL fFilesIncluded;
291 BOOL fText;
292 CHAR szText[256];
293 CHAR prompt[80];
294}
295MASK;
[2]296
[551]297typedef struct
298{
299 CHAR *title; /* title of dialog */
300 CHAR *prompt; /* prompt to user */
301 CHAR *ret; /* buffer out, default in */
302 CHAR *help; /* help text */
303 INT inputlen; /* max len of ret */
304}
305STRINGINPARMS;
[2]306
[551]307typedef struct
308{
[2]309 CHAR *source;
310 CHAR target[CCHMAXPATH];
311 BOOL rename;
312 BOOL skip;
313 BOOL dontask;
314 BOOL overold;
315 BOOL overnew;
316 BOOL overwrite;
[551]317}
318MOVEIT;
[2]319
[551]320typedef struct HOLDFEA
321{
322 PFEA2 pfea;
323 CHAR *name;
324 CHAR *value;
325 BYTE fEA;
326 BYTE cbName;
327 USHORT cbValue;
328 struct HOLDFEA *next;
329}
330HOLDFEA;
[2]331
[551]332typedef struct
333{
334 HWND hwnd;
335 HWND hwndS;
336 USHORT type;
337 USHORT id;
338 INT flags;
339 struct __arc_type__ *info;
340 CHAR **list;
341 ULONG *ulitemID;
342 ULONG *cbFile;
343 CHAR targetpath[CCHMAXPATH + 6];
344 CHAR arcname[CCHMAXPATH];
345 CHAR runfile[CCHMAXPATH];
346}
347LISTINFO;
[2]348
[551]349typedef struct
350{
351 USHORT size;
352 USHORT dummy;
353 CHAR directory[CCHMAXPATH];
354 HWND hwndParent;
355 HWND hwndFrame;
356 HWND hwndClient;
357 HWND hwndCnr;
[2]358 LISTINFO *li;
[551]359}
360WORKER;
[2]361
[551]362typedef struct
363{
[2]364 USHORT size;
365 USHORT flags;
366 USHORT cmd;
367 USHORT dummy;
[551]368 CHAR *prompt;
[2]369 CHAR **list;
[551]370}
371CHECKLIST;
[2]372
[551]373typedef struct
374{
[2]375 ULONG flags;
376 CHAR *commandline;
[551]377 CHAR path[CCHMAXPATH];
378 CHAR environment[1001];
379 CHAR tempprompt[128];
380 CHAR title[80];
381 BOOL dropped;
382}
383EXECARGS;
[2]384
385#pragma pack(1)
386
387#define CNRITEM_SMALLER 0x00010000
388#define CNRITEM_LARGER 0x00020000
389#define CNRITEM_NEWER 0x00040000
390#define CNRITEM_OLDER 0x00080000
391#define CNRITEM_EXISTS 0x00100000
392
393#define RECFLAGS_ENV 0x00000001
394#define RECFLAGS_NODRAG 0x00000002
395#define RECFLAGS_NODROP 0x00000004
396#define RECFLAGS_UNDERENV 0x00000008
397
398#define ARCFLAGS_REALDIR 0x00000001
399#define ARCFLAGS_PSEUDODIR 0x00000002
400
[49]401#define CBLIST_TO_EASIZE(cb) ((cb) > 4 ? (cb) / 2 : 0) // FILEFINDBUF4.cbList to logical EA size
402
[551]403typedef struct _CNRITEM
404{ /* CONTAINER RECORD STRUCTURE */
405 MINIRECORDCORE rc; /* Base information */
406 HWND hwndCnr; /* The container holding this record */
407 PSZ pszFileName; // Points to szFileName - required by CFA_STRING
408 CHAR szFileName[CCHMAXPATH]; // Path name - fixme to rename to szPathName?
409 CHAR szSubject[40]; /* Subject string */
410 CHAR *pszSubject; // Points szSubject - required by CFA_STRING
411 CHAR *pszDispAttr; // Points to szDispAttr - required by CFA_STRING
412 CDATE date; /* Last write date of file */
413 CTIME time; /* Last write time of file */
414 CDATE ladate; /* Last access date of file */
415 CTIME latime; /* Last access time of file */
416 CDATE crdate; /* Creation date of file */
417 CTIME crtime; /* Creation time of file */
418 CHAR szDispAttr[6]; /* Attrib string for details display */
419 CHAR *pszLongname; // Points to szLongName - required by CFA_STRING
420 ULONGLONG cbFile; /* File size */
421 ULONGLONG easize; // Size of EAs - dirsize uses this - hack cough
422 ULONG attrFile; /* Attributes of this file */
423 ULONG flags;
424 CHAR szLongname[1]; // Holds .LONGNAME EA or root flag
425}
426CNRITEM, *PCNRITEM;
[2]427
[551]428typedef struct _ARCITEM
429{ // ARCHIVE CONTAINER RECORD STRUCTURE
430 MINIRECORDCORE rc; // Base information
431 HWND hwndCnr; /* Container holding this record */
432 PSZ pszFileName; // Pointer to file name
433 CHAR szFileName[CCHMAXPATH]; // File name
434 CHAR szDate[40]; // File's assembled date
435 PSZ pszDate; // Pointer to date
436 CDATE date; // if we know date format
437 CTIME time; // if we know time format
438 ULONG cbFile; // File's original size
439 ULONG cbComp; // File's compressed size
440 ULONG flags;
441}
442ARCITEM, *PARCITEM;
[2]443
444#pragma pack()
445
[551]446typedef struct
447{
[2]448 ULONG attrFile;
449 ULONG cbFile;
450 ULONG easize;
451 FDATE date;
452 FTIME time;
453 FDATE ladate;
454 FTIME latime;
455 FDATE crdate;
456 FTIME crtime;
[551]457 CHAR fname[1];
458}
459FILELIST;
[2]460
[551]461typedef struct __arc_type__
462{
463 CHAR *id; // User id
464 CHAR *ext; // Extension (without leading dot)
465 LONG file_offset; // Offset to signature (0..n)
466 CHAR *list; // List command
467 CHAR *extract; // Extract command
468 CHAR *exwdirs; // Extract with directories command
469 CHAR *test; // Test command
470 CHAR *create; // Create without directories
471 CHAR *move; // Move into archive without directories
472 CHAR *createrecurse; // Create with recurse and directories
473 CHAR *createwdirs; // Create with directories
474 CHAR *movewdirs; // Move into archive with directories
475 CHAR *delete; // Delete from archive
476 CHAR *signature; // Archiver signature
477 CHAR *startlist; // Listing start marker (blank means no start marker)
478 CHAR *endlist; // Listing end marker (blank means next blank line or EOF)
479 INT siglen; // Signature length in bytes
480 INT osizepos; // Original file size position (0..n) or -1
481 INT nsizepos; // Compressed file size position or -1
482 INT fdpos; // File date position or -1
483 INT fdflds; // File date element count (typically 3) or -1
484 INT fnpos; // File name position or -1 if last
485 INT datetype; // Date field format
486 UINT comment_line_num; // Comment start in old sig file (1..n), 0 if none
487 UINT defn_line_num; // Definition start in old sig file (1..n), 0 if none
488 BOOL nameislast; // Name is last item on line
489 BOOL nameisnext; // File name is on next line
490 BOOL nameisfirst; // File name is first item on line
491 struct __arc_type__ *next;
492 struct __arc_type__ *prev;
493}
494ARC_TYPE;
[2]495
[551]496typedef struct
497{
498 USHORT size;
[2]499 ARC_TYPE *info;
[551]500 CHAR *arcname;
501 CHAR masks[257];
502 CHAR command[257];
503 CHAR extractdir[CCHMAXPATH];
504 INT ret;
505}
506EXTRDATA;
[2]507
[551]508typedef struct
509{
[2]510 ARC_TYPE *info;
[551]511 CHAR listname[CCHMAXPATH];
512 CHAR arcname[CCHMAXPATH];
513 CHAR *errmsg;
514}
515ARCDUMP;
[2]516
[551]517typedef struct DIRCNRDATA
518{
519 USHORT size;
520 USHORT id;
521 INT type;
522 ULONG flWindowAttr;
523 HWND hwndParent;
524 HWND hwndCnr;
525 HWND hwndObject;
526 HWND hwndFrame;
527 HWND hwndClient;
528 HWND hwndLastMenu;
529 HWND hwndExtract;
530 HWND hwndLastDirCnr;
531 HWND hwndRestore;
532 CHAR directory[CCHMAXPATH];
533 CHAR previous[CCHMAXPATH];
534 ULONG fg, bg, hifg, hibg, border;
535 PFNWP oldproc;
536 CHAR font[CCHMAXPATH];
537 MASK mask;
[165]538 ULONGLONG ullTotalBytes;
539 ULONGLONG selectedbytes;
[551]540 ULONG selectedfiles;
541 ULONG totalfiles;
542 BOOL cnremphasized;
543 BOOL dontclose;
[2]544 ARC_TYPE *info;
[551]545 CHAR arcname[CCHMAXPATH];
546 CHAR command[257];
547 CHAR stopflag;
548 CHAR workdir[CCHMAXPATH];
549 CHAR lastfilename[CCHMAXPATH];
550 BOOL namecanchange;
551 BOOL fmoving;
552 BOOL amextracted;
553 INT lasthelp;
554 INT sortFlags;
555 BOOL detailsladate, detailslatime, detailscrdate, detailscrtime,
556 detailslongname, detailsea, detailssize, detailssubject,
557 detailslwdate, detailslwtime, detailsattr, detailsicon;
558 CHAR **lastselection;
559 USHORT shiftstate;
560 USHORT suspendview;
561 CHAR szCommonName[CCHMAXPATH];
562 ULONG lasttime;
563 BOOL arcfilled;
564 HMTX filling;
565 BOOL firsttree;
566 ULONG lastattr;
[672]567 ULONG ulItemsToUnHilite;
[551]568}
569DIRCNRDATA;
[2]570
[551]571typedef struct
572{
573 USHORT size;
574 HWND hwndCnr;
575 CHAR directory[CCHMAXPATH];
576 BOOL collapsefirst;
[2]577 DIRCNRDATA *dcd;
[551]578}
579SHOWREC;
[2]580
[551]581typedef struct
582{
[2]583 USHORT size;
584 USHORT dummy;
[551]585 CHAR file1[CCHMAXPATH];
586 CHAR file2[CCHMAXPATH];
587 HWND hwndParent;
588 HWND hwndList;
589 HWND hwndReport;
590 HWND hwndHelp;
591}
592FCOMPARE;
[2]593
[551]594typedef struct COMPARE
595{
[2]596 USHORT size;
[551]597 HWND hwnd;
598 HWND hwndParent;
599 CHAR leftdir[CCHMAXPATH + 2];
600 CHAR rightdir[CCHMAXPATH + 2];
601 BOOL forcescroll;
602 BOOL filling;
603 BOOL includesubdirs;
604 INT action;
605 INT selleft;
606 INT selright;
607 INT totalleft;
608 INT totalright;
609 CHAR rightlist[CCHMAXPATH]; // Snapshot file name
610 BOOL reset;
611 HWND hwndCalling;
612 struct COMPARE *cmp; // callers compare defintion
[2]613 struct DIRCNRDATA dcd;
[551]614}
615COMPARE;
[2]616
617/* init.c */
618VOID FindSwapperDat(VOID);
[551]619BOOL InitFM3DLL(HAB hab, int argc, char **argv);
620HWND StartFM3(HAB hab, INT argc, CHAR ** argv);
[2]621
622/* filldir.c */
[551]623VOID FillDirCnr(HWND hwndCnr, CHAR * pszDirectory, DIRCNRDATA * pdcd,
624 PULONGLONG pullBytes);
625VOID FillTreeCnr(HWND hwndCnr, HWND hwndParent);
[165]626VOID ProcessDirectory(const HWND hwndCnr, const PCNRITEM pciParent,
[551]627 const CHAR * szDirBase, const BOOL filestoo,
628 const BOOL recurse, const BOOL partial,
629 CHAR * stopflag, DIRCNRDATA * pdcd,
630 PULONG pullTotalFiles, PULONGLONG pullTotalBytes);
631ULONGLONG FillInRecordFromFFB(HWND hwndCnr, PCNRITEM pci,
632 const PSZ pszDirectory,
633 const PFILEFINDBUF4 pffb, const BOOL partial,
634 DIRCNRDATA * pdcd);
635ULONGLONG FillInRecordFromFSA(HWND hwndCnr, PCNRITEM pci,
636 const PSZ pszFileName, const PFILESTATUS4 pfsa4,
637 const BOOL partial, DIRCNRDATA * pdcd);
[2]638
639/* flesh.c */
[551]640BOOL Stubby(HWND hwndCnr, PCNRITEM pciParent);
641BOOL Flesh(HWND hwndCnr, PCNRITEM pciParent);
642BOOL FleshEnv(HWND hwndCnr, PCNRITEM pciParent);
643BOOL UnFlesh(HWND hwndCnr, PCNRITEM pciParent);
[2]644
645/* error.c */
[636]646VOID DbgMsg(PCSZ pszSrcFile, UINT uSrcLineNo, PCSZ pszFmt, ...);
[551]647INT Dos_Error(ULONG mb_type, ULONG ulRC, HWND hwndOwner,
[636]648 PCSZ pszSrcFile, UINT uSrcLineNo, PCSZ pszFmt, ...);
649INT Dos_Error2(ULONG mb_type, ULONG ulRC, HWND hwndOwner, PCSZ pszSrcFile,
650 UINT uSrcLineNo, UINT idMsg);
[551]651VOID Runtime_Error(PCSZ pszSrcFile, UINT uSrcLineNo, PCSZ pszFmt, ...);
[381]652VOID Runtime_Error2(PCSZ pszSrcFile, UINT uSrcLineNo, UINT idMsg);
[551]653APIRET saymsg(ULONG mb_type, HWND hwnd, PCSZ pszTitle, PCSZ pszFmt, ...);
[636]654VOID Win_Error(HWND hwndErr, HWND hwndOwner,
655 PCSZ pszSrcFile, UINT uSrcLineNo, PCSZ pszFmt, ...);
656VOID Win_Error2(HWND hwndErr, HWND hwndOwner, PCSZ pszSrcFile,
657 UINT uSrcLineNo, UINT idMsg);
658VOID Win_Error_NoMsgBox(HWND hwndErr, HWND hwndOwner,
659 PCSZ pszSrcFile, UINT uSrcLineNo, PCSZ pszFmt, ...);
[2]660
661/* valid.c */
[551]662INT CheckDrive(CHAR Drive, CHAR * FileSystem, ULONG * type);
663int TestDates(char *file1, char *file2);
664BOOL IsNewer(char *file1, char *file2);
665BOOL IsRoot(CHAR * filename);
666BOOL IsFileSame(CHAR * filename1, CHAR * filename2);
667INT IsFile(CHAR * filename);
668BOOL IsFullName(CHAR * filename);
669BOOL IsValidDir(CHAR * test);
670BOOL IsValidDrive(CHAR drive);
671CHAR *MakeValidDir(CHAR * path);
672BOOL IsExecutable(CHAR * filename);
673VOID FillInDriveFlags(VOID * dummy);
674VOID DriveFlagsOne(INT x);
675VOID ArgDriveFlags(INT argc, CHAR ** argv);
676CHAR *assign_ignores(CHAR * s);
677BOOL needs_quoting(CHAR * f);
678BOOL IsBinary(CHAR * str, ULONG len);
679BOOL TestBinary(CHAR * filename);
680BOOL ParentIsDesktop(HWND hwnd, HWND hwndParent);
681BOOL IsDesktop(HAB hab, HWND hwnd);
682char *IsVowel(char a);
683VOID GetDesktopName(CHAR * objectpath, ULONG size);
684char *RootName(char *filename);
685APIRET MakeFullName(char *filename);
[2]686
687/* misc.c */
[687]688BOOL IsFm2Window(HWND hwnd, BOOL chkTid);
[551]689VOID SetShiftState(VOID);
690void EmphasizeButton(HWND hwnd, BOOL on);
691void DrawTargetEmphasis(HWND hwnd, BOOL on);
692void BoxWindow(HWND hwnd, HPS hps, LONG color);
693VOID PaintRecessedWindow(HWND hwnd, HPS hps, BOOL outtie, BOOL dbl);
694void PaintSTextWindow(HWND hwnd, HPS hps);
695BOOL AdjustCnrColVis(HWND hwndCnr, CHAR * title, BOOL visible, BOOL toggle);
696BOOL AdjustCnrColRO(HWND hwndCnr, CHAR * title, BOOL readonly, BOOL toggle);
697VOID AdjustCnrColsForFSType(HWND hwndCnr, CHAR * directory, DIRCNRDATA * dcd);
698VOID AdjustCnrColsForPref(HWND hwndCnr, CHAR * directory, DIRCNRDATA * dcd,
699 BOOL compare);
700BOOL SetCnrCols(HWND hwndCnr, BOOL compare);
701MRESULT CnrDirectEdit(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
702BOOL SetMenuCheck(HWND hwndMenu, USHORT id, BOOL * bool, BOOL toggle,
703 CHAR * savename);
704VOID disable_menuitem(HWND hwndMenu, USHORT id, BOOL enable);
705BOOL ViewHelp(CHAR * filename);
706VOID CloseHelp(VOID);
707INT ExecFile(HWND hwnd, CHAR * filename);
708VOID EmptyCnr(HWND hwnd);
709VOID SetDetailsSwitches(HWND hwnd, DIRCNRDATA * dcd);
710VOID AdjustDetailsSwitches(HWND hwnd, HWND hwndMenu, USHORT cmd,
711 CHAR * directory, CHAR * keyroot, DIRCNRDATA * dcd,
712 BOOL compare);
713VOID FreeMallocedMem(VOID * mem);
714VOID FcloseFile(FILE * fp);
715VOID SetConditionalCascade(HWND hwndMenu, USHORT id, USHORT def);
716VOID SetSortChecks(HWND hwndMenu, INT sortflags);
717VOID SetupCommandMenu(HWND hwndMenu, HWND hwndCnr);
718VOID LoadDetailsSwitches(CHAR * keyroot, DIRCNRDATA * dcd);
719HWND FindDirCnr(HWND hwndParent);
720VOID HeapThread(VOID * dummy);
721VOID FixSwitchList(HWND hwnd, CHAR * text);
722VOID QuickPopup(HWND hwnd, DIRCNRDATA * dcd, HWND hwndMenu, USHORT id);
723PMINIRECORDCORE CurrentRecord(HWND hwndCnr);
724BOOL PostMsg(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
725VOID OpenEdit(HWND hwnd);
726VOID PortholeInit(HWND hwndNew, MPARAM mp1, MPARAM mp2);
727HWND CheckMenu(HWND * hwndMenu, USHORT id);
728SHORT AddToListboxBottom(HWND hwnd, CHAR * str);
729VOID SetSysMenu(HWND hwndSysMenu);
730VOID LoadLibPath(CHAR * str, LONG len);
731void SaySort(HWND hwnd, INT sortflags, BOOL archive);
732void SayView(HWND hwnd, ULONG flWindowAttr);
733void SayFilter(HWND hwnd, MASK * mask, BOOL archive);
734void SetViewMenu(HWND hwndMenu, ULONG flWindowAttr);
735char *GetCmdSpec(BOOL dos);
736void Broadcast(HAB hab, HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
737void SetupWinList(HWND hwndMenu, HWND hwndTop, HWND hwndFrame);
738BOOL SwitchCommand(HWND hwndMenu, USHORT cmd);
[2]739
740/* mainwnd.c */
[551]741ULONG CountDirCnrs(HWND hwndParent);
742HWND TopWindow(HWND hwndParent, HWND exclude);
743HWND TopWindowName(HWND hwndParent, HWND exclude, CHAR * ret);
744HWND FindDirCnrByName(CHAR * directory, BOOL restore);
745MRESULT EXPENTRY MainWndProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
746VOID GetNextWindowPos(HWND hwndClient, PSWP pswp, ULONG * ulCntR,
747 ULONG * ulNumMinChildrenR);
748VOID TileChildren(HWND hwndClient, BOOL absolute);
749VOID FillClient(HWND hwndClient, PSWP pswp, PRECTL prectl, BOOL avoidtree);
750MRESULT EXPENTRY ToolBackProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
751MRESULT EXPENTRY DriveBackProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
752MRESULT EXPENTRY ChildButtonProc(HWND hwnd, ULONG msg, MPARAM mp1,
753 MPARAM mp2);
754MRESULT EXPENTRY DriveProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
755MRESULT EXPENTRY BubbleProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
756BOOL SaveDirCnrState(HWND hwndClient, CHAR * name);
757MRESULT EXPENTRY LEDProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
758MRESULT EXPENTRY StatusProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
759VOID BuildDriveBarButtons(HWND hwndT);
760VOID ResizeDrives(HWND hwndT, long xwidth);
761BOOL CloseChildren(HWND hwndClient);
762VOID BuildTools(HWND hwndT, BOOL resize);
763void BubbleHelp(HWND hwnd, BOOL other, BOOL data, BOOL above, char *help);
764VOID MakeBubble(HWND hwnd, BOOL above, CHAR * help);
765MRESULT EXPENTRY MainWMCommand(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
766VOID MakeMainObjWin(VOID * args);
[2]767
768/* mainwnd2.c */
[551]769MRESULT EXPENTRY MainWndProc2(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
770MRESULT EXPENTRY FileListProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
771HWND StartFM32(HAB hab, INT argc, CHAR ** argv);
[2]772
773/* treecnr.c */
[551]774MRESULT EXPENTRY TreeStatProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
775MRESULT EXPENTRY TreeClientWndProc(HWND hwnd, ULONG msg, MPARAM mp1,
776 MPARAM mp2);
777HWND StartTreeCnr(HWND hwndParent, ULONG flags);
778MRESULT EXPENTRY TreeObjWndProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
779VOID ShowTreeRec(HWND hwndCnr, CHAR * dirname, BOOL collapsefirst,
780 BOOL maketop);
781MRESULT EXPENTRY OpenButtonProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
[2]782
783/* dircnrs.c */
[551]784MRESULT EXPENTRY DirClientWndProc(HWND hwnd, ULONG msg, MPARAM mp1,
785 MPARAM mp2);
786HWND StartDirCnr(HWND hwndParent, CHAR * directory, HWND hwndRestore,
787 ULONG flags);
788MRESULT EXPENTRY DirTextProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
789MRESULT EXPENTRY DirFolderProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
790MRESULT EXPENTRY DirMaxProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
791MRESULT EXPENTRY DirObjWndProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
[2]792
793/* presparm.c */
[551]794VOID StoreWndPresParams(HWND hwnd, CHAR * tagname, HINI prof);
795
[2]796#ifdef INCL_GPI
[551]797VOID SetPresParams(HWND hwnd, RGB2 * back, RGB2 * fore, RGB2 * border,
798 CHAR * font);
[2]799#endif
[551]800VOID CopyPresParams(HWND target, HWND source);
801VOID IfNoParam(HWND hwnd, CHAR * keyroot, ULONG size, PVOID attrvalue);
802VOID PresParamChanged(HWND hwnd, CHAR * keyroot, MPARAM mp1, MPARAM mp2);
803VOID RestorePresParams(HWND hwnd, CHAR * keyroot);
[2]804
805/* dirs.c */
[551]806APIRET save_dir2(CHAR * curdir);
807APIRET save_dir(CHAR * curdir);
808APIRET switch_to(CHAR * s);
[2]809
810/* strips.c */
[365]811VOID chop_at_crnl(PSZ pszSrc);
812PSZ convert_nl_to_nul(PSZ pszSrc);
[551]813void strip_lead_char(char *pszStripChars, char *pszSrc);
814void strip_trail_char(char *pszStripChars, char *pszSrc);
815
[2]816#define lstrip(s) strip_lead_char(" \t",(s))
817#define rstrip(s) strip_trail_char(" \t",(s))
818#define stripcr(s) strip_trail_char("\r\n",(s))
[120]819// Strip leading and trailing white
820#define bstrip(s) (strip_lead_char(" \t",(s)),strip_trail_char(" \t",(s)))
821// Strip leading and trailing white and trail cr/nl
822#define bstripcr(s) (strip_lead_char(" \t",(s)),strip_trail_char("\r\n \t",(s)))
[2]823
824/* delims.c */
[551]825char *skip_delim(char *a, register char *delim);
826char *to_delim(char *a, register char *delim);
[2]827
828/* copyf.c */
[551]829BOOL AdjustWildcardName(CHAR * oldname, CHAR * newname);
[2]830CHAR default_disk(VOID);
[551]831APIRET docopyf(INT type, CHAR * oldname, CHAR * newname, ...);
[2]832
[551]833#define COPY 0
834#define MOVE 1
835#define WPSCOPY 2
836#define WPSMOVE 4
837INT unlinkf(CHAR * string, ...);
838INT unlink_allf(CHAR * string, ...);
839INT wipeallf(CHAR * string, ...);
840INT make_deleteable(CHAR * filename);
841CHAR *TruncName(CHAR * oldname, CHAR * buffer);
842CHAR *GetLongName(CHAR * oldname, CHAR * buffer);
843BOOL WriteLongName(CHAR * filename, CHAR * longname);
844
[2]845/* mkdir.c */
[551]846APIRET SetDir(HWND hwndClient, HWND hwnd, CHAR * dir, INT flags);
847APIRET MassMkdir(HWND hwndClient, CHAR * dir);
848BOOL PMMkDir(HWND hwnd, CHAR * filename, BOOL copy);
849void SetTargetDir(HWND hwnd, BOOL justshow);
[2]850
851/* srchpath.c */
[632]852INT RunFM2Util(CHAR *appname, CHAR *filename);
[551]853CHAR *first_path(CHAR * path, CHAR * ret);
854CHAR *searchapath(CHAR * path, CHAR * filename);
855CHAR *searchpath(CHAR * filename);
[2]856
857/* literal.c */
[120]858UINT literal(PSZ pszBuf);
[551]859BOOL wildcard(const PSZ pszBuf, const PSZ pszWildCard,
860 const BOOL fNotFileSpec);
861PSZ fixup(const PCH pachInBuf, PSZ pszOutBuf, const UINT cBufBytes,
862 const UINT cInBytes);
[2]863
864/* stristr.c */
[551]865CHAR *stristr(const CHAR * t, const CHAR * s);
866CHAR *strnistr(register CHAR * t, CHAR * s, LONG len);
867CHAR *strnstr(register CHAR * t, CHAR * s, LONG len);
868CHAR *findstring(CHAR * findthis, ULONG lenthis, CHAR * findin,
869 ULONG lenin, BOOL insensitive);
[2]870
871/* avl.c */
[551]872ARC_TYPE *quick_find_type(CHAR * filespec, ARC_TYPE * topsig);
873ARC_TYPE *find_type(CHAR * filespec, ARC_TYPE * topsig);
874INT load_archivers(VOID);
875BOOL ArcDateTime(CHAR * dt, INT type, CDATE * cdate, CTIME * ctime);
[2]876
877/* avv.c */
[551]878VOID rewrite_archiverbb2(CHAR * archiverbb2);
879MRESULT EXPENTRY ArcReviewDlgProc(HWND hwnd, ULONG msg, MPARAM mp1,
880 MPARAM mp2);
[419]881VOID EditArchiverDefinition(HWND hwnd);
[2]882
883/* systemf.c */
[551]884BOOL ShowSession(HWND hwnd, PID pid);
885INT ExecOnList(HWND hwnd, CHAR * command, INT flags, CHAR * tpath,
886 CHAR ** list, CHAR * prompt);
887INT runemf2(INT type, HWND hwnd, CHAR * directory, CHAR * environment,
888 CHAR * formatstring, ...);
889HAPP Exec(HWND hwndNotify, BOOL child, char *startdir, char *env,
890 PROGTYPE * progt, ULONG fl, char *formatstring, ...);
[2]891#define SYNCHRONOUS 1
892#define ASYNCHRONOUS 2
893#define DETACHED 3
894#define SEPARATE 4
895#define SEPARATEKEEP 5
896#define WINDOWED 16
897#define MAXIMIZED 32
898#define MINIMIZED 64
899#define FULLSCREEN 128
900#define INVISIBLE 256
901#define BACKGROUND 512
902#define WAIT 1024
903#define PROMPT 2048
904#define KEEP 4096
905#define ONCE 8192
906#define DIEAFTER 16384
907#define SEAMLESS 32768
908#define CHILD 65536
909
910/* cmdline.c */
[551]911BOOL add_cmdline(CHAR * cmdline, BOOL big);
912VOID save_cmdlines(BOOL big);
913MRESULT EXPENTRY CmdLineDlgProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
914MRESULT EXPENTRY CmdLine2DlgProc(HWND hwnd, ULONG msg, MPARAM mp1,
915 MPARAM mp2);
[2]916
917/* makelist.c */
[551]918INT AddToList(CHAR * string, CHAR *** list, INT * numfiles, INT * numalloced);
919INT AddToFileList(CHAR * string, FILEFINDBUF4 * ffb4, FILELIST *** list,
920 INT * numfiles, INT * numalloced);
921CHAR **BuildList(HWND hwndCnr);
922VOID FreeListInfo(LISTINFO * li);
923VOID FreeList(CHAR ** list);
924VOID SortList(LISTINFO * li);
925CHAR **BuildArcList(HWND hwndCnr);
926CHAR **RemoveFromList(CHAR ** list, CHAR * item);
927CHAR **CombineLists(CHAR ** prime, CHAR ** add);
[2]928
929/* chklist.c */
[551]930VOID PosOverOkay(HWND hwnd);
931VOID CenterOverWindow(HWND hwnd);
932BOOL PopupMenu(HWND hwndParent, HWND hwndOwner, HWND hwndMenu);
933MRESULT EXPENTRY CheckListProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
934MRESULT EXPENTRY DropListProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
[2]935
936/* eas.c */
[551]937VOID HexDump(HWND hwnd, CHAR * value, ULONG cbValue);
938HOLDFEA *GetFileEAs(CHAR * filename, BOOL ishandle, BOOL silentfail);
939VOID Free_FEAList(HOLDFEA * pFEA);
940MRESULT EXPENTRY DisplayEAsProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
941PVOID SaveEA(CHAR * filename, HOLDFEA * current, CHAR * newdata,
942 BOOL silentfail);
[2]943
944/* inis.c */
[551]945MRESULT EXPENTRY IniProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
946HWND StartIniEditor(HWND hwnd, CHAR * filename, INT flags);
[2]947
948/* subj.c */
[551]949INT Subject(HWND hwnd, CHAR * filename);
[2]950
951/* dirsize.c */
[551]952MRESULT EXPENTRY DirSizeProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
[2]953
954/* getnames.c */
[551]955BOOL insert_filename(HWND hwnd, CHAR * filename, INT loadit, BOOL newok);
956BOOL export_filename(HWND hwnd, CHAR * filename, INT overwrite);
957MRESULT EXPENTRY CustomFileDlg(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
[2]958
959/* input.c */
[551]960MRESULT EXPENTRY InputDlgProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
[2]961
962/* select.c */
[672]963VOID UnHilite(HWND hwndCnr, BOOL all, CHAR *** list, ULONG ulItemsToUnHilite);
[551]964VOID SelectList(HWND hwndCnr, BOOL partial, BOOL deselect, BOOL clearfirst,
965 PCNRITEM pciParent, CHAR * filename, CHAR ** list);
966VOID SelectAll(HWND hwndCnr, BOOL files, BOOL dirs, CHAR * mask, CHAR * text,
967 BOOL arc);
968VOID DeselectAll(HWND hwndCnr, BOOL files, BOOL dirs, CHAR * mask,
969 CHAR * text, BOOL arc);
970VOID Deselect(HWND hwndCnr);
971VOID HideAll(HWND hwndCnr);
972VOID RemoveAll(HWND hwndCnr, ULONGLONG * ullTotalBytes, ULONG * totalfiles);
973VOID MarkAll(HWND hwndCnr, BOOL quitit, BOOL target, BOOL source);
974VOID SetMask(CHAR * str, MASK * mask);
975VOID ExpandAll(HWND hwndCnr, BOOL expand, PCNRITEM pciParent);
976VOID InvertAll(HWND hwndCnr);
977VOID SpecialSelect(HWND hwndCnrS, HWND hwndCnrD, INT action, BOOL reset);
978VOID SpecialSelect2(HWND hwndParent, INT action);
[2]979
980/* viewer.c */
[551]981MRESULT EXPENTRY MLEEditorProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
982HWND StartMLEEditor(HWND hwnd, INT flags, CHAR * filename, HWND hwndRestore);
[2]983
984/* codepage.c */
[551]985INT PickCodepage(HWND hwnd);
[2]986
987/* fonts.c */
[551]988VOID SetFont(HWND hwnd);
989FATTRS *SetMLEFont(HWND hwndMLE, FATTRS * fattrs, ULONG flags);
990VOID SetPresParamFromFattrs(HWND hwnd, FATTRS * fattrs,
991 SHORT sNominalPointSize, FIXED fxPointSize);
[2]992
993/* saveclip.c */
[551]994BOOL SaveToClip(HWND hwnd, CHAR * text, BOOL append);
995VOID ListToClipboard(HWND hwnd, CHAR ** list, BOOL append);
996CHAR **ListFromClipboard(HWND hwnd);
997BOOL SaveToClipHab(HAB hab, CHAR * text, BOOL append);
998VOID ListToClipboardHab(HAB hab, CHAR ** list, BOOL append);
999CHAR **ListFromClipboardHab(HAB hab);
1000MRESULT EXPENTRY SaveListDlgProc(HWND hwnd, ULONG msg, MPARAM mp1,
1001 MPARAM mp2);
1002MRESULT EXPENTRY SaveAllListDlgProc(HWND hwnd, ULONG msg, MPARAM mp1,
1003 MPARAM mp2);
[2]1004
1005/* filter.c */
[551]1006INT APIENTRY Filter(PMINIRECORDCORE rmini, PVOID arg);
1007BOOL FilterAttrs(PCNRITEM pci, MASK * mask);
1008VOID save_masks(VOID);
1009MRESULT EXPENTRY PickMaskDlgProc(HWND hwnd, ULONG msg, MPARAM mp1,
1010 MPARAM mp2);
[2]1011
1012/* archive.c */
[551]1013MRESULT EXPENTRY ArchiveDlgProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
1014MRESULT EXPENTRY SBoxDlgProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
[2]1015
1016/* extract.c */
[551]1017MRESULT EXPENTRY ExtractDlgProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
[2]1018
1019/* walkem.c */
[551]1020VOID load_udirs(VOID);
1021VOID save_udirs(VOID);
1022BOOL add_udir(BOOL userdirs, CHAR * inpath);
1023BOOL remove_udir(CHAR * path);
1024BOOL remove_ldir(CHAR * path);
1025VOID load_setups(VOID);
1026VOID save_setups(VOID);
1027BOOL add_setup(CHAR * name);
1028BOOL remove_setup(CHAR * name);
1029VOID FillPathListBox(HWND hwnd, HWND hwnddrive, HWND hwnddir, CHAR * path,
1030 BOOL nounwriteable);
1031MRESULT EXPENTRY WalkDlgProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
1032MRESULT EXPENTRY WalkAllDlgProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
1033MRESULT EXPENTRY WalkCopyDlgProc(HWND hwnd, ULONG msg, MPARAM mp1,
1034 MPARAM mp2);
1035MRESULT EXPENTRY WalkMoveDlgProc(HWND hwnd, ULONG msg, MPARAM mp1,
1036 MPARAM mp2);
1037MRESULT EXPENTRY WalkExtractDlgProc(HWND hwnd, ULONG msg, MPARAM mp1,
1038 MPARAM mp2);
1039MRESULT EXPENTRY WalkTargetDlgProc(HWND hwnd, ULONG msg, MPARAM mp1,
1040 MPARAM mp2);
1041MRESULT EXPENTRY WalkTwoDlgProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
1042MRESULT EXPENTRY WalkTwoCmpDlgProc(HWND hwnd, ULONG msg, MPARAM mp1,
1043 MPARAM mp2);
1044MRESULT EXPENTRY WalkTwoSetDlgProc(HWND hwnd, ULONG msg, MPARAM mp1,
1045 MPARAM mp2);
[2]1046
1047/* arccnrs.c */
[551]1048MRESULT EXPENTRY ArcClientWndProc(HWND hwnd, ULONG msg, MPARAM mp1,
1049 MPARAM mp2);
1050HWND StartArcCnr(HWND hwndParent, HWND hwndCaller, CHAR * arcname, INT flags,
1051 ARC_TYPE * sinfo);
1052MRESULT EXPENTRY ArcTextProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
1053MRESULT EXPENTRY ArcFolderProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
1054MRESULT EXPENTRY ArcObjWndProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
[2]1055
1056/* assoc.c */
[551]1057INT ExecAssociation(HWND hwnd, CHAR * datafile);
1058VOID EditAssociations(HWND hwnd);
1059VOID load_associations(VOID);
1060VOID save_associations(VOID);
[2]1061
1062/*draglist.c */
[551]1063HWND DoFileDrag(HWND hwndCnr, HWND hwndObj, PCNRDRAGINIT pcd, CHAR * arcfile,
1064 CHAR * directory, BOOL moveok);
1065HWND DragOne(HWND hwndCnr, HWND hwndObj, CHAR * filename, BOOL moveok);
1066HWND DragList(HWND hwnd, HWND hwndObj, CHAR ** list, BOOL moveok);
1067BOOL PickUp(HWND hwndCnr, HWND hwndObj, PCNRDRAGINIT pcd);
[2]1068
1069/* droplist.c */
[551]1070void DropHelp(MPARAM mp1, MPARAM mp2, HWND hwnd, char *text);
[618]1071BOOL AcceptOneDrop(HWND hwnd, MPARAM mp1, MPARAM mp2);
1072BOOL GetOneDrop(HWND hwnd, MPARAM mp1, MPARAM mp2, char *buffer, ULONG buflen);
[551]1073BOOL FullDrgName(PDRAGITEM pDItem, CHAR * buffer, ULONG buflen);
1074BOOL TwoDrgNames(PDRAGITEM pDItem, CHAR * buffer1, ULONG buflen1,
1075 char *buffer2, ULONG buflen2);
1076LISTINFO *DoFileDrop(HWND hwndCnr, CHAR * directory, BOOL arcfilesok,
1077 MPARAM mp1, MPARAM mp2);
[618]1078VOID FreeDragInfoData (HWND hwnd, PDRAGINFO pDInfo);
[687]1079BOOL CheckPmDrgLimit(PDRAGINFO pDInfo);
[2]1080
1081/* shadow.c */
[551]1082HOBJECT CreateProgramObject(CHAR * objtitle, CHAR * location, CHAR * path,
1083 CHAR * cnr);
1084HOBJECT CreateDataObject(CHAR * objtitle, CHAR * location, CHAR * path,
1085 CHAR * cnr);
1086HOBJECT CreateFolderObject(CHAR * objtitle, CHAR * cnr);
1087HOBJECT CreateShadowObject(CHAR * objtitle, CHAR * location, CHAR * path,
1088 BOOL executable, CHAR * cnr);
1089VOID MakeShadows(HWND hwnd, CHAR ** list, ULONG Shadows, CHAR * cnr,
1090 CHAR * foldername);
1091VOID OpenObject(CHAR * filename, CHAR * type, HWND hwnd);
1092BOOL RunSeamless(CHAR * exename, CHAR * args, HWND hwnd);
[2]1093
1094/* printer.c */
[551]1095BOOL PrinterReady(CHAR * printdevname);
1096BOOL SayPrinterReady(HWND hwnd);
1097VOID PrintListThread(VOID * arg);
1098MRESULT EXPENTRY PrintDlgProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
[2]1099
1100/* attribs.c */
[551]1101MRESULT EXPENTRY AttrListDlgProc(HWND hwnd, ULONG msg, MPARAM mp1,
1102 MPARAM mp2);
[2]1103
1104/* rename.c */
[551]1105MRESULT EXPENTRY RenameProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
[2]1106
1107/* comp.c */
[551]1108MRESULT EXPENTRY CFileDlgProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
1109MRESULT EXPENTRY CompareDlgProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
[2]1110
1111/* findrec.c */
[551]1112PCNRITEM FindCnrRecord(HWND hwndCnr, CHAR * filename, PCNRITEM pciParent,
1113 BOOL partial, BOOL partmatch, BOOL noenv);
1114PCNRITEM FindParentRecord(HWND hwndCnr, PCNRITEM pciC);
1115VOID ShowCnrRecord(HWND hwndCnr, PMINIRECORDCORE pmi);
[2]1116
1117/* update.c */
[557]1118HPOINTER SelectDriveIcon(PCNRITEM pci);
[551]1119PCNRITEM UpdateCnrRecord(HWND hwndCnr, CHAR * filename, BOOL partial,
1120 DIRCNRDATA * dcd);
1121BOOL UpdateCnrList(HWND hwndCnr, CHAR ** filename, INT howmany, BOOL partial,
1122 DIRCNRDATA * dcd);
[2]1123
1124/* info.c */
[551]1125MRESULT EXPENTRY DrvInfoProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
1126MRESULT EXPENTRY FileInfoProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
1127MRESULT EXPENTRY SetDrvProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
[2]1128
[689]1129#if defined(__IBMC__)
[2]1130/* fsopen.c */
[551]1131FILE *_fsopen(CHAR * filename, CHAR * mode, INT sharemode, ...);
[689]1132#endif
[2]1133
1134/* seticon.c */
[551]1135MRESULT EXPENTRY SetIconDlgProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
[2]1136
1137/* objcnr.c */
[551]1138MRESULT EXPENTRY ObjCnrDlgProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
[2]1139
1140/* sortcnr.c */
[551]1141SHORT APIENTRY SortTreeCnr(PMINIRECORDCORE p1, PMINIRECORDCORE p2,
1142 PVOID pStorage);
1143SHORT APIENTRY SortDirCnr(PMINIRECORDCORE p1, PMINIRECORDCORE p2,
1144 PVOID pStorage);
1145SHORT APIENTRY SortCollectorCnr(PMINIRECORDCORE p1, PMINIRECORDCORE p2,
1146 PVOID pStorage);
1147SHORT SortCnr(PMINIRECORDCORE p1, PMINIRECORDCORE p2, INT Sortflags);
[2]1148
1149/* collect.c */
[551]1150MRESULT EXPENTRY CollectorClientWndProc(HWND hwnd, ULONG msg, MPARAM mp1,
1151 MPARAM mp2);
1152MRESULT EXPENTRY CollectorTextProc(HWND hwnd, ULONG msg, MPARAM mp1,
1153 MPARAM mp2);
1154HWND StartCollector(HWND hwndParent, INT flags);
1155MRESULT EXPENTRY CollectorObjWndProc(HWND hwnd, ULONG msg, MPARAM mp1,
1156 MPARAM mp2);
[2]1157
1158/* command.c */
[551]1159VOID RunCommand(HWND hwnd, INT cx);
1160VOID EditCommands(HWND hwnd);
1161CHAR *command_title(INT cx);
1162VOID load_commands(VOID);
[2]1163
1164/* instant.c */
[551]1165MRESULT EXPENTRY InstantDlgProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
[2]1166
1167/* undel.c */
[551]1168MRESULT EXPENTRY UndeleteDlgProc(HWND hwnd, ULONG msg, MPARAM mp1,
1169 MPARAM mp2);
[2]1170
1171/* killproc.c */
[551]1172MRESULT EXPENTRY KillDlgProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
[2]1173
1174/* sysinfo.c */
[551]1175MRESULT EXPENTRY SysInfoDlgProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
[2]1176
1177/* objwin.c */
[551]1178MRESULT EXPENTRY ObjectWndProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
1179VOID MakeObjWin(VOID * args);
[2]1180
1181/* progstup.c */
[551]1182MRESULT EXPENTRY ProgDlgProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
[2]1183
1184/* key.c */
[551]1185MRESULT EXPENTRY AboutDlgProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
[2]1186
1187/* notify.c */
[551]1188MRESULT EXPENTRY NotifyWndProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
1189HWND Notify(char *text);
1190HWND DoNotify(char *text);
1191VOID NotifyError(CHAR * filename, APIRET error);
1192VOID StartNotes(CHAR * s);
1193BOOL AddNote(CHAR * note);
1194VOID EndNote(VOID);
1195VOID ShowNote(VOID);
1196VOID HideNote(VOID);
[2]1197
1198/* winlist.c */
1199VOID WindowList(HWND hwnd);
1200
1201/* viewinf.c */
[551]1202MRESULT EXPENTRY ViewInfProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
[2]1203
1204/* notebook.c */
[551]1205MRESULT EXPENTRY CfgDlgProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
[2]1206
1207/* commafmt.c */
[551]1208size_t commafmt(PSZ pszBuf, UINT cBufSize, LONG lNumber);
1209size_t CommaFmtUL(char *pszBuf, UINT cBufSize, ULONG ullNumber,
[165]1210 CHAR chPreferred);
[551]1211size_t CommaFmtULL(char *pszBuf, UINT cBufSize, ULONGLONG ullNumber,
[165]1212 CHAR chPreferred);
[2]1213
1214/* autoview.c */
[551]1215BOOL WriteEA(HWND hwnd, CHAR * filename, CHAR * eaname, USHORT type,
1216 CHAR * data);
1217BOOL PutComments(HWND hwnd, CHAR * filename, CHAR * comments);
1218MRESULT EXPENTRY AutoViewProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
1219ULONG CreateHexDump(CHAR * value, ULONG cbValue, CHAR * ret, ULONG retlen,
1220 ULONG startval, BOOL longlead);
[2]1221
1222/* menu.c */
[551]1223BOOL AddToMenu(CHAR * filename, HWND hwndMenu);
[2]1224
1225/* worker.c */
[551]1226VOID MassAction(VOID * args);
1227VOID Action(VOID * args);
[2]1228
1229/* fm2cmd.c */
[551]1230BOOL FM2Command(CHAR * directory, CHAR * command);
[2]1231
1232/* seeall.c */
[551]1233MRESULT EXPENTRY SeeAllWndProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
1234MRESULT EXPENTRY SeeStatusProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
1235HWND StartSeeAll(HWND hwndParent, BOOL standalone, CHAR * startpath);
[2]1236
1237/* newview.c */
[551]1238MRESULT EXPENTRY ViewWndProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
1239MRESULT EXPENTRY ViewStatusProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
1240HWND StartViewer(HWND hwndParent, USHORT flags, CHAR * filename,
1241 HWND hwndRestore);
[2]1242
1243/* colors.c */
[551]1244MRESULT EXPENTRY ColorDlgProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
[2]1245
1246/* defview.c */
[551]1247BOOL ShowMultimedia(CHAR * filename);
1248VOID DefaultView(HWND hwnd, HWND hwndFrame, HWND hwndParent, SWP * swp,
1249 ULONG flags, CHAR * filename);
1250VOID DefaultViewKeys(HWND hwnd, HWND hwndFrame, HWND hwndParent,
1251 SWP * swp, CHAR * filename);
[2]1252#define QuickView(h,f) DefaultView(h,(HWND)0,(HWND)0,NULL,0,f)
1253#define QuickEdit(h,f) DefaultView(h,(HWND)0,(HWND)0,NULL,8,f)
1254
1255/* catalog.c */
[551]1256MRESULT EXPENTRY CatalogProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
[2]1257
1258/* uudecode.c */
[551]1259int UUD(char *filename, char *outname);
1260MRESULT EXPENTRY MergeDlgProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
[2]1261
1262/* loadbmp.c */
[551]1263HBITMAP LoadBitmapFromFileNum(USHORT id);
1264HBITMAP LoadBitmapFromFile(CHAR * pszFileName);
[2]1265
1266/* remap.c */
[551]1267MRESULT EXPENTRY RemapDlgProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
[2]1268
1269/* timer.c */
[551]1270BOOL StartTimer(void);
1271void StopTimer(void);
[2]1272
1273/* grep2.c */
[551]1274MRESULT EXPENTRY GrepDlgProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
[2]1275
1276/* common.c */
[551]1277MRESULT EXPENTRY CommonFrameWndProc(USHORT id,
1278 HWND hwnd,
1279 ULONG msg, MPARAM mp1, MPARAM mp2);
1280MRESULT EXPENTRY CommonTextProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
1281void CommonTextPaint(HWND hwnd, HPS hps);
1282void CommonCreateTextChildren(HWND hwnd, char *class, USHORT * ids);
1283void CommonDriveCmd(HWND hwnd, char *drive, USHORT cmd);
1284void CommonCreateMainChildren(HWND hwnd, SWP * swp);
1285MRESULT EXPENTRY CommonMainWndProc(HWND hwnd, ULONG msg, MPARAM mp1,
1286 MPARAM mp2);
1287MRESULT EXPENTRY CommonTextButton(HWND hwnd, ULONG msg, MPARAM mp1,
1288 MPARAM mp2);
1289MRESULT EXPENTRY CommonCnrProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
1290HWND OpenDirCnr(HWND hwnd, HWND hwndParent, HWND hwndRestore,
1291 BOOL noautotile, char *directory);
[520]1292VOID IncrThreadUsage(VOID);
1293VOID DecrThreadUsage(VOID);
[2]1294
1295/* string.c */
[551]1296BOOL LoadStrings(char *filename);
1297char *GetPString(ULONG id);
1298BOOL StringsLoaded(void);
[2]1299
[337]1300/* wrappers.c */
[551]1301PSZ xfgets(PSZ pszBuf, size_t cMaxBytes, FILE * fp, PCSZ pszSrcFile,
1302 UINT uiLineNumber);
1303PSZ xfgets_bstripcr(PSZ pszBuf, size_t cMaxBytes, FILE * fp, PCSZ pszSrcFile,
1304 UINT uiLineNumber);
1305FILE *xfopen(PCSZ pszFileName, PCSZ pszMode, PCSZ pszSrcFile,
1306 UINT uiLineNumber);
1307FILE *xfsopen(PCSZ pszFileName, PCSZ pszMode, INT fSharemode, PCSZ pszSrcFile,
1308 UINT uiLineNumber);
1309VOID xfree(PVOID pv);
[337]1310PVOID xmalloc(size_t cBytes, PCSZ pszSrcFile, UINT uiLineNumber);
1311PVOID xmallocz(size_t cBytes, PCSZ pszSrcFile, UINT uiLineNumber);
1312PVOID xrealloc(PVOID pvIn, size_t cBytes, PCSZ pszSrcFile, UINT uiLineNumber);
1313PVOID xstrdup(PCSZ pszIn, PCSZ pszSrcFile, UINT uiLineNumber);
1314
1315//=====================================================================
1316
[2]1317#ifdef DEFINE_GLOBALS
[551]1318#define DATADEF
[2]1319#else
[551]1320#define DATADEF extern
[2]1321#endif
1322
1323DATADEF ARC_TYPE *arcsighead;
[551]1324DATADEF BOOL arcsigsloaded;
1325DATADEF BOOL arcsigsmodified;
1326DATADEF UINT arcsigs_header_lines; // Header comments line count in archiver.bb2
1327DATADEF UINT arcsigs_trailer_line_num; // Trailer comments start line number (1..n)
[311]1328
[551]1329DATADEF USHORT nodes, shiftstate;
1330DATADEF HEV CompactSem;
1331DATADEF HWND hwndMain, hwndTree, hwndStatus, hwndStatus2, hwndTrash,
1332 hwndButtonlist, hwndDrivelist, hwndStatelist, hwndUserlist,
1333 hwndAutoview, hwndAttr, hwndDate, hwndName, hwndBack,
1334 hwndLED, hwndLEDHdr, hwndAutoMLE, hwndCmdlist;
1335DATADEF HBITMAP hbmLEDon, hbmLEDoff;
1336DATADEF CHAR ArcTempRoot[9];
1337DATADEF HPOINTER hptrArrow, hptrBusy, hptrLast, hptrDir, hptrFile, hptrRemote,
[552]1338 hptrFloppy, hptrDrive, hptrRemovable, hptrCDROM,hptrVirtual,hptrRamdisk,
[551]1339 hptrFinger, hptrApp, hptrDunno, hptrSystem, hptrHidden,
1340 hptrReadonly, hptrNS, hptrZipstrm, hptrArc, hptrArt, hptrEW,
1341 hptrCommon, hptrEnv;
1342DATADEF PFNWP PFNWPCnr, PFNWPFrame, PFNWPButton, PFNWPStatic, PFNWPMLE;
1343DATADEF BOOL fLoadSubject, fLoadLongnames, fForceUpper, fForceLower,
1344 fSyncUpdates, fAutoTile, fDontMoveMouse, loadedudirs,
1345 fUnHilite, fWorkPlace, fConfirmDelete, fToolbar,
1346 fToolsChanged, MenuInvisible, fFreeTree, fFollowTree,
1347 fNoIconsFiles, fNoIconsDirs, fVerify, fDCOpens,
1348 fLinkSetsIcon, fSaveState, fTextTools, fCopyDefault,
1349 fToolTitles, fLogFile, fRealIdle, fNoSaveState,
1350 fSplitStatus, fArcStuffVisible, fUseMCI, fAmAV2,
1351 fNoTreeGap, fDummy, fVTreeOpensWPS, fUseQProcStat,
1352 fStartMinimized, fStartMaximized, fRemoteBug, fReminimize,
1353 fDragndropDlg, fMinOnOpen, fUserComboBox, loadedsetups,
1354 fQuickArcFind, fNoRemovableScan, fAutoView, fDataMin,
1355 fDataToFore, fDataShowDrives, fDataInclRemote,
1356 fExternalArcboxes, fExternalViewer, fExternalCollector,
1357 fExternalINIs, fDefaultDeletePerm, fIniExisted, fUseNewViewer,
1358 fTileBackwards, fFolderAfterExtract, fUserListSwitches,
1359 fGuessType, fAutoAddDirs, fUdirsChanged, fSelectedAlways,
1360 fToolbarHelp, fComments, fMoreButtons, fNoSearch, fOtherHelp,
1361 fKeepCmdLine, fAmClosing, fSeparateParms, fTopDir,
1362 fLookInDir, fSwitchTree, fSwitchTreeOnFocus, fDrivebar,
1363 fSwitchTreeExpand, fCollapseFirst, fFilesInTree, fNoDead,
1364 fThreadNotes, fOkayMinimize, fRunning, fDullMin, fBlueLED,
[633]1365 fViewChild, fShowEnv, fLeaveTree, fNoFoldMenu,
[551]1366 fCustomFileDlg, fSaveMiniCmds, fSaveBigCmds, fNoTileUpdate,
1367 fFM2Deletes, fAutoAddAllDirs, fConfirmTarget, fChangeTarget,
[606]1368 fFirstTime, fShowTarget, fNoFinger, fDrivebarHelp, fCheckMM;
[551]1369DATADEF BOOL detailsladate, detailslatime, detailscrdate, detailscrtime,
1370 detailslongname, detailsea, detailssize, detailssubject,
1371 detailslwdate, detailslwtime, detailsattr, detailsicon;
1372DATADEF PID mypid;
1373DATADEF INT driveflags[26], driveserial[26];
[672]1374DATADEF ULONG NoBrokenNotify, fwsAnimate, OS2ver[2], DriveLines;
[551]1375DATADEF HINI fmprof;
1376DATADEF HELPINIT hini;
1377DATADEF HWND hwndHelp, LastDir, AboutBox, DirMenu, FileMenu, TreeMenu,
1378 ArcMenu, DirCnrMenu, TreeCnrMenu, ArcCnrMenu,
1379 CollectorCnrMenu, CollectorFileMenu, CollectorDirMenu,
1380 Collector, MainPopupMenu, DataHwnd, AutoMenu, hwndBubble,
1381 hwndToolback, MainObjectHwnd;
[2]1382#ifdef DEFINE_GLOBALS
[551]1383#pragma data_seg(GLOBAL2)
[2]1384#endif
[551]1385DATADEF CHAR *DEBUG_STRING, *FM3Str, *FM2Str, *NullStr, *Default, *Settings,
1386 *DRM_OS2FILE, *DRM_FM2ARCMEMBER, *DRF_FM2ARCHIVE,
1387 *DRMDRFLIST, *DRMDRFOS2FILE, *DRMDRFFM2ARC,
1388 *DRM_FM2INIRECORD, *DRF_FM2INI, *SUBJECT, *LONGNAME,
[555]1389 *HPFS, *JFS, *CDFS, *FAT32, *HPFS386, *NDFS32, *CBSIFS, *ISOFS, *RAMFS, *NTFS,
[552]1390 *WPProgram, *FM3Folder, *FM3Tools;
[551]1391DATADEF RGB2 RGBGREY, RGBBLACK;
1392DATADEF CHAR archiverbb2[CCHMAXPATH], StopPrinting, profile[CCHMAXPATH];
1393DATADEF CHAR appname[12], realappname[12];
1394DATADEF CHAR editor[CCHMAXPATH], viewer[CCHMAXPATH],
1395 virus[CCHMAXPATH], printer[CCHMAXPATH],
1396 compare[CCHMAXPATH], extractpath[CCHMAXPATH],
1397 lastextractpath[CCHMAXPATH], lasttoolbox[CCHMAXPATH],
1398 HomePath[CCHMAXPATH], SwapperDat[CCHMAXPATH],
1399 binview[CCHMAXPATH], bined[CCHMAXPATH],
1400 dircompare[CCHMAXPATH], szDefArc[CCHMAXPATH],
1401 ftprun[CCHMAXPATH], httprun[CCHMAXPATH], targetdir[CCHMAXPATH];
1402DATADEF HMODULE FM3DllHandle, FM3ModHandle;
1403DATADEF CHAR *quicktool[50];
1404DATADEF BOOL qtloaded;
1405DATADEF INT sortFlags, TreesortFlags, CollectorsortFlags;
1406DATADEF INT butxsize, butysize;
1407DATADEF FILE *LogFileHandle;
1408DATADEF ULONG ulCnrType, FilesToGet, AutoviewHeight, TreeWidth, FM3UL;
1409DATADEF long prnwidth, prnlength, prntmargin, prnbmargin, prnlmargin,
1410 prnrmargin, prnspacing, prntabspaces;
1411DATADEF BOOL prnpagenums, prnformat, prnformfeedbefore, prnformfeedafter,
1412 prnalt;
1413DATADEF LINKDIRS *udirhead, *ldirhead;
1414DATADEF LINKCMDS *cmdhead, *cmdtail;
1415DATADEF BOOL cmdloaded;
[593]1416DATADEF CHAR *WC_OBJECTWINDOW, *WC_BUBBLE, *WC_TOOLBUTTONS, *WC_DRIVEBUTTONS, *WC_DIRCONTAINER,
1417 *WC_DIRSTATUS, *WC_TREECONTAINER, *WC_TREEOPENBUTTON, *WC_TREESTATUS, *WC_MAINWND,
1418 *WC_MAINWND2, *WC_AUTOVIEW, *WC_LED, *WC_COLLECTOR, *WC_COLSTATUS, *WC_STATUS, *WC_TOOLBACK,
1419 *WC_DRIVEBACK, *WC_ARCCONTAINER, *WC_ARCSTATUS, *WC_MLEEDITOR, *WC_INIEDITOR, *WC_SEEALL,
1420 *WC_NEWVIEW, *WC_SEESTATUS, *WC_VIEWSTATUS, *WC_ERRORWND, *WC_MINITIME, *WC_DATABAR;
[551]1421
[2]1422#ifdef DEFINE_GLOBALS
[551]1423#pragma data_seg(GLOBAL3)
[2]1424#endif
1425#define MAXNUMSETUPS 100
[551]1426DATADEF CHAR lastsetups[MAXNUMSETUPS][13];
1427DATADEF INT lastsetup;
1428DATADEF LONG standardcolors[16];
[2]1429
1430#ifdef INCL_MMIOOS2
1431#pragma pack(4)
1432/* definitions for MMPM/2 imports */
[551]1433typedef DWORD(APIENTRY MMIOIDENTIFYFILE) (PSZ, PMMIOINFO, PMMFORMATINFO,
1434 PFOURCC, DWORD, DWORD);
[2]1435typedef MMIOIDENTIFYFILE *PMMIOIDENTIFYFILE;
[570]1436typedef DWORD(APIENTRY MMIOOPEN)( PSZ, PMMIOINFO, DWORD);
1437typedef MMIOOPEN *PMMIOOPEN;
1438typedef WORD (APIENTRY MMIOGETINFO)( HMMIO, PMMIOINFO, WORD);
1439typedef MMIOGETINFO *PMMIOGETINFO;
1440typedef WORD (APIENTRY MMIOCLOSE)( HMMIO, WORD);
1441typedef MMIOCLOSE *PMMIOCLOSE;
[551]1442
[2]1443#pragma pack()
1444#endif
1445
1446#ifdef DEFINE_GLOBALS
[551]1447#pragma data_seg(GLOBAL4)
[2]1448#endif
[551]1449DATADEF HSWITCH switches[499];
1450DATADEF ULONG numswitches;
[2]1451
1452#define priority_idle() DosSetPriority(PRTYS_THREAD,PRTYC_IDLETIME,30L,0L)
1453#define priority_normal() DosSetPriority(PRTYS_THREAD,PRTYC_REGULAR,0L,0L)
1454#define priority_tweaked() DosSetPriority(PRTYS_THREAD,PRTYC_REGULAR,1L,0L)
1455#define priority_bumped() DosSetPriority(PRTYS_THREAD,PRTYC_REGULAR,3L,0L)
1456#define priority_critical() DosSetPriority(PRTYS_THREAD,PRTYC_FOREGROUNDSERVER,2L,0L)
1457#define priority_max() DosSetPriority(PRTYS_THREAD,PRTYC_FOREGROUNDSERVER,31L,0L)
1458#define SysVal(value) WinQuerySysValue(HWND_DESKTOP, (value))
Note: See TracBrowser for help on using the repository browser.