source: trunk/global.c@ 1176

Last change on this file since 1176 was 1176, checked in by John Small, 17 years ago

Ticket 187: Draft 2: Move remaining function declarations

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 2.1 KB
Line 
1
2/***********************************************************************
3
4 $Id: global.c 1176 2008-09-10 21:52:46Z jbs $
5
6 See all files applet
7
8 Copyright (c) 1993-98 M. Kimes
9 Copyright (c) 2008 Steven H.Levine
10
11 05 Jan 08 SHL Sync
12
13***********************************************************************/
14
15#include <string.h>
16
17#define INCL_DOS
18#define INCL_WIN
19
20#include "dll\fm3dll.h"
21#include "dll\fm3str.h"
22#include "dll\seeall.h" // StartSeeAll
23#include "dll\valid.h" // IsFile
24#include "dll\init.h" // InitFM3DLL
25
26int main(int argc, char *argv[])
27{
28 HAB hab;
29 HMQ hmq;
30 QMSG qmsg;
31 HWND hwndFrame;
32 static CHAR fullname[CCHMAXPATH];
33 INT x;
34
35 *fullname = 0;
36 strcpy(appname, "SEEALL");
37 DosError(FERR_DISABLEHARDERR);
38 hab = WinInitialize(0);
39 if (hab) {
40 hmq = WinCreateMsgQueue(hab, 1024);
41 if (hmq) {
42 if (InitFM3DLL(hab, argc, argv)) {
43 for (x = 1; x < argc; x++) {
44 if (!strchr("/;,`\'", *argv[x]) && !*fullname &&
45 (IsRoot(argv[x]) || IsFile(argv[x]) == 0)) {
46 if (IsRoot(argv[x]))
47 strcpy(fullname, argv[x]);
48 else if (DosQueryPathInfo(argv[x],
49 FIL_QUERYFULLNAME,
50 fullname, sizeof(fullname)))
51 *fullname = 0;
52 }
53 }
54 hwndFrame = StartSeeAll(HWND_DESKTOP, TRUE, fullname);
55 if (hwndFrame) {
56 for (;;) {
57 if (!WinGetMsg(hab, &qmsg, (HWND) 0, 0, 0)) {
58 if (qmsg.hwnd)
59 qmsg.msg = WM_CLOSE;
60 else
61 break;
62 }
63 if (hwndBubble &&
64 ((qmsg.msg > (WM_BUTTON1DOWN - 1) &&
65 qmsg.msg < (WM_BUTTON3DBLCLK + 1)) ||
66 (qmsg.msg > (WM_CHORD - 1) &&
67 qmsg.msg < (WM_BUTTON3CLICK + 1))) &&
68 WinIsWindowVisible(hwndBubble))
69 WinShowWindow(hwndBubble, FALSE);
70 WinDispatchMsg(hab, &qmsg);
71 }
72 DosSleep(125L);
73 }
74 }
75 DosSleep(125L);
76 WinDestroyMsgQueue(hmq);
77 }
78 WinTerminate(hab);
79 }
80 return 0;
81}
Note: See TracBrowser for help on using the repository browser.