fixed dbus icon color
This commit is contained in:
parent
2263cf252c
commit
b750faf85e
|
@ -69,9 +69,7 @@ QString FreedesktopNotification_Frontend::getImagefromHint(const FreedesktopImag
|
|||
QFile file(filename);
|
||||
if(file.exists())return filename;
|
||||
|
||||
QImage *qimage = img.toQImage();
|
||||
qimage->save(filename,"PNG");
|
||||
delete qimage;
|
||||
img.toQImage().save(filename,"PNG");
|
||||
qDebug()<<"Saving to "<<filename;
|
||||
return filename;
|
||||
}
|
||||
|
|
|
@ -88,10 +88,8 @@ FreedesktopImageHint::FreedesktopImageHint(const QImage &img) {
|
|||
}
|
||||
|
||||
|
||||
QImage *FreedesktopImageHint::toQImage() const {
|
||||
QImage *img = new QImage((uchar*)imageData.data(),width,height,QImage::Format_ARGB32 );
|
||||
img->rgbSwapped();
|
||||
return img;
|
||||
QImage FreedesktopImageHint::toQImage() const {
|
||||
return QImage((uchar*)imageData.data(),width,height,QImage::Format_ARGB32 ).rgbSwapped();
|
||||
}
|
||||
|
||||
QDBusArgument &operator<<(QDBusArgument &a, const FreedesktopImageHint &i) {
|
||||
|
|
|
@ -47,7 +47,7 @@ public:
|
|||
FreedesktopImageHint();
|
||||
FreedesktopImageHint(const QImage &img);
|
||||
|
||||
QImage* toQImage()const;
|
||||
QImage toQImage()const;
|
||||
|
||||
int width;
|
||||
int height;
|
||||
|
|
Loading…
Reference in New Issue