mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
Create 2272 release branch for CEF3.
git-svn-id: https://chromiumembedded.googlecode.com/svn/branches/2272@1993 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
This commit is contained in:
26
tests/cefclient/util_win.h
Normal file
26
tests/cefclient/util_win.h
Normal file
@@ -0,0 +1,26 @@
|
||||
// Copyright (c) 2015 The Chromium Embedded Framework Authors. All rights
|
||||
// reserved. Use of this source code is governed by a BSD-style license that
|
||||
// can be found in the LICENSE file.
|
||||
|
||||
#include <windows.h>
|
||||
#include <string>
|
||||
|
||||
namespace client {
|
||||
|
||||
// Set the window's user data pointer.
|
||||
void SetUserDataPtr(HWND hWnd, void* ptr);
|
||||
|
||||
// Return the window's user data pointer.
|
||||
template <typename T>
|
||||
T GetUserDataPtr(HWND hWnd) {
|
||||
return reinterpret_cast<T>(GetWindowLongPtr(hWnd, GWLP_USERDATA));
|
||||
}
|
||||
|
||||
// Set the window's window procedure pointer and return the old value.
|
||||
WNDPROC SetWndProcPtr(HWND hWnd, WNDPROC wndProc);
|
||||
|
||||
int GetCefMouseModifiers(WPARAM wparam);
|
||||
int GetCefKeyboardModifiers(WPARAM wparam, LPARAM lparam);
|
||||
bool IsKeyDown(WPARAM wparam);
|
||||
|
||||
} // namespace client
|
Reference in New Issue
Block a user