Ignore:
Timestamp:
Jan 20, 2000, 10:39:36 PM (26 years ago)
Author:
sandervl
Message:

VT: Codepages changes for CreateCompatibleDC

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/gdi32/gdi32.cpp

    r2352 r2484  
    1 /* $Id: gdi32.cpp,v 1.29 2000-01-07 17:37:53 cbratschi Exp $ */
     1/* $Id: gdi32.cpp,v 1.30 2000-01-20 21:39:35 sandervl Exp $ */
    22
    33/*
     
    1818#include "unicode.h"
    1919#include "dibsect.h"
     20#include <codepage.h>
     21#include "oslibgpi.h"
    2022
    2123static ULONG QueryPaletteSize(BITMAPINFOHEADER *pBHdr)
     
    306308//******************************************************************************
    307309//******************************************************************************
    308 HDC WIN32API CreateCompatibleDC( HDC arg1)
    309 {
    310  HDC rc;
    311 
    312     rc = O32_CreateCompatibleDC(arg1);
    313     dprintf(("GDI32: CreateCompatibleDC %X returned %x", arg1, rc));
    314     return rc;
     310HDC WIN32API CreateCompatibleDC( HDC hdc)
     311{
     312 HDC newHdc;
     313 ULONG oldcp;
     314
     315    newHdc = O32_CreateCompatibleDC(hdc);
     316    oldcp = OSLibGpiQueryCp(hdc);
     317    if (!oldcp) { /* If new DC is to be created */
     318        oldcp = GetDisplayCodepage();
     319        OSLibGpiSetCp(newHdc, oldcp);
     320    }
     321
     322    return newHdc;
    315323}
    316324//******************************************************************************
Note: See TracChangeset for help on using the changeset viewer.