X-Git-Url: http://code.vuplus.com/gitweb/?p=vuplus_dvbapp;a=blobdiff_plain;f=lib%2Fgdi%2Ferect.h;h=35ebeda19901339252ba66d68fbb1b89999677e4;hp=65fd8d7112655a34ed21b12f4d53ccb87b20c156;hb=849b33656dc710cfa5f644a55680fd396ab1d8d7;hpb=ba02fb4aced5868d047a5bffbd2ed87583daee4d diff --git a/lib/gdi/erect.h b/lib/gdi/erect.h index 65fd8d7..35ebeda 100644 --- a/lib/gdi/erect.h +++ b/lib/gdi/erect.h @@ -119,6 +119,8 @@ public: static eRect emptyRect() { return eRect(0, 0, 0, 0); } static eRect invalidRect() { return eRect(); } + void scale(int x_n, int x_d, int y_n, int y_d); + private: int x1; int y1; @@ -143,7 +145,7 @@ inline eRect::eRect( int left, int top, int width, int height ) } inline bool eRect::empty() const -{ return x1 == x2 && y1 == y2; } +{ return x1 >= x2 || y1 >= y2; } inline bool eRect::valid() const { return x1 <= x2 && y1 <= y2; }