chromium/third_party/blink/renderer/core/paint/paint_controller_paint_test.h

// Copyright 2015 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#ifndef THIRD_PARTY_BLINK_RENDERER_CORE_PAINT_PAINT_CONTROLLER_PAINT_TEST_H_
#define THIRD_PARTY_BLINK_RENDERER_CORE_PAINT_PAINT_CONTROLLER_PAINT_TEST_H_

#include "base/check_op.h"
#include "cc/paint/paint_op.h"
#include "cc/paint/paint_op_buffer_iterator.h"
#include "third_party/blink/renderer/core/dom/events/add_event_listener_options_resolved.h"
#include "third_party/blink/renderer/core/dom/events/native_event_listener.h"
#include "third_party/blink/renderer/core/editing/frame_selection.h"
#include "third_party/blink/renderer/core/frame/local_frame_view.h"
#include "third_party/blink/renderer/core/layout/layout_view.h"
#include "third_party/blink/renderer/core/paint/cull_rect_updater.h"
#include "third_party/blink/renderer/core/paint/paint_layer.h"
#include "third_party/blink/renderer/core/paint/paint_layer_scrollable_area.h"
#include "third_party/blink/renderer/core/testing/core_unit_test_helper.h"
#include "third_party/blink/renderer/platform/graphics/graphics_context.h"
#include "third_party/blink/renderer/platform/graphics/paint/cull_rect.h"
#include "third_party/blink/renderer/platform/graphics/paint/paint_chunk_subset.h"
#include "third_party/blink/renderer/platform/graphics/paint/paint_controller_test.h"
#include "third_party/blink/renderer/platform/testing/paint_test_configurations.h"

namespace blink {

class PaintControllerPaintTestBase : public RenderingTest {};

class PaintControllerPaintTest : public PaintTestConfigurations,
                                 public PaintControllerPaintTestBase {};

// Shorter names for frequently used display item types in core/ tests.
const DisplayItem::Type kBackgroundChunkType =;
const DisplayItem::Type kHitTestChunkType =;
const DisplayItem::Type kScrollingBackgroundChunkType =;
const DisplayItem::Type kClippedContentsBackgroundChunkType =;

#define VIEW_SCROLLING_BACKGROUND_DISPLAY_ITEM

// Checks for view scrolling background chunk in common case that there is only
// one display item in the chunk and no hit test rects.
#define VIEW_SCROLLING_BACKGROUND_CHUNK_COMMON

// This version also checks the following additional parameters:
//   wtf_size_t display_item_count,
//   const HitTestData* hit_test_data,
//   (optional) const gfx::Rect& bounds
#define VIEW_SCROLLING_BACKGROUND_CHUNK(display_item_count, ...)

}  // namespace blink

#endif  // THIRD_PARTY_BLINK_RENDERER_CORE_PAINT_PAINT_CONTROLLER_PAINT_TEST_H_