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

Unified Diff: ui/gfx/render_text_unittest.cc

Issue 1543183002: Switch to standard integer types in ui/gfx/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/gfx/render_text_mac.mm ('k') | ui/gfx/scoped_canvas.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/gfx/render_text_unittest.cc
diff --git a/ui/gfx/render_text_unittest.cc b/ui/gfx/render_text_unittest.cc
index 5750f19e7ad7b9943f55b4a5345a0d043c2ae4fd..b24c1be5ba8ec0984b1b35a22ec63725d8f7b64d 100644
--- a/ui/gfx/render_text_unittest.cc
+++ b/ui/gfx/render_text_unittest.cc
@@ -4,15 +4,20 @@
#include "ui/gfx/render_text.h"
+#include <stddef.h>
+#include <stdint.h>
+
#include <algorithm>
#include "base/format_macros.h"
#include "base/i18n/break_iterator.h"
+#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/strings/string_split.h"
#include "base/strings/string_util.h"
#include "base/strings/stringprintf.h"
#include "base/strings/utf_string_conversions.h"
+#include "build/build_config.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "third_party/skia/include/core/SkSurface.h"
#include "ui/gfx/break_list.h"
@@ -156,7 +161,7 @@ class TestSkiaTextRenderer : public internal::SkiaTextRenderer {
private:
// internal::SkiaTextRenderer:
void DrawPosText(const SkPoint* pos,
- const uint16* glyphs,
+ const uint16_t* glyphs,
size_t glyph_count) override {
TextLog log_entry;
log_entry.glyph_count = glyph_count;
@@ -2613,7 +2618,7 @@ TEST_F(RenderTextTest, HarfBuzz_HorizontalPositions) {
// Test TextRunHarfBuzz's cluster finding logic.
TEST_F(RenderTextTest, HarfBuzz_Clusters) {
struct {
- uint32 glyph_to_char[4];
+ uint32_t glyph_to_char[4];
Range chars[4];
Range glyphs[4];
bool is_rtl;
@@ -2701,7 +2706,7 @@ TEST_F(RenderTextTest, HarfBuzz_SubglyphGraphemeCases) {
// Test the partition of a multi-grapheme cluster into grapheme ranges.
TEST_F(RenderTextTest, HarfBuzz_SubglyphGraphemePartition) {
struct {
- uint32 glyph_to_char[2];
+ uint32_t glyph_to_char[2];
Range bounds[4];
bool is_rtl;
} cases[] = {
@@ -3035,8 +3040,8 @@ TEST_F(RenderTextTest, TextDoesntClip) {
render_text->Draw(&canvas);
ASSERT_LT(string_size.width() + kTestSize, kCanvasSize.width());
- const uint32* buffer =
- static_cast<const uint32*>(surface->peekPixels(nullptr, nullptr));
+ const uint32_t* buffer =
+ static_cast<const uint32_t*>(surface->peekPixels(nullptr, nullptr));
ASSERT_NE(nullptr, buffer);
TestRectangleBuffer rect_buffer(string, buffer, kCanvasSize.width(),
kCanvasSize.height());
@@ -3111,8 +3116,8 @@ TEST_F(RenderTextTest, TextDoesClip) {
render_text->set_clip_to_display_rect(true);
render_text->Draw(&canvas);
ASSERT_LT(string_size.width() + kTestSize, kCanvasSize.width());
- const uint32* buffer =
- static_cast<const uint32*>(surface->peekPixels(nullptr, nullptr));
+ const uint32_t* buffer =
+ static_cast<const uint32_t*>(surface->peekPixels(nullptr, nullptr));
ASSERT_NE(nullptr, buffer);
TestRectangleBuffer rect_buffer(string, buffer, kCanvasSize.width(),
kCanvasSize.height());
« no previous file with comments | « ui/gfx/render_text_mac.mm ('k') | ui/gfx/scoped_canvas.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698