Commit 9b46c2d8 authored by Adam Barth's avatar Adam Barth

Update playfair after package:flutter rename

parent 30757563
...@@ -4,11 +4,10 @@ ...@@ -4,11 +4,10 @@
library playfair; library playfair;
import 'dart:sky' as sky; import 'dart:ui' as ui;
import 'dart:math' as math; import 'dart:math' as math;
import 'package:sky/material.dart'; import 'package:flutter/material.dart';
import 'package:sky/rendering.dart'; import 'package:flutter/rendering.dart';
import 'package:sky/widgets.dart';
part 'src/base.dart'; part 'src/base.dart';
...@@ -236,7 +236,7 @@ class ChartPainter { ...@@ -236,7 +236,7 @@ class ChartPainter {
return new Point(x, y); return new Point(x, y);
} }
void _paintGrid(sky.Canvas canvas) { void _paintGrid(ui.Canvas canvas) {
Paint paint = new Paint() Paint paint = new Paint()
..strokeWidth = kGridStrokeWidth ..strokeWidth = kGridStrokeWidth
..color = kGridColor; ..color = kGridColor;
...@@ -246,21 +246,21 @@ class ChartPainter { ...@@ -246,21 +246,21 @@ class ChartPainter {
} }
} }
void _paintChart(sky.Canvas canvas) { void _paintChart(ui.Canvas canvas) {
Paint paint = new Paint() Paint paint = new Paint()
..strokeWidth = kMarkerStrokeWidth ..strokeWidth = kMarkerStrokeWidth
..color = kMarkerColor; ..color = kMarkerColor;
Path path = new sky.Path(); Path path = new Path();
path.moveTo(_markers[0].x, _markers[0].y); path.moveTo(_markers[0].x, _markers[0].y);
for (Point marker in _markers) { for (Point marker in _markers) {
canvas.drawCircle(marker, kMarkerRadius, paint); canvas.drawCircle(marker, kMarkerRadius, paint);
path.lineTo(marker.x, marker.y); path.lineTo(marker.x, marker.y);
} }
paint.setStyle(sky.PaintingStyle.stroke); paint.setStyle(ui.PaintingStyle.stroke);
canvas.drawPath(path, paint); canvas.drawPath(path, paint);
} }
void _paintIndicator(sky.Canvas canvas) { void _paintIndicator(ui.Canvas canvas) {
if (_indicator == null) if (_indicator == null)
return; return;
Paint paint = new Paint() Paint paint = new Paint()
...@@ -271,7 +271,7 @@ class ChartPainter { ...@@ -271,7 +271,7 @@ class ChartPainter {
_indicator.labelPainter.paint(canvas, _indicator.labelPosition.toOffset()); _indicator.labelPainter.paint(canvas, _indicator.labelPosition.toOffset());
} }
void paint(sky.Canvas canvas, Rect rect) { void paint(ui.Canvas canvas, Rect rect) {
if (rect != _rect) if (rect != _rect)
_needsLayout = true; _needsLayout = true;
_rect = rect; _rect = rect;
......
name: playfair name: playfair
description: A simple charting library for Flutter description: A simple charting library for Flutter
version: 0.0.9 version: 0.0.10
author: Flutter Authors <flutter-dev@googlegroups.com> author: Flutter Authors <flutter-dev@googlegroups.com>
homepage: https://github.com/flutter/playfair homepage: https://github.com/flutter/playfair
dependencies: dependencies:
sky: any flutter: ">=0.0.3 <0.1.0"
sky_tools: any
dev_dependencies: dev_dependencies:
sky_tools: any
test: ^0.12.0 test: ^0.12.0
environment: environment:
sdk: '>=1.8.0 <2.0.0' sdk: '>=1.8.0 <2.0.0'
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