Partager via


GweBypassCoredllThunk_t::GetDC_I (Windows Embedded CE 6.0)

1/6/2010

This method retrieves a handle to a display device context for the client area of the specified window. The display device context can be used in subsequent graphics display interface (GDI) functions to draw in the client area of the window.

Syntax

static HDC WINAPI GetDC_I(
  HWND hwndThis
);

Parameters

  • hwndThis
    [in] Handle to the window for which the device context is to be retrieved. If this value is NULL, GweBypassCoredllThunk_t::GetDC_I retrieves the device context for the entire screen.

Return Value

The handle to the device context for the client area of the specified window indicates success. NULL indicates failure.

To get extended error information, call GetLastError.

Remarks

This method is an internal version of the GetDC function.

The GweBypassCoredllThunk_t::GetDC_I method retrieves a common, class, or private device context depending on the class style specified for the specified window. For common device contexts, GweBypassCoredllThunk_t::GetDC_I assigns default attributes to the device context each time the device context is retrieved. For class and private device contexts, GweBypassCoredllThunk_t::GetDC_I leaves the previously assigned attributes unchanged.

After painting with a common device context, the GweBypassCoredllThunk_t::ReleaseDC_I method must be called to release the device context. Class and private device contexts do not have to be released. The number of device contexts is limited only by available memory.

Requirements

Header gwebypasscoredllthunk.hpp
Windows Embedded CE Windows CE .NET 4.0 and later

See Also

Reference

GweBypassCoredllThunk_t
GetDC
GweBypassCoredllThunk_t::GetWindowDC_I
GweBypassCoredllThunk_t::ReleaseDC_I