diff options
-rw-r--r-- | cc/test/fake_proxy.cc | 3 | ||||
-rw-r--r-- | cc/test/fake_proxy.h | 1 | ||||
-rw-r--r-- | cc/trees/layer_tree_host.cc | 6 | ||||
-rw-r--r-- | cc/trees/layer_tree_host.h | 3 | ||||
-rw-r--r-- | cc/trees/layer_tree_host_impl.cc | 18 | ||||
-rw-r--r-- | cc/trees/layer_tree_host_impl.h | 4 | ||||
-rw-r--r-- | cc/trees/layer_tree_host_impl_unittest.cc | 7 | ||||
-rw-r--r-- | cc/trees/proxy.h | 2 | ||||
-rw-r--r-- | cc/trees/single_thread_proxy.cc | 12 | ||||
-rw-r--r-- | cc/trees/single_thread_proxy.h | 1 | ||||
-rw-r--r-- | cc/trees/thread_proxy.cc | 25 | ||||
-rw-r--r-- | cc/trees/thread_proxy.h | 3 |
12 files changed, 4 insertions, 81 deletions
diff --git a/cc/test/fake_proxy.cc b/cc/test/fake_proxy.cc index b288c07..9c24162 100644 --- a/cc/test/fake_proxy.cc +++ b/cc/test/fake_proxy.cc @@ -42,7 +42,4 @@ bool FakeProxy::MainFrameWillHappenForTesting() { return false; } -void FakeProxy::AsValueInto(base::trace_event::TracedValue*) const { -} - } // namespace cc diff --git a/cc/test/fake_proxy.h b/cc/test/fake_proxy.h index 2309fef..d5ad313 100644 --- a/cc/test/fake_proxy.h +++ b/cc/test/fake_proxy.h @@ -46,7 +46,6 @@ class FakeProxy : public Proxy { bool SupportsImplScrolling() const override; void SetDebugState(const LayerTreeDebugState& debug_state) override {} bool MainFrameWillHappenForTesting() override; - void AsValueInto(base::trace_event::TracedValue* state) const override; void SetChildrenNeedBeginFrames(bool children_need_begin_frames) override {} virtual RendererCapabilities& GetRendererCapabilities(); diff --git a/cc/trees/layer_tree_host.cc b/cc/trees/layer_tree_host.cc index 5b656a8..2ac7ebe 100644 --- a/cc/trees/layer_tree_host.cc +++ b/cc/trees/layer_tree_host.cc @@ -1138,12 +1138,6 @@ void LayerTreeHost::UpdateTopControlsState(TopControlsState constraints, animate)); } -void LayerTreeHost::AsValueInto(base::trace_event::TracedValue* state) const { - state->BeginDictionary("proxy"); - proxy_->AsValueInto(state); - state->EndDictionary(); -} - void LayerTreeHost::AnimateLayers(base::TimeTicks monotonic_time) { if (!settings_.accelerated_animation_enabled) return; diff --git a/cc/trees/layer_tree_host.h b/cc/trees/layer_tree_host.h index e677f89..840a4fa 100644 --- a/cc/trees/layer_tree_host.h +++ b/cc/trees/layer_tree_host.h @@ -272,9 +272,6 @@ class CC_EXPORT LayerTreeHost { return animation_registrar_.get(); } - // Obtains a thorough dump of the LayerTreeHost as a value. - void AsValueInto(base::trace_event::TracedValue* value) const; - bool in_paint_layer_contents() const { return in_paint_layer_contents_; } // CreateUIResource creates a resource given a bitmap. The bitmap is diff --git a/cc/trees/layer_tree_host_impl.cc b/cc/trees/layer_tree_host_impl.cc index 0bd757d..7a3eaf9 100644 --- a/cc/trees/layer_tree_host_impl.cc +++ b/cc/trees/layer_tree_host_impl.cc @@ -3235,11 +3235,6 @@ BeginFrameArgs LayerTreeHostImpl::CurrentBeginFrameArgs() const { } scoped_refptr<base::trace_event::ConvertableToTraceFormat> -LayerTreeHostImpl::AsValue() const { - return AsValueWithFrame(NULL); -} - -scoped_refptr<base::trace_event::ConvertableToTraceFormat> LayerTreeHostImpl::AsValueWithFrame(FrameData* frame) const { scoped_refptr<base::trace_event::TracedValue> state = new base::trace_event::TracedValue(); @@ -3247,11 +3242,6 @@ LayerTreeHostImpl::AsValueWithFrame(FrameData* frame) const { return state; } -void LayerTreeHostImpl::AsValueInto( - base::trace_event::TracedValue* value) const { - return AsValueWithFrameInto(NULL, value); -} - void LayerTreeHostImpl::AsValueWithFrameInto( FrameData* frame, base::trace_event::TracedValue* state) const { @@ -3300,14 +3290,6 @@ void LayerTreeHostImpl::AsValueWithFrameInto( } } -scoped_refptr<base::trace_event::ConvertableToTraceFormat> -LayerTreeHostImpl::ActivationStateAsValue() const { - scoped_refptr<base::trace_event::TracedValue> state = - new base::trace_event::TracedValue(); - ActivationStateAsValueInto(state.get()); - return state; -} - void LayerTreeHostImpl::ActivationStateAsValueInto( base::trace_event::TracedValue* state) const { TracedValue::SetIDRef(this, state, "lthi"); diff --git a/cc/trees/layer_tree_host_impl.h b/cc/trees/layer_tree_host_impl.h index 0be16b0..94012e0 100644 --- a/cc/trees/layer_tree_host_impl.h +++ b/cc/trees/layer_tree_host_impl.h @@ -450,14 +450,10 @@ class CC_EXPORT LayerTreeHostImpl return begin_impl_frame_interval_; } - void AsValueInto(base::trace_event::TracedValue* value) const; void AsValueWithFrameInto(FrameData* frame, base::trace_event::TracedValue* value) const; - scoped_refptr<base::trace_event::ConvertableToTraceFormat> AsValue() const; scoped_refptr<base::trace_event::ConvertableToTraceFormat> AsValueWithFrame( FrameData* frame) const; - scoped_refptr<base::trace_event::ConvertableToTraceFormat> - ActivationStateAsValue() const; void ActivationStateAsValueInto(base::trace_event::TracedValue* value) const; bool page_scale_animation_active() const { return !!page_scale_animation_; } diff --git a/cc/trees/layer_tree_host_impl_unittest.cc b/cc/trees/layer_tree_host_impl_unittest.cc index 23ea9dc..31c0303 100644 --- a/cc/trees/layer_tree_host_impl_unittest.cc +++ b/cc/trees/layer_tree_host_impl_unittest.cc @@ -6515,9 +6515,10 @@ TEST_F(LayerTreeHostImplTest, ForcedDrawToSoftwareDeviceBasicRender) { EXPECT_EQ(1, software_device->frames_began_); EXPECT_EQ(1, software_device->frames_ended_); - // Call other API methods that are likely to hit NULL pointer in this mode. - EXPECT_TRUE(host_impl_->AsValue().get()); - EXPECT_TRUE(host_impl_->ActivationStateAsValue().get()); + // Call another API method that is likely to hit nullptr in this mode. + scoped_refptr<base::trace_event::TracedValue> state = + make_scoped_refptr(new base::trace_event::TracedValue()); + host_impl_->ActivationStateAsValueInto(state.get()); } TEST_F(LayerTreeHostImplTest, diff --git a/cc/trees/proxy.h b/cc/trees/proxy.h index 539effe..0d6d3e9 100644 --- a/cc/trees/proxy.h +++ b/cc/trees/proxy.h @@ -103,8 +103,6 @@ class CC_EXPORT Proxy { virtual bool SupportsImplScrolling() const = 0; - virtual void AsValueInto(base::trace_event::TracedValue* value) const = 0; - virtual void SetDebugState(const LayerTreeDebugState& debug_state) = 0; virtual void SetChildrenNeedBeginFrames(bool children_need_begin_frames) = 0; diff --git a/cc/trees/single_thread_proxy.cc b/cc/trees/single_thread_proxy.cc index 401a4b8..81c70f0 100644 --- a/cc/trees/single_thread_proxy.cc +++ b/cc/trees/single_thread_proxy.cc @@ -549,18 +549,6 @@ void SingleThreadProxy::CompositeImmediately(base::TimeTicks frame_begin_time) { } } -void SingleThreadProxy::AsValueInto( - base::trace_event::TracedValue* state) const { - // The following line casts away const modifiers because it is just - // setting debug state. We still want the AsValue() function and its - // call chain to be const throughout. - DebugScopedSetImplThread impl(const_cast<SingleThreadProxy*>(this)); - - state->BeginDictionary("layer_tree_host_impl"); - layer_tree_host_impl_->AsValueInto(state); - state->EndDictionary(); -} - void SingleThreadProxy::ForceSerializeOnSwapBuffers() { { DebugScopedSetImplThread impl(this); diff --git a/cc/trees/single_thread_proxy.h b/cc/trees/single_thread_proxy.h index 2612a4d..5bc6d3d 100644 --- a/cc/trees/single_thread_proxy.h +++ b/cc/trees/single_thread_proxy.h @@ -59,7 +59,6 @@ class CC_EXPORT SingleThreadProxy : public Proxy, size_t MaxPartialTextureUpdates() const override; void ForceSerializeOnSwapBuffers() override; bool SupportsImplScrolling() const override; - void AsValueInto(base::trace_event::TracedValue* state) const override; bool MainFrameWillHappenForTesting() override; void SetChildrenNeedBeginFrames(bool children_need_begin_frames) override; diff --git a/cc/trees/thread_proxy.cc b/cc/trees/thread_proxy.cc index 8c766f2..7452520 100644 --- a/cc/trees/thread_proxy.cc +++ b/cc/trees/thread_proxy.cc @@ -1252,31 +1252,6 @@ ThreadProxy::BeginMainFrameAndCommitState::BeginMainFrameAndCommitState() ThreadProxy::BeginMainFrameAndCommitState::~BeginMainFrameAndCommitState() {} -void ThreadProxy::AsValueInto(base::trace_event::TracedValue* state) const { - CompletionEvent completion; - { - DebugScopedSetMainThreadBlocked main_thread_blocked( - const_cast<ThreadProxy*>(this)); - scoped_refptr<base::trace_event::TracedValue> state_refptr(state); - Proxy::ImplThreadTaskRunner()->PostTask( - FROM_HERE, - base::Bind(&ThreadProxy::AsValueOnImplThread, - impl_thread_weak_ptr_, - &completion, - state_refptr)); - completion.Wait(); - } -} - -void ThreadProxy::AsValueOnImplThread( - CompletionEvent* completion, - base::trace_event::TracedValue* state) const { - state->BeginDictionary("layer_tree_host_impl"); - impl().layer_tree_host_impl->AsValueInto(state); - state->EndDictionary(); - completion->Signal(); -} - bool ThreadProxy::MainFrameWillHappenForTesting() { DCHECK(IsMainThread()); CompletionEvent completion; diff --git a/cc/trees/thread_proxy.h b/cc/trees/thread_proxy.h index c2dd348..927caab 100644 --- a/cc/trees/thread_proxy.h +++ b/cc/trees/thread_proxy.h @@ -175,7 +175,6 @@ class CC_EXPORT ThreadProxy : public Proxy, void ForceSerializeOnSwapBuffers() override; bool SupportsImplScrolling() const override; void SetDebugState(const LayerTreeDebugState& debug_state) override; - void AsValueInto(base::trace_event::TracedValue* value) const override; bool MainFrameWillHappenForTesting() override; void SetChildrenNeedBeginFrames(bool children_need_begin_frames) override; @@ -279,8 +278,6 @@ class CC_EXPORT ThreadProxy : public Proxy, void ForceSerializeOnSwapBuffersOnImplThread(CompletionEvent* completion); void MainFrameWillHappenOnImplThreadForTesting(CompletionEvent* completion, bool* main_frame_will_happen); - void AsValueOnImplThread(CompletionEvent* completion, - base::trace_event::TracedValue* state) const; void SetSwapUsedIncompleteTileOnImplThread(bool used_incomplete_tile); void MainThreadHasStoppedFlingingOnImplThread(); void SetInputThrottledUntilCommitOnImplThread(bool is_throttled); |