Merge pull request #495 from shun-iwasawa/revert_planeviewer

(incompletely) Fix crash on using Shader Fx
This commit is contained in:
Shinya Kitaoka 2016-06-23 17:06:54 +09:00 committed by GitHub
commit 0d7879fb9b
2 changed files with 10 additions and 4 deletions

View file

@ -9,7 +9,7 @@
#include "timage.h"
// Qt includes
#include <QOpenGLWidget>
#include <QGLWidget>
#undef DVAPI
#undef DVVAR
@ -51,7 +51,13 @@ class TVectorImageP;
efficient image-drawing functions for all Toonz image types.
*/
class DVAPI PlaneViewer : public QOpenGLWidget {
/*
CAUTION : Changing PlaneViewer to inherit QOpenGLWidget causes crash bug with
shader fx for some unknown reasons. So I will reluctantly keep using the
obsolete class until the shader fx being overhauled. 2016/6/22 Shun
*/
class DVAPI PlaneViewer : public QGLWidget {
public:
PlaneViewer(QWidget *parent);

View file

@ -55,7 +55,7 @@ bool PlaneViewerZoomer::zoom(bool zoomin, bool resetZoom) {
//=========================================================================================
PlaneViewer::PlaneViewer(QWidget *parent)
: QOpenGLWidget(parent)
: QGLWidget(parent)
, m_firstResize(true)
, m_xpos(0)
, m_ypos(0)
@ -186,7 +186,7 @@ void PlaneViewer::wheelEvent(QWheelEvent *event) {
void PlaneViewer::keyPressEvent(QKeyEvent *event) {
if (PlaneViewerZoomer(this).exec(event)) return;
QOpenGLWidget::keyPressEvent(event);
QGLWidget::keyPressEvent(event);
}
//------------------------------------------------------