summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorasvitkine@chromium.org <asvitkine@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-10-08 00:27:32 +0000
committerasvitkine@chromium.org <asvitkine@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-10-08 00:27:32 +0000
commit8f31e3b8877432a599c1f7f4e9345db0e2ef61db (patch)
treebc93b684af6dc9cf08e66bd5a8d72d37bfae94c9
parent3a41ebbf06dff52eb931d9441679948657007c83 (diff)
downloadchromium_src-8f31e3b8877432a599c1f7f4e9345db0e2ef61db.zip
chromium_src-8f31e3b8877432a599c1f7f4e9345db0e2ef61db.tar.gz
chromium_src-8f31e3b8877432a599c1f7f4e9345db0e2ef61db.tar.bz2
Remove Linux-specific canvas_skia.cc hack.
This was added because tooltip_controller.cc didn't SetMultiLine() on strings it was drawing. It now does, so this shouldn't be necessary. BUG=107357 TEST=No functional changes. Review URL: https://codereview.chromium.org/26291002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@227403 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--ui/gfx/canvas_skia.cc16
1 files changed, 0 insertions, 16 deletions
diff --git a/ui/gfx/canvas_skia.cc b/ui/gfx/canvas_skia.cc
index b6830d5..ad15edd 100644
--- a/ui/gfx/canvas_skia.cc
+++ b/ui/gfx/canvas_skia.cc
@@ -152,18 +152,6 @@ void UpdateRenderText(const Rect& rect,
render_text->SetStyle(UNDERLINE, (font_style & Font::UNDERLINE) != 0);
}
-// Returns updated |flags| to match platform-specific expected behavior.
-int AdjustPlatformSpecificFlags(const base::string16& text, int flags) {
-#if defined(OS_LINUX)
- // TODO(asvitkine): ash/tooltips/tooltip_controller.cc adds \n's to the string
- // without passing MULTI_LINE.
- if (text.find('\n') != base::string16::npos)
- flags |= Canvas::MULTI_LINE;
-#endif
-
- return flags;
-}
-
} // namespace
// static
@@ -175,8 +163,6 @@ void Canvas::SizeStringInt(const base::string16& text,
DCHECK_GE(*width, 0);
DCHECK_GE(*height, 0);
- flags = AdjustPlatformSpecificFlags(text, flags);
-
base::string16 adjusted_text = text;
#if defined(OS_WIN)
AdjustStringDirection(flags, &adjusted_text);
@@ -239,8 +225,6 @@ void Canvas::DrawStringRectWithShadows(const base::string16& text,
if (!IntersectsClipRect(text_bounds))
return;
- flags = AdjustPlatformSpecificFlags(text, flags);
-
Rect clip_rect(text_bounds);
clip_rect.Inset(ShadowValue::GetMargin(shadows));