source: trunk/dll/misc.h

Last change on this file was 1840, checked in by Steven Levine, 10 years ago

Expose GetTidForThread and use

  • Property svn:eolstyle set to native
  • Property svn:keywords set to Id
File size: 3.8 KB
Line 
1
2/***********************************************************************
3
4 $Id: misc.h 1840 2015-08-12 05:06:11Z stevenhl $
5
6 Misc utility functions
7
8 Copyright (c) 1993-98 M. Kimes
9 Copyright (c) 2008, 2015 Steven H. Levine
10
11 17 Jul 08 SHL Baseline
12 08 Mar 09 GKY Add WriteDetailsSwitches and use LoadDetailsSwitches to replace in line code
13 22 Jul 09 GKY Check if drives support EAs add driveflag for this
14 22 Jul 09 GKY Allow .LONGNAME to be displayed for FAT drives.
15 09 Aug 15 SHL Expose GetTidForThread
16
17***********************************************************************/
18
19#if !defined(MISC_H)
20#define MISC_H
21
22#if !defined(OS2_INCLUDED)
23#include <os2.h>
24#endif
25
26#include "dircnrs.h" // typedef for DETAILS_SETTINGS
27
28UINT GetTidForThread(VOID);
29
30#ifdef FORTIFY
31UINT GetTidForWindow(HWND hwnd);
32#endif
33
34SHORT AddToListboxBottom(HWND hwnd, PCSZ str);
35BOOL AdjustCnrColRO(HWND hwndCnr, PCSZ title, BOOL readonly, BOOL toggle);
36BOOL AdjustCnrColVis(HWND hwndCnr, PCSZ title, BOOL visible, BOOL toggle);
37VOID AdjustCnrColsForFSType(HWND hwndCnr, PCSZ directory, DETAILS_SETTINGS *pds, BOOL compare);
38VOID AdjustCnrColsForPref(HWND hwndCnr, PCSZ directory, DETAILS_SETTINGS *pds,
39 BOOL compare);
40VOID AdjustDetailsSwitches(HWND hwnd, HWND hwndMenu, USHORT cmd,
41 PCSZ directory, PCSZ keyroot, DETAILS_SETTINGS * pds,
42 BOOL compare);
43void BoxWindow(HWND hwnd, HPS hps, LONG color);
44void Broadcast(HAB hab, HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
45INT CheckDriveSpaceAvail(PCSZ pTargetPath, ULONGLONG ullSpaceNeeded,
46 ULONGLONG ullFreeSpaceWhenComplete);
47HWND CheckMenu(HWND hwnd, HWND * hwndMenu, USHORT id);
48MRESULT CnrDirectEdit(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
49PMINIRECORDCORE CurrentRecord(HWND hwndCnr);
50void DrawTargetEmphasis(HWND hwnd, BOOL on);
51void EmphasizeButton(HWND hwnd, BOOL on);
52INT ExecFile(HWND hwnd, PCSZ filename);
53HWND FindDirCnr(HWND hwndParent);
54VOID FixSwitchList(HWND hwnd, PCSZ text);
55char *GetCmdSpec(BOOL dos);
56VOID HeapThread(VOID * dummy);
57BOOL IsFm2Window(HWND hwnd, BOOL chkTid);
58VOID LoadDetailsSwitches(PCSZ keyroot, DETAILS_SETTINGS *pds, BOOL state);
59VOID WriteDetailsSwitches(PCSZ keyroot, DETAILS_SETTINGS *pds, BOOL state);
60VOID RemoveCnrSwitches(PCSZ keyroot, PCSZ statename);
61VOID RemoveOldCnrSwitches(PCSZ szPrefix, ULONG ulTemp);
62VOID LoadLibPath(PSZ str, LONG len);
63VOID OpenEdit(HWND hwnd);
64VOID PaintRecessedWindow(HWND hwnd, HPS hps, BOOL outtie, BOOL dbl);
65void PaintSTextWindow(HWND hwnd, HPS hps);
66VOID PortholeInit(HWND hwndNew, MPARAM mp1, MPARAM mp2);
67BOOL PostMsg(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
68VOID QuickPopup(HWND hwnd, DIRCNRDATA * dcd, HWND hwndMenu, USHORT id);
69void SayFilter(HWND hwnd, MASK * mask, BOOL archive);
70void SaySort(HWND hwnd, INT sortflags, BOOL archive);
71void SayView(HWND hwnd, ULONG flWindowAttr);
72BOOL SetCnrCols(HWND hwndCnr, BOOL compare);
73VOID SetConditionalCascade(HWND hwndMenu, USHORT id, USHORT def);
74VOID SetDetailsSwitches(HWND hwnd, DETAILS_SETTINGS * pds);
75BOOL SetMenuCheck(HWND hwndMenu, USHORT id, BOOL * bool, BOOL toggle,
76 PCSZ savename);
77VOID SetShiftState(VOID);
78VOID SetSortChecks(HWND hwndMenu, INT sortflags);
79VOID SetSysMenu(HWND hwndSysMenu);
80void SetViewMenu(HWND hwndMenu, ULONG flWindowAttr);
81VOID SetupCommandMenu(HWND hwndMenu, HWND hwndCnr);
82void SetupWinList(HWND hwndMenu, HWND hwndTop, HWND hwndFrame);
83BOOL SwitchCommand(HWND hwndMenu, USHORT cmd);
84BOOL ViewHelp(PCSZ filename);
85VOID disable_menuitem(HWND hwndMenu, USHORT id, BOOL enable);
86
87// Data declarations
88extern HWND CollectorDirMenu;
89extern HWND CollectorFileMenu;
90extern HWND DirMenu;
91extern HWND FileMenu;
92extern HWND TreeMenu;
93extern BOOL fDefaultDeletePerm;
94extern BOOL fWorkPlace;
95extern ULONG numswitches;
96extern HSWITCH switches[499];
97
98#endif // MISC_H
Note: See TracBrowser for help on using the repository browser.