Changeset 43 for trunk/src/helpers/winh.c
- Timestamp:
- Mar 7, 2001, 10:41:07 PM (24 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/helpers/winh.c
r35 r43 41 41 #define INCL_DOSDEVICES 42 42 #define INCL_DOSDEVIOCTL 43 #define INCL_DOSSESMGR 43 44 #define INCL_DOSERRORS 44 45 … … 2557 2558 2558 2559 /* 2560 *@@ winhQueryAppType: 2561 * returns the Control Program (Dos) and 2562 * Win* PROG_* application types for the 2563 * specified executable. Essentially, this 2564 * is a wrapper around DosQueryAppType. 2565 * 2566 * pcszExecutable must be fully qualified. 2567 * You can use doshFindExecutable to qualify 2568 * it. 2569 * 2570 * This returns the APIRET of DosQueryAppType. 2571 * If this is NO_ERROR; *pulDosAppType receives 2572 * the app type of DosQueryAppType. In addition, 2573 * *pulWinAppType is set to one of the following: 2574 * 2575 * -- PROG_FULLSCREEN 2576 * 2577 * -- PROG_PDD 2578 * 2579 * -- PROG_VDD 2580 * 2581 * -- PROG_XWP_DLL: new apptype defined in winh.h for 2582 * dynamic link libraries. 2583 * 2584 * -- PROG_WINDOWEDVDM 2585 * 2586 * -- PROG_PM 2587 * 2588 * -- PROG_31_ENH 2589 * 2590 * -- PROG_WINDOWABLEVIO 2591 * 2592 *@@added V0.9.9 (2001-03-07) [umoeller] 2593 */ 2594 2595 APIRET winhQueryAppType(const char *pcszExecutable, 2596 PULONG pulDosAppType, 2597 PULONG pulWinAppType) 2598 { 2599 APIRET arc = DosQueryAppType((PSZ)pcszExecutable, pulDosAppType); 2600 if (arc == NO_ERROR) 2601 { 2602 ULONG _ulDosAppType = *pulDosAppType; 2603 2604 if (_ulDosAppType == 0) 2605 *pulWinAppType = PROG_FULLSCREEN; 2606 else if (_ulDosAppType & 0x40) 2607 *pulWinAppType = PROG_PDD; 2608 else if (_ulDosAppType & 0x80) 2609 *pulWinAppType = PROG_VDD; 2610 else if ((_ulDosAppType & 0xF0) == 0x10) 2611 // DLL bit set 2612 *pulWinAppType = PROG_XWP_DLL; 2613 else if (_ulDosAppType & 0x20) 2614 // DOS bit set? 2615 *pulWinAppType = PROG_WINDOWEDVDM; 2616 else if ((_ulDosAppType & 0x0003) == 0x0003) // "Window-API" == PM 2617 *pulWinAppType = PROG_PM; 2618 else if ( ((_ulDosAppType & 0xFFFF) == 0x1000) // windows program (?!?) 2619 || ((_ulDosAppType & 0xFFFF) == 0x0400) // windows program (?!?) 2620 ) 2621 *pulWinAppType = PROG_31_ENH; 2622 else if ((_ulDosAppType & 0x03) == 0x02) 2623 *pulWinAppType = PROG_WINDOWABLEVIO; 2624 else if ((_ulDosAppType & 0x03) == 0x01) 2625 *pulWinAppType = PROG_FULLSCREEN; 2626 } 2627 2628 return (arc); 2629 } 2630 2631 /* 2559 2632 *@@ winhStartApp: 2560 2633 * wrapper around WinStartApp which fixes the … … 2569 2642 * -- starting ".CMD" and ".BAT" files as 2570 2643 * PROGDETAILS.pszExecutable. 2644 * 2645 * Unless it is "*", PROGDETAILS.pszExecutable must 2646 * be a proper file name. The full path may be omitted 2647 * if it is on the PATH, but the extension (.EXE etc.) 2648 * must be given. You can use doshFindExecutable to 2649 * find executables if you don't know the extension. 2571 2650 * 2572 2651 * This also handles and merges special and default … … 2802 2881 } 2803 2882 } 2804 2805 // _Pmpf((__FUNCTION__ ": calling WinStartApp"));2806 // _Pmpf((" exec: %s",2807 // (ProgDetails.pszExecutable)2808 // ? ProgDetails.pszExecutable2809 // : "NULL"));2810 // _Pmpf((" startupDir: %s",2811 // (ProgDetails.pszStartupDir)2812 // ? ProgDetails.pszStartupDir2813 // : "NULL"));2814 // _Pmpf((" params: %s",2815 // (pszParamsPatched)2816 // ? pszParamsPatched2817 // : "NULL"));2818 // _Pmpf((" new progc: 0x%lX", ProgDetails.progt.progc));2819 2883 2820 2884 ProgDetails.pszParameters = strParamsPatched.psz; … … 3282 3346 ULONG flFrameCreateFlags, // in: FCF_* flags 3283 3347 ULONG ulFrameStyle, // in: WS_* flags (e.g. WS_VISIBLE, WS_ANIMATE) 3284 const char *pcszFrameTitle, 3348 const char *pcszFrameTitle, // in: frame title (title bar) 3285 3349 ULONG ulResourcesID, // in: according to FCF_* flags 3286 const char *pcszClassClient, 3287 ULONG flStyleClient, 3350 const char *pcszClassClient, // in: client class name 3351 ULONG flStyleClient, // in: client style 3288 3352 ULONG ulID, // in: frame window ID 3289 3353 PVOID pClientCtlData, // in: pCtlData structure pointer for client
Note:
See TracChangeset
for help on using the changeset viewer.