| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 "components/html_viewer/html_widget.h" | 5 #include "components/html_viewer/html_widget.h" |
| 6 | 6 |
| 7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
| 8 #include "components/html_viewer/blink_settings.h" | 8 #include "components/html_viewer/blink_settings.h" |
| 9 #include "components/html_viewer/global_state.h" | 9 #include "components/html_viewer/global_state.h" |
| 10 #include "components/html_viewer/ime_controller.h" | 10 #include "components/html_viewer/ime_controller.h" |
| (...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 119 } | 119 } |
| 120 | 120 |
| 121 blink::WebLayerTreeView* HTMLWidgetRootLocal::layerTreeView() { | 121 blink::WebLayerTreeView* HTMLWidgetRootLocal::layerTreeView() { |
| 122 return web_layer_tree_view_impl_.get(); | 122 return web_layer_tree_view_impl_.get(); |
| 123 } | 123 } |
| 124 | 124 |
| 125 void HTMLWidgetRootLocal::didMeaningfulLayout( | 125 void HTMLWidgetRootLocal::didMeaningfulLayout( |
| 126 blink::WebMeaningfulLayout layout_type) { | 126 blink::WebMeaningfulLayout layout_type) { |
| 127 static bool called = false; | 127 static bool called = false; |
| 128 if (!called && layout_type == blink::WebMeaningfulLayout::VisuallyNonEmpty) { | 128 if (!called && layout_type == blink::WebMeaningfulLayout::VisuallyNonEmpty) { |
| 129 const int64 time = base::Time::Now().ToInternalValue(); | 129 const int64 ticks = base::TimeTicks::Now().ToInternalValue(); |
| 130 tracing::StartupPerformanceDataCollectorPtr collector = | 130 tracing::StartupPerformanceDataCollectorPtr collector = |
| 131 StatsCollectionController::ConnectToDataCollector(app_); | 131 StatsCollectionController::ConnectToDataCollector(app_); |
| 132 if (collector) | 132 if (collector) |
| 133 collector->SetFirstVisuallyNonEmptyLayoutTime(time); | 133 collector->SetFirstVisuallyNonEmptyLayoutTicks(ticks); |
| 134 called = true; | 134 called = true; |
| 135 } | 135 } |
| 136 } | 136 } |
| 137 | 137 |
| 138 void HTMLWidgetRootLocal::resetInputMethod() { | 138 void HTMLWidgetRootLocal::resetInputMethod() { |
| 139 ime_controller_->ResetInputMethod(); | 139 ime_controller_->ResetInputMethod(); |
| 140 } | 140 } |
| 141 | 141 |
| 142 void HTMLWidgetRootLocal::didHandleGestureEvent( | 142 void HTMLWidgetRootLocal::didHandleGestureEvent( |
| 143 const blink::WebGestureEvent& event, | 143 const blink::WebGestureEvent& event, |
| (...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 214 | 214 |
| 215 void HTMLWidgetLocalRoot::didUpdateTextOfFocusedElementByNonUserInput() { | 215 void HTMLWidgetLocalRoot::didUpdateTextOfFocusedElementByNonUserInput() { |
| 216 ime_controller_->DidUpdateTextOfFocusedElementByNonUserInput(); | 216 ime_controller_->DidUpdateTextOfFocusedElementByNonUserInput(); |
| 217 } | 217 } |
| 218 | 218 |
| 219 void HTMLWidgetLocalRoot::showImeIfNeeded() { | 219 void HTMLWidgetLocalRoot::showImeIfNeeded() { |
| 220 ime_controller_->ShowImeIfNeeded(); | 220 ime_controller_->ShowImeIfNeeded(); |
| 221 } | 221 } |
| 222 | 222 |
| 223 } // namespace html_viewer | 223 } // namespace html_viewer |
| OLD | NEW |