1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef CONTENT_BROWSER_SYSTEM_MESSAGE_WINDOW_WIN_H_
6 #define CONTENT_BROWSER_SYSTEM_MESSAGE_WINDOW_WIN_H_
10 #include "base/basictypes.h"
11 #include "base/memory/scoped_ptr.h"
12 #include "base/profiler/scoped_tracker.h"
13 #include "content/common/content_export.h"
17 class CONTENT_EXPORT SystemMessageWindowWin
{
19 SystemMessageWindowWin();
21 virtual ~SystemMessageWindowWin();
23 virtual LRESULT
OnDeviceChange(UINT event_type
, LPARAM data
);
28 LRESULT CALLBACK
WndProc(HWND hwnd
, UINT message
,
29 WPARAM wparam
, LPARAM lparam
);
31 static LRESULT CALLBACK
WndProcThunk(HWND hwnd
,
35 SystemMessageWindowWin
* msg_wnd
= reinterpret_cast<SystemMessageWindowWin
*>(
36 GetWindowLongPtr(hwnd
, GWLP_USERDATA
));
38 return msg_wnd
->WndProc(hwnd
, message
, wparam
, lparam
);
39 return ::DefWindowProc(hwnd
, message
, wparam
, lparam
);
44 class DeviceNotifications
;
45 scoped_ptr
<DeviceNotifications
> device_notifications_
;
47 DISALLOW_COPY_AND_ASSIGN(SystemMessageWindowWin
);
50 } // namespace content
52 #endif // CONTENT_BROWSER_SYSTEM_MESSAGE_WINDOW_WIN_H_