summaryrefslogtreecommitdiffstats
path: root/components/html_viewer/web_layer_impl.h
blob: cc8ded5c9ee09c6a59457627bdafe4a0e965588c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
// Copyright 2015 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 COMPONENTS_HTML_VIEWER_WEB_LAYER_IMPL_H_
#define COMPONENTS_HTML_VIEWER_WEB_LAYER_IMPL_H_

#include <utility>

#include "cc/blink/web_layer_impl.h"

namespace mojo {
class View;
}

namespace html_viewer {

class WebLayerImpl : public cc_blink::WebLayerImpl {
 public:
  WebLayerImpl(mojo::View* view, float device_pixel_ratio);
  ~WebLayerImpl() override;

  // WebLayer implementation.
  void setBounds(const blink::WebSize& bounds) override;
  void setPosition(const blink::WebFloatPoint& position) override;

 private:
  mojo::View* view_;
  const float device_pixel_ratio_;

  DISALLOW_COPY_AND_ASSIGN(WebLayerImpl);
};

}  // namespace html_viewer

#endif  // COMPONENTS_HTML_VIEWER_WEB_LAYER_IMPL_H_