From 35d3a4a351ad96ebf14407dbfb495259ddb2da2c Mon Sep 17 00:00:00 2001 From: Paul Davis Date: Wed, 8 Jan 2014 10:31:39 -0500 Subject: [PATCH] remove unused code --- libs/canvas/canvas/types.h | 4 +--- libs/canvas/types.cc | 33 --------------------------------- 2 files changed, 1 insertion(+), 36 deletions(-) diff --git a/libs/canvas/canvas/types.h b/libs/canvas/canvas/types.h index 77c148f3a0..1e8b7b145f 100644 --- a/libs/canvas/canvas/types.h +++ b/libs/canvas/canvas/types.h @@ -95,9 +95,7 @@ struct LIBCANVAS_API Rect Rect expand (Distance) const; bool contains (Duple) const; Rect fix () const; - - Rect convert_to_device (Cairo::RefPtr) const; - Rect convert_to_user (Cairo::RefPtr) const; + bool empty() const { return (x0 == x1 && y0 == y1); } Distance width () const { return x1 - x0; diff --git a/libs/canvas/types.cc b/libs/canvas/types.cc index a8c690bbbe..7d7a495df5 100644 --- a/libs/canvas/types.cc +++ b/libs/canvas/types.cc @@ -121,39 +121,6 @@ Rect::fix () const return r; } -Rect -Rect::convert_to_device (Cairo::RefPtr c) const -{ - Coord xa, ya, xb, yb; - - xa = x0; - xb = x1; - ya = y0; - yb = y1; - - c->user_to_device (xa, ya); - c->user_to_device (xb, yb); - - return Rect (xa, ya, xb, yb); -} - - -Rect -Rect::convert_to_user (Cairo::RefPtr c) const -{ - Coord xa, ya, xb, yb; - - xa = x0; - xb = x1; - ya = y0; - yb = y1; - - c->device_to_user (xa, ya); - c->device_to_user (xb, yb); - - return Rect (xa, ya, xb, yb); -} - Duple ArdourCanvas::operator- (Duple const & o) {