Battery Status API: add UMA logging for Linux.
[chromium-blink-merge.git] / remoting / host / verify_config_window_win.h
blobbf3302b662b222df051d06d9062b31204e018acb
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 REMOTING_HOST_VERIFY_CONFIG_WINDOW_WIN_H_
6 #define REMOTING_HOST_VERIFY_CONFIG_WINDOW_WIN_H_
8 // altbase.h must be included before atlapp.h
9 #include <atlbase.h>
10 #include <atlapp.h>
11 #include <atlcrack.h>
12 #include <atlwin.h>
13 #include <atluser.h>
14 #include <string>
16 #include "base/callback.h"
17 #include "remoting/host/win/core_resource.h"
19 namespace remoting {
21 class VerifyConfigWindowWin : public ATL::CDialogImpl<VerifyConfigWindowWin> {
22 public:
23 enum { IDD = IDD_VERIFY_CONFIG_DIALOG };
25 BEGIN_MSG_MAP_EX(VerifyConfigWindowWin)
26 MSG_WM_INITDIALOG(OnInitDialog)
27 MSG_WM_CLOSE(OnClose)
28 COMMAND_ID_HANDLER_EX(IDOK, OnOk)
29 COMMAND_ID_HANDLER_EX(IDCANCEL, OnCancel)
30 END_MSG_MAP()
32 VerifyConfigWindowWin(const std::string& email,
33 const std::string& host_id,
34 const std::string& host_secret_hash);
36 void OnCancel(UINT code, int id, HWND control);
37 void OnClose();
38 LRESULT OnInitDialog(HWND wparam, LPARAM lparam);
39 void OnOk(UINT code, int id, HWND control);
41 private:
42 // Centers the dialog window against the owner window.
43 void CenterWindow();
44 bool VerifyHostSecretHash();
46 CIcon icon_;
48 const std::string email_;
49 const std::string host_id_;
50 const std::string host_secret_hash_;
52 DISALLOW_COPY_AND_ASSIGN(VerifyConfigWindowWin);
55 } // namespace remoting
57 #endif // REMOTING_HOST_VERIFY_CONFIG_WINDOW_WIN_H_