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

Unified Diff: sky/sdk/lib/painting/box_painter.dart

Issue 1226113007: Add @override annotation to known overriden methods (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 5 years, 5 months 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 | « sky/sdk/lib/mojo/asset_bundle.dart ('k') | sky/sdk/lib/painting/text_style.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sky/sdk/lib/painting/box_painter.dart
diff --git a/sky/sdk/lib/painting/box_painter.dart b/sky/sdk/lib/painting/box_painter.dart
index e775a25ac050f1866406581e4331527fe8201140..ea4ff482e97bccda294994c8b0c245b206276d83 100644
--- a/sky/sdk/lib/painting/box_painter.dart
+++ b/sky/sdk/lib/painting/box_painter.dart
@@ -20,12 +20,15 @@ class BorderSide {
static const none = const BorderSide(width: 0.0);
+ @override
int get hashCode {
int value = 373;
value = 37 * value * color.hashCode;
value = 37 * value * width.hashCode;
return value;
}
+
+ @override
String toString() => 'BorderSide($color, $width)';
}
@@ -48,6 +51,7 @@ class Border {
final BorderSide bottom;
final BorderSide left;
+ @override
int get hashCode {
int value = 373;
value = 37 * value * top.hashCode;
@@ -56,6 +60,8 @@ class Border {
value = 37 * value * left.hashCode;
return value;
}
+
+ @override
String toString() => 'Border($top, $right, $bottom, $left)';
}
@@ -70,6 +76,7 @@ class BoxShadow {
final Offset offset;
final double blur;
+ @override
String toString() => 'BoxShadow($color, $offset, $blur)';
}
@@ -92,9 +99,11 @@ class LinearGradient extends Gradient {
this.tileMode: sky.TileMode.clamp
});
+ @override
String toString() =>
'LinearGradient($endPoints, $colors, $colorStops, $tileMode)';
+ @override
sky.Shader createShader() {
return new sky.Gradient.linear(this.endPoints, this.colors, this.colorStops,
this.tileMode);
@@ -115,9 +124,11 @@ class RadialGradient extends Gradient {
this.tileMode: sky.TileMode.clamp
});
+ @override
String toString() =>
'RadialGradient($center, $radius, $colors, $colorStops, $tileMode)';
+ @override
sky.Shader createShader() {
return new sky.Gradient.radial(this.center, this.radius, this.colors,
this.colorStops, this.tileMode);
@@ -173,6 +184,7 @@ class BackgroundImage {
_listeners.remove(listener);
}
+ @override
String toString() => 'BackgroundImage($fit, $repeat)';
}
@@ -198,6 +210,7 @@ class BoxDecoration {
final Gradient gradient;
final Shape shape;
+ @override
String toString([String prefix = '']) {
List<String> result = [];
if (backgroundColor != null)
« no previous file with comments | « sky/sdk/lib/mojo/asset_bundle.dart ('k') | sky/sdk/lib/painting/text_style.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698