mirror of
https://github.com/archlinuxarm/PKGBUILDs.git
synced 2024-11-08 22:45:43 +00:00
extra/qt5-base to 5.6.0-4
This commit is contained in:
parent
173fc9bb1b
commit
fa5a188e27
2 changed files with 89 additions and 3 deletions
|
@ -10,7 +10,7 @@
|
|||
pkgname=qt5-base
|
||||
_qtver=5.6.0
|
||||
pkgver=${_qtver/-/}
|
||||
pkgrel=3
|
||||
pkgrel=4
|
||||
arch=('i686' 'x86_64')
|
||||
url='http://qt-project.org/'
|
||||
license=('GPL3' 'LGPL' 'FDL' 'custom')
|
||||
|
@ -25,18 +25,20 @@ optdepends=('qt5-svg: to use SVG icon themes'
|
|||
'libmariadbclient: MariaDB driver'
|
||||
'unixodbc: ODBC driver'
|
||||
'libfbclient: Firebird/iBase driver'
|
||||
'freetds: MS SQL driver'
|
||||
'mtdev: evdev plugin'
|
||||
'gtk2: GTK2 plugin')
|
||||
conflicts=('qt')
|
||||
groups=('qt' 'qt5')
|
||||
_pkgfqn="${pkgname/5-/}-opensource-src-${_qtver}"
|
||||
source=("http://download.qt.io/official_releases/qt/${pkgver%.*}/${_qtver}/submodules/${_pkgfqn}.tar.xz" qt5-alsa1.11.patch
|
||||
qtbug-51648.patch qtbug-51649.patch qtbug-51676.patch)
|
||||
qtbug-51648.patch qtbug-51649.patch qtbug-51676.patch qtbug-45812.patch)
|
||||
md5sums=('d6b6cfd333c22829c6c85fc52ceed019'
|
||||
'5e96b5cfa248b8b071919adb27abc715'
|
||||
'b09aa4f5763f013b06153fbdbc844404'
|
||||
'ef981ff6892337cdab424ebb113b3c39'
|
||||
'f59a1ea0f10a055ba930a53832933482')
|
||||
'f59a1ea0f10a055ba930a53832933482'
|
||||
'6f03c2ae236cd9698f9291bd8adcbea9')
|
||||
|
||||
prepare() {
|
||||
cd ${_pkgfqn}
|
||||
|
@ -62,6 +64,9 @@ prepare() {
|
|||
patch -p1 -i ../qtbug-51648.patch
|
||||
patch -p1 -i ../qtbug-51649.patch
|
||||
patch -p1 -i ../qtbug-51676.patch
|
||||
|
||||
# Fix drag and drop from some applications
|
||||
patch -p1 -i ../qtbug-45812.patch
|
||||
}
|
||||
|
||||
build() {
|
||||
|
|
81
extra/qt5-base/qtbug-45812.patch
Normal file
81
extra/qt5-base/qtbug-45812.patch
Normal file
|
@ -0,0 +1,81 @@
|
|||
From 9f5c5d799ed45faff6cb31333b531444d68c2c9a Mon Sep 17 00:00:00 2001
|
||||
From: Urs Fleisch <ufleisch@users.sourceforge.net>
|
||||
Date: Fri, 26 Feb 2016 17:46:09 +0100
|
||||
Subject: [PATCH] xcb: Fix drag and drop to applications like Emacs and
|
||||
Chromium.
|
||||
|
||||
Drops without matching time stamp do not work. I have fixed the issue by
|
||||
reanimating the findXdndAwareParent() function (adapted to XCB) and
|
||||
using it to find a matching transaction if all else fails.
|
||||
|
||||
Task-number: QTBUG-45812
|
||||
Change-Id: Ibca15bbab02ccf2f25280418e9edf36972ebf9a0
|
||||
---
|
||||
src/plugins/platforms/xcb/qxcbdrag.cpp | 44 ++++++++++++++++++++++++++++++++++
|
||||
1 file changed, 44 insertions(+)
|
||||
|
||||
diff --git a/src/plugins/platforms/xcb/qxcbdrag.cpp b/src/plugins/platforms/xcb/qxcbdrag.cpp
|
||||
index 1d13adf..b22f4af 100644
|
||||
--- a/src/plugins/platforms/xcb/qxcbdrag.cpp
|
||||
+++ b/src/plugins/platforms/xcb/qxcbdrag.cpp
|
||||
@@ -1074,6 +1074,40 @@ void QXcbDrag::cancel()
|
||||
send_leave();
|
||||
}
|
||||
|
||||
+// find an ancestor with XdndAware on it
|
||||
+static xcb_window_t findXdndAwareParent(QXcbConnection *c, xcb_window_t window)
|
||||
+{
|
||||
+ xcb_window_t target = 0;
|
||||
+ forever {
|
||||
+ // check if window has XdndAware
|
||||
+ xcb_get_property_cookie_t gpCookie = Q_XCB_CALL(
|
||||
+ xcb_get_property(c->xcb_connection(), false, window,
|
||||
+ c->atom(QXcbAtom::XdndAware), XCB_GET_PROPERTY_TYPE_ANY, 0, 0));
|
||||
+ xcb_get_property_reply_t *gpReply = xcb_get_property_reply(
|
||||
+ c->xcb_connection(), gpCookie, 0);
|
||||
+ bool aware = gpReply && gpReply->type != XCB_NONE;
|
||||
+ free(gpReply);
|
||||
+ if (aware) {
|
||||
+ target = window;
|
||||
+ break;
|
||||
+ }
|
||||
+
|
||||
+ // try window's parent
|
||||
+ xcb_query_tree_cookie_t qtCookie = xcb_query_tree_unchecked(
|
||||
+ c->xcb_connection(), window);
|
||||
+ xcb_query_tree_reply_t *qtReply = xcb_query_tree_reply(
|
||||
+ c->xcb_connection(), qtCookie, NULL);
|
||||
+ if (!qtReply)
|
||||
+ break;
|
||||
+ xcb_window_t root = qtReply->root;
|
||||
+ xcb_window_t parent = qtReply->parent;
|
||||
+ free(qtReply);
|
||||
+ if (window == root)
|
||||
+ break;
|
||||
+ window = parent;
|
||||
+ }
|
||||
+ return target;
|
||||
+}
|
||||
|
||||
void QXcbDrag::handleSelectionRequest(const xcb_selection_request_event_t *event)
|
||||
{
|
||||
@@ -1101,6 +1135,16 @@ void QXcbDrag::handleSelectionRequest(const xcb_selection_request_event_t *event
|
||||
// xcb_convert_selection() that we sent the XdndDrop event to.
|
||||
at = findTransactionByWindow(event->requestor);
|
||||
}
|
||||
+
|
||||
+ if (at == -1 && event->time == XCB_CURRENT_TIME) {
|
||||
+ xcb_window_t target = findXdndAwareParent(connection(), event->requestor);
|
||||
+ if (target) {
|
||||
+ if (current_target && current_target == target)
|
||||
+ at = -2;
|
||||
+ else
|
||||
+ at = findTransactionByWindow(target);
|
||||
+ }
|
||||
+ }
|
||||
// if (at == -1 && event->time == XCB_CURRENT_TIME) {
|
||||
// // previous Qt versions always requested the data on a child of the target window
|
||||
// // using CurrentTime... but it could be asking for either drop data or the current drag's data
|
||||
--
|
||||
2.7.4
|
||||
|
Loading…
Reference in a new issue