Merge pull request #3178 from SimonSapin/canvas-crate

Add a canvas create, break script’s dependency on gfx.
This commit is contained in:
Simon Sapin 2014-08-29 09:14:07 +01:00
commit 1f2c5c0bcb
7 changed files with 29 additions and 14 deletions

View file

@ -0,0 +1,11 @@
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#![crate_name = "canvas"]
#![crate_type = "rlib"]
extern crate azure;
extern crate geom;
pub mod canvas_render_task;

View file

@ -55,10 +55,6 @@ pub mod color;
pub mod display_list;
pub mod render_task;
// Canvas Rendering
#[allow(dead_code)]
pub mod canvas_render_task;
// Fonts
pub mod font;
pub mod font_context;

View file

@ -14,7 +14,7 @@ use geom::point::Point2D;
use geom::rect::Rect;
use geom::size::Size2D;
use gfx::canvas_render_task::{CanvasMsg, CanvasRenderTask, ClearRect, Close, FillRect, Recreate, StrokeRect};
use canvas::canvas_render_task::{CanvasMsg, CanvasRenderTask, ClearRect, Close, FillRect, Recreate, StrokeRect};
#[deriving(Encodable)]
pub struct CanvasRenderingContext2D {

View file

@ -33,6 +33,7 @@ extern crate net;
extern crate rustrt;
extern crate serialize;
extern crate time;
extern crate canvas;
extern crate script_traits;
#[phase(plugin)]
extern crate servo_macros = "macros";
@ -42,7 +43,6 @@ extern crate style;
extern crate sync;
extern crate servo_msg = "msg";
extern crate url;
extern crate gfx;
pub mod cors;