浏览代码

Merge pull request #2289 from laanwj/201301_qimage_bits

Use QImage.bits instead of QImage.constBits to ease backporting
tags/v0.15.1
Wladimir J. van der Laan 8 年前
父节点
当前提交
6749082294
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1
    1
      src/qt/notificator.cpp

+ 1
- 1
src/qt/notificator.cpp 查看文件

@@ -113,7 +113,7 @@ FreedesktopImage::FreedesktopImage(const QImage &img):
{
// Convert 00xAARRGGBB to RGBA bytewise (endian-independent) format
QImage tmp = img.convertToFormat(QImage::Format_ARGB32);
const uint32_t *data = reinterpret_cast<const uint32_t*>(tmp.constBits());
const uint32_t *data = reinterpret_cast<const uint32_t*>(tmp.bits());

unsigned int num_pixels = width * height;
image.resize(num_pixels * BYTES_PER_PIXEL);

正在加载...
取消
保存