diff options
author | lbartoletti <l.bartoletti@free.fr> | 2019-10-22 18:46:26 +0200 |
---|---|---|
committer | lbartoletti <l.bartoletti@free.fr> | 2019-10-22 18:46:26 +0200 |
commit | 5ca20dd233e60b38635d7b4edf3a2b6a60974e7d (patch) | |
tree | 3f5a89289b62632f10c34c08449349ba07207c5d | |
parent | screenCount -> QGuiApplication::screens() (diff) | |
download | lumina-5ca20dd233e60b38635d7b4edf3a2b6a60974e7d.tar.gz lumina-5ca20dd233e60b38635d7b4edf3a2b6a60974e7d.tar.bz2 lumina-5ca20dd233e60b38635d7b4edf3a2b6a60974e7d.zip |
fix warning: 'byteCount' is deprecated: Use sizeInBytes
-rw-r--r-- | src-qt5/core/libLumina/LuminaX11.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src-qt5/core/libLumina/LuminaX11.cpp b/src-qt5/core/libLumina/LuminaX11.cpp index ee4ed5b7..1df5a9f0 100644 --- a/src-qt5/core/libLumina/LuminaX11.cpp +++ b/src-qt5/core/libLumina/LuminaX11.cpp @@ -498,7 +498,7 @@ QIcon LXCB::WindowIcon(WId win){ QImage image(iter.width, iter.height, QImage::Format_ARGB32); //initial setup uint* dat = iter.data; //dat+=2; //remember the first 2 element offset - for(int i=0; i<image.byteCount()/4; ++i, ++dat){ + for(qsizetype i=0; i<image.sizeInBytes()/4; ++i, ++dat){ ((uint*)image.bits())[i] = *dat; } icon.addPixmap(QPixmap::fromImage(image)); //layer this pixmap onto the icon @@ -547,7 +547,7 @@ void LXCB::paintRoot(QRect area, const QPixmap *pix){ QImage qimage = pix->toImage().convertToFormat(QImage::Format_ARGB32); xcb_image_t *image = xcb_image_create(pix->width(), pix->height(), XCB_IMAGE_FORMAT_XY_PIXMAP, 32, qimage.depth(), 32, 32, XCB_IMAGE_ORDER_LSB_FIRST, XCB_IMAGE_ORDER_LSB_FIRST, - 0, qimage.byteCount(), qimage.bits()); + 0, qimage.sizeInBytes(), qimage.bits()); //Now paint on the root window |