source: trunk/dll/fm3dll.h@ 627

Last change on this file since 627 was 627, checked in by Gregg Young, 19 years ago

Eliminate global fAddUtils so can search both path and \utils for FM2PLAY.EXE & Image.exe

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