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.cpp

    r151983f rffd878f  
    208208{
    209209    Control *control;
     210    QPoint p(0,0);
    210211    // FAVOURITE ICONs
    211212    // on
    212213    control = new Control(FavouriteControlOn,QString(":icons/favourite-on.png"));
    213     control->setDrawPoint(QPoint(-control->image()->width()-SPACER,SPACER));
     214    p = QPoint(0,0);
     215    p.setX(p.x()-control->image()->width()-SPACER);
     216    control->setDrawPoint(p);
    214217    mControls.insert(FavouriteControlOn,control);
    215218    // off
    216219    control = new Control(FavouriteControlOff,QString(":icons/favourite-off.png"));
    217     control->setDrawPoint(QPoint(-control->image()->width()-SPACER,SPACER));
     220    p = QPoint(0,0);
     221    p.setX(p.x()-control->image()->width()-SPACER);
     222    control->setDrawPoint(p);
    218223    mControls.insert(FavouriteControlOff,control);
    219224
    220225    // ALARM ICONs
    221226    // on
    222     control = new Control(AlarmControlOn,QString(":icons/alarm-on.png"));
    223     control->setDrawPoint(QPoint(-mControls[FavouriteControlOn]->image()->width()-control->image()->width()-2*SPACER,SPACER));
     227    control = new Control(AlarmControlOn,QString(":icons/alarm-off.png"));
     228    p = mControls[FavouriteControlOn]->drawPoint();
     229    p.setX(p.x()-control->image()->width()-SPACER);
     230    control->setDrawPoint(p);
    224231    mControls.insert(AlarmControlOn,control);
    225232    // off
    226233    control = new Control(AlarmControlOff,QString(":icons/alarm-off.png"));
    227     control->setDrawPoint(QPoint(-mControls[FavouriteControlOff]->image()->width()-control->image()->width()-2*SPACER,SPACER));
     234    p = mControls[FavouriteControlOff]->drawPoint();
     235    p.setX(p.x()-control->image()->width()-SPACER);
     236    control->setDrawPoint(p);
    228237    mControls.insert(AlarmControlOff,control);
    229238
    230239    // MAP ICON
    231240    control = new Control(MapControl,QString(":icons/compass.png"));
    232     control->setDrawPoint(QPoint(-mControls[AlarmControlOn]->image()->width()-control->image()->width()
    233                                  -mControls[FavouriteControlOn]->image()->width()-3*SPACER,SPACER));
     241    p = mControls[AlarmControlOn]->drawPoint();
     242    p.setX(p.x()-control->image()->width()-SPACER);
     243    control->setDrawPoint(p);
    234244    mControls.insert(MapControl,control);
    235245}
Note: See TracChangeset for help on using the changeset viewer.