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

Unified Diff: packages/charted/lib/core/utils/rect.dart

Issue 2213693002: Updated charted DEP to 0.4.X (Closed) Base URL: https://github.com/dart-lang/observatory_pub_packages.git@master
Patch Set: Created 4 years, 4 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 | « packages/charted/lib/core/utils/lists.dart ('k') | packages/charted/lib/layout/src/hierarchy_layout.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: packages/charted/lib/core/utils/rect.dart
diff --git a/packages/charted/lib/core/utils/rect.dart b/packages/charted/lib/core/utils/rect.dart
index 3e666ee0452849db2a7b3a80cabdcea555958265..beaa2cc46a4b7a6d8c1ad5fa78d3fc7cafa62394 100644
--- a/packages/charted/lib/core/utils/rect.dart
+++ b/packages/charted/lib/core/utils/rect.dart
@@ -10,18 +10,23 @@ part of charted.core.utils;
/// Interface representing size and position of an element
class Rect {
- final num x;
- final num y;
- final num width;
- final num height;
-
- const Rect([this.x = 0, this.y = 0, this.width = 0, this.height = 0]);
- const Rect.size(this.width, this.height)
- : x = 0,
- y = 0;
- const Rect.position(this.x, this.y)
- : width = 0,
- height = 0;
+ final num _x;
+ final num _y;
+ final num _width;
+ final num _height;
+
+ num get x => _x;
+ num get y => _y;
+ num get width => _width;
+ num get height => _height;
+
+ const Rect([this._x = 0, this._y = 0, this._width = 0, this._height = 0]);
+ const Rect.size(this._width, this._height)
+ : _x = 0,
+ _y = 0;
+ const Rect.position(this._x, this._y)
+ : _width = 0,
+ _height = 0;
bool isSameSizeAs(Rect other) =>
other != null && width == other.width && height == other.height;
« no previous file with comments | « packages/charted/lib/core/utils/lists.dart ('k') | packages/charted/lib/layout/src/hierarchy_layout.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698