Changeset ffd878f for src/mvc/delegate.h


Ignore:
Timestamp:
01/18/10 14:49:08 (12 years ago)
Author:
pavelpa <pavelpa@…>
Branches:
master, qt5
Children:
5842349
Parents:
151983f
Message:

added GrayScale? versions (inactive/OFF) of the icons

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/mvc/delegate.h

    r151983f rffd878f  
    3232                inline QImage *image() const { return mImage; }
    3333                inline void setDrawPoint(const QPoint &aPoint) { mDrawPoint = aPoint; }
    34                 inline QPoint drawPoint(const QRect &aRect) const // for painter to draw Control
     34                inline QPoint drawPoint(const QRect &aRect = QRect()) const // for painter to draw Control
    3535                {
    36                     return QPoint(aRect.x()+aRect.width(),aRect.y()) + mDrawPoint;
     36                    if(aRect == QRect()) // null rectangle
     37                        return mDrawPoint; // returns relative drawing point
     38                    else
     39                        return QPoint(aRect.x()+aRect.width(),aRect.y()) + mDrawPoint; // returns absolute drawing point
    3740                }
    3841                inline QRect drawRect(const QRect &aRect) const // helper for determining if Control was clicked
Note: See TracChangeset for help on using the changeset viewer.