| Last change
 on this file since 720 was             551, checked in by Gregg Young, 19 years ago | 
        
          | 
Indentation cleanup
 | 
        
          | 
              
Property                 svn:eol-style
 set to                 native
Property                 svn:keywords
 set to                 Author Date Id Revision | 
        
          | File size:
            1.2 KB | 
      
      
| Rev | Line |  | 
|---|
| [2] | 1 | #define INCL_DOS | 
|---|
|  | 2 | #define INCL_WIN | 
|---|
|  | 3 |  | 
|---|
|  | 4 | #include <os2.h> | 
|---|
|  | 5 | #include <stdarg.h> | 
|---|
|  | 6 | #include <stdio.h> | 
|---|
|  | 7 | #include <stdlib.h> | 
|---|
|  | 8 | #include <string.h> | 
|---|
|  | 9 | #include <ctype.h> | 
|---|
|  | 10 | #include "dll\fm3dll.h" | 
|---|
|  | 11 | #include "dll\fm3dlg.h" | 
|---|
|  | 12 |  | 
|---|
| [551] | 13 | int main(int argc, char *argv[]) | 
|---|
|  | 14 | { | 
|---|
| [2] | 15 |  | 
|---|
| [551] | 16 | HAB hab; | 
|---|
|  | 17 | HMQ hmq; | 
|---|
| [2] | 18 | FILESTATUS3 fs; | 
|---|
|  | 19 | static CHAR fullname[CCHMAXPATH]; | 
|---|
| [551] | 20 | CHAR *thisarg = NULL; | 
|---|
|  | 21 | INT x; | 
|---|
| [2] | 22 |  | 
|---|
|  | 23 | DosError(FERR_DISABLEHARDERR); | 
|---|
| [551] | 24 | for (x = 1; x < argc; x++) { | 
|---|
|  | 25 | if (!strchr("/;,`\'", *argv[x]) && !thisarg) { | 
|---|
| [2] | 26 | thisarg = argv[x]; | 
|---|
|  | 27 | break; | 
|---|
|  | 28 | } | 
|---|
|  | 29 | } | 
|---|
| [551] | 30 | if (!thisarg) { | 
|---|
| [2] | 31 | thisarg = fullname; | 
|---|
|  | 32 | save_dir(fullname); | 
|---|
|  | 33 | } | 
|---|
|  | 34 | DosError(FERR_DISABLEHARDERR); | 
|---|
| [551] | 35 | if (thisarg && !DosQueryPathInfo(thisarg, FIL_STANDARD, &fs, sizeof(fs))) { | 
|---|
|  | 36 | if (DosQueryPathInfo(thisarg, | 
|---|
|  | 37 | FIL_QUERYFULLNAME, fullname, sizeof(fullname))) | 
|---|
|  | 38 | strcpy(fullname, thisarg); | 
|---|
| [2] | 39 | hab = WinInitialize(0); | 
|---|
| [551] | 40 | if (hab) { | 
|---|
|  | 41 | hmq = WinCreateMsgQueue(hab, 256); | 
|---|
|  | 42 | if (hmq) { | 
|---|
|  | 43 | if (InitFM3DLL(hab, argc, argv)) { | 
|---|
|  | 44 | MakeValidDir(fullname); | 
|---|
|  | 45 | WinDlgBox(HWND_DESKTOP, | 
|---|
|  | 46 | HWND_DESKTOP, | 
|---|
|  | 47 | UndeleteDlgProc, | 
|---|
|  | 48 | FM3ModHandle, UNDEL_FRAME, (PVOID) fullname); | 
|---|
|  | 49 | } | 
|---|
|  | 50 | DosSleep(250L); | 
|---|
|  | 51 | WinDestroyMsgQueue(hmq); | 
|---|
| [2] | 52 | } | 
|---|
|  | 53 | WinTerminate(hab); | 
|---|
|  | 54 | } | 
|---|
|  | 55 | } | 
|---|
|  | 56 | else | 
|---|
| [551] | 57 | DosBeep(250, 100); | 
|---|
| [2] | 58 | return 0; | 
|---|
|  | 59 | } | 
|---|
       
      
  Note:
 See   
TracBrowser
 for help on using the repository browser.