| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef CHROME_FRAME_CHROME_FRAME_ACTIVEX_BASE_H_ | 5 #ifndef CHROME_FRAME_CHROME_FRAME_ACTIVEX_BASE_H_ |
| 6 #define CHROME_FRAME_CHROME_FRAME_ACTIVEX_BASE_H_ | 6 #define CHROME_FRAME_CHROME_FRAME_ACTIVEX_BASE_H_ |
| 7 | 7 |
| 8 #include <atlbase.h> | 8 #include <atlbase.h> |
| 9 #include <atlcom.h> | 9 #include <atlcom.h> |
| 10 #include <atlctl.h> | 10 #include <atlctl.h> |
| (...skipping 449 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 460 const IPC::ContextMenuParams& params) { | 460 const IPC::ContextMenuParams& params) { |
| 461 scoped_refptr<BasePlugin> ref(this); | 461 scoped_refptr<BasePlugin> ref(this); |
| 462 ChromeFramePlugin<T>::OnHandleContextMenu(tab_handle, menu_handle, | 462 ChromeFramePlugin<T>::OnHandleContextMenu(tab_handle, menu_handle, |
| 463 align_flags, params); | 463 align_flags, params); |
| 464 } | 464 } |
| 465 | 465 |
| 466 LRESULT OnCreate(UINT message, WPARAM wparam, LPARAM lparam, | 466 LRESULT OnCreate(UINT message, WPARAM wparam, LPARAM lparam, |
| 467 BOOL& handled) { // NO_LINT | 467 BOOL& handled) { // NO_LINT |
| 468 ModifyStyle(0, WS_CLIPCHILDREN | WS_CLIPSIBLINGS, 0); | 468 ModifyStyle(0, WS_CLIPCHILDREN | WS_CLIPSIBLINGS, 0); |
| 469 url_fetcher_.put_notification_window(m_hWnd); | 469 url_fetcher_.put_notification_window(m_hWnd); |
| 470 automation_client_->SetParentWindow(m_hWnd); | 470 if (automation_client_.get()) { |
| 471 automation_client_->SetParentWindow(m_hWnd); |
| 472 } else { |
| 473 NOTREACHED() << "No automation server"; |
| 474 return -1; |
| 475 } |
| 471 // Only fire the 'interactive' ready state if we aren't there already. | 476 // Only fire the 'interactive' ready state if we aren't there already. |
| 472 if (ready_state_ < READYSTATE_INTERACTIVE) { | 477 if (ready_state_ < READYSTATE_INTERACTIVE) { |
| 473 ready_state_ = READYSTATE_INTERACTIVE; | 478 ready_state_ = READYSTATE_INTERACTIVE; |
| 474 FireOnChanged(DISPID_READYSTATE); | 479 FireOnChanged(DISPID_READYSTATE); |
| 475 } | 480 } |
| 476 return 0; | 481 return 0; |
| 477 } | 482 } |
| 478 | 483 |
| 479 LRESULT OnDestroy(UINT message, WPARAM wparam, LPARAM lparam, | 484 LRESULT OnDestroy(UINT message, WPARAM wparam, LPARAM lparam, |
| 480 BOOL& handled) { // NO_LINT | 485 BOOL& handled) { // NO_LINT |
| (...skipping 656 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1137 EventHandlers onreadystatechanged_; | 1142 EventHandlers onreadystatechanged_; |
| 1138 EventHandlers onprivatemessage_; | 1143 EventHandlers onprivatemessage_; |
| 1139 EventHandlers onextensionready_; | 1144 EventHandlers onextensionready_; |
| 1140 | 1145 |
| 1141 // Handle network requests when host network stack is used. Passed to the | 1146 // Handle network requests when host network stack is used. Passed to the |
| 1142 // automation client on initialization. | 1147 // automation client on initialization. |
| 1143 UrlmonUrlRequestManager url_fetcher_; | 1148 UrlmonUrlRequestManager url_fetcher_; |
| 1144 }; | 1149 }; |
| 1145 | 1150 |
| 1146 #endif // CHROME_FRAME_CHROME_FRAME_ACTIVEX_BASE_H_ | 1151 #endif // CHROME_FRAME_CHROME_FRAME_ACTIVEX_BASE_H_ |
| OLD | NEW |