Remove QtWidgets dependencies
Remove references to libQtOpenGL, and use QGuiApplication instead of QApplication Change-Id: If8f652223492cf758175a260c27b687f3af1c4ad Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
This commit is contained in:
parent
6d67ff4061
commit
cad51669d8
@ -41,7 +41,6 @@
|
||||
|
||||
#include <QDebug>
|
||||
#include <QLibrary>
|
||||
#include <QGLFormat>
|
||||
|
||||
#include "qxlibwindow.h"
|
||||
#include "qxlibscreen.h"
|
||||
|
@ -62,7 +62,8 @@
|
||||
|
||||
#include <QtGui/QWindowSystemInterface>
|
||||
#include <QSocketNotifier>
|
||||
#include <QApplication>
|
||||
#include <QGuiApplication>
|
||||
#include <QStyleHints>
|
||||
#include <QDebug>
|
||||
|
||||
//#define MYX11_DEBUG
|
||||
@ -379,10 +380,11 @@ void QXlibWindow::mousePressEvent(XButtonEvent *e)
|
||||
|
||||
QEvent::Type type = QEvent::MouseButtonPress;
|
||||
|
||||
if (e->window == prevWindow && long(e->time) - prevTime < QApplication::doubleClickInterval()
|
||||
const int doubleClickInterval = qApp->styleHints()->mouseDoubleClickInterval();
|
||||
if (e->window == prevWindow && long(e->time) - prevTime < doubleClickInterval
|
||||
&& qAbs(e->x - prevX) < 5 && qAbs(e->y - prevY) < 5) {
|
||||
type = QEvent::MouseButtonDblClick;
|
||||
prevTime = e->time - QApplication::doubleClickInterval(); //no double click next time
|
||||
prevTime = e->time - doubleClickInterval; //no double click next time
|
||||
} else {
|
||||
prevTime = e->time;
|
||||
}
|
||||
@ -724,7 +726,7 @@ void QXlibWindow::doSizeHints()
|
||||
s.flags |= USSize;
|
||||
s.flags |= PSize;
|
||||
s.flags |= PWinGravity;
|
||||
s.win_gravity = QApplication::isRightToLeft() ? NorthEastGravity : NorthWestGravity;
|
||||
s.win_gravity = QGuiApplication::isRightToLeft() ? NorthEastGravity : NorthWestGravity;
|
||||
XSetWMNormalHints(mScreen->display()->nativeDisplay(), x_window, &s);
|
||||
}
|
||||
|
||||
|
@ -43,7 +43,6 @@ mac {
|
||||
CONFIG += qpa/genericunixfontdatabase
|
||||
|
||||
contains(QT_CONFIG, opengl) {
|
||||
QT += opengl
|
||||
!contains(QT_CONFIG, opengles2) {
|
||||
# load(qpa/glx/convenience)
|
||||
HEADERS += qglxintegration.h
|
||||
|
Loading…
Reference in New Issue
Block a user