make errors more consistent; patch by zrusin

BUG:22428

svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=746766
This commit is contained in:
Aaron J. Seigo 2007-12-10 05:03:47 +00:00
parent 950cc1c149
commit a9b8490d33

View File

@ -71,6 +71,7 @@ GLApplet::GLApplet(QGraphicsItem *parent,
d(new Private) d(new Private)
{ {
if (!d->dummy->isValid() || if (!d->dummy->isValid() ||
!QGLPixelBuffer::hasOpenGLPbuffers() ||
!d->pbuf->isValid()) { !d->pbuf->isValid()) {
setFailedToLaunch(true, i18n("This system does not support OpenGL applets.")); setFailedToLaunch(true, i18n("This system does not support OpenGL applets."));
} }
@ -80,6 +81,11 @@ GLApplet::GLApplet(QObject *parent, const QVariantList &args)
: Applet(parent, args), : Applet(parent, args),
d(new Private) d(new Private)
{ {
if (!d->dummy->isValid() ||
!QGLPixelBuffer::hasOpenGLPbuffers() ||
!d->pbuf->isValid()) {
setFailedToLaunch(true, i18n("This system does not support OpenGL applets."));
}
} }
GLApplet::~GLApplet() GLApplet::~GLApplet()