git-svn-id: svn://db.shs.com.ru/libs@288 a8b55f48-bf90-11e4-a774-851b48703e85

This commit is contained in:
2017-10-03 13:47:43 +00:00
parent fc04d04e9b
commit 90d8a5f1a0
3 changed files with 137 additions and 8 deletions

View File

@@ -28,7 +28,7 @@ QDataStream & operator <<(QDataStream & s, const QGraphicsItem * item) {
} else if (ipath) {
s << int(4) << (ipath->pen()) << (ipath->path());
} else if (ipixmap) {
s << int(5) << (ipixmap->pixmap());
s << int(7) << (ipixmap->pixmap()) << (ipixmap->transform());
} else {
s << int(-1);
return s;
@@ -94,6 +94,11 @@ QDataStream & operator >>(QDataStream & s, QGraphicsItem *& item) {
npixmap = new QGraphicsPixmapItem(); item = npixmap;
{QPixmap _v; s >> _v; npixmap->setPixmap(_v);}
break;
case 7:
npixmap = new QGraphicsPixmapItem(); item = npixmap;
{QPixmap _v; s >> _v; npixmap->setPixmap(_v);}
{QTransform _t; s >> _t; npixmap->setTransform(_t);}
break;
}
if (item) {
{QPointF _v; s >> _v; item->setPos(_v);}