summaryrefslogtreecommitdiffstats
path: root/webkit
diff options
context:
space:
mode:
authorjamesr@chromium.org <jamesr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-03-18 12:16:34 +0000
committerjamesr@chromium.org <jamesr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-03-18 12:16:34 +0000
commit9af1a09e3782c31f70b89cc2fdcb2ad7128d6b97 (patch)
treed0f18fc31fc4ff29312bad2fe2db83e4b506d2bc /webkit
parent729a1261d350d27e74eab59ef1271c05db28c2c9 (diff)
downloadchromium_src-9af1a09e3782c31f70b89cc2fdcb2ad7128d6b97.zip
chromium_src-9af1a09e3782c31f70b89cc2fdcb2ad7128d6b97.tar.gz
chromium_src-9af1a09e3782c31f70b89cc2fdcb2ad7128d6b97.tar.bz2
Move compositor bindings implementations out of WebKit::, fix style
This moves the implementation of compositor binding classes in webkit/compositor_bindings/ out of namespace WebKit and into namespace webkit. This is important since several of the chromium clang style plugin checks key off of the namespace to avoid WebKit API and thus weren't running on these classes. Also makes these files cpplint.py clean. R=enne@chromium.org Review URL: https://chromiumcodereview.appspot.com/12496013 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@188720 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit')
-rw-r--r--webkit/compositor_bindings/compositor_bindings.gyp2
-rw-r--r--webkit/compositor_bindings/web_animation_curve_common.cc16
-rw-r--r--webkit/compositor_bindings/web_animation_curve_common.h12
-rw-r--r--webkit/compositor_bindings/web_animation_impl.cc14
-rw-r--r--webkit/compositor_bindings/web_animation_impl.h34
-rw-r--r--webkit/compositor_bindings/web_animation_unittest.cc10
-rw-r--r--webkit/compositor_bindings/web_compositor_support_impl.cc21
-rw-r--r--webkit/compositor_bindings/web_compositor_support_impl.h3
-rw-r--r--webkit/compositor_bindings/web_content_layer_impl.cc13
-rw-r--r--webkit/compositor_bindings/web_content_layer_impl.h34
-rw-r--r--webkit/compositor_bindings/web_external_texture_layer_impl.cc31
-rw-r--r--webkit/compositor_bindings/web_external_texture_layer_impl.h39
-rw-r--r--webkit/compositor_bindings/web_float_animation_curve_impl.cc15
-rw-r--r--webkit/compositor_bindings/web_float_animation_curve_impl.h26
-rw-r--r--webkit/compositor_bindings/web_float_animation_curve_unittest.cc6
-rw-r--r--webkit/compositor_bindings/web_image_layer_impl.cc12
-rw-r--r--webkit/compositor_bindings/web_image_layer_impl.h17
-rw-r--r--webkit/compositor_bindings/web_layer_impl.cc29
-rw-r--r--webkit/compositor_bindings/web_layer_impl.h108
-rw-r--r--webkit/compositor_bindings/web_layer_impl_fixed_bounds.cc17
-rw-r--r--webkit/compositor_bindings/web_layer_impl_fixed_bounds.h31
-rw-r--r--webkit/compositor_bindings/web_layer_impl_fixed_bounds_unittest.cc10
-rw-r--r--webkit/compositor_bindings/web_layer_tree_view_impl_for_testing.cc16
-rw-r--r--webkit/compositor_bindings/web_layer_tree_view_impl_for_testing.h35
-rw-r--r--webkit/compositor_bindings/web_nine_patch_layer_impl.cc31
-rw-r--r--webkit/compositor_bindings/web_nine_patch_layer_impl.h31
-rw-r--r--webkit/compositor_bindings/web_rendering_stats_impl.h6
-rw-r--r--webkit/compositor_bindings/web_scrollbar_layer_impl.cc15
-rw-r--r--webkit/compositor_bindings/web_scrollbar_layer_impl.h31
-rw-r--r--webkit/compositor_bindings/web_solid_color_layer_impl.cc8
-rw-r--r--webkit/compositor_bindings/web_solid_color_layer_impl.h20
-rw-r--r--webkit/compositor_bindings/web_to_ccinput_handler_adapter.cc7
-rw-r--r--webkit/compositor_bindings/web_to_ccinput_handler_adapter.h10
-rw-r--r--webkit/compositor_bindings/web_to_ccscrollbar_theme_painter_adapter.cc11
-rw-r--r--webkit/compositor_bindings/web_to_ccscrollbar_theme_painter_adapter.h17
-rw-r--r--webkit/compositor_bindings/web_to_ccvideo_frame_provider.cc4
-rw-r--r--webkit/compositor_bindings/web_to_ccvideo_frame_provider.h4
-rw-r--r--webkit/compositor_bindings/web_transform_animation_curve_impl.cc12
-rw-r--r--webkit/compositor_bindings/web_transform_animation_curve_impl.h30
-rw-r--r--webkit/compositor_bindings/web_transform_operations_impl.h4
-rw-r--r--webkit/compositor_bindings/web_video_layer_impl.cc12
-rw-r--r--webkit/compositor_bindings/web_video_layer_impl.h24
-rw-r--r--webkit/plugins/npapi/webplugin_impl.cc2
-rw-r--r--webkit/plugins/ppapi/ppapi_plugin_instance.cc2
-rw-r--r--webkit/support/test_webkit_platform_support.cc2
-rw-r--r--webkit/support/webkit_support.cc4
46 files changed, 440 insertions, 398 deletions
diff --git a/webkit/compositor_bindings/compositor_bindings.gyp b/webkit/compositor_bindings/compositor_bindings.gyp
index 50b1fac..bd2412e 100644
--- a/webkit/compositor_bindings/compositor_bindings.gyp
+++ b/webkit/compositor_bindings/compositor_bindings.gyp
@@ -21,8 +21,6 @@
'web_layer_impl.h',
'web_layer_impl_fixed_bounds.cc',
'web_layer_impl_fixed_bounds.h',
- 'web_nine_patch_layer_impl.cc',
- 'web_nine_patch_layer_impl.h',
'web_to_ccinput_handler_adapter.cc',
'web_to_ccinput_handler_adapter.h',
'web_to_ccscrollbar_theme_painter_adapter.cc',
diff --git a/webkit/compositor_bindings/web_animation_curve_common.cc b/webkit/compositor_bindings/web_animation_curve_common.cc
index 82bfd14e..914348b 100644
--- a/webkit/compositor_bindings/web_animation_curve_common.cc
+++ b/webkit/compositor_bindings/web_animation_curve_common.cc
@@ -6,20 +6,20 @@
#include "cc/animation/timing_function.h"
-namespace WebKit {
+namespace webkit {
-scoped_ptr<cc::TimingFunction> createTimingFunction(
- WebAnimationCurve::TimingFunctionType type) {
+scoped_ptr<cc::TimingFunction> CreateTimingFunction(
+ WebKit::WebAnimationCurve::TimingFunctionType type) {
switch (type) {
- case WebAnimationCurve::TimingFunctionTypeEase:
+ case WebKit::WebAnimationCurve::TimingFunctionTypeEase:
return cc::EaseTimingFunction::create();
- case WebAnimationCurve::TimingFunctionTypeEaseIn:
+ case WebKit::WebAnimationCurve::TimingFunctionTypeEaseIn:
return cc::EaseInTimingFunction::create();
- case WebAnimationCurve::TimingFunctionTypeEaseOut:
+ case WebKit::WebAnimationCurve::TimingFunctionTypeEaseOut:
return cc::EaseOutTimingFunction::create();
- case WebAnimationCurve::TimingFunctionTypeEaseInOut:
+ case WebKit::WebAnimationCurve::TimingFunctionTypeEaseInOut:
return cc::EaseInOutTimingFunction::create();
- case WebAnimationCurve::TimingFunctionTypeLinear:
+ case WebKit::WebAnimationCurve::TimingFunctionTypeLinear:
return scoped_ptr<cc::TimingFunction>();
}
return scoped_ptr<cc::TimingFunction>();
diff --git a/webkit/compositor_bindings/web_animation_curve_common.h b/webkit/compositor_bindings/web_animation_curve_common.h
index 03550da..45014e1 100644
--- a/webkit/compositor_bindings/web_animation_curve_common.h
+++ b/webkit/compositor_bindings/web_animation_curve_common.h
@@ -2,17 +2,17 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef WebAnimationCurveCommon_h
-#define WebAnimationCurveCommon_h
+#ifndef WEBKIT_COMPOSITOR_BINDINGS_WEB_ANIMATION_CURVE_COMMON_H_
+#define WEBKIT_COMPOSITOR_BINDINGS_WEB_ANIMATION_CURVE_COMMON_H_
#include "base/memory/scoped_ptr.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebAnimationCurve.h"
namespace cc { class TimingFunction; }
-namespace WebKit {
-scoped_ptr<cc::TimingFunction> createTimingFunction(
- WebAnimationCurve::TimingFunctionType);
+namespace webkit {
+scoped_ptr<cc::TimingFunction> CreateTimingFunction(
+ WebKit::WebAnimationCurve::TimingFunctionType);
}
-#endif // WebAnimationCurveCommon_h
+#endif // WEBKIT_COMPOSITOR_BINDINGS_WEB_ANIMATION_CURVE_COMMON_H_
diff --git a/webkit/compositor_bindings/web_animation_impl.cc b/webkit/compositor_bindings/web_animation_impl.cc
index bc09cb8..afb1f6b 100644
--- a/webkit/compositor_bindings/web_animation_impl.cc
+++ b/webkit/compositor_bindings/web_animation_impl.cc
@@ -15,7 +15,9 @@
using cc::Animation;
using cc::AnimationIdProvider;
-namespace WebKit {
+using WebKit::WebAnimationCurve;
+
+namespace webkit {
WebAnimationImpl::WebAnimationImpl(const WebAnimationCurve& web_curve,
TargetProperty target_property,
@@ -32,13 +34,13 @@ WebAnimationImpl::WebAnimationImpl(const WebAnimationCurve& web_curve,
case WebAnimationCurve::AnimationCurveTypeFloat: {
const WebFloatAnimationCurveImpl* float_curve_impl =
static_cast<const WebFloatAnimationCurveImpl*>(&web_curve);
- curve = float_curve_impl->cloneToAnimationCurve();
+ curve = float_curve_impl->CloneToAnimationCurve();
break;
}
case WebAnimationCurve::AnimationCurveTypeTransform: {
const WebTransformAnimationCurveImpl* transform_curve_impl =
static_cast<const WebTransformAnimationCurveImpl*>(&web_curve);
- curve = transform_curve_impl->cloneToAnimationCurve();
+ curve = transform_curve_impl->CloneToAnimationCurve();
break;
}
}
@@ -53,7 +55,7 @@ WebAnimationImpl::~WebAnimationImpl() {}
int WebAnimationImpl::id() { return animation_->id(); }
-WebAnimation::TargetProperty WebAnimationImpl::targetProperty() const {
+WebKit::WebAnimation::TargetProperty WebAnimationImpl::targetProperty() const {
return static_cast<WebAnimationImpl::TargetProperty>(
animation_->target_property());
}
@@ -84,11 +86,11 @@ void WebAnimationImpl::setAlternatesDirection(bool alternates) {
animation_->set_alternates_direction(alternates);
}
-scoped_ptr<cc::Animation> WebAnimationImpl::cloneToAnimation() {
+scoped_ptr<cc::Animation> WebAnimationImpl::CloneToAnimation() {
scoped_ptr<cc::Animation> to_return(
animation_->Clone(cc::Animation::NonControllingInstance));
to_return->set_needs_synchronized_start_time(true);
return to_return.Pass();
}
-} // namespace WebKit
+} // namespace webkit
diff --git a/webkit/compositor_bindings/web_animation_impl.h b/webkit/compositor_bindings/web_animation_impl.h
index b70a3c6..53071bf 100644
--- a/webkit/compositor_bindings/web_animation_impl.h
+++ b/webkit/compositor_bindings/web_animation_impl.h
@@ -2,8 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef WebAnimationImpl_h
-#define WebAnimationImpl_h
+#ifndef WEBKIT_COMPOSITOR_BINDINGS_WEB_ANIMATION_IMPL_H_
+#define WEBKIT_COMPOSITOR_BINDINGS_WEB_ANIMATION_IMPL_H_
#include "base/memory/scoped_ptr.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebAnimation.h"
@@ -11,35 +11,39 @@
namespace cc { class Animation; }
-namespace WebKit {
-class WebAnimationCurve;
+namespace WebKit { class WebAnimationCurve; }
-class WebAnimationImpl : public WebAnimation {
+namespace webkit {
+
+class WebAnimationImpl : public WebKit::WebAnimation {
public:
- WEBKIT_COMPOSITOR_BINDINGS_EXPORT WebAnimationImpl(const WebAnimationCurve&,
- TargetProperty,
- int animation_id,
- int group_id = 0);
+ WEBKIT_COMPOSITOR_BINDINGS_EXPORT WebAnimationImpl(
+ const WebKit::WebAnimationCurve& curve,
+ TargetProperty target,
+ int animation_id,
+ int group_id);
virtual ~WebAnimationImpl();
- // WebAnimation implementation
+ // WebKit::WebAnimation implementation
virtual int id();
virtual TargetProperty targetProperty() const;
virtual int iterations() const;
- virtual void setIterations(int);
+ virtual void setIterations(int iterations);
virtual double startTime() const;
virtual void setStartTime(double monotonic_time);
virtual double timeOffset() const;
virtual void setTimeOffset(double monotonic_time);
virtual bool alternatesDirection() const;
- virtual void setAlternatesDirection(bool);
+ virtual void setAlternatesDirection(bool alternates);
- scoped_ptr<cc::Animation> cloneToAnimation();
+ scoped_ptr<cc::Animation> CloneToAnimation();
private:
scoped_ptr<cc::Animation> animation_;
+
+ DISALLOW_COPY_AND_ASSIGN(WebAnimationImpl);
};
-}
+} // namespace webkit
-#endif // WebAnimationImpl_h
+#endif // WEBKIT_COMPOSITOR_BINDINGS_WEB_ANIMATION_IMPL_H_
diff --git a/webkit/compositor_bindings/web_animation_unittest.cc b/webkit/compositor_bindings/web_animation_unittest.cc
index 4fc1ba0..925a78b 100644
--- a/webkit/compositor_bindings/web_animation_unittest.cc
+++ b/webkit/compositor_bindings/web_animation_unittest.cc
@@ -7,14 +7,17 @@
#include "webkit/compositor_bindings/web_animation_impl.h"
#include "webkit/compositor_bindings/web_float_animation_curve_impl.h"
-using namespace WebKit;
+using WebKit::WebAnimation;
+using WebKit::WebAnimationCurve;
+using WebKit::WebFloatAnimationCurve;
+namespace webkit {
namespace {
TEST(WebAnimationTest, DefaultSettings) {
scoped_ptr<WebAnimationCurve> curve(new WebFloatAnimationCurveImpl());
scoped_ptr<WebAnimation> animation(
- new WebAnimationImpl(*curve, WebAnimation::TargetPropertyOpacity, 1));
+ new WebAnimationImpl(*curve, WebAnimation::TargetPropertyOpacity, 1, 0));
// Ensure that the defaults are correct.
EXPECT_EQ(1, animation->iterations());
@@ -26,7 +29,7 @@ TEST(WebAnimationTest, DefaultSettings) {
TEST(WebAnimationTest, ModifiedSettings) {
scoped_ptr<WebFloatAnimationCurve> curve(new WebFloatAnimationCurveImpl());
scoped_ptr<WebAnimation> animation(
- new WebAnimationImpl(*curve, WebAnimation::TargetPropertyOpacity, 1));
+ new WebAnimationImpl(*curve, WebAnimation::TargetPropertyOpacity, 1, 0));
animation->setIterations(2);
animation->setStartTime(2);
animation->setTimeOffset(2);
@@ -39,3 +42,4 @@ TEST(WebAnimationTest, ModifiedSettings) {
}
} // namespace
+} // namespace webkit
diff --git a/webkit/compositor_bindings/web_compositor_support_impl.cc b/webkit/compositor_bindings/web_compositor_support_impl.cc
index dcda417..b0efb22 100644
--- a/webkit/compositor_bindings/web_compositor_support_impl.cc
+++ b/webkit/compositor_bindings/web_compositor_support_impl.cc
@@ -32,7 +32,6 @@ using WebKit::WebExternalTextureLayer;
using WebKit::WebExternalTextureLayerClient;
using WebKit::WebFloatAnimationCurve;
using WebKit::WebImageLayer;
-using WebKit::WebImageLayer;
using WebKit::WebLayer;
using WebKit::WebScrollbar;
using WebKit::WebScrollbarLayer;
@@ -51,53 +50,53 @@ WebCompositorSupportImpl::WebCompositorSupportImpl() {}
WebCompositorSupportImpl::~WebCompositorSupportImpl() {}
WebLayer* WebCompositorSupportImpl::createLayer() {
- return new WebKit::WebLayerImpl();
+ return new WebLayerImpl();
}
WebContentLayer* WebCompositorSupportImpl::createContentLayer(
WebContentLayerClient* client) {
- return new WebKit::WebContentLayerImpl(client);
+ return new WebContentLayerImpl(client);
}
WebExternalTextureLayer* WebCompositorSupportImpl::createExternalTextureLayer(
WebExternalTextureLayerClient* client) {
- return new WebKit::WebExternalTextureLayerImpl(client);
+ return new WebExternalTextureLayerImpl(client);
}
WebKit::WebImageLayer* WebCompositorSupportImpl::createImageLayer() {
- return new WebKit::WebImageLayerImpl();
+ return new WebImageLayerImpl();
}
WebSolidColorLayer* WebCompositorSupportImpl::createSolidColorLayer() {
- return new WebKit::WebSolidColorLayerImpl();
+ return new WebSolidColorLayerImpl();
}
WebVideoLayer* WebCompositorSupportImpl::createVideoLayer(
WebKit::WebVideoFrameProvider* provider) {
- return new WebKit::WebVideoLayerImpl(provider);
+ return new WebVideoLayerImpl(provider);
}
WebScrollbarLayer* WebCompositorSupportImpl::createScrollbarLayer(
WebScrollbar* scrollbar,
WebScrollbarThemePainter painter,
WebScrollbarThemeGeometry* geometry) {
- return new WebKit::WebScrollbarLayerImpl(scrollbar, painter, geometry);
+ return new WebScrollbarLayerImpl(scrollbar, painter, geometry);
}
WebAnimation* WebCompositorSupportImpl::createAnimation(
const WebKit::WebAnimationCurve& curve,
WebKit::WebAnimation::TargetProperty target,
int animation_id) {
- return new WebKit::WebAnimationImpl(curve, target, animation_id);
+ return new WebAnimationImpl(curve, target, animation_id, 0);
}
WebFloatAnimationCurve* WebCompositorSupportImpl::createFloatAnimationCurve() {
- return new WebKit::WebFloatAnimationCurveImpl();
+ return new WebFloatAnimationCurveImpl();
}
WebTransformAnimationCurve*
WebCompositorSupportImpl::createTransformAnimationCurve() {
- return new WebKit::WebTransformAnimationCurveImpl();
+ return new WebTransformAnimationCurveImpl();
}
WebTransformOperations* WebCompositorSupportImpl::createTransformOperations() {
diff --git a/webkit/compositor_bindings/web_compositor_support_impl.h b/webkit/compositor_bindings/web_compositor_support_impl.h
index 4b726c2..05feaa8 100644
--- a/webkit/compositor_bindings/web_compositor_support_impl.h
+++ b/webkit/compositor_bindings/web_compositor_support_impl.h
@@ -42,6 +42,9 @@ class WebCompositorSupportImpl : public WebKit::WebCompositorSupport {
virtual WebKit::WebFloatAnimationCurve* createFloatAnimationCurve();
virtual WebKit::WebTransformAnimationCurve* createTransformAnimationCurve();
virtual WebKit::WebTransformOperations* createTransformOperations();
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(WebCompositorSupportImpl);
};
} // namespace webkit
diff --git a/webkit/compositor_bindings/web_content_layer_impl.cc b/webkit/compositor_bindings/web_content_layer_impl.cc
index e9a66c1..6503a89 100644
--- a/webkit/compositor_bindings/web_content_layer_impl.cc
+++ b/webkit/compositor_bindings/web_content_layer_impl.cc
@@ -15,15 +15,16 @@
#include "third_party/WebKit/Source/Platform/chromium/public/WebSize.h"
#include "third_party/skia/include/utils/SkMatrix44.h"
-using namespace cc;
+using cc::ContentLayer;
+using cc::PictureLayer;
-namespace WebKit {
+namespace webkit {
static bool usingPictureLayer() {
return cc::switches::IsImplSidePaintingEnabled();
}
-WebContentLayerImpl::WebContentLayerImpl(WebContentLayerClient* client)
+WebContentLayerImpl::WebContentLayerImpl(WebKit::WebContentLayerClient* client)
: client_(client) {
if (usingPictureLayer())
layer_ = make_scoped_ptr(new WebLayerImpl(PictureLayer::Create(this)));
@@ -39,7 +40,7 @@ WebContentLayerImpl::~WebContentLayerImpl() {
static_cast<ContentLayer*>(layer_->layer())->ClearClient();
}
-WebLayer* WebContentLayerImpl::layer() { return layer_.get(); }
+WebKit::WebLayer* WebContentLayerImpl::layer() { return layer_.get(); }
void WebContentLayerImpl::setDoubleSided(bool double_sided) {
layer_->layer()->SetDoubleSided(double_sided);
@@ -71,10 +72,10 @@ void WebContentLayerImpl::PaintContents(SkCanvas* canvas,
if (!client_)
return;
- WebFloatRect web_opaque;
+ WebKit::WebFloatRect web_opaque;
client_->paintContents(
canvas, clip, layer_->layer()->can_use_lcd_text(), web_opaque);
*opaque = web_opaque;
}
-} // namespace WebKit
+} // namespace webkit
diff --git a/webkit/compositor_bindings/web_content_layer_impl.h b/webkit/compositor_bindings/web_content_layer_impl.h
index 6094854..d687c91 100644
--- a/webkit/compositor_bindings/web_content_layer_impl.h
+++ b/webkit/compositor_bindings/web_content_layer_impl.h
@@ -2,8 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef WebContentLayerImpl_h
-#define WebContentLayerImpl_h
+#ifndef WEBKIT_COMPOSITOR_BINDINGS_WEB_CONTENT_LAYER_IMPL_H_
+#define WEBKIT_COMPOSITOR_BINDINGS_WEB_CONTENT_LAYER_IMPL_H_
#include "base/memory/scoped_ptr.h"
#include "cc/layers/content_layer_client.h"
@@ -16,23 +16,24 @@ class IntRect;
class FloatRect;
}
-namespace WebKit {
-class WebContentLayerClient;
+namespace WebKit { class WebContentLayerClient; }
-class WebContentLayerImpl : public WebContentLayer,
+namespace webkit {
+
+class WebContentLayerImpl : public WebKit::WebContentLayer,
public cc::ContentLayerClient {
public:
WEBKIT_COMPOSITOR_BINDINGS_EXPORT explicit WebContentLayerImpl(
- WebContentLayerClient*);
+ WebKit::WebContentLayerClient*);
// WebContentLayer implementation.
- virtual WebLayer* layer();
- virtual void setDoubleSided(bool);
- virtual void setBoundsContainPageScale(bool);
+ virtual WebKit::WebLayer* layer();
+ virtual void setDoubleSided(bool double_sided);
+ virtual void setBoundsContainPageScale(bool contains);
virtual bool boundsContainPageScale() const;
- virtual void setUseLCDText(bool);
- virtual void setDrawCheckerboardForMissingTiles(bool);
- virtual void setAutomaticallyComputeRasterScale(bool);
+ virtual void setUseLCDText(bool use_lcd_text);
+ virtual void setDrawCheckerboardForMissingTiles(bool checkerboard);
+ virtual void setAutomaticallyComputeRasterScale(bool compute_raster);
protected:
virtual ~WebContentLayerImpl();
@@ -43,10 +44,13 @@ class WebContentLayerImpl : public WebContentLayer,
gfx::RectF* opaque) OVERRIDE;
scoped_ptr<WebLayerImpl> layer_;
- WebContentLayerClient* client_;
+ WebKit::WebContentLayerClient* client_;
bool draws_content_;
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(WebContentLayerImpl);
};
-} // namespace WebKit
+} // namespace webkit
-#endif // WebContentLayerImpl_h
+#endif // WEBKIT_COMPOSITOR_BINDINGS_WEB_CONTENT_LAYER_IMPL_H_
diff --git a/webkit/compositor_bindings/web_external_texture_layer_impl.cc b/webkit/compositor_bindings/web_external_texture_layer_impl.cc
index ac888aa..0b270f4 100644
--- a/webkit/compositor_bindings/web_external_texture_layer_impl.cc
+++ b/webkit/compositor_bindings/web_external_texture_layer_impl.cc
@@ -11,12 +11,13 @@
#include "third_party/WebKit/Source/Platform/chromium/public/WebSize.h"
#include "webkit/compositor_bindings/web_layer_impl.h"
-using namespace cc;
+using cc::TextureLayer;
+using cc::ResourceUpdateQueue;
-namespace WebKit {
+namespace webkit {
WebExternalTextureLayerImpl::WebExternalTextureLayerImpl(
- WebExternalTextureLayerClient* client)
+ WebKit::WebExternalTextureLayerClient* client)
: client_(client) {
scoped_refptr<TextureLayer> layer;
if (client_)
@@ -31,7 +32,7 @@ WebExternalTextureLayerImpl::~WebExternalTextureLayerImpl() {
static_cast<TextureLayer*>(layer_->layer())->ClearClient();
}
-WebLayer* WebExternalTextureLayerImpl::layer() { return layer_.get(); }
+WebKit::WebLayer* WebExternalTextureLayerImpl::layer() { return layer_.get(); }
void WebExternalTextureLayerImpl::setTextureId(unsigned id) {
static_cast<TextureLayer*>(layer_->layer())->SetTextureId(id);
@@ -41,7 +42,7 @@ void WebExternalTextureLayerImpl::setFlipped(bool flipped) {
static_cast<TextureLayer*>(layer_->layer())->SetFlipped(flipped);
}
-void WebExternalTextureLayerImpl::setUVRect(const WebFloatRect& rect) {
+void WebExternalTextureLayerImpl::setUVRect(const WebKit::WebFloatRect& rect) {
static_cast<TextureLayer*>(layer_->layer())->SetUV(
gfx::PointF(rect.x, rect.y),
gfx::PointF(rect.x + rect.width, rect.y + rect.height));
@@ -65,32 +66,32 @@ void WebExternalTextureLayerImpl::setRateLimitContext(bool rate_limit) {
static_cast<TextureLayer*>(layer_->layer())->SetRateLimitContext(rate_limit);
}
-class WebTextureUpdaterImpl : public WebTextureUpdater {
+class WebTextureUpdaterImpl : public WebKit::WebTextureUpdater {
public:
- explicit WebTextureUpdaterImpl(ResourceUpdateQueue& queue) : queue_(queue) {}
+ explicit WebTextureUpdaterImpl(ResourceUpdateQueue* queue) : queue_(queue) {}
virtual void appendCopy(unsigned source_texture,
unsigned destination_texture,
- WebSize size) OVERRIDE {
- TextureCopier::Parameters copy = { source_texture, destination_texture,
- size };
- queue_.appendCopy(copy);
+ WebKit::WebSize size) OVERRIDE {
+ cc::TextureCopier::Parameters copy = { source_texture, destination_texture,
+ size };
+ queue_->appendCopy(copy);
}
private:
- ResourceUpdateQueue& queue_;
+ ResourceUpdateQueue* queue_;
};
unsigned WebExternalTextureLayerImpl::prepareTexture(
ResourceUpdateQueue& queue) {
DCHECK(client_);
- WebTextureUpdaterImpl updater_impl(queue);
+ WebTextureUpdaterImpl updater_impl(&queue);
return client_->prepareTexture(updater_impl);
}
-WebGraphicsContext3D* WebExternalTextureLayerImpl::context() {
+WebKit::WebGraphicsContext3D* WebExternalTextureLayerImpl::context() {
DCHECK(client_);
return client_->context();
}
-} // namespace WebKit
+} // namespace webkit
diff --git a/webkit/compositor_bindings/web_external_texture_layer_impl.h b/webkit/compositor_bindings/web_external_texture_layer_impl.h
index a70ad51..6cd3e71 100644
--- a/webkit/compositor_bindings/web_external_texture_layer_impl.h
+++ b/webkit/compositor_bindings/web_external_texture_layer_impl.h
@@ -2,45 +2,48 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef WebExternalTextureLayerImpl_h
-#define WebExternalTextureLayerImpl_h
+#ifndef WEBKIT_COMPOSITOR_BINDINGS_WEB_EXTERNAL_TEXTURE_LAYER_IMPL_H_
+#define WEBKIT_COMPOSITOR_BINDINGS_WEB_EXTERNAL_TEXTURE_LAYER_IMPL_H_
#include "base/memory/scoped_ptr.h"
#include "cc/layers/texture_layer_client.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebExternalTextureLayer.h"
#include "webkit/compositor_bindings/webkit_compositor_bindings_export.h"
-namespace WebKit {
+namespace WebKit { struct WebFloatRect; }
+
+namespace webkit {
class WebLayerImpl;
-struct WebFloatRect;
-class WebExternalTextureLayerImpl : public WebExternalTextureLayer,
+class WebExternalTextureLayerImpl : public WebKit::WebExternalTextureLayer,
public cc::TextureLayerClient {
public:
WEBKIT_COMPOSITOR_BINDINGS_EXPORT explicit WebExternalTextureLayerImpl(
- WebExternalTextureLayerClient*);
+ WebKit::WebExternalTextureLayerClient*);
virtual ~WebExternalTextureLayerImpl();
- // WebExternalTextureLayer implementation.
- virtual WebLayer* layer();
- virtual void setTextureId(unsigned);
- virtual void setFlipped(bool);
- virtual void setUVRect(const WebFloatRect&);
- virtual void setOpaque(bool);
- virtual void setPremultipliedAlpha(bool);
+ // WebKit::WebExternalTextureLayer implementation.
+ virtual WebKit::WebLayer* layer();
+ virtual void setTextureId(unsigned texture_id);
+ virtual void setFlipped(bool flipped);
+ virtual void setUVRect(const WebKit::WebFloatRect& uv_rect);
+ virtual void setOpaque(bool opaque);
+ virtual void setPremultipliedAlpha(bool premultiplied);
virtual void willModifyTexture();
- virtual void setRateLimitContext(bool);
+ virtual void setRateLimitContext(bool rate_limit);
// TextureLayerClient implementation.
virtual unsigned prepareTexture(cc::ResourceUpdateQueue&) OVERRIDE;
- virtual WebGraphicsContext3D* context() OVERRIDE;
+ virtual WebKit::WebGraphicsContext3D* context() OVERRIDE;
private:
- WebExternalTextureLayerClient* client_;
+ WebKit::WebExternalTextureLayerClient* client_;
scoped_ptr<WebLayerImpl> layer_;
+
+ DISALLOW_COPY_AND_ASSIGN(WebExternalTextureLayerImpl);
};
-}
+} // namespace webkit
-#endif // WebExternalTextureLayerImpl_h
+#endif // WEBKIT_COMPOSITOR_BINDINGS_WEB_EXTERNAL_TEXTURE_LAYER_IMPL_H_
diff --git a/webkit/compositor_bindings/web_float_animation_curve_impl.cc b/webkit/compositor_bindings/web_float_animation_curve_impl.cc
index cb3357f..5d13564 100644
--- a/webkit/compositor_bindings/web_float_animation_curve_impl.cc
+++ b/webkit/compositor_bindings/web_float_animation_curve_impl.cc
@@ -9,15 +9,18 @@
#include "cc/animation/timing_function.h"
#include "webkit/compositor_bindings/web_animation_curve_common.h"
-namespace WebKit {
+using WebKit::WebFloatKeyframe;
+
+namespace webkit {
WebFloatAnimationCurveImpl::WebFloatAnimationCurveImpl()
: curve_(cc::KeyframedFloatAnimationCurve::Create()) {}
WebFloatAnimationCurveImpl::~WebFloatAnimationCurveImpl() {}
-WebAnimationCurve::AnimationCurveType WebFloatAnimationCurveImpl::type() const {
- return WebAnimationCurve::AnimationCurveTypeFloat;
+WebKit::WebAnimationCurve::AnimationCurveType
+WebFloatAnimationCurveImpl::type() const {
+ return WebKit::WebAnimationCurve::AnimationCurveTypeFloat;
}
void WebFloatAnimationCurveImpl::add(const WebFloatKeyframe& keyframe) {
@@ -27,7 +30,7 @@ void WebFloatAnimationCurveImpl::add(const WebFloatKeyframe& keyframe) {
void WebFloatAnimationCurveImpl::add(const WebFloatKeyframe& keyframe,
TimingFunctionType type) {
curve_->AddKeyframe(cc::FloatKeyframe::Create(
- keyframe.time, keyframe.value, createTimingFunction(type)));
+ keyframe.time, keyframe.value, CreateTimingFunction(type)));
}
void WebFloatAnimationCurveImpl::add(const WebFloatKeyframe& keyframe,
@@ -47,8 +50,8 @@ float WebFloatAnimationCurveImpl::getValue(double time) const {
}
scoped_ptr<cc::AnimationCurve>
-WebFloatAnimationCurveImpl::cloneToAnimationCurve() const {
+WebFloatAnimationCurveImpl::CloneToAnimationCurve() const {
return curve_->Clone();
}
-} // namespace WebKit
+} // namespace webkit
diff --git a/webkit/compositor_bindings/web_float_animation_curve_impl.h b/webkit/compositor_bindings/web_float_animation_curve_impl.h
index d20f243..dd9101f 100644
--- a/webkit/compositor_bindings/web_float_animation_curve_impl.h
+++ b/webkit/compositor_bindings/web_float_animation_curve_impl.h
@@ -2,8 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef WebFloatAnimationCurveImpl_h
-#define WebFloatAnimationCurveImpl_h
+#ifndef WEBKIT_COMPOSITOR_BINDINGS_WEB_FLOAT_ANIMATION_CURVE_IMPL_H_
+#define WEBKIT_COMPOSITOR_BINDINGS_WEB_FLOAT_ANIMATION_CURVE_IMPL_H_
#include "base/memory/scoped_ptr.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebFloatAnimationCurve.h"
@@ -14,10 +14,11 @@ class AnimationCurve;
class KeyframedFloatAnimationCurve;
}
-namespace WebKit {
-struct WebFloatKeyframe;
+namespace WebKit { struct WebFloatKeyframe; }
-class WebFloatAnimationCurveImpl : public WebFloatAnimationCurve {
+namespace webkit {
+
+class WebFloatAnimationCurveImpl : public WebKit::WebFloatAnimationCurve {
public:
WEBKIT_COMPOSITOR_BINDINGS_EXPORT WebFloatAnimationCurveImpl();
virtual ~WebFloatAnimationCurveImpl();
@@ -26,9 +27,10 @@ class WebFloatAnimationCurveImpl : public WebFloatAnimationCurve {
virtual AnimationCurveType type() const;
// WebFloatAnimationCurve implementation.
- virtual void add(const WebFloatKeyframe&);
- virtual void add(const WebFloatKeyframe&, TimingFunctionType);
- virtual void add(const WebFloatKeyframe&,
+ virtual void add(const WebKit::WebFloatKeyframe& keyframe);
+ virtual void add(const WebKit::WebFloatKeyframe& keyframe,
+ TimingFunctionType type);
+ virtual void add(const WebKit::WebFloatKeyframe& keyframe,
double x1,
double y1,
double x2,
@@ -36,12 +38,14 @@ class WebFloatAnimationCurveImpl : public WebFloatAnimationCurve {
virtual float getValue(double time) const;
- scoped_ptr<cc::AnimationCurve> cloneToAnimationCurve() const;
+ scoped_ptr<cc::AnimationCurve> CloneToAnimationCurve() const;
private:
scoped_ptr<cc::KeyframedFloatAnimationCurve> curve_;
+
+ DISALLOW_COPY_AND_ASSIGN(WebFloatAnimationCurveImpl);
};
-}
+} // namespace webkit
-#endif // WebFloatAnimationCurveImpl_h
+#endif // WEBKIT_COMPOSITOR_BINDINGS_WEB_FLOAT_ANIMATION_CURVE_IMPL_H_
diff --git a/webkit/compositor_bindings/web_float_animation_curve_unittest.cc b/webkit/compositor_bindings/web_float_animation_curve_unittest.cc
index ec272ab..3910a3c 100644
--- a/webkit/compositor_bindings/web_float_animation_curve_unittest.cc
+++ b/webkit/compositor_bindings/web_float_animation_curve_unittest.cc
@@ -7,8 +7,11 @@
#include "testing/gtest/include/gtest/gtest.h"
#include "webkit/compositor_bindings/web_float_animation_curve_impl.h"
-using namespace WebKit;
+using WebKit::WebAnimationCurve;
+using WebKit::WebFloatAnimationCurve;
+using WebKit::WebFloatKeyframe;
+namespace webkit {
namespace {
// Tests that a float animation with one keyframe works as expected.
@@ -227,3 +230,4 @@ TEST(WebFloatAnimationCurveTest, DefaultTimingFunction) {
}
} // namespace
+} // namespace webkit
diff --git a/webkit/compositor_bindings/web_image_layer_impl.cc b/webkit/compositor_bindings/web_image_layer_impl.cc
index 7ec6744..a4210c0 100644
--- a/webkit/compositor_bindings/web_image_layer_impl.cc
+++ b/webkit/compositor_bindings/web_image_layer_impl.cc
@@ -15,7 +15,7 @@ static bool usingPictureLayer() {
return cc::switches::IsImplSidePaintingEnabled();
}
-namespace WebKit {
+namespace webkit {
WebImageLayerImpl::WebImageLayerImpl() {
if (usingPictureLayer())
@@ -26,14 +26,16 @@ WebImageLayerImpl::WebImageLayerImpl() {
WebImageLayerImpl::~WebImageLayerImpl() {}
-WebLayer* WebImageLayerImpl::layer() { return layer_.get(); }
+WebKit::WebLayer* WebImageLayerImpl::layer() { return layer_.get(); }
void WebImageLayerImpl::setBitmap(SkBitmap bitmap) {
if (usingPictureLayer()) {
static_cast<cc::PictureImageLayer*>(layer_->layer())->SetBitmap(bitmap);
- static_cast<WebLayerImplFixedBounds*>(layer_.get())->SetFixedBounds(gfx::Size(bitmap.width(), bitmap.height()));
- } else
+ static_cast<WebLayerImplFixedBounds*>(layer_.get())->SetFixedBounds(
+ gfx::Size(bitmap.width(), bitmap.height()));
+ } else {
static_cast<cc::ImageLayer*>(layer_->layer())->SetBitmap(bitmap);
+ }
}
-} // namespace WebKit
+} // namespace webkit
diff --git a/webkit/compositor_bindings/web_image_layer_impl.h b/webkit/compositor_bindings/web_image_layer_impl.h
index 77ec628..d4a483c 100644
--- a/webkit/compositor_bindings/web_image_layer_impl.h
+++ b/webkit/compositor_bindings/web_image_layer_impl.h
@@ -2,30 +2,33 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef WebImageLayerImpl_h
-#define WebImageLayerImpl_h
+#ifndef WEBKIT_COMPOSITOR_BINDINGS_WEB_IMAGE_LAYER_IMPL_H_
+#define WEBKIT_COMPOSITOR_BINDINGS_WEB_IMAGE_LAYER_IMPL_H_
#include "base/memory/scoped_ptr.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebImageLayer.h"
#include "third_party/skia/include/core/SkBitmap.h"
#include "webkit/compositor_bindings/webkit_compositor_bindings_export.h"
-namespace WebKit {
+namespace webkit {
+
class WebLayerImpl;
-class WebImageLayerImpl : public WebImageLayer {
+class WebImageLayerImpl : public WebKit::WebImageLayer {
public:
WEBKIT_COMPOSITOR_BINDINGS_EXPORT WebImageLayerImpl();
virtual ~WebImageLayerImpl();
- // WebImageLayer implementation.
- virtual WebLayer* layer();
+ // WebKit::WebImageLayer implementation.
+ virtual WebKit::WebLayer* layer();
virtual void setBitmap(SkBitmap);
private:
scoped_ptr<WebLayerImpl> layer_;
+
+ DISALLOW_COPY_AND_ASSIGN(WebImageLayerImpl);
};
}
-#endif // WebImageLayerImpl_h
+#endif // WEBKIT_COMPOSITOR_BINDINGS_WEB_IMAGE_LAYER_IMPL_H_
diff --git a/webkit/compositor_bindings/web_layer_impl.cc b/webkit/compositor_bindings/web_layer_impl.cc
index 391ce74..7adb2f1 100644
--- a/webkit/compositor_bindings/web_layer_impl.cc
+++ b/webkit/compositor_bindings/web_layer_impl.cc
@@ -16,8 +16,15 @@
using cc::Animation;
using cc::Layer;
+using WebKit::WebLayer;
+using WebKit::WebFloatPoint;
+using WebKit::WebVector;
+using WebKit::WebRect;
+using WebKit::WebSize;
+using WebKit::WebColor;
+using WebKit::WebFilterOperations;
-namespace WebKit {
+namespace webkit {
WebLayerImpl::WebLayerImpl() : layer_(Layer::Create()) {}
@@ -30,7 +37,7 @@ WebLayerImpl::~WebLayerImpl() {
int WebLayerImpl::id() const { return layer_->id(); }
-void WebLayerImpl::invalidateRect(const WebFloatRect& rect) {
+void WebLayerImpl::invalidateRect(const WebKit::WebFloatRect& rect) {
layer_->SetNeedsDisplayRect(rect);
}
@@ -157,17 +164,18 @@ void WebLayerImpl::setFilter(SkImageFilter* filter) {
layer_->SetFilter(skia::AdoptRef(filter));
}
-void WebLayerImpl::setDebugName(WebString name) {
+void WebLayerImpl::setDebugName(WebKit::WebString name) {
layer_->SetDebugName(UTF16ToASCII(string16(name.data(), name.length())));
}
-void WebLayerImpl::setAnimationDelegate(WebAnimationDelegate* delegate) {
+void WebLayerImpl::setAnimationDelegate(
+ WebKit::WebAnimationDelegate* delegate) {
layer_->set_layer_animation_delegate(delegate);
}
-bool WebLayerImpl::addAnimation(WebAnimation* animation) {
+bool WebLayerImpl::addAnimation(WebKit::WebAnimation* animation) {
return layer_->AddAnimation(
- static_cast<WebAnimationImpl*>(animation)->cloneToAnimation());
+ static_cast<WebAnimationImpl*>(animation)->CloneToAnimation());
}
void WebLayerImpl::removeAnimation(int animation_id) {
@@ -176,7 +184,7 @@ void WebLayerImpl::removeAnimation(int animation_id) {
void WebLayerImpl::removeAnimation(
int animation_id,
- WebAnimation::TargetProperty target_property) {
+ WebKit::WebAnimation::TargetProperty target_property) {
layer_->layer_animation_controller()->RemoveAnimation(
animation_id,
static_cast<Animation::TargetProperty>(target_property));
@@ -206,11 +214,11 @@ void WebLayerImpl::setForceRenderSurface(bool force_render_surface) {
layer_->SetForceRenderSurface(force_render_surface);
}
-void WebLayerImpl::setScrollPosition(WebPoint position) {
+void WebLayerImpl::setScrollPosition(WebKit::WebPoint position) {
layer_->SetScrollOffset(gfx::Point(position).OffsetFromOrigin());
}
-WebPoint WebLayerImpl::scrollPosition() const {
+WebKit::WebPoint WebLayerImpl::scrollPosition() const {
return gfx::PointAtOffsetFromOrigin(layer_->scroll_offset());
}
@@ -311,7 +319,8 @@ bool WebLayerImpl::fixedToContainerLayer() const {
return layer_->fixed_to_container_layer();
}
-void WebLayerImpl::setScrollClient(WebLayerScrollClient* scroll_client) {
+void WebLayerImpl::setScrollClient(
+ WebKit::WebLayerScrollClient* scroll_client) {
layer_->set_layer_scroll_client(scroll_client);
}
diff --git a/webkit/compositor_bindings/web_layer_impl.h b/webkit/compositor_bindings/web_layer_impl.h
index fb6da63..e7252b0 100644
--- a/webkit/compositor_bindings/web_layer_impl.h
+++ b/webkit/compositor_bindings/web_layer_impl.h
@@ -2,8 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef WebLayerImpl_h
-#define WebLayerImpl_h
+#ifndef WEBKIT_COMPOSITOR_BINDINGS_WEB_LAYER_IMPL_H_
+#define WEBKIT_COMPOSITOR_BINDINGS_WEB_LAYER_IMPL_H_
#include "base/memory/ref_counted.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebAnimation.h"
@@ -28,8 +28,11 @@ class WebAnimationDelegate;
class WebFilterOperations;
class WebLayerScrollClient;
struct WebFloatRect;
+}
-class WebLayerImpl : public WebLayer {
+namespace webkit {
+
+class WebLayerImpl : public WebKit::WebLayer {
public:
WEBKIT_COMPOSITOR_BINDINGS_EXPORT WebLayerImpl();
WEBKIT_COMPOSITOR_BINDINGS_EXPORT explicit WebLayerImpl(
@@ -40,77 +43,84 @@ class WebLayerImpl : public WebLayer {
// WebLayer implementation.
virtual int id() const;
- virtual void invalidateRect(const WebFloatRect&);
+ virtual void invalidateRect(const WebKit::WebFloatRect&);
virtual void invalidate();
- virtual void addChild(WebLayer*);
- virtual void insertChild(WebLayer*, size_t index);
- virtual void replaceChild(WebLayer* reference, WebLayer* new_layer);
+ virtual void addChild(WebKit::WebLayer* child);
+ virtual void insertChild(WebKit::WebLayer* child, size_t index);
+ virtual void replaceChild(WebKit::WebLayer* reference,
+ WebKit::WebLayer* new_layer);
virtual void removeFromParent();
virtual void removeAllChildren();
- virtual void setAnchorPoint(const WebFloatPoint&);
- virtual WebFloatPoint anchorPoint() const;
- virtual void setAnchorPointZ(float);
+ virtual void setAnchorPoint(const WebKit::WebFloatPoint&);
+ virtual WebKit::WebFloatPoint anchorPoint() const;
+ virtual void setAnchorPointZ(float anchor_point_z);
virtual float anchorPointZ() const;
- virtual void setBounds(const WebSize&);
- virtual WebSize bounds() const;
- virtual void setMasksToBounds(bool);
+ virtual void setBounds(const WebKit::WebSize& bounds);
+ virtual WebKit::WebSize bounds() const;
+ virtual void setMasksToBounds(bool masks_to_bounds);
virtual bool masksToBounds() const;
- virtual void setMaskLayer(WebLayer*);
- virtual void setReplicaLayer(WebLayer*);
- virtual void setOpacity(float);
+ virtual void setMaskLayer(WebKit::WebLayer* mask);
+ virtual void setReplicaLayer(WebKit::WebLayer* replica);
+ virtual void setOpacity(float opacity);
virtual float opacity() const;
- virtual void setOpaque(bool);
+ virtual void setOpaque(bool opaque);
virtual bool opaque() const;
- virtual void setPosition(const WebFloatPoint&);
- virtual WebFloatPoint position() const;
+ virtual void setPosition(const WebKit::WebFloatPoint& position);
+ virtual WebKit::WebFloatPoint position() const;
virtual void setSublayerTransform(const SkMatrix44&);
virtual SkMatrix44 sublayerTransform() const;
- virtual void setTransform(const SkMatrix44&);
+ virtual void setTransform(const SkMatrix44& transform);
virtual SkMatrix44 transform() const;
- virtual void setDrawsContent(bool);
+ virtual void setDrawsContent(bool draws_content);
virtual bool drawsContent() const;
- virtual void setPreserves3D(bool);
- virtual void setUseParentBackfaceVisibility(bool);
- virtual void setBackgroundColor(WebColor);
- virtual WebColor backgroundColor() const;
- virtual void setFilter(SkImageFilter*);
- virtual void setFilters(const WebFilterOperations&);
- virtual void setBackgroundFilters(const WebFilterOperations&);
- virtual void setDebugName(WebString);
- virtual void setAnimationDelegate(WebAnimationDelegate*);
- virtual bool addAnimation(WebAnimation*);
+ virtual void setPreserves3D(bool preserves_3d);
+ virtual void setUseParentBackfaceVisibility(bool visible);
+ virtual void setBackgroundColor(WebKit::WebColor color);
+ virtual WebKit::WebColor backgroundColor() const;
+ virtual void setFilter(SkImageFilter* filter);
+ virtual void setFilters(const WebKit::WebFilterOperations& filters);
+ virtual void setBackgroundFilters(const WebKit::WebFilterOperations& filters);
+ virtual void setDebugName(WebKit::WebString name);
+ virtual void setAnimationDelegate(WebKit::WebAnimationDelegate* delegate);
+ virtual bool addAnimation(WebKit::WebAnimation* animation);
virtual void removeAnimation(int animation_id);
- virtual void removeAnimation(int animation_id, WebAnimation::TargetProperty);
+ virtual void removeAnimation(int animation_id,
+ WebKit::WebAnimation::TargetProperty);
virtual void pauseAnimation(int animation_id, double time_offset);
virtual void suspendAnimations(double monotonic_time);
virtual void resumeAnimations(double monotonic_time);
virtual bool hasActiveAnimation();
- virtual void transferAnimationsTo(WebLayer*);
- virtual void setForceRenderSurface(bool);
- virtual void setScrollPosition(WebPoint);
- virtual WebPoint scrollPosition() const;
- virtual void setMaxScrollPosition(WebSize);
- virtual WebSize maxScrollPosition() const;
- virtual void setScrollable(bool);
+ virtual void transferAnimationsTo(WebKit::WebLayer* layer);
+ virtual void setForceRenderSurface(bool force);
+ virtual void setScrollPosition(WebKit::WebPoint position);
+ virtual WebKit::WebPoint scrollPosition() const;
+ virtual void setMaxScrollPosition(WebKit::WebSize max_position);
+ virtual WebKit::WebSize maxScrollPosition() const;
+ virtual void setScrollable(bool scrollable);
virtual bool scrollable() const;
- virtual void setHaveWheelEventHandlers(bool);
+ virtual void setHaveWheelEventHandlers(bool have_wheel_event_handlers);
virtual bool haveWheelEventHandlers() const;
- virtual void setShouldScrollOnMainThread(bool);
+ virtual void setShouldScrollOnMainThread(bool scroll_on_main);
virtual bool shouldScrollOnMainThread() const;
- virtual void setNonFastScrollableRegion(const WebVector<WebRect>&);
- virtual WebVector<WebRect> nonFastScrollableRegion() const;
- virtual void setTouchEventHandlerRegion(const WebVector<WebRect>&);
- virtual WebVector<WebRect> touchEventHandlerRegion() const;
- virtual void setIsContainerForFixedPositionLayers(bool);
+ virtual void setNonFastScrollableRegion(
+ const WebKit::WebVector<WebKit::WebRect>& region);
+ virtual WebKit::WebVector<WebKit::WebRect> nonFastScrollableRegion() const;
+ virtual void setTouchEventHandlerRegion(
+ const WebKit::WebVector<WebKit::WebRect>& region);
+ virtual WebKit::WebVector<WebKit::WebRect> touchEventHandlerRegion() const;
+ virtual void setIsContainerForFixedPositionLayers(bool is_container);
virtual bool isContainerForFixedPositionLayers() const;
- virtual void setFixedToContainerLayer(bool);
+ virtual void setFixedToContainerLayer(bool is_fixed);
virtual bool fixedToContainerLayer() const;
- virtual void setScrollClient(WebLayerScrollClient*);
+ virtual void setScrollClient(WebKit::WebLayerScrollClient* client);
protected:
scoped_refptr<cc::Layer> layer_;
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(WebLayerImpl);
};
} // namespace WebKit
-#endif // WebLayerImpl_h
+#endif // WEBKIT_COMPOSITOR_BINDINGS_WEB_LAYER_IMPL_H_
diff --git a/webkit/compositor_bindings/web_layer_impl_fixed_bounds.cc b/webkit/compositor_bindings/web_layer_impl_fixed_bounds.cc
index 0999dff..7804da3 100644
--- a/webkit/compositor_bindings/web_layer_impl_fixed_bounds.cc
+++ b/webkit/compositor_bindings/web_layer_impl_fixed_bounds.cc
@@ -11,7 +11,7 @@
using cc::Layer;
-namespace WebKit {
+namespace webkit {
WebLayerImplFixedBounds::WebLayerImplFixedBounds() {
}
@@ -24,28 +24,28 @@ WebLayerImplFixedBounds::WebLayerImplFixedBounds(scoped_refptr<Layer> layer)
WebLayerImplFixedBounds::~WebLayerImplFixedBounds() {
}
-void WebLayerImplFixedBounds::invalidateRect(const WebFloatRect& rect) {
+void WebLayerImplFixedBounds::invalidateRect(const WebKit::WebFloatRect& rect) {
// Partial invalidations seldom occur for such layers.
// Simply invalidate the whole layer to avoid transformation of coordinates.
invalidate();
}
void WebLayerImplFixedBounds::setAnchorPoint(
- const WebFloatPoint& anchor_point) {
+ const WebKit::WebFloatPoint& anchor_point) {
if (anchor_point != this->anchorPoint()) {
layer_->SetAnchorPoint(anchor_point);
UpdateLayerBoundsAndTransform();
}
}
-void WebLayerImplFixedBounds::setBounds(const WebSize& bounds) {
+void WebLayerImplFixedBounds::setBounds(const WebKit::WebSize& bounds) {
if (original_bounds_ != gfx::Size(bounds)) {
original_bounds_ = bounds;
UpdateLayerBoundsAndTransform();
}
}
-WebSize WebLayerImplFixedBounds::bounds() const {
+WebKit::WebSize WebLayerImplFixedBounds::bounds() const {
return original_bounds_;
}
@@ -69,7 +69,7 @@ SkMatrix44 WebLayerImplFixedBounds::transform() const {
return original_transform_.matrix();
}
-void WebLayerImplFixedBounds::SetFixedBounds(const gfx::Size& fixed_bounds) {
+void WebLayerImplFixedBounds::SetFixedBounds(gfx::Size fixed_bounds) {
if (fixed_bounds_ != fixed_bounds) {
fixed_bounds_ = fixed_bounds;
UpdateLayerBoundsAndTransform();
@@ -92,8 +92,7 @@ void WebLayerImplFixedBounds::SetTransformInternal(
}
}
-void WebLayerImplFixedBounds::UpdateLayerBoundsAndTransform()
-{
+void WebLayerImplFixedBounds::UpdateLayerBoundsAndTransform() {
if (fixed_bounds_.IsEmpty() || original_bounds_.IsEmpty() ||
fixed_bounds_ == original_bounds_ ||
// For now fall back to non-fixed bounds for non-zero anchor point.
@@ -126,4 +125,4 @@ void WebLayerImplFixedBounds::UpdateLayerBoundsAndTransform()
layer_->SetSublayerTransform(sublayer_transform_with_inverse_bounds_scale);
}
-} // namespace WebKit
+} // namespace WebKit
diff --git a/webkit/compositor_bindings/web_layer_impl_fixed_bounds.h b/webkit/compositor_bindings/web_layer_impl_fixed_bounds.h
index f1f6060..2e906b9 100644
--- a/webkit/compositor_bindings/web_layer_impl_fixed_bounds.h
+++ b/webkit/compositor_bindings/web_layer_impl_fixed_bounds.h
@@ -2,14 +2,14 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef WebLayerImplFixedBounds_h
-#define WebLayerImplFixedBounds_h
+#ifndef WEBKIT_COMPOSITOR_BINDINGS_WEB_LAYER_IMPL_FIXED_BOUNDS_H_
+#define WEBKIT_COMPOSITOR_BINDINGS_WEB_LAYER_IMPL_FIXED_BOUNDS_H_
#include "ui/gfx/size.h"
#include "ui/gfx/transform.h"
#include "webkit/compositor_bindings/web_layer_impl.h"
-namespace WebKit {
+namespace webkit {
// A special implementation of WebLayerImpl for layers that its contents
// need to be automatically scaled when the bounds changes. The compositor
@@ -24,28 +24,31 @@ class WebLayerImplFixedBounds : public WebLayerImpl {
virtual ~WebLayerImplFixedBounds();
// WebLayerImpl overrides.
- virtual void invalidateRect(const WebFloatRect&);
- virtual void setAnchorPoint(const WebFloatPoint&);
- virtual void setBounds(const WebSize&);
- virtual WebSize bounds() const;
- virtual void setSublayerTransform(const SkMatrix44&);
+ virtual void invalidateRect(const WebKit::WebFloatRect& rect);
+ virtual void setAnchorPoint(const WebKit::WebFloatPoint& anchor_point);
+ virtual void setBounds(const WebKit::WebSize& bounds);
+ virtual WebKit::WebSize bounds() const;
+ virtual void setSublayerTransform(const SkMatrix44& transform);
virtual SkMatrix44 sublayerTransform() const;
- virtual void setTransform(const SkMatrix44&);
+ virtual void setTransform(const SkMatrix44& transform);
virtual SkMatrix44 transform() const;
- WEBKIT_COMPOSITOR_BINDINGS_EXPORT void SetFixedBounds(const gfx::Size&);
+ WEBKIT_COMPOSITOR_BINDINGS_EXPORT void SetFixedBounds(gfx::Size bounds);
protected:
- void SetTransformInternal(const gfx::Transform&);
- void SetSublayerTransformInternal(const gfx::Transform&);
+ void SetTransformInternal(const gfx::Transform& transform);
+ void SetSublayerTransformInternal(const gfx::Transform& transform);
void UpdateLayerBoundsAndTransform();
gfx::Transform original_sublayer_transform_;
gfx::Transform original_transform_;
gfx::Size original_bounds_;
gfx::Size fixed_bounds_;
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(WebLayerImplFixedBounds);
};
-} // namespace WebKit
+} // namespace webkit
-#endif // WebLayerImplFixedBounds_h
+#endif // WEBKIT_COMPOSITOR_BINDINGS_WEB_LAYER_IMPL_FIXED_BOUNDS_H_
diff --git a/webkit/compositor_bindings/web_layer_impl_fixed_bounds_unittest.cc b/webkit/compositor_bindings/web_layer_impl_fixed_bounds_unittest.cc
index 7322d3f..5346a83 100644
--- a/webkit/compositor_bindings/web_layer_impl_fixed_bounds_unittest.cc
+++ b/webkit/compositor_bindings/web_layer_impl_fixed_bounds_unittest.cc
@@ -2,6 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include <vector>
#include "cc/layers/picture_image_layer.h"
#include "cc/test/geometry_test_utils.h"
#include "cc/trees/layer_tree_host_common.h"
@@ -12,7 +13,11 @@
#include "ui/gfx/point3_f.h"
#include "webkit/compositor_bindings/web_layer_impl_fixed_bounds.h"
-using namespace WebKit;
+using WebKit::WebFloatPoint;
+using WebKit::WebSize;
+
+namespace webkit {
+namespace {
TEST(WebLayerImplFixedBoundsTest, IdentityBounds) {
scoped_ptr<WebLayerImplFixedBounds> layer(new WebLayerImplFixedBounds());
@@ -187,3 +192,6 @@ TEST(WebLayerImplFixedBoundsTest, CompareToWebLayerImplComplex) {
transform,
sublayer_transform);
}
+
+} // namespace
+} // namespace webkit
diff --git a/webkit/compositor_bindings/web_layer_tree_view_impl_for_testing.cc b/webkit/compositor_bindings/web_layer_tree_view_impl_for_testing.cc
index 7d1d3a7..9d618c9 100644
--- a/webkit/compositor_bindings/web_layer_tree_view_impl_for_testing.cc
+++ b/webkit/compositor_bindings/web_layer_tree_view_impl_for_testing.cc
@@ -31,7 +31,14 @@
#include "webkit/gpu/test_context_provider_factory.h"
#include "webkit/support/test_webkit_platform_support.h"
-namespace WebKit {
+using WebKit::WebColor;
+using WebKit::WebGraphicsContext3D;
+using WebKit::WebRect;
+using WebKit::WebRenderingStats;
+using WebKit::WebSize;
+
+namespace webkit {
+
WebLayerTreeViewImplForTesting::WebLayerTreeViewImplForTesting(
webkit_support::LayerTreeViewType type,
webkit_support::DRTLayerTreeViewClient* client)
@@ -57,7 +64,8 @@ void WebLayerTreeViewImplForTesting::setSurfaceReady() {
layer_tree_host_->SetSurfaceReady();
}
-void WebLayerTreeViewImplForTesting::setRootLayer(const WebLayer& root) {
+void WebLayerTreeViewImplForTesting::setRootLayer(
+ const WebKit::WebLayer& root) {
layer_tree_host_->SetRootLayer(
static_cast<const WebLayerImpl*>(&root)->layer());
}
@@ -111,7 +119,7 @@ void WebLayerTreeViewImplForTesting::setPageScaleFactorAndLimits(
}
void WebLayerTreeViewImplForTesting::startPageScaleAnimation(
- const WebPoint& scroll,
+ const WebKit::WebPoint& scroll,
bool use_anchor,
float new_page_scale,
double duration_sec) {}
@@ -233,4 +241,4 @@ WebLayerTreeViewImplForTesting::OffscreenContextProviderForCompositorThread() {
OffscreenContextProviderForCompositorThread();
}
-} // namespace WebKit
+} // namespace webkit
diff --git a/webkit/compositor_bindings/web_layer_tree_view_impl_for_testing.h b/webkit/compositor_bindings/web_layer_tree_view_impl_for_testing.h
index b8d980f..ffd3b8f 100644
--- a/webkit/compositor_bindings/web_layer_tree_view_impl_for_testing.h
+++ b/webkit/compositor_bindings/web_layer_tree_view_impl_for_testing.h
@@ -16,8 +16,9 @@ class LayerTreeHost;
class Thread;
}
-namespace WebKit {
-class WebLayer;
+namespace WebKit { class WebLayer; }
+
+namespace webkit {
class WebLayerTreeViewImplForTesting : public WebKit::WebLayerTreeView,
public cc::LayerTreeHostClient {
@@ -30,23 +31,23 @@ class WebLayerTreeViewImplForTesting : public WebKit::WebLayerTreeView,
WEBKIT_COMPOSITOR_BINDINGS_EXPORT bool initialize(
scoped_ptr<cc::Thread> compositor_thread);
- // WebLayerTreeView implementation.
+ // WebKit::WebLayerTreeView implementation.
virtual void setSurfaceReady();
- virtual void setRootLayer(const WebLayer&);
+ virtual void setRootLayer(const WebKit::WebLayer& layer);
virtual void clearRootLayer();
- virtual void setViewportSize(const WebSize& layout_viewport_size,
- const WebSize& device_viewport_size);
- virtual WebSize layoutViewportSize() const;
- virtual WebSize deviceViewportSize() const;
- virtual void setDeviceScaleFactor(float);
+ virtual void setViewportSize(const WebKit::WebSize& layout_viewport_size,
+ const WebKit::WebSize& device_viewport_size);
+ virtual WebKit::WebSize layoutViewportSize() const;
+ virtual WebKit::WebSize deviceViewportSize() const;
+ virtual void setDeviceScaleFactor(float scale_factor);
virtual float deviceScaleFactor() const;
- virtual void setBackgroundColor(WebColor);
- virtual void setHasTransparentBackground(bool);
- virtual void setVisible(bool);
+ virtual void setBackgroundColor(WebKit::WebColor);
+ virtual void setHasTransparentBackground(bool transparent);
+ virtual void setVisible(bool visible);
virtual void setPageScaleFactorAndLimits(float page_scale_factor,
float minimum,
float maximum);
- virtual void startPageScaleAnimation(const WebPoint& destination,
+ virtual void startPageScaleAnimation(const WebKit::WebPoint& destination,
bool use_anchor,
float new_page_scale,
double duration_sec);
@@ -56,10 +57,10 @@ class WebLayerTreeViewImplForTesting : public WebKit::WebLayerTreeView,
virtual void composite();
virtual void updateAnimations(double frame_begin_time);
virtual void didStopFlinging();
- virtual bool compositeAndReadback(void* pixels, const WebRect&);
+ virtual bool compositeAndReadback(void* pixels, const WebKit::WebRect& rect);
virtual void finishAllRendering();
virtual void setDeferCommits(bool defer_commits);
- virtual void renderingStats(WebRenderingStats&) const;
+ virtual void renderingStats(WebKit::WebRenderingStats& stats) const;
// cc::LayerTreeHostClient implementation.
virtual void willBeginFrame() OVERRIDE;
@@ -85,8 +86,10 @@ class WebLayerTreeViewImplForTesting : public WebKit::WebLayerTreeView,
webkit_support::LayerTreeViewType type_;
webkit_support::DRTLayerTreeViewClient* client_;
scoped_ptr<cc::LayerTreeHost> layer_tree_host_;
+
+ DISALLOW_COPY_AND_ASSIGN(WebLayerTreeViewImplForTesting);
};
-} // namespace Web_kit
+} // namespace webkit
#endif // WEBKIT_COMPOSITOR_BINDINGS_WEB_LAYER_TREE_VIEW_IMPL_FOR_TESTING_H_
diff --git a/webkit/compositor_bindings/web_nine_patch_layer_impl.cc b/webkit/compositor_bindings/web_nine_patch_layer_impl.cc
deleted file mode 100644
index 03c32fb..0000000
--- a/webkit/compositor_bindings/web_nine_patch_layer_impl.cc
+++ /dev/null
@@ -1,31 +0,0 @@
-// Copyright 2012 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "webkit/compositor_bindings/web_nine_patch_layer_impl.h"
-
-#include "cc/layers/nine_patch_layer.h"
-#include "third_party/skia/include/core/SkBitmap.h"
-#include "ui/gfx/rect.h"
-#include "webkit/compositor_bindings/web_layer_impl.h"
-
-using cc::NinePatchLayer;
-
-namespace WebKit {
-
-WebNinePatchLayerImpl::WebNinePatchLayerImpl()
- : layer_(new WebLayerImpl(NinePatchLayer::Create())) {
- layer_->layer()->SetIsDrawable(true);
-}
-
-WebNinePatchLayerImpl::~WebNinePatchLayerImpl() {}
-
-WebLayer* WebNinePatchLayerImpl::layer() { return layer_.get(); }
-
-void WebNinePatchLayerImpl::setBitmap(const SkBitmap& bitmap,
- const WebRect& aperture) {
- static_cast<NinePatchLayer*>(layer_->layer())->SetBitmap(bitmap,
- gfx::Rect(aperture));
-}
-
-} // namespace WebKit
diff --git a/webkit/compositor_bindings/web_nine_patch_layer_impl.h b/webkit/compositor_bindings/web_nine_patch_layer_impl.h
deleted file mode 100644
index 8d6cbfe..0000000
--- a/webkit/compositor_bindings/web_nine_patch_layer_impl.h
+++ /dev/null
@@ -1,31 +0,0 @@
-// Copyright 2012 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef WebNinePatchLayerImpl_h
-#define WebNinePatchLayerImpl_h
-
-#include "base/memory/scoped_ptr.h"
-#include "third_party/skia/include/core/SkBitmap.h"
-#include "webkit/compositor_bindings/web_layer_impl.h"
-
-namespace WebKit {
-
-class WebLayerImpl;
-
-class WebNinePatchLayerImpl {
- public:
- WebNinePatchLayerImpl();
- virtual ~WebNinePatchLayerImpl();
-
- WebLayer* layer();
-
- void setBitmap(const SkBitmap& bitmap, const WebRect& aperture);
-
- private:
- scoped_ptr<WebLayerImpl> layer_;
-};
-
-} // namespace WebKit
-
-#endif
diff --git a/webkit/compositor_bindings/web_rendering_stats_impl.h b/webkit/compositor_bindings/web_rendering_stats_impl.h
index 022f80c..22a9ef0 100644
--- a/webkit/compositor_bindings/web_rendering_stats_impl.h
+++ b/webkit/compositor_bindings/web_rendering_stats_impl.h
@@ -2,8 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef WEB_RENDERING_STATS_IMPL_H_
-#define WEB_RENDERING_STATS_IMPL_H_
+#ifndef WEBKIT_COMPOSITOR_BINDINGS_WEB_RENDERING_STATS_IMPL_H_
+#define WEBKIT_COMPOSITOR_BINDINGS_WEB_RENDERING_STATS_IMPL_H_
#include "cc/debug/rendering_stats.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebRenderingStats.h"
@@ -18,4 +18,4 @@ struct WebRenderingStatsImpl : public WebRenderingStats {
} // namespace WebKit
-#endif // WEB_RENDERING_STATS_IMPL_H_
+#endif // WEBKIT_COMPOSITOR_BINDINGS_WEB_RENDERING_STATS_IMPL_H_
diff --git a/webkit/compositor_bindings/web_scrollbar_layer_impl.cc b/webkit/compositor_bindings/web_scrollbar_layer_impl.cc
index 88cd2cc..9332d43 100644
--- a/webkit/compositor_bindings/web_scrollbar_layer_impl.cc
+++ b/webkit/compositor_bindings/web_scrollbar_layer_impl.cc
@@ -10,13 +10,14 @@
using cc::ScrollbarLayer;
using cc::ScrollbarThemePainter;
+using WebKit::WebScrollbarThemePainter;
-namespace WebKit {
+namespace webkit {
WebScrollbarLayerImpl::WebScrollbarLayerImpl(
- WebScrollbar* scrollbar,
- WebScrollbarThemePainter painter,
- WebScrollbarThemeGeometry* geometry)
+ WebKit::WebScrollbar* scrollbar,
+ WebKit::WebScrollbarThemePainter painter,
+ WebKit::WebScrollbarThemeGeometry* geometry)
: layer_(new WebLayerImpl(ScrollbarLayer::Create(
make_scoped_ptr(scrollbar),
WebToCCScrollbarThemePainterAdapter::Create(
@@ -27,11 +28,11 @@ WebScrollbarLayerImpl::WebScrollbarLayerImpl(
WebScrollbarLayerImpl::~WebScrollbarLayerImpl() {}
-WebLayer* WebScrollbarLayerImpl::layer() { return layer_.get(); }
+WebKit::WebLayer* WebScrollbarLayerImpl::layer() { return layer_.get(); }
-void WebScrollbarLayerImpl::setScrollLayer(WebLayer* layer) {
+void WebScrollbarLayerImpl::setScrollLayer(WebKit::WebLayer* layer) {
int id = layer ? static_cast<WebLayerImpl*>(layer)->layer()->id() : 0;
static_cast<ScrollbarLayer*>(layer_->layer())->SetScrollLayerId(id);
}
-} // namespace WebKit
+} // namespace webkit
diff --git a/webkit/compositor_bindings/web_scrollbar_layer_impl.h b/webkit/compositor_bindings/web_scrollbar_layer_impl.h
index 8fb4c7c..6d37477 100644
--- a/webkit/compositor_bindings/web_scrollbar_layer_impl.h
+++ b/webkit/compositor_bindings/web_scrollbar_layer_impl.h
@@ -2,36 +2,41 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef WebScrollbarLayerImpl_h
-#define WebScrollbarLayerImpl_h
+#ifndef WEBKIT_COMPOSITOR_BINDINGS_WEB_SCROLLBAR_LAYER_IMPL_H_
+#define WEBKIT_COMPOSITOR_BINDINGS_WEB_SCROLLBAR_LAYER_IMPL_H_
#include "base/memory/scoped_ptr.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebScrollbarLayer.h"
#include "webkit/compositor_bindings/webkit_compositor_bindings_export.h"
namespace WebKit {
-
-class WebLayerImpl;
class WebScrollbar;
class WebScrollbarThemeGeometry;
class WebScrollbarThemePainter;
+}
+
+namespace webkit {
-class WebScrollbarLayerImpl : public WebScrollbarLayer {
+class WebLayerImpl;
+
+class WebScrollbarLayerImpl : public WebKit::WebScrollbarLayer {
public:
WEBKIT_COMPOSITOR_BINDINGS_EXPORT WebScrollbarLayerImpl(
- WebScrollbar*,
- WebScrollbarThemePainter,
- WebScrollbarThemeGeometry*);
+ WebKit::WebScrollbar* scrollbar,
+ WebKit::WebScrollbarThemePainter painter,
+ WebKit::WebScrollbarThemeGeometry* geometry);
virtual ~WebScrollbarLayerImpl();
- // WebScrollbarLayer implementation.
- virtual WebLayer* layer();
- virtual void setScrollLayer(WebLayer*);
+ // WebKit::WebScrollbarLayer implementation.
+ virtual WebKit::WebLayer* layer();
+ virtual void setScrollLayer(WebKit::WebLayer* layer);
private:
scoped_ptr<WebLayerImpl> layer_;
+
+ DISALLOW_COPY_AND_ASSIGN(WebScrollbarLayerImpl);
};
-}
+} // namespace webkit
-#endif // WebScrollbarLayerImpl_h
+#endif // WEBKIT_COMPOSITOR_BINDINGS_WEB_SCROLLBAR_LAYER_IMPL_H_
diff --git a/webkit/compositor_bindings/web_solid_color_layer_impl.cc b/webkit/compositor_bindings/web_solid_color_layer_impl.cc
index 38ceb10..aaf19be 100644
--- a/webkit/compositor_bindings/web_solid_color_layer_impl.cc
+++ b/webkit/compositor_bindings/web_solid_color_layer_impl.cc
@@ -9,7 +9,7 @@
using cc::SolidColorLayer;
-namespace WebKit {
+namespace webkit {
WebSolidColorLayerImpl::WebSolidColorLayerImpl()
: layer_(new WebLayerImpl(SolidColorLayer::Create())) {
@@ -18,10 +18,10 @@ WebSolidColorLayerImpl::WebSolidColorLayerImpl()
WebSolidColorLayerImpl::~WebSolidColorLayerImpl() {}
-WebLayer* WebSolidColorLayerImpl::layer() { return layer_.get(); }
+WebKit::WebLayer* WebSolidColorLayerImpl::layer() { return layer_.get(); }
-void WebSolidColorLayerImpl::setBackgroundColor(WebColor color) {
+void WebSolidColorLayerImpl::setBackgroundColor(WebKit::WebColor color) {
layer_->setBackgroundColor(color);
}
-} // namespace WebKit
+} // namespace webkit
diff --git a/webkit/compositor_bindings/web_solid_color_layer_impl.h b/webkit/compositor_bindings/web_solid_color_layer_impl.h
index 6d841b4..bb7732a 100644
--- a/webkit/compositor_bindings/web_solid_color_layer_impl.h
+++ b/webkit/compositor_bindings/web_solid_color_layer_impl.h
@@ -2,31 +2,33 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef WebSolidColorLayerImpl_h
-#define WebSolidColorLayerImpl_h
+#ifndef WEBKIT_COMPOSITOR_BINDINGS_WEB_SOLID_COLOR_LAYER_IMPL_H_
+#define WEBKIT_COMPOSITOR_BINDINGS_WEB_SOLID_COLOR_LAYER_IMPL_H_
#include "base/memory/scoped_ptr.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebColor.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebSolidColorLayer.h"
#include "webkit/compositor_bindings/webkit_compositor_bindings_export.h"
-namespace WebKit {
+namespace webkit {
class WebLayerImpl;
-class WebSolidColorLayerImpl : public WebSolidColorLayer {
+class WebSolidColorLayerImpl : public WebKit::WebSolidColorLayer {
public:
WEBKIT_COMPOSITOR_BINDINGS_EXPORT WebSolidColorLayerImpl();
virtual ~WebSolidColorLayerImpl();
- // WebSolidColorLayer implementation.
- virtual WebLayer* layer();
- virtual void setBackgroundColor(WebColor);
+ // WebKit::WebSolidColorLayer implementation.
+ virtual WebKit::WebLayer* layer();
+ virtual void setBackgroundColor(WebKit::WebColor);
private:
scoped_ptr<WebLayerImpl> layer_;
+
+ DISALLOW_COPY_AND_ASSIGN(WebSolidColorLayerImpl);
};
-} // namespace WebKit
+} // namespace webkit
-#endif // WebSolidColorLayerImpl_h
+#endif // WEBKIT_COMPOSITOR_BINDINGS_WEB_SOLID_COLOR_LAYER_IMPL_H_
diff --git a/webkit/compositor_bindings/web_to_ccinput_handler_adapter.cc b/webkit/compositor_bindings/web_to_ccinput_handler_adapter.cc
index 581e515..d079a0b 100644
--- a/webkit/compositor_bindings/web_to_ccinput_handler_adapter.cc
+++ b/webkit/compositor_bindings/web_to_ccinput_handler_adapter.cc
@@ -6,8 +6,9 @@
#include "third_party/WebKit/Source/Platform/chromium/public/WebInputHandlerClient.h"
-#define COMPILE_ASSERT_MATCHING_ENUM(webkit_name, cc_name) \
- COMPILE_ASSERT(int(WebKit::webkit_name) == int(cc::cc_name), \
+#define COMPILE_ASSERT_MATCHING_ENUM(webkit_name, cc_name) \
+ COMPILE_ASSERT(static_cast<int>(WebKit::webkit_name) == \
+ static_cast<int>(cc::cc_name), \
mismatching_enums)
COMPILE_ASSERT_MATCHING_ENUM(WebInputHandlerClient::ScrollStatusOnMainThread,
@@ -37,7 +38,7 @@ WebToCCInputHandlerAdapter::~WebToCCInputHandlerAdapter() {}
class WebToCCInputHandlerAdapter::ClientAdapter : public WebInputHandlerClient {
public:
- ClientAdapter(cc::InputHandlerClient* client) : client_(client) {}
+ explicit ClientAdapter(cc::InputHandlerClient* client) : client_(client) {}
virtual ~ClientAdapter() {}
diff --git a/webkit/compositor_bindings/web_to_ccinput_handler_adapter.h b/webkit/compositor_bindings/web_to_ccinput_handler_adapter.h
index 4eca7b8..f6c899e5 100644
--- a/webkit/compositor_bindings/web_to_ccinput_handler_adapter.h
+++ b/webkit/compositor_bindings/web_to_ccinput_handler_adapter.h
@@ -2,8 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef WebToCCInputHandlerAdapter_h
-#define WebToCCInputHandlerAdapter_h
+#ifndef WEBKIT_COMPOSITOR_BINDINGS_WEB_TO_CCINPUT_HANDLER_ADAPTER_H_
+#define WEBKIT_COMPOSITOR_BINDINGS_WEB_TO_CCINPUT_HANDLER_ADAPTER_H_
#include "base/memory/scoped_ptr.h"
#include "cc/input/input_handler.h"
@@ -14,7 +14,7 @@ namespace WebKit {
class WebToCCInputHandlerAdapter : public cc::InputHandler {
public:
- WEBKIT_COMPOSITOR_BINDINGS_EXPORT static
+ WEBKIT_COMPOSITOR_BINDINGS_EXPORT static
scoped_ptr<WebToCCInputHandlerAdapter> create(
scoped_ptr<WebInputHandler>);
virtual ~WebToCCInputHandlerAdapter();
@@ -30,8 +30,10 @@ class WebToCCInputHandlerAdapter : public cc::InputHandler {
class ClientAdapter;
scoped_ptr<ClientAdapter> client_adapter_;
scoped_ptr<WebInputHandler> handler_;
+
+ DISALLOW_COPY_AND_ASSIGN(WebToCCInputHandlerAdapter);
};
}
-#endif // WebToCCInputHandlerAdapter_h
+#endif // WEBKIT_COMPOSITOR_BINDINGS_WEB_TO_CCINPUT_HANDLER_ADAPTER_H_
diff --git a/webkit/compositor_bindings/web_to_ccscrollbar_theme_painter_adapter.cc b/webkit/compositor_bindings/web_to_ccscrollbar_theme_painter_adapter.cc
index b83757c..38f267c 100644
--- a/webkit/compositor_bindings/web_to_ccscrollbar_theme_painter_adapter.cc
+++ b/webkit/compositor_bindings/web_to_ccscrollbar_theme_painter_adapter.cc
@@ -7,7 +7,14 @@
#include "third_party/WebKit/Source/Platform/chromium/public/WebRect.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebScrollbarThemePainter.h"
-namespace WebKit {
+using WebKit::WebScrollbarThemePainter;
+
+namespace webkit {
+
+WebToCCScrollbarThemePainterAdapter::
+WebToCCScrollbarThemePainterAdapter(
+ scoped_ptr<WebScrollbarThemePainter> web_painter)
+ : painter_(web_painter.Pass()) {}
WebToCCScrollbarThemePainterAdapter::~WebToCCScrollbarThemePainterAdapter() {}
@@ -70,4 +77,4 @@ void WebToCCScrollbarThemePainterAdapter::PaintThumb(SkCanvas* canvas,
painter_->paintThumb(canvas, rect);
}
-} // namespace WebKit
+} // namespace webkit
diff --git a/webkit/compositor_bindings/web_to_ccscrollbar_theme_painter_adapter.h b/webkit/compositor_bindings/web_to_ccscrollbar_theme_painter_adapter.h
index 47e365b..c763464 100644
--- a/webkit/compositor_bindings/web_to_ccscrollbar_theme_painter_adapter.h
+++ b/webkit/compositor_bindings/web_to_ccscrollbar_theme_painter_adapter.h
@@ -8,14 +8,14 @@
#include "base/memory/scoped_ptr.h"
#include "cc/layers/scrollbar_theme_painter.h"
-namespace WebKit {
+namespace WebKit { class WebScrollbarThemePainter; }
-class WebScrollbarThemePainter;
+namespace webkit {
class WebToCCScrollbarThemePainterAdapter : public cc::ScrollbarThemePainter {
public:
static scoped_ptr<WebToCCScrollbarThemePainterAdapter> Create(
- scoped_ptr<WebScrollbarThemePainter> web_painter) {
+ scoped_ptr<WebKit::WebScrollbarThemePainter> web_painter) {
return make_scoped_ptr(
new WebToCCScrollbarThemePainterAdapter(web_painter.Pass()));
}
@@ -41,13 +41,14 @@ class WebToCCScrollbarThemePainterAdapter : public cc::ScrollbarThemePainter {
virtual void PaintThumb(SkCanvas* canvas, const gfx::Rect& rect) OVERRIDE;
private:
- WebToCCScrollbarThemePainterAdapter(
- scoped_ptr<WebScrollbarThemePainter> web_painter)
- : painter_(web_painter.Pass()) {}
+ explicit WebToCCScrollbarThemePainterAdapter(
+ scoped_ptr<WebKit::WebScrollbarThemePainter> web_painter);
- scoped_ptr<WebScrollbarThemePainter> painter_;
+ scoped_ptr<WebKit::WebScrollbarThemePainter> painter_;
+
+ DISALLOW_COPY_AND_ASSIGN(WebToCCScrollbarThemePainterAdapter);
};
-} // namespace WebKit
+} // namespace webkit
#endif // WEBKIT_COMPOSITOR_BINDINGS_WEB_TO_CCSCROLLBAR_THEME_PAINTER_ADAPTER_H_
diff --git a/webkit/compositor_bindings/web_to_ccvideo_frame_provider.cc b/webkit/compositor_bindings/web_to_ccvideo_frame_provider.cc
index 7d4211d..e411352 100644
--- a/webkit/compositor_bindings/web_to_ccvideo_frame_provider.cc
+++ b/webkit/compositor_bindings/web_to_ccvideo_frame_provider.cc
@@ -25,8 +25,8 @@ WebToCCVideoFrameProvider::WebToCCVideoFrameProvider(
WebToCCVideoFrameProvider::~WebToCCVideoFrameProvider() {}
-class WebToCCVideoFrameProvider::ClientAdapter :
- public WebVideoFrameProvider::Client {
+class WebToCCVideoFrameProvider::ClientAdapter
+ : public WebVideoFrameProvider::Client {
public:
explicit ClientAdapter(cc::VideoFrameProvider::Client* cc_client)
: cc_client_(cc_client) {}
diff --git a/webkit/compositor_bindings/web_to_ccvideo_frame_provider.h b/webkit/compositor_bindings/web_to_ccvideo_frame_provider.h
index 882288c..ec743df 100644
--- a/webkit/compositor_bindings/web_to_ccvideo_frame_provider.h
+++ b/webkit/compositor_bindings/web_to_ccvideo_frame_provider.h
@@ -23,7 +23,7 @@ class WebToCCVideoFrameProvider : public cc::VideoFrameProvider {
virtual ~WebToCCVideoFrameProvider();
// cc::VideoFrameProvider implementation.
- virtual void SetVideoFrameProviderClient(Client*) OVERRIDE;
+ virtual void SetVideoFrameProviderClient(Client* client) OVERRIDE;
virtual scoped_refptr<media::VideoFrame> GetCurrentFrame() OVERRIDE;
virtual void PutCurrentFrame(const scoped_refptr<media::VideoFrame>& frame)
OVERRIDE;
@@ -35,6 +35,8 @@ class WebToCCVideoFrameProvider : public cc::VideoFrameProvider {
scoped_ptr<ClientAdapter> client_adapter_;
WebKit::WebVideoFrameProvider* web_provider_;
WebKit::WebVideoFrame* web_frame_;
+
+ DISALLOW_COPY_AND_ASSIGN(WebToCCVideoFrameProvider);
};
} // namespace webkit
diff --git a/webkit/compositor_bindings/web_transform_animation_curve_impl.cc b/webkit/compositor_bindings/web_transform_animation_curve_impl.cc
index db30520..52f2f54 100644
--- a/webkit/compositor_bindings/web_transform_animation_curve_impl.cc
+++ b/webkit/compositor_bindings/web_transform_animation_curve_impl.cc
@@ -10,14 +10,16 @@
#include "webkit/compositor_bindings/web_animation_curve_common.h"
#include "webkit/compositor_bindings/web_transform_operations_impl.h"
-namespace WebKit {
+using WebKit::WebTransformKeyframe;
+
+namespace webkit {
WebTransformAnimationCurveImpl::WebTransformAnimationCurveImpl()
: curve_(cc::KeyframedTransformAnimationCurve::Create()) {}
WebTransformAnimationCurveImpl::~WebTransformAnimationCurveImpl() {}
-WebAnimationCurve::AnimationCurveType
+WebKit::WebAnimationCurve::AnimationCurveType
WebTransformAnimationCurveImpl::type() const {
return WebAnimationCurve::AnimationCurveTypeTransform;
}
@@ -32,7 +34,7 @@ void WebTransformAnimationCurveImpl::add(const WebTransformKeyframe& keyframe,
static_cast<const webkit::WebTransformOperationsImpl&>(keyframe.value())
.AsTransformOperations();
curve_->AddKeyframe(cc::TransformKeyframe::Create(
- keyframe.time(), transform_operations, createTimingFunction(type)));
+ keyframe.time(), transform_operations, CreateTimingFunction(type)));
}
void WebTransformAnimationCurveImpl::add(const WebTransformKeyframe& keyframe,
@@ -51,8 +53,8 @@ void WebTransformAnimationCurveImpl::add(const WebTransformKeyframe& keyframe,
}
scoped_ptr<cc::AnimationCurve>
-WebTransformAnimationCurveImpl::cloneToAnimationCurve() const {
+WebTransformAnimationCurveImpl::CloneToAnimationCurve() const {
return curve_->Clone();
}
-} // namespace WebKit
+} // namespace webkit
diff --git a/webkit/compositor_bindings/web_transform_animation_curve_impl.h b/webkit/compositor_bindings/web_transform_animation_curve_impl.h
index abf1f34..00c8136 100644
--- a/webkit/compositor_bindings/web_transform_animation_curve_impl.h
+++ b/webkit/compositor_bindings/web_transform_animation_curve_impl.h
@@ -2,8 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef WebTransformAnimationCurveImpl_h
-#define WebTransformAnimationCurveImpl_h
+#ifndef WEBKIT_COMPOSITOR_BINDINGS_WEB_TRANSFORM_ANIMATION_CURVE_IMPL_H_
+#define WEBKIT_COMPOSITOR_BINDINGS_WEB_TRANSFORM_ANIMATION_CURVE_IMPL_H_
#include "base/memory/scoped_ptr.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebTransformAnimationCurve.h"
@@ -14,33 +14,37 @@ class AnimationCurve;
class KeyframedTransformAnimationCurve;
}
-namespace WebKit {
+namespace WebKit { class WebTransformKeyframe; }
-class WebTransformKeyframe;
+namespace webkit {
-class WebTransformAnimationCurveImpl : public WebTransformAnimationCurve {
+class WebTransformAnimationCurveImpl
+ : public WebKit::WebTransformAnimationCurve {
public:
WEBKIT_COMPOSITOR_BINDINGS_EXPORT WebTransformAnimationCurveImpl();
virtual ~WebTransformAnimationCurveImpl();
- // WebAnimationCurve implementation.
+ // WebKit::WebAnimationCurve implementation.
virtual AnimationCurveType type() const;
- // WebTransformAnimationCurve implementation.
- virtual void add(const WebTransformKeyframe&);
- virtual void add(const WebTransformKeyframe&, TimingFunctionType);
- virtual void add(const WebTransformKeyframe&,
+ // WebKit::WebTransformAnimationCurve implementation.
+ virtual void add(const WebKit::WebTransformKeyframe& keyframe);
+ virtual void add(const WebKit::WebTransformKeyframe& keyframe,
+ TimingFunctionType type);
+ virtual void add(const WebKit::WebTransformKeyframe& keyframe,
double x1,
double y1,
double x2,
double y2);
- scoped_ptr<cc::AnimationCurve> cloneToAnimationCurve() const;
+ scoped_ptr<cc::AnimationCurve> CloneToAnimationCurve() const;
private:
scoped_ptr<cc::KeyframedTransformAnimationCurve> curve_;
+
+ DISALLOW_COPY_AND_ASSIGN(WebTransformAnimationCurveImpl);
};
-}
+} // namespace webkit
-#endif // WebTransformAnimationCurveImpl_h
+#endif // WEBKIT_COMPOSITOR_BINDINGS_WEB_TRANSFORM_ANIMATION_CURVE_IMPL_H_
diff --git a/webkit/compositor_bindings/web_transform_operations_impl.h b/webkit/compositor_bindings/web_transform_operations_impl.h
index 49a464e..b923a5f 100644
--- a/webkit/compositor_bindings/web_transform_operations_impl.h
+++ b/webkit/compositor_bindings/web_transform_operations_impl.h
@@ -31,9 +31,9 @@ class WebTransformOperationsImpl : public WebKit::WebTransformOperations {
virtual bool isIdentity() const;
private:
- DISALLOW_COPY_AND_ASSIGN(WebTransformOperationsImpl);
-
cc::TransformOperations transform_operations_;
+
+ DISALLOW_COPY_AND_ASSIGN(WebTransformOperationsImpl);
};
} // namespace webkit
diff --git a/webkit/compositor_bindings/web_video_layer_impl.cc b/webkit/compositor_bindings/web_video_layer_impl.cc
index 45d01e6..eadd452 100644
--- a/webkit/compositor_bindings/web_video_layer_impl.cc
+++ b/webkit/compositor_bindings/web_video_layer_impl.cc
@@ -10,20 +10,20 @@
#include "webkit/compositor_bindings/web_to_ccvideo_frame_provider.h"
#include "webkit/media/webvideoframe_impl.h"
-namespace WebKit {
+namespace webkit {
-WebVideoLayerImpl::WebVideoLayerImpl(WebVideoFrameProvider* web_provider)
- : provider_adapter_(
- webkit::WebToCCVideoFrameProvider::Create(web_provider)),
+WebVideoLayerImpl::WebVideoLayerImpl(
+ WebKit::WebVideoFrameProvider* web_provider)
+ : provider_adapter_(WebToCCVideoFrameProvider::Create(web_provider)),
layer_(
new WebLayerImpl(cc::VideoLayer::Create(provider_adapter_.get()))) {}
WebVideoLayerImpl::~WebVideoLayerImpl() {}
-WebLayer* WebVideoLayerImpl::layer() { return layer_.get(); }
+WebKit::WebLayer* WebVideoLayerImpl::layer() { return layer_.get(); }
bool WebVideoLayerImpl::active() const {
return layer_->layer()->layer_tree_host();
}
-} // namespace WebKit
+} // namespace webkit
diff --git a/webkit/compositor_bindings/web_video_layer_impl.h b/webkit/compositor_bindings/web_video_layer_impl.h
index 71c45e7..cb960a1 100644
--- a/webkit/compositor_bindings/web_video_layer_impl.h
+++ b/webkit/compositor_bindings/web_video_layer_impl.h
@@ -2,35 +2,37 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef WebVideoLayerImpl_h
-#define WebVideoLayerImpl_h
+#ifndef WEBKIT_COMPOSITOR_BINDINGS_WEB_VIDEO_LAYER_IMPL_H_
+#define WEBKIT_COMPOSITOR_BINDINGS_WEB_VIDEO_LAYER_IMPL_H_
#include "base/memory/scoped_ptr.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebVideoLayer.h"
#include "webkit/compositor_bindings/webkit_compositor_bindings_export.h"
-namespace webkit { class WebToCCVideoFrameProvider; }
+namespace WebKit { class WebVideoFrameProvider; }
-namespace WebKit {
+namespace webkit {
class WebLayerImpl;
-class WebVideoFrameProvider;
+class WebToCCVideoFrameProvider;
-class WebVideoLayerImpl : public WebVideoLayer {
+class WebVideoLayerImpl : public WebKit::WebVideoLayer {
public:
WEBKIT_COMPOSITOR_BINDINGS_EXPORT explicit WebVideoLayerImpl(
- WebVideoFrameProvider*);
+ WebKit::WebVideoFrameProvider*);
virtual ~WebVideoLayerImpl();
- // WebVideoLayer implementation.
- virtual WebLayer* layer();
+ // WebKit::WebVideoLayer implementation.
+ virtual WebKit::WebLayer* layer();
virtual bool active() const;
private:
- scoped_ptr<webkit::WebToCCVideoFrameProvider> provider_adapter_;
+ scoped_ptr<WebToCCVideoFrameProvider> provider_adapter_;
scoped_ptr<WebLayerImpl> layer_;
+
+ DISALLOW_COPY_AND_ASSIGN(WebVideoLayerImpl);
};
}
-#endif // WebVideoLayerImpl_h
+#endif // WEBKIT_COMPOSITOR_BINDINGS_WEB_VIDEO_LAYER_IMPL_H_
diff --git a/webkit/plugins/npapi/webplugin_impl.cc b/webkit/plugins/npapi/webplugin_impl.cc
index b3c277e..1b4615b 100644
--- a/webkit/plugins/npapi/webplugin_impl.cc
+++ b/webkit/plugins/npapi/webplugin_impl.cc
@@ -783,7 +783,7 @@ void WebPluginImpl::AcceleratedPluginSwappedIOSurface() {
if (next_io_surface_id_) {
if (!io_surface_layer_.get()) {
io_surface_layer_ = cc::IOSurfaceLayer::Create();
- web_layer_.reset(new WebKit::WebLayerImpl(io_surface_layer_));
+ web_layer_.reset(new webkit::WebLayerImpl(io_surface_layer_));
container_->setWebLayer(web_layer_.get());
}
io_surface_layer_->SetIOSurfaceProperties(
diff --git a/webkit/plugins/ppapi/ppapi_plugin_instance.cc b/webkit/plugins/ppapi/ppapi_plugin_instance.cc
index a333593..efc6d43 100644
--- a/webkit/plugins/ppapi/ppapi_plugin_instance.cc
+++ b/webkit/plugins/ppapi/ppapi_plugin_instance.cc
@@ -1717,7 +1717,7 @@ void PluginInstance::UpdateLayer() {
if (want_layer) {
DCHECK(bound_graphics_3d_.get());
texture_layer_ = cc::TextureLayer::Create(this);
- web_layer_.reset(new WebKit::WebLayerImpl(texture_layer_));
+ web_layer_.reset(new webkit::WebLayerImpl(texture_layer_));
if (fullscreen_container_)
fullscreen_container_->SetLayer(web_layer_.get());
else
diff --git a/webkit/support/test_webkit_platform_support.cc b/webkit/support/test_webkit_platform_support.cc
index 55d9ff7..b0e23d8 100644
--- a/webkit/support/test_webkit_platform_support.cc
+++ b/webkit/support/test_webkit_platform_support.cc
@@ -66,8 +66,8 @@
#include "base/mac/mac_util.h"
#endif
-using WebKit::WebLayerTreeViewImplForTesting;
using WebKit::WebScriptController;
+using webkit::WebLayerTreeViewImplForTesting;
TestWebKitPlatformSupport::TestWebKitPlatformSupport(bool unit_test_mode,
WebKit::Platform* shadow_platform_delegate)
diff --git a/webkit/support/webkit_support.cc b/webkit/support/webkit_support.cc
index 1dae721..087eb69 100644
--- a/webkit/support/webkit_support.cc
+++ b/webkit/support/webkit_support.cc
@@ -538,8 +538,8 @@ WebKit::WebLayerTreeView* CreateLayerTreeView(
static_cast<webkit_glue::WebThreadImpl*>(thread)->
message_loop()->message_loop_proxy());
- scoped_ptr<WebKit::WebLayerTreeViewImplForTesting> view(
- new WebKit::WebLayerTreeViewImplForTesting(type, client));
+ scoped_ptr<webkit::WebLayerTreeViewImplForTesting> view(
+ new webkit::WebLayerTreeViewImplForTesting(type, client));
if (!view->initialize(compositor_thread.Pass()))
return NULL;