mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-01-16 20:02:24 +01:00
8aac23386e
- Implement CefRequestHandler::OnBeforeBrowse using NavigationThrottle instead of ResourceThrottle (see http://crbug.com/537634). The CefRequest object passed to OnBeforeBrowse will no longer have an associated request identifier. - Mac: Remove additional helper apps which are no longer required (see http://crbug.com/520680) - Remove the UR_FLAG_REPORT_RAW_HEADERS flag which is no longer supported (see http://crbug.com/517114) - Remove the CefBrowserSettings.java parameter. Java is an NPAPI plugin and NPAPI plugins are no longer supported (see http://crbug.com/470301#c11) - Add CefFormatUrlForSecurityDisplay function in cef_parser.h - Fix crash when passing `--disable-extensions` command-line flag (issue #1721) - Linux: Fix NSS handler loading (issue #1727)
68 lines
2.7 KiB
Diff
68 lines
2.7 KiB
Diff
diff --git content/browser/compositor/gpu_process_transport_factory.cc content/browser/compositor/gpu_process_transport_factory.cc
|
|
index b7ed844..c6ec2a9 100644
|
|
--- content/browser/compositor/gpu_process_transport_factory.cc
|
|
+++ content/browser/compositor/gpu_process_transport_factory.cc
|
|
@@ -142,6 +142,13 @@ GpuProcessTransportFactory::CreateOffscreenCommandBufferContext() {
|
|
scoped_ptr<cc::SoftwareOutputDevice>
|
|
GpuProcessTransportFactory::CreateSoftwareOutputDevice(
|
|
ui::Compositor* compositor) {
|
|
+ if (compositor->delegate()) {
|
|
+ scoped_ptr<cc::SoftwareOutputDevice> output_device =
|
|
+ compositor->delegate()->CreateSoftwareOutputDevice(compositor);
|
|
+ if (output_device.get())
|
|
+ return output_device;
|
|
+ }
|
|
+
|
|
#if defined(OS_WIN)
|
|
return scoped_ptr<cc::SoftwareOutputDevice>(
|
|
new SoftwareOutputDeviceWin(software_backing_.get(), compositor));
|
|
diff --git ui/compositor/compositor.h ui/compositor/compositor.h
|
|
index fe2a033..b6cd7c9 100644
|
|
--- ui/compositor/compositor.h
|
|
+++ ui/compositor/compositor.h
|
|
@@ -15,6 +15,7 @@
|
|
#include "base/single_thread_task_runner.h"
|
|
#include "base/time/time.h"
|
|
#include "cc/output/begin_frame_args.h"
|
|
+#include "cc/output/software_output_device.h"
|
|
#include "cc/surfaces/surface_sequence.h"
|
|
#include "cc/trees/layer_tree_host_client.h"
|
|
#include "cc/trees/layer_tree_host_single_thread_client.h"
|
|
@@ -149,6 +150,17 @@ class COMPOSITOR_EXPORT CompositorBeginFrameObserver {
|
|
virtual void OnSendBeginFrame(const cc::BeginFrameArgs& args) = 0;
|
|
};
|
|
|
|
+class COMPOSITOR_EXPORT CompositorDelegate {
|
|
+ public:
|
|
+ virtual scoped_ptr<cc::SoftwareOutputDevice> CreateSoftwareOutputDevice(
|
|
+ ui::Compositor* compositor) {
|
|
+ return scoped_ptr<cc::SoftwareOutputDevice>();
|
|
+ }
|
|
+
|
|
+ protected:
|
|
+ virtual ~CompositorDelegate() {}
|
|
+};
|
|
+
|
|
// Compositor object to take care of GPU painting.
|
|
// A Browser compositor object is responsible for generating the final
|
|
// displayable form of pixels comprising a single widget's contents. It draws an
|
|
@@ -169,6 +181,9 @@ class COMPOSITOR_EXPORT Compositor
|
|
// Schedules a redraw of the layer tree associated with this compositor.
|
|
void ScheduleDraw();
|
|
|
|
+ CompositorDelegate* delegate() const { return delegate_; }
|
|
+ void SetDelegate(CompositorDelegate* delegate) { delegate_ = delegate; }
|
|
+
|
|
// Sets the root of the layer tree drawn by this Compositor. The root layer
|
|
// must have no parent. The compositor's root layer is reset if the root layer
|
|
// is destroyed. NULL can be passed to reset the root layer, in which case the
|
|
@@ -335,6 +350,8 @@ class COMPOSITOR_EXPORT Compositor
|
|
|
|
ui::ContextFactory* context_factory_;
|
|
|
|
+ CompositorDelegate* delegate_ = nullptr;
|
|
+
|
|
// The root of the Layer tree drawn by this compositor.
|
|
Layer* root_layer_;
|
|
|