Changeset 1291 for trunk/src


Ignore:
Timestamp:
Oct 14, 1999, 5:15:22 PM (26 years ago)
Author:
phaller
Message:

Fix: GetStartupInfo extended

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/kernel32/KERNEL32.CPP

    r1134 r1291  
    1 /* $Id: KERNEL32.CPP,v 1.21 1999-10-04 22:25:01 phaller Exp $ */
     1/* $Id: KERNEL32.CPP,v 1.22 1999-10-14 15:15:22 phaller Exp $ */
    22
    33/*
     
    1919 * Includes                                                                  *
    2020 *****************************************************************************/
     21
     22#include <odin.h>
     23#include <odinwrap.h>
     24#include <os2sel.h>
     25
    2126#include <os2win.h>
    2227#include <winnt.h>
     
    3742 * Defines                                                                   *
    3843 *****************************************************************************/
     44
     45ODINDEBUGCHANNEL(KERNEL32-KERNEL32)
    3946
    4047                /* this define enables certain less important debug messages */
     
    675682//Borrowed from Wine
    676683//******************************************************************************
    677 VOID WIN32API GetStartupInfoA(LPSTARTUPINFOA lpStartupInfo)
    678 {
    679   dprintf(("KERNEL32:  GetStartupInfo\n"));
    680   lpStartupInfo->cb = sizeof(STARTUPINFOA);
    681   lpStartupInfo->lpReserved = "<Reserved>";
    682   lpStartupInfo->lpDesktop = "Desktop";
    683   lpStartupInfo->lpTitle = "Title";
    684 
    685   lpStartupInfo->cbReserved2 = 0;
    686   lpStartupInfo->lpReserved2 = NULL; /* must be NULL for VC runtime */
    687 
     684ODINPROCEDURE1(GetStartupInfoA,LPSTARTUPINFOA,lpStartupInfo)
     685{
     686  lpStartupInfo->cb               = sizeof(STARTUPINFOA);
     687  lpStartupInfo->lpReserved       = "<Reserved>";
     688  lpStartupInfo->lpDesktop        = "Desktop";
     689  lpStartupInfo->lpTitle          = "Title";
     690  lpStartupInfo->dwX              = 0;
     691  lpStartupInfo->dwY              = 0;
     692  lpStartupInfo->dwXSize          = 640;
     693  lpStartupInfo->dwYSize          = 480;
     694  lpStartupInfo->dwXCountChars    = 80;      // for console
     695  lpStartupInfo->dwYCountChars    = 25;
     696  lpStartupInfo->dwFillAttribute  = 0x0720;
     697  lpStartupInfo->dwFlags          = STARTF_USESHOWWINDOW   |
     698                                    STARTF_USEPOSITION     |
     699                                    STARTF_USESIZE         |
     700                                    STARTF_USECOUNTCHARS   |
     701                                    STARTF_USEFILLATTRIBUTE|
     702                                    STARTF_USESTDHANDLES;
     703  lpStartupInfo->wShowWindow      = SW_SHOWDEFAULT;
     704  lpStartupInfo->cbReserved2      = 0;
     705  lpStartupInfo->lpReserved2      = NULL; /* must be NULL for VC runtime */
    688706  /* @@@PH 98/07/13 Handlemanager support */
    689   lpStartupInfo->hStdInput   = GetStdHandle(STD_INPUT_HANDLE);
    690   lpStartupInfo->hStdOutput  = GetStdHandle(STD_OUTPUT_HANDLE);
    691   lpStartupInfo->hStdError   = GetStdHandle(STD_ERROR_HANDLE);
     707  lpStartupInfo->hStdInput        = GetStdHandle(STD_INPUT_HANDLE);
     708  lpStartupInfo->hStdOutput       = GetStdHandle(STD_OUTPUT_HANDLE);
     709  lpStartupInfo->hStdError        = GetStdHandle(STD_ERROR_HANDLE);
    692710  return;
    693711}
     
    695713//Borrowed from Wine
    696714//******************************************************************************
    697 VOID WIN32API GetStartupInfoW(LPSTARTUPINFOW lpStartupInfo)
    698 {
    699  static WCHAR lpReserved[] = {'<', 'R','e','s','e','r','v','e','d','>', 0};
    700  static WCHAR lpDesktop[]  = {'D', 'e','s','k','t','o','p', 0};
    701  static WCHAR lpTitle[]    = {'T', 'i','t','l','e', 0};
    702 
    703   dprintf(("KERNEL32: GetStartupInfoW\n"));
     715ODINPROCEDURE1(GetStartupInfoW,LPSTARTUPINFOW,lpStartupInfo)
     716{
     717  static WCHAR lpReserved[] = {'<', 'R','e','s','e','r','v','e','d','>', 0};
     718  static WCHAR lpDesktop[]  = {'D', 'e','s','k','t','o','p', 0};
     719  static WCHAR lpTitle[]    = {'T', 'i','t','l','e', 0};
     720
     721  // forward call to ascii variant
     722  GetStartupInfoA((LPSTARTUPINFOA)lpStartupInfo);
    704723  lpStartupInfo->cb          = sizeof(STARTUPINFOW);
    705724  lpStartupInfo->lpReserved  = lpReserved;
    706725  lpStartupInfo->lpDesktop   = lpDesktop;
    707726  lpStartupInfo->lpTitle     = lpTitle;
    708 
    709   lpStartupInfo->cbReserved2 = 0;
    710   lpStartupInfo->lpReserved2 = NULL; /* must be NULL for VC runtime */
    711 
    712   /* @@@PH 98/07/13 Handlemanager support */
    713   lpStartupInfo->hStdInput   = GetStdHandle(STD_INPUT_HANDLE);
    714   lpStartupInfo->hStdOutput  = GetStdHandle(STD_OUTPUT_HANDLE);
    715   lpStartupInfo->hStdError   = GetStdHandle(STD_ERROR_HANDLE);
    716727  return;
    717728}
Note: See TracChangeset for help on using the changeset viewer.