Unverified Commit 9e7cc970 authored by Tomasz Gucio's avatar Tomasz Gucio Committed by GitHub

Use int for PlaceholderSpan.placeholderCodeUnit (#98971)

parent c178cf85
......@@ -42,7 +42,7 @@ abstract class PlaceholderSpan extends InlineSpan {
}) : super(style: style);
/// The unicode character to represent a placeholder.
static const String placeholderCodeUnit = '\uFFFC';
static const int placeholderCodeUnit = 0xFFFC;
/// How the placeholder aligns vertically with the text.
///
......@@ -60,7 +60,7 @@ abstract class PlaceholderSpan extends InlineSpan {
@override
void computeToPlainText(StringBuffer buffer, {bool includeSemanticsLabels = true, bool includePlaceholders = true}) {
if (includePlaceholders) {
buffer.write(placeholderCodeUnit);
buffer.writeCharCode(placeholderCodeUnit);
}
}
......
......@@ -140,7 +140,7 @@ class WidgetSpan extends PlaceholderSpan {
@override
int? codeUnitAtVisitor(int index, Accumulator offset) {
offset.increment(1);
return PlaceholderSpan.placeholderCodeUnit.codeUnitAt(0);
return PlaceholderSpan.placeholderCodeUnit;
}
@override
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment