[arch-commits] Commit in deepin-menu/trunk (PKGBUILD fix-mouse-event-issue.patch)

2015-10-23 Thread Felix Yan
Date: Friday, October 23, 2015 @ 10:35:06
  Author: fyan
Revision: 144775

upgpkg: deepin-menu 2.90.1-1

Modified:
  deepin-menu/trunk/PKGBUILD
Deleted:
  deepin-menu/trunk/fix-mouse-event-issue.patch

-+
 PKGBUILD|   11 --
 fix-mouse-event-issue.patch |  205 --
 2 files changed, 4 insertions(+), 212 deletions(-)

Modified: PKGBUILD
===
--- PKGBUILD2015-10-23 08:34:51 UTC (rev 144774)
+++ PKGBUILD2015-10-23 08:35:06 UTC (rev 144775)
@@ -4,8 +4,8 @@
 # Contributor: Xu Fasheng 
 
 pkgname=deepin-menu
-pkgver=2.3.0
-pkgrel=2
+pkgver=2.90.1
+pkgrel=1
 pkgdesc="Deepin menu service for building beautiful menus"
 arch=('i686' 'x86_64')
 url="https://gitcafe.com/Deepin/deepin-menu;
@@ -13,15 +13,12 @@
 depends=('python2-pyqt5' 'qt5-x11extras')
 makedepends=('python2-setuptools' 'qt5-declarative' 'git')
 groups=('deepin')
-source=("git+https://github.com/linuxdeepin/deepin-menu.git#tag=$pkgver;
-"fix-mouse-event-issue.patch")
-sha256sums=('SKIP' 'SKIP')
+source=("git+https://github.com/linuxdeepin/deepin-menu.git#tag=$pkgver;)
+sha256sums=('SKIP')
 
 prepare() {
   cd deepin-menu
 
-  patch -p1 -i ../fix-mouse-event-issue.patch
-
   # fix python version
   find -iname "*.py" | xargs sed -i 's=\(^#! */usr/bin.*\)python *$=\1python2='
 }

Deleted: fix-mouse-event-issue.patch
===
--- fix-mouse-event-issue.patch 2015-10-23 08:34:51 UTC (rev 144774)
+++ fix-mouse-event-issue.patch 2015-10-23 08:35:06 UTC (rev 144775)
@@ -1,205 +0,0 @@
-commit f15fc5c0c8f1d74d66b4a5067567e21d56c9786f
-Author: Xu Fasheng 
-Date:   2015-09-28 14:01:22 +0800
-
-fix issue that could not receive XCB_BUTTON* message
-
-If Qt configured with "-xinput2", the original code will not catch the
-core X11 events like XCB_BUTTON*, instead, we should dispatch mouse and
-button events from xinput2 specially.
-
-https://bugreports.qt.io/browse/QTBUG-48472
-
-Change-Id: I4011c47d904a08d7c92d3c0cc9fb6436e86b064c
-
-diff --git a/deepin-menu.pro b/deepin-menu.pro
-index 6b21a54..9257ff2 100644
 a/deepin-menu.pro
-+++ b/deepin-menu.pro
-@@ -37,7 +37,7 @@ HEADERS  += \
- ddockmenu.h \
- dmenuapplication.h
- 
--LIBS += -lxcb
-+LIBS += -lxcb -lX11
- 
- RESOURCES += \
- images.qrc
-diff --git a/dmenubase.cpp b/dmenubase.cpp
-index ce9a1c0..9469dd5 100644
 a/dmenubase.cpp
-+++ b/dmenubase.cpp
-@@ -12,9 +12,10 @@
- #include 
- #include 
- #include 
-+#include 
- 
--#include 
- #include 
-+#include 
- 
- #include "dmenubase.h"
- #include "dmenucontent.h"
-@@ -30,6 +31,8 @@ DMenuBase::DMenuBase(QWidget *parent) :
- {
- this->setAttribute(Qt::WA_TranslucentBackground);
- 
-+queryXIExtension();
-+
- _dropShadow = new QGraphicsDropShadowEffect(this);
- _dropShadow->setBlurRadius(0);
- _dropShadow->setColor(Qt::black);
-@@ -334,7 +337,7 @@ bool DMenuBase::nativeEvent(const QByteArray , 
void *message, long *)
- switch (responseType) {
- case XCB_BUTTON_PRESS: {
- xcb_button_press_event_t *ev = 
reinterpret_cast(event);
--qDebug() << "nativeEvent" <<  responseType <<
-+qDebug() << "nativeEvent XCB_BUTTON_PRESS" <<  responseType <<
- ev->detail << ev->child << ev->root_x << ev->root_y;
- if (!this->menuUnderPoint(QPoint(ev->root_x, ev->root_y))) {
- this->destroyAll();
-@@ -343,7 +346,7 @@ bool DMenuBase::nativeEvent(const QByteArray , 
void *message, long *)
- }
- case XCB_BUTTON_RELEASE: {
- xcb_button_release_event_t *ev = 
reinterpret_cast(event);
--qDebug() << "nativeEvent" <<  responseType <<
-+qDebug() << "nativeEvent XCB_BUTTON_RELEASE" <<  responseType <<
- ev->detail << ev->child << ev->root_x << ev->root_y;
- 
- if (this->menuUnderPoint(QPoint(ev->root_x, ev->root_y)) && 
_menuContent){
-@@ -353,7 +356,7 @@ bool DMenuBase::nativeEvent(const QByteArray , 
void *message, long *)
- }
- case XCB_MOTION_NOTIFY: {
- xcb_motion_notify_event_t *ev = 
reinterpret_cast(event);
--qDebug() << "nativeEvent" <<  responseType <<
-+qDebug() << "nativeEvent XCB_MOTION_NOTIFY" <<  responseType <<
- ev->detail << ev->child << ev->root_x << ev->root_y;
- DMenuBase *menuUnderPoint = 
this->menuUnderPoint(QPoint(ev->root_x, ev->root_y));
- if (menuUnderPoint &&
-@@ -363,11 +366,66 @@ bool DMenuBase::nativeEvent(const QByteArray , 
void *message, long *)
- }
- break;
- }
-+default:
-+if (isXIType(event, 

[arch-commits] Commit in deepin-menu/trunk (PKGBUILD fix-mouse-event-issue.patch)

2015-09-28 Thread Felix Yan
Date: Tuesday, September 29, 2015 @ 05:06:05
  Author: fyan
Revision: 142175

upgpkg: deepin-menu 2.3.0-2

Add a patch to fix mouse event missing issue. 
(https://github.com/felixonmars/archlinux-community/pull/1)

Added:
  deepin-menu/trunk/fix-mouse-event-issue.patch
Modified:
  deepin-menu/trunk/PKGBUILD

-+
 PKGBUILD|9 +
 fix-mouse-event-issue.patch |  205 ++
 2 files changed, 211 insertions(+), 3 deletions(-)

Modified: PKGBUILD
===
--- PKGBUILD2015-09-29 03:05:19 UTC (rev 142174)
+++ PKGBUILD2015-09-29 03:06:05 UTC (rev 142175)
@@ -5,7 +5,7 @@
 
 pkgname=deepin-menu
 pkgver=2.3.0
-pkgrel=1
+pkgrel=2
 pkgdesc="Deepin menu service for building beautiful menus"
 arch=('i686' 'x86_64')
 url="https://gitcafe.com/Deepin/deepin-menu;
@@ -13,12 +13,15 @@
 depends=('python2-pyqt5' 'qt5-x11extras')
 makedepends=('python2-setuptools' 'qt5-declarative' 'git')
 groups=('deepin')
-source=("git+https://github.com/linuxdeepin/deepin-menu.git#tag=$pkgver;)
-sha256sums=('SKIP')
+source=("git+https://github.com/linuxdeepin/deepin-menu.git#tag=$pkgver;
+"fix-mouse-event-issue.patch")
+sha256sums=('SKIP' 'SKIP')
 
 prepare() {
   cd deepin-menu
 
+  patch -p1 -i ../fix-mouse-event-issue.patch
+
   # fix python version
   find -iname "*.py" | xargs sed -i 's=\(^#! */usr/bin.*\)python *$=\1python2='
 }

Added: fix-mouse-event-issue.patch
===
--- fix-mouse-event-issue.patch (rev 0)
+++ fix-mouse-event-issue.patch 2015-09-29 03:06:05 UTC (rev 142175)
@@ -0,0 +1,205 @@
+commit f15fc5c0c8f1d74d66b4a5067567e21d56c9786f
+Author: Xu Fasheng 
+Date:   2015-09-28 14:01:22 +0800
+
+fix issue that could not receive XCB_BUTTON* message
+
+If Qt configured with "-xinput2", the original code will not catch the
+core X11 events like XCB_BUTTON*, instead, we should dispatch mouse and
+button events from xinput2 specially.
+
+https://bugreports.qt.io/browse/QTBUG-48472
+
+Change-Id: I4011c47d904a08d7c92d3c0cc9fb6436e86b064c
+
+diff --git a/deepin-menu.pro b/deepin-menu.pro
+index 6b21a54..9257ff2 100644
+--- a/deepin-menu.pro
 b/deepin-menu.pro
+@@ -37,7 +37,7 @@ HEADERS  += \
+ ddockmenu.h \
+ dmenuapplication.h
+ 
+-LIBS += -lxcb
++LIBS += -lxcb -lX11
+ 
+ RESOURCES += \
+ images.qrc
+diff --git a/dmenubase.cpp b/dmenubase.cpp
+index ce9a1c0..9469dd5 100644
+--- a/dmenubase.cpp
 b/dmenubase.cpp
+@@ -12,9 +12,10 @@
+ #include 
+ #include 
+ #include 
++#include 
+ 
+-#include 
+ #include 
++#include 
+ 
+ #include "dmenubase.h"
+ #include "dmenucontent.h"
+@@ -30,6 +31,8 @@ DMenuBase::DMenuBase(QWidget *parent) :
+ {
+ this->setAttribute(Qt::WA_TranslucentBackground);
+ 
++queryXIExtension();
++
+ _dropShadow = new QGraphicsDropShadowEffect(this);
+ _dropShadow->setBlurRadius(0);
+ _dropShadow->setColor(Qt::black);
+@@ -334,7 +337,7 @@ bool DMenuBase::nativeEvent(const QByteArray , 
void *message, long *)
+ switch (responseType) {
+ case XCB_BUTTON_PRESS: {
+ xcb_button_press_event_t *ev = 
reinterpret_cast(event);
+-qDebug() << "nativeEvent" <<  responseType <<
++qDebug() << "nativeEvent XCB_BUTTON_PRESS" <<  responseType <<
+ ev->detail << ev->child << ev->root_x << ev->root_y;
+ if (!this->menuUnderPoint(QPoint(ev->root_x, ev->root_y))) {
+ this->destroyAll();
+@@ -343,7 +346,7 @@ bool DMenuBase::nativeEvent(const QByteArray , 
void *message, long *)
+ }
+ case XCB_BUTTON_RELEASE: {
+ xcb_button_release_event_t *ev = 
reinterpret_cast(event);
+-qDebug() << "nativeEvent" <<  responseType <<
++qDebug() << "nativeEvent XCB_BUTTON_RELEASE" <<  responseType <<
+ ev->detail << ev->child << ev->root_x << ev->root_y;
+ 
+ if (this->menuUnderPoint(QPoint(ev->root_x, ev->root_y)) && 
_menuContent){
+@@ -353,7 +356,7 @@ bool DMenuBase::nativeEvent(const QByteArray , 
void *message, long *)
+ }
+ case XCB_MOTION_NOTIFY: {
+ xcb_motion_notify_event_t *ev = 
reinterpret_cast(event);
+-qDebug() << "nativeEvent" <<  responseType <<
++qDebug() << "nativeEvent XCB_MOTION_NOTIFY" <<  responseType <<
+ ev->detail << ev->child << ev->root_x << ev->root_y;
+ DMenuBase *menuUnderPoint = 
this->menuUnderPoint(QPoint(ev->root_x, ev->root_y));
+ if (menuUnderPoint &&
+@@ -363,11 +366,66 @@ bool DMenuBase::nativeEvent(const QByteArray , 
void *message, long *)
+ }
+ break;
+ }
++default:
++