src/gui/image/qpixmap_x11.cpp
changeset 22 79de32ba3296
parent 18 2f34d5167611
child 30 5dc02b23752f
equal deleted inserted replaced
19:fcece45ef507 22:79de32ba3296
   381     bool hasAlpha() const {
   381     bool hasAlpha() const {
   382         if (checked)
   382         if (checked)
   383             return has;
   383             return has;
   384         // Will implicitly also check format and return quickly for opaque types...
   384         // Will implicitly also check format and return quickly for opaque types...
   385         checked = true;
   385         checked = true;
   386         has = const_cast<QImage *>(image)->data_ptr()->checkForAlphaPixels();
   386         has = image->isNull() ? false : const_cast<QImage *>(image)->data_ptr()->checkForAlphaPixels();
   387         return has;
   387         return has;
   388     }
   388     }
   389 
   389 
   390     bool hasXRenderAndAlpha() const {
   390     bool hasXRenderAndAlpha() const {
   391         if (!X11->use_xrender)
   391         if (!X11->use_xrender)