Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(191)

Side by Side Diff: content/browser/renderer_host/render_widget_host_view_android.cc

Issue 1274763003: Initialize GPU shader disk cache on brower thread. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address content_unittests failure on Android Created 5 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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/renderer_host/render_widget_host_view_android.h" 5 #include "content/browser/renderer_host/render_widget_host_view_android.h"
6 6
7 #include <android/bitmap.h> 7 #include <android/bitmap.h>
8 8
9 #include "base/android/build_info.h" 9 #include "base/android/build_info.h"
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 1521 matching lines...) Expand 10 before | Expand all | Expand 10 after
1532 1532
1533 // TODO(jrg): Find out the implications and answer correctly here, 1533 // TODO(jrg): Find out the implications and answer correctly here,
1534 // as we are returning the WebView and not root window bounds. 1534 // as we are returning the WebView and not root window bounds.
1535 gfx::Rect RenderWidgetHostViewAndroid::GetBoundsInRootWindow() { 1535 gfx::Rect RenderWidgetHostViewAndroid::GetBoundsInRootWindow() {
1536 return GetViewBounds(); 1536 return GetViewBounds();
1537 } 1537 }
1538 1538
1539 gfx::GLSurfaceHandle RenderWidgetHostViewAndroid::GetCompositingSurface() { 1539 gfx::GLSurfaceHandle RenderWidgetHostViewAndroid::GetCompositingSurface() {
1540 gfx::GLSurfaceHandle handle = 1540 gfx::GLSurfaceHandle handle =
1541 gfx::GLSurfaceHandle(gfx::kNullPluginWindow, gfx::NULL_TRANSPORT); 1541 gfx::GLSurfaceHandle(gfx::kNullPluginWindow, gfx::NULL_TRANSPORT);
1542 if (using_browser_compositor_) { 1542 // Null check for when we're running inside content_unittests.
1543 if (using_browser_compositor_ && BrowserGpuChannelHostFactory::instance()) {
1543 handle.parent_client_id = 1544 handle.parent_client_id =
1544 BrowserGpuChannelHostFactory::instance()->GetGpuChannelId(); 1545 BrowserGpuChannelHostFactory::instance()->GetGpuChannelId();
1545 } 1546 }
1546 return handle; 1547 return handle;
1547 } 1548 }
1548 1549
1549 void RenderWidgetHostViewAndroid::ProcessAckedTouchEvent( 1550 void RenderWidgetHostViewAndroid::ProcessAckedTouchEvent(
1550 const TouchEventWithLatencyInfo& touch, InputEventAckState ack_result) { 1551 const TouchEventWithLatencyInfo& touch, InputEventAckState ack_result) {
1551 const bool event_consumed = ack_result == INPUT_EVENT_ACK_STATE_CONSUMED; 1552 const bool event_consumed = ack_result == INPUT_EVENT_ACK_STATE_CONSUMED;
1552 gesture_provider_.OnTouchEventAck(touch.event.uniqueTouchEventId, 1553 gesture_provider_.OnTouchEventAck(touch.event.uniqueTouchEventId,
(...skipping 464 matching lines...) Expand 10 before | Expand all | Expand 10 after
2017 results->orientationAngle = display.RotationAsDegree(); 2018 results->orientationAngle = display.RotationAsDegree();
2018 results->orientationType = 2019 results->orientationType =
2019 RenderWidgetHostViewBase::GetOrientationTypeForMobile(display); 2020 RenderWidgetHostViewBase::GetOrientationTypeForMobile(display);
2020 gfx::DeviceDisplayInfo info; 2021 gfx::DeviceDisplayInfo info;
2021 results->depth = info.GetBitsPerPixel(); 2022 results->depth = info.GetBitsPerPixel();
2022 results->depthPerComponent = info.GetBitsPerComponent(); 2023 results->depthPerComponent = info.GetBitsPerComponent();
2023 results->isMonochrome = (results->depthPerComponent == 0); 2024 results->isMonochrome = (results->depthPerComponent == 0);
2024 } 2025 }
2025 2026
2026 } // namespace content 2027 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/gpu/browser_gpu_channel_host_factory.cc ('k') | content/public/browser/content_browser_client.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698