OLD | NEW |
---|---|
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 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 | 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 #include "content/browser/devtools/render_frame_devtools_agent_host.h" | 5 #include "content/browser/devtools/render_frame_devtools_agent_host.h" |
6 | 6 |
7 #include "base/basictypes.h" | 7 #include "base/basictypes.h" |
8 #include "base/lazy_instance.h" | 8 #include "base/lazy_instance.h" |
9 #include "base/strings/utf_string_conversions.h" | 9 #include "base/strings/utf_string_conversions.h" |
10 #include "content/browser/child_process_security_policy_impl.h" | 10 #include "content/browser/child_process_security_policy_impl.h" |
(...skipping 406 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
417 if (pending_) | 417 if (pending_) |
418 pending_->InspectElement(x, y); | 418 pending_->InspectElement(x, y); |
419 } | 419 } |
420 | 420 |
421 void RenderFrameDevToolsAgentHost::OnClientAttached() { | 421 void RenderFrameDevToolsAgentHost::OnClientAttached() { |
422 if (!web_contents()) | 422 if (!web_contents()) |
423 return; | 423 return; |
424 | 424 |
425 frame_trace_recorder_.reset(new DevToolsFrameTraceRecorder()); | 425 frame_trace_recorder_.reset(new DevToolsFrameTraceRecorder()); |
426 | 426 |
427 #if defined(OS_ANDROID) | 427 #if defined(OS_ANDROID) && !defined(USE_AURA) |
no sievers
2015/10/20 19:24:22
TODO: power save blocker
| |
428 power_save_blocker_.reset(static_cast<PowerSaveBlockerImpl*>( | 428 power_save_blocker_.reset(static_cast<PowerSaveBlockerImpl*>( |
429 PowerSaveBlocker::Create( | 429 PowerSaveBlocker::Create( |
430 PowerSaveBlocker::kPowerSaveBlockPreventDisplaySleep, | 430 PowerSaveBlocker::kPowerSaveBlockPreventDisplaySleep, |
431 PowerSaveBlocker::kReasonOther, "DevTools").release())); | 431 PowerSaveBlocker::kReasonOther, "DevTools").release())); |
432 power_save_blocker_->InitDisplaySleepBlocker(web_contents()); | 432 power_save_blocker_->InitDisplaySleepBlocker(web_contents()); |
433 #endif | 433 #endif |
434 | 434 |
435 // TODO(kaznacheev): Move this call back to DevToolsManager when | 435 // TODO(kaznacheev): Move this call back to DevToolsManager when |
436 // extensions::ProcessManager no longer relies on this notification. | 436 // extensions::ProcessManager no longer relies on this notification. |
437 DevToolsAgentHostImpl::NotifyCallbacks(this, true); | 437 DevToolsAgentHostImpl::NotifyCallbacks(this, true); |
(...skipping 279 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
717 RenderFrameHost* host) { | 717 RenderFrameHost* host) { |
718 return (current_ && current_->host() == host) || | 718 return (current_ && current_->host() == host) || |
719 (pending_ && pending_->host() == host); | 719 (pending_ && pending_->host() == host); |
720 } | 720 } |
721 | 721 |
722 bool RenderFrameDevToolsAgentHost::IsChildFrame() { | 722 bool RenderFrameDevToolsAgentHost::IsChildFrame() { |
723 return current_ && current_->host()->GetParent(); | 723 return current_ && current_->host()->GetParent(); |
724 } | 724 } |
725 | 725 |
726 } // namespace content | 726 } // namespace content |
OLD | NEW |