From 94eecc00eef26e72537e640f305fbdf2f135ccc4 Mon Sep 17 00:00:00 2001 From: Timothy Redaelli Date: Mon, 16 Jan 2012 08:00:26 +0000 Subject: [PATCH] updated on Mon Jan 16 08:00:26 UTC 2012 --- bamtools/PKGBUILD | 36 + dnsval/PKGBUILD | 59 ++ doomseeker/PKGBUILD | 13 +- doomseeker/skulltag.patch | 19 - linux-lqx/PKGBUILD | 4 +- lv2-ll-plugins/PKGBUILD | 33 + namebench/PKGBUILD | 6 +- nvidia-lqx/PKGBUILD | 10 +- nvidia-lqx/nvidia-lqx.install | 4 +- rainlendar-beta-unstable/PKGBUILD | 6 +- tardy/PKGBUILD | 6 +- unitary-gnome/PKGBUILD | 8 +- unitary-gnome/unitary-gnome.install | 2 +- unity/PKGBUILD | 64 +- unity/debian-changes-4.24.0-0ubuntu2 | 362 --------- unity/default-settings.patch | 2 +- unity/disable-multitouch.patch | 1376 ++++------------------------------ unity/make-tests-optional.patch | 38 +- unity/unity.install | 16 +- unity/unity.sh | 8 +- unity/unity.xml.defaults | 134 ++++ 21 files changed, 532 insertions(+), 1674 deletions(-) create mode 100755 bamtools/PKGBUILD create mode 100644 dnsval/PKGBUILD delete mode 100644 doomseeker/skulltag.patch create mode 100644 lv2-ll-plugins/PKGBUILD delete mode 100644 unity/debian-changes-4.24.0-0ubuntu2 rewrite unity/disable-multitouch.patch (90%) rewrite unity/make-tests-optional.patch (77%) create mode 100644 unity/unity.xml.defaults diff --git a/bamtools/PKGBUILD b/bamtools/PKGBUILD new file mode 100755 index 000000000..dfcd3761e --- /dev/null +++ b/bamtools/PKGBUILD @@ -0,0 +1,36 @@ +# Maintainer: Thiago Yukio Kikuchi Oliveira + +pkgname=bamtools +pkgver=1.0.2 +pkgrel=1 +pkgdesc="BamTools provides both a programmer's API and an end-user's toolkit for handling BAM files." +arch=("x86_64") +url="https://github.com/pezmaster31/bamtools" +license=('MIT') +depends=('cmake') + +source=(https://github.com/downloads/pezmaster31/$pkgname/$pkgname-$pkgver.tar.gz) +md5sums=('e4f3a7d90605b48a57050fc96c7af775') + +build() { + cd $srcdir/$pkgname-$pkgver + mkdir build + cd build + + cmake .. + make + + # installing + for d in 'bin' 'lib' 'include' + do + install -d "$pkgdir/usr/$d" + cd "$srcdir/$pkgname-$pkgver/$d" + + for f in * + do + cp -rf "$f" "$pkgdir/usr/$d" + done + + done + +} diff --git a/dnsval/PKGBUILD b/dnsval/PKGBUILD new file mode 100644 index 000000000..738984cf9 --- /dev/null +++ b/dnsval/PKGBUILD @@ -0,0 +1,59 @@ +# Contributor: Thomas Mudrunka +# Maintainer: Thomas Mudrunka +# You can also contact me on http://blog.harvie.cz/ +# Patches welcome: http://github.com/harvie/archlinux-packages + +pkgname=dnsval +pkgver=1.11 +pkgrel=1 +pkgdesc="C libraries that implement DNSSEC aware DNS resolution APIs." +url="http://www.dnssec-tools.org/" +license="Custom" +arch=('i686' 'x86_64') +depends=('dnssec-root-zone-trust-anchors' 'dnssec-tools') +source=("http://www.dnssec-tools.org/download/${pkgname}-${pkgver}.tar.gz") +md5sums=('2c02c0f0f4ed0a73eae029e39fd7ed8c') +sha1sums=('cf69fe9c0192bbf77198d22586cef776c97b8b29') +sha256sums=('31ba003a4abf4537e4b79556ab21f8fc84586681fc8e1e5a7648b05795375f66') +sha384sums=('33e3e7c2a15496631e15c02cd115db1fb382739573e1416fe359903a0482e032fee36e25159419c1b148ddab186139e9') +sha512sums=('bb65c094aaa14f5c81de4016db6497168ddd32a25fcb90abd751ba441453e4eed8add6c4f3fca2356ff8ba479726b286ed2c910954f5dd062ab52778e9d0fe92') + + +build() { + #Segfaults with optimizations... + ARCH="$(echo -ne "$CARCH" | tr _ -)" + export CFLAGS="-march=$ARCH -mtune=generic" + export CXXFLAGS="-march=$ARCH -mtune=generic" + echo $ARCH > /home/max/arch.txt + + cd ${srcdir}/${pkgname}-${pkgver}/ || return 1 + msg 'Configuring...' + ./configure\ + --exec_prefix=/usr --prefix=/usr\ + --sysconfdir=/etc --mandir=/usr/share/man\ + --with-resolv-conf=/etc/dnssec-tools/resolv.conf\ + --with-root-hints=/etc/dnssec-tools/root.hints\ + --with-dnsval-conf=/etc/dnsec-tools/dnsval.conf\ + --with-ipv6\ + --with-nsec3\ + --with-dlv + + # msg 'Fixing bugs...' + #grep VAL_ROOT_HINTS ./validator/libval/val_policy.h || { + # msg2 'fixing missing VAL_ROOT_HINTS in ./validator/libval/val_policy.h' + # root_hints="$(grep '^VAL_ROOT_HINTS=' ./validator/config.log | head -n 1 | tr = ' ' | tr "'" '"' | sed -e 's/\//\\\//g')" + # cat ./validator/libval/val_policy.h | sed -e 's/#include "val_parse.h"/#include "val_parse.h"\n#define '"$root_hints"'/' > tmp + # mv tmp ./validator/libval/val_policy.h + #} + + msg 'Building...' + make -j1 +} +package() { + cd ${srcdir}/${pkgname}-${pkgver}/ || return 1 + msg 'Installing files to package...' + make -j1 install DESTDIR="${pkgdir}" + msg 'Cleaning...' + #have to do this because of some issues... + rm -rf "${srcdir}/" +} diff --git a/doomseeker/PKGBUILD b/doomseeker/PKGBUILD index d1a334ec6..b3c1a0805 100644 --- a/doomseeker/PKGBUILD +++ b/doomseeker/PKGBUILD @@ -2,28 +2,25 @@ # Contributor: MP2E pkgname=doomseeker -pkgver=0.7b -pkgrel=3 +pkgver=0.8b +pkgrel=2 pkgdesc="A cross-platform server browser for Chocolate Doom, Odamex, Skulltag, Vavoom, and ZDaemon." arch=('i686' 'x86_64') url="http://doomseeker.drdteam.org/" -conflicts=('doomseeker-svn') +conflicts=('doomseeker-svn doomseeker-hg') depends=('qt' 'zlib') -makedepends=('cmake' 'make' 'gcc') +makedepends=('cmake' 'make' 'gcc' 'mercurial') optdepends=('chocolate-doom: to play on Chocolate Doom servers' 'odamex: to play on Odamex servers' 'skulltag: to play on Skulltag servers' 'vavoom: to play on Vavoom servers' 'wine: to play on ZDaemon servers') license=('GPL') -source=("skulltag.patch") -md5sums=('4d769904ee9c09d629e755ccf08a4811') build() { - hg clone https://bitbucket.org/Blzut3/doomseeker -u 7245b85a6f3a + hg clone https://bitbucket.org/Blzut3/doomseeker -u 5ba7373b7ff6 cd $pkgname - patch -uN $srcdir/$pkgname/src/skulltag/skulltagmain.cpp ../skulltag.patch || return 1 cmake . make || return 1 } diff --git a/doomseeker/skulltag.patch b/doomseeker/skulltag.patch deleted file mode 100644 index 50d033074..000000000 --- a/doomseeker/skulltag.patch +++ /dev/null @@ -1,19 +0,0 @@ ---- src/skulltag/skulltagmain.cpp 2011-12-04 16:56:33.881561048 -0800 -+++ src/skulltag/skulltagmain.cpp.new 2011-12-04 16:58:08.361554958 -0800 -@@ -139,7 +139,7 @@ - void masterHost(QString &host, unsigned short &port) const - { - QString str = pConfig->setting("Masterserver"); -- Strings::translateServerAddress(str, host, port, "skulltag.servegame.com", 15300); -+ Strings::translateServerAddress(str, host, port, "master.skulltag.net", 15300); - } - - void registerIRCServer(QVector &networks) const -@@ -187,6 +187,6 @@ - config.createSetting("ServerBinaryPath", pf.findFile("skulltag-server")); - #endif - -- config.createSetting("Masterserver", "skulltag.servegame.com:15300"); -+ config.createSetting("Masterserver", "master.skulltag.net:15300"); - config.createSetting("EnableTesting", true); - } diff --git a/linux-lqx/PKGBUILD b/linux-lqx/PKGBUILD index ca74ee555..b3304c9a4 100644 --- a/linux-lqx/PKGBUILD +++ b/linux-lqx/PKGBUILD @@ -24,7 +24,7 @@ _compress_modules="y" #compress(gzip -9) modules to save about 100MB of space # _basekernel=3.1 -pkgver=${_basekernel}.6 +pkgver=${_basekernel}.8 pkgrel=1 _kernelname=-lqx pkgname=linux${_kernelname} @@ -263,7 +263,7 @@ build() { # vim:ts=2:sw=2:expandtab # oh hai thar: checksums sha512sums=('131b814325d888bb11ba552bc5bdd91ee2d8e139b06ac7ba94e716bcbbcc99ba30867eeea4aab580907916203bc526ae0bccda688151b250ba7943e193e50252' - 'cd9b8382a101857fcd9d04c62f9fd479135abbaa41dea614197db0925c7db383c7060833ef000cf14a6d092bb028581c4878a831353497bf3ba709ae37e1110b' + '5807f20ebad52e76a2c0253eee965485c7e1e62aec67d7865b59839a502656b5606a6defa5e6bd5dc4a86269cff20326cb0c9af70354c2b728d229cf0a7b88a4' '2cf4b4e1ba55c1610fe61f654503b4aaa965a3aa2aac7270440d0c1213c5b5ad3ad7bff85bf01bb648fa816ff3a89737904cf5252b93e2f14dc2b34216973a7f' '9698effef8635d1b58d741ff5bfe9df3a426e338ebf4b0cace4dc0ac68e4a0c1312ee21a049b399dc0318ac9e6a4a01c6e400be2ad73197d89fab831b4dc8db0' '65fd484647b52ed8b75ab5d5f296ab1b79917ee83625bee9e74a8b3c1f9b155674001934c0a81e630997050816fdfd2b597eaf076838f250d61b51e4ec2aac16') diff --git a/lv2-ll-plugins/PKGBUILD b/lv2-ll-plugins/PKGBUILD new file mode 100644 index 000000000..a07a04e25 --- /dev/null +++ b/lv2-ll-plugins/PKGBUILD @@ -0,0 +1,33 @@ +# $Id$ +# Maintainer: Arch Linux Pro Audio +# Contributor: Philipp Überbacher +# Contributor: SpepS + +pkgname=lv2-ll-plugins +_realname=ll-plugins +pkgver=0.2.8 +pkgrel=3 +pkgdesc="A lv2 host and a collection of lv2 plugins by Lars Luthman" +arch=('i686' 'x86_64') +url="http://ll-plugins.nongnu.org/index.html" +license=('GPL3') +provides=('ll-plugins' 'lv2-ll') +conflicts=('ll-plugins' 'lv2-ll') +depends=('gtkmm' 'lv2-c++-tools' 'libsigc++' 'lash' 'jack' 'lv2core') +source=(http://download.savannah.gnu.org/releases/ll-plugins/ll-plugins-0.2.8.tar.bz2) +md5sums=('56e7f4a62fce6b22b4acdb02ba06669c') + +build() { + + export LDFLAGS="${LDFLAGS} -ldl" + cd "${srcdir}/${_realname}-${pkgver}" + + ./configure --prefix="/usr" + make +} + +package() { + + cd "${srcdir}/${_realname}-${pkgver}" + make DESTDIR="${pkgdir}" install +} diff --git a/namebench/PKGBUILD b/namebench/PKGBUILD index d18a8a56f..73fe39cf9 100644 --- a/namebench/PKGBUILD +++ b/namebench/PKGBUILD @@ -1,13 +1,15 @@ +# Maintainer: Daniel Micay # Contributor: Marti Raudsepp pkgname=namebench pkgver=1.3.1 -pkgrel=3 +pkgrel=4 pkgdesc="Open-source DNS benchmark utility" arch=(any) url="http://code.google.com/p/namebench/" license=('Apache') -depends=('python2' 'python-dnspython' 'python-jinja' 'tk') +depends=('python2' 'python-dnspython' 'python2-jinja') +optdepends=('tk: gui') # optional: python-graphy (not in Arch/AUR), pyobjc (presumably OS X support) source=(http://$pkgname.googlecode.com/files/$pkgname-$pkgver-source.tgz) md5sums=('34e74eac37d6747592f8d5085f03ee4f') diff --git a/nvidia-lqx/PKGBUILD b/nvidia-lqx/PKGBUILD index 6f870e695..d5e9bef62 100644 --- a/nvidia-lqx/PKGBUILD +++ b/nvidia-lqx/PKGBUILD @@ -3,12 +3,12 @@ pkgname=nvidia-lqx pkgver=290.10 -_kernver='3.1.0-lqx' -pkgrel=1 +_kernver='3.2.0-lqx' +pkgrel=2 pkgdesc="NVIDIA drivers for linux-lqx." arch=('i686' 'x86_64') url="http://www.nvidia.com/" -depends=("linux-lqx>=3.1" "linux-lqx<3.2" "nvidia-utils=${pkgver}") +depends=("linux-lqx>=3.2" "linux-lqx<3.3" "nvidia-utils=${pkgver}") conflicts=() license=('custom') install=nvidia-lqx.install @@ -30,14 +30,14 @@ build() { cd $srcdir sh ${_pkg}.run --extract-only cd ${_pkg}/kernel - make SYSSRC=/lib/modules/${_kernver}/build module || return 1 + make SYSSRC=/lib/modules/${_kernver}/build module } package() { install -D -m644 "$srcdir"/$_pkg/kernel/nvidia.ko \ "$pkgdir"/lib/modules/$_kernver/kernel/drivers/video/nvidia.ko install -d -m755 "$pkgdir"/etc/modprobe.d - echo "blacklist nouveau" >> "$pkgdir"/etc/modprobe.d/nouveau_blacklist_ck.conf + echo "blacklist nouveau" >> "$pkgdir"/etc/modprobe.d/nouveau_blacklist_lqx.conf sed -i -e "s/KERNEL_VERSION='.*'/KERNEL_VERSION='$_kernver'/" "$startdir/nvidia-lqx.install" gzip "${pkgdir}/lib/modules/${_kernver}/kernel/drivers/video/nvidia.ko" } diff --git a/nvidia-lqx/nvidia-lqx.install b/nvidia-lqx/nvidia-lqx.install index 8c35370bd..2a66a3c68 100644 --- a/nvidia-lqx/nvidia-lqx.install +++ b/nvidia-lqx/nvidia-lqx.install @@ -1,5 +1,5 @@ post_install() { - KERNEL_VERSION='3.1.0-lqx' + KERNEL_VERSION='3.2.0-lqx' depmod $KERNEL_VERSION } @@ -9,7 +9,7 @@ post_upgrade() { } post_remove() { - KERNEL_VERSION='3.1.0-lqx' + KERNEL_VERSION='3.2.0-lqx' depmod $KERNEL_VERSION } diff --git a/rainlendar-beta-unstable/PKGBUILD b/rainlendar-beta-unstable/PKGBUILD index 3049216bc..32ab3a62c 100644 --- a/rainlendar-beta-unstable/PKGBUILD +++ b/rainlendar-beta-unstable/PKGBUILD @@ -1,14 +1,14 @@ # Contributor: Ng Oon-Ee # Based on rainlendar-beta by Blasse pkgname=rainlendar-beta-unstable -pkgver=2.10.b113 +pkgver=2.10.b114 pkgrel=1 if [ "${CARCH}" = 'i686' ]; then source=(http://www.rainlendar.net/download/Rainlendar-$pkgver-i386.tar.bz2) - md5sums=('ef52f66b005708029dcb93a16422b07e') + md5sums=('4d5312cc5a8a3ae5f5e4648644539655') else source=(http://www.rainlendar.net/download/Rainlendar-$pkgver-amd64.tar.bz2) - md5sums=('e11b5c3fff7dcbcbb9d54b8063486832') + md5sums=('f75ff1bc55571ee45dd54be9334d634b') fi pkgdesc="A desktop Calendar, ToDo list and Event list. An unstable (untested) beta version." diff --git a/tardy/PKGBUILD b/tardy/PKGBUILD index 21ffd5a04..fecc4789f 100644 --- a/tardy/PKGBUILD +++ b/tardy/PKGBUILD @@ -1,15 +1,15 @@ # Maintainer: SpepS pkgname=tardy -pkgver=1.24 +pkgver=1.25 pkgrel=1 pkgdesc="A tar post-processor to manipulate the file headers in various ways." arch=(i686 x86_64) url="http://tardy.sourceforge.net/" -license=('GPL') +license=('GPL3') depends=('zlib' 'libexplain') source=("$url$pkgname-$pkgver.tar.gz") -md5sums=('3171e46c6aabdf67f774577399ef3424') +md5sums=('27e1b625488d824d6e95412ba88c0651') build() { cd "$srcdir/$pkgname-$pkgver" diff --git a/unitary-gnome/PKGBUILD b/unitary-gnome/PKGBUILD index 24caedfb6..02c36ec40 100644 --- a/unitary-gnome/PKGBUILD +++ b/unitary-gnome/PKGBUILD @@ -1,14 +1,14 @@ pkgname=unitary-gnome -pkgver=1.0 -pkgrel=3 +pkgver=1.1 +pkgrel=1 pkgdesc="Unity-2D Launcher for Gnome Shell" url="http://techunit.deviantart.com/art/Unitary-Gnome-279375636" -license=('GPL') +license=('Creative Commons') arch=('any') depends=('gnome-shell' 'unity-2d') install=$pkgname.install source=("http://www.deviantart.com/download/279375636/unitary_gnome_by_techunit-d4mbzmc.zip") -md5sums=('5b95cb3048995ec2fa4b603f38792455') +md5sums=('4a19d0ee918d6bfb9b4235555e464182') build() { cd $srcdir diff --git a/unitary-gnome/unitary-gnome.install b/unitary-gnome/unitary-gnome.install index 7868c7183..647346990 100644 --- a/unitary-gnome/unitary-gnome.install +++ b/unitary-gnome/unitary-gnome.install @@ -1,5 +1,5 @@ pre_install() { - install -Dm644 /usr/share/unity-2d/launcher/Launcher.qml /usr/share/unity-2d/launcher/Launcher_backup.qml + cp /usr/share/unity-2d/launcher/Launcher.qml /usr/share/unity-2d/launcher/Launcher_backup.qml } post_install() { diff --git a/unity/PKGBUILD b/unity/PKGBUILD index bbb0116bd..56cee5ce2 100644 --- a/unity/PKGBUILD +++ b/unity/PKGBUILD @@ -1,17 +1,16 @@ # Maintainer: György Balló pkgbase=unity pkgname=unity -true & pkgname=(unity-common unity) -pkgver=4.24.0 -pkgrel=3 +true && pkgname=(unity-common unity) +pkgver=5.0.0 +pkgrel=1 arch=('i686' 'x86_64') url="https://launchpad.net/unity" license=('GPL') -makedepends=('nux>=1.4.0-2' 'libunity' 'libindicator3' 'compiz-core-dev' 'bamf' 'libunity-misc>=0.4.0' 'json-glib' 'libnotify' 'gnome-desktop' 'cmake' 'boost' 'intltool' 'glproto' 'dri2proto') -source=(http://launchpad.net/$pkgbase/4.0/$pkgver/+download/$pkgbase-$pkgver.tar.bz2 +makedepends=('nux' 'libunity' 'libindicator3' 'compiz-core-devel' 'bamf' 'libunity-misc' 'json-glib' 'libnotify' 'gnome-desktop' 'libgdu' 'cmake' 'boost' 'intltool' 'glproto' 'dri2proto') +source=(http://launchpad.net/$pkgbase/5.0/$pkgver/+download/$pkgbase-$pkgver.tar.bz2 launchpad-export.tar.gz nautilus-home.desktop - debian-changes-4.24.0-0ubuntu2 make-tests-optional.patch disable-multitouch.patch use-unity-profile.patch @@ -19,27 +18,36 @@ source=(http://launchpad.net/$pkgbase/4.0/$pkgver/+download/$pkgbase-$pkgver.tar unity.ini unity.sh unity.session - unity.desktop) -md5sums=('dd804fc0e0d08b7bf7da7fc2d0fbc53a' + unity.desktop + unity.xml.defaults) +md5sums=('e41f5991ca0cdaac73f5c807a671b374' 'abba8f4ebdcc90983633248ebab361e1' '236c7d9173d65adc704b953d77724739' - '2ce17276159e7baf2dd1f4a1e4e87fed' - '24a0bc31e9d01a3c99bf70982f8a7f2c' - '4ac83fa16eff01b836bca357b6094f0f' + 'dfe8f2933a88c387f07ce2aa0794fa21' + '9c5cbf40364615ea578bf8abb82ff837' 'cd19df00c59f647b1ae8b9d8cfd94c24' - '79b8df38ecd937393d8366d297a1575e' + '8a8562a167973519666efceaf06d05a0' 'd954f6aba40501f4baeec94247aefef4' - 'c151208ef97f8e6139daeef72db6e08c' + '00713cf28268247a582f7bf1fcf1fc20' 'e0b1d90fc06601ccc57fd49827266f9d' - 'fe17963c172e71d68704dfa4bb04bea4') + 'fe17963c172e71d68704dfa4bb04bea4' + 'a4d4fd820a458962faf07238d613ffbe') build() { cd "$srcdir/$pkgbase-$pkgver" sed -i 's@^#!.*python$@#!/usr/bin/python2@' tools/* - patch -Np1 -i "$srcdir/debian-changes-4.24.0-0ubuntu2" - patch -Np1 -i "$srcdir/make-tests-optional.patch" + + # Disable multitouch support patch -Np1 -i "$srcdir/disable-multitouch.patch" + rm plugins/unityshell/src/{GeisAdapter,GestureEngine}.{h,cpp} + + # Make tests optional + patch -Np1 -i "$srcdir/make-tests-optional.patch" + + # Use unity profile patch -Np1 -i "$srcdir/use-unity-profile.patch" + + # Set some default settings patch -Np1 -i "$srcdir/default-settings.patch" # Install updated language files @@ -47,16 +55,23 @@ build() { rename $pkgbase- '' ../po/$pkgbase-*.po mv -f -t po ../po/* + # Fix build + echo "$pkgver" > VERSION + [[ -d build ]] || mkdir build cd build - cmake .. -DCMAKE_BUILD_TYPE=Release -DCOMPIZ_PLUGIN_INSTALL_TYPE=package -DCMAKE_INSTALL_PREFIX=/usr -DBUILD_TESTS=OFF + cmake .. -DCMAKE_INSTALL_PREFIX=/usr \ + -DCMAKE_BUILD_TYPE=Release \ + -DCOMPIZ_PACKAGING_ENABLED=ON \ + -DCOMPIZ_BUILD_WITH_RPATH=OFF \ + -DBUILD_TESTS=OFF make } package_unity-common() { pkgdesc="Shared files between unity and unity-2d" - depends=('nux>=1.4.0-2' 'libunity' 'libindicator3' 'dconf') + depends=('nux' 'libunity' 'libindicator3' 'dconf') install=unity-common.install cd "$srcdir/$pkgbase-$pkgver/build" @@ -66,7 +81,7 @@ package_unity-common() { ### Split unity files [[ -d $srcdir/unity ]] && rm -r "$srcdir/unity/" [[ -d $srcdir/unity-gconf ]] && rm -r "$srcdir/unity-gconf/" - mkdir -p "$srcdir"/unity{,-gconf}/usr/{lib,share/{glib-2.0/schemas,man/man1}} + mkdir -p "$srcdir"/unity{,-gconf}/usr/{lib,share/man/man1} mv {"$pkgdir","$srcdir/unity"}/usr/bin mv {"$pkgdir","$srcdir/unity"}/usr/lib/compiz @@ -74,7 +89,6 @@ package_unity-common() { mv {"$pkgdir","$srcdir/unity"}/usr/share/ccsm mv {"$pkgdir","$srcdir/unity"}/usr/share/compiz mv {"$pkgdir","$srcdir/unity-gconf"}/usr/share/gconf - mv "$pkgdir"/usr/share/glib-2.0/schemas/org.freedesktop.compiz.*.gschema.xml "$srcdir/unity/usr/share/glib-2.0/schemas" mv {"$pkgdir","$srcdir/unity"}/usr/share/locale # Install Home folder for launcher @@ -83,7 +97,7 @@ package_unity-common() { package_unity() { pkgdesc="A desktop experience designed for efficiency of space and interaction" - depends=("unity-common=$pkgver" 'compiz-core-dev' 'bamf' 'libunity-misc>=0.4.0' 'unity-asset-pool' 'gnome-session' 'gnome-settings-daemon') + depends=("unity-common=$pkgver" 'compiz-decorator-gtk-devel' 'compizconfig-backend-gconf-devel' 'bamf' 'libunity-misc' 'libgdu' 'unity-asset-pool' 'gnome-session' 'gnome-settings-daemon') optdepends=('indicator-application: take menus from applications and place them in the panel' 'indicator-appmenu: host the menus from an application' 'indicator-datetime: a very, very simple clock' @@ -104,9 +118,11 @@ package_unity() { mkdir -p "$pkgdir"/usr/share/gconf/schemas gconf-merge-schema "$pkgdir"/usr/share/gconf/schemas/compiz-unity.schemas \ "$srcdir"/unity-gconf/usr/share/gconf/schemas/*.schemas - sed -i 's|||' "$pkgdir"/usr/share/gconf/schemas/compiz-unity.schemas + sed -i '//d' "$pkgdir"/usr/share/gconf/schemas/compiz-unity.schemas - # Install Unity Compiz profile + # Install Compiz profile and settings + install -dm755 "$pkgdir"/etc/gconf/unity.xml.defaults + gconftool-2 --direct --config-source xml:readwrite:"$pkgdir/etc/gconf/unity.xml.defaults" --load "$srcdir/unity.xml.defaults" install -Dm644 "$srcdir/unity.ini" "$pkgdir/etc/compizconfig/unity.ini" install -Dm755 "$srcdir/unity.sh" "$pkgdir/etc/profile.d/unity.sh" @@ -115,5 +131,5 @@ package_unity() { install -Dm644 "$srcdir/unity.desktop" "$pkgdir/usr/share/xsessions/unity.desktop" } -depends=('nux>=1.4.0-2' 'libunity' 'libindicator' 'compiz-core-dev' 'bamf' 'libunity-misc>=0.4.0' 'unity-asset-pool' 'gnome-session' 'gnome-settings-daemon') +depends=('nux' 'libunity' 'libindicator' 'compiz-decorator-gtk-devel' 'compizconfig-backend-gconf-devel' 'bamf' 'libunity-misc' 'libgdu' 'unity-asset-pool' 'gnome-session' 'gnome-settings-daemon') true && depends=() diff --git a/unity/debian-changes-4.24.0-0ubuntu2 b/unity/debian-changes-4.24.0-0ubuntu2 deleted file mode 100644 index abf7075db..000000000 --- a/unity/debian-changes-4.24.0-0ubuntu2 +++ /dev/null @@ -1,362 +0,0 @@ -Description: Upstream changes introduced in version 4.24.0-0ubuntu2 - This patch has been created by dpkg-source during the package build. - Here's the last changelog entry, hopefully it gives details on why - those changes were made: - . - unity (4.24.0-0ubuntu2) oneiric-proposed; urgency=low - . - * Cherry-pick upstream: - - SRU0-Regression: scrollbar displacement caused dash rows to show less - icons (LP: #875023) - - Really reverts the UI change that was still uploaded even if we had - reverted it… - . - The person named in the Author field signed this changelog entry. -Author: Didier Roche -Bug-Ubuntu: https://bugs.launchpad.net/bugs/875023 - ---- -The information above should follow the Patch Tagging Guidelines, please -checkout http://dep.debian.net/deps/dep3/ to learn about the format. Here -are templates for supplementary fields that you might want to add: - -Origin: , -Bug: -Bug-Debian: http://bugs.debian.org/ -Bug-Ubuntu: https://launchpad.net/bugs/ -Forwarded: -Reviewed-By: -Last-Update: - ---- unity-4.24.0.orig/services/panel-service.c -+++ unity-4.24.0/services/panel-service.c -@@ -1160,8 +1160,11 @@ panel_service_sync_geometry (PanelServic - - if (entry2geometry_hash == NULL) - { -+ //FIXME - this leaks memory but i'm not 100% on the logic, -+ // using g_free as the keys destructor function causes all -+ // kinds of problems - entry2geometry_hash = g_hash_table_new_full (g_direct_hash, g_direct_equal, -- g_free, g_free); -+ NULL, g_free); - g_hash_table_insert (priv->panel2entries_hash, g_strdup (panel_id), - entry2geometry_hash); - } ---- unity-4.24.0.orig/services/CMakeLists.txt -+++ unity-4.24.0/services/CMakeLists.txt -@@ -39,7 +39,7 @@ set(CFLAGS - "-DGETTEXT_PACKAGE=\"unity\"" - "-DINDICATORDIR=\"${_indicatordir}\"" - "-DINDICATORICONDIR=\"${_iconsdir}\"" -- "-Werror -Wall" -+ "-Wall" - ) - add_definitions(${CFLAGS}) - ---- unity-4.24.0.orig/plugins/unityshell/src/WindowManager.cpp -+++ unity-4.24.0/plugins/unityshell/src/WindowManager.cpp -@@ -68,6 +68,11 @@ class WindowManagerDummy : public Window - return true; - } - -+ bool IsWindowVisible(guint32 xid) -+ { -+ return true; -+ } -+ - void Restore(guint32 xid) - { - g_debug("%s", G_STRFUNC); ---- unity-4.24.0.orig/plugins/unityshell/src/unityshell.h -+++ unity-4.24.0/plugins/unityshell/src/unityshell.h -@@ -269,6 +269,8 @@ private: - void restartLauncherKeyNav(); - void OnLauncherHiddenChanged(); - -+ void OnDashRealized (); -+ - static void OnQuicklistEndKeyNav(GVariant* data, void* value); - static void OnLauncherStartKeyNav(GVariant* data, void* value); - static void OnLauncherEndKeyNav(GVariant* data, void* value); ---- unity-4.24.0.orig/plugins/unityshell/src/PanelView.cpp -+++ unity-4.24.0/plugins/unityshell/src/PanelView.cpp -@@ -374,7 +374,7 @@ PanelView::UpdateBackground() - _last_height = geo.height; - _is_dirty = false; - -- if (_dash_is_open && (_menu_view->GetMaximizedWindow() == 0)) -+ if (_dash_is_open) - { - if (_bg_layer) - delete _bg_layer; ---- unity-4.24.0.orig/plugins/unityshell/src/PluginAdapter.h -+++ unity-4.24.0/plugins/unityshell/src/PluginAdapter.h -@@ -117,6 +117,7 @@ public: - bool IsWindowOnCurrentDesktop(guint xid); - bool IsWindowObscured(guint xid); - bool IsWindowMapped(guint xid); -+ bool IsWindowVisible(guint32 xid); - void Restore(guint32 xid); - void Minimize(guint32 xid); - void Close(guint32 xid); ---- unity-4.24.0.orig/plugins/unityshell/src/PluginAdapter.cpp -+++ unity-4.24.0/plugins/unityshell/src/PluginAdapter.cpp -@@ -489,6 +489,19 @@ PluginAdapter::IsWindowMapped(guint32 xi - return true; - } - -+bool -+PluginAdapter::IsWindowVisible(guint32 xid) -+{ -+ Window win = (Window) xid; -+ CompWindow* window; -+ -+ window = m_Screen->findWindow(win); -+ if (window) -+ return !(window->state () & CompWindowStateHiddenMask); -+ -+ return true; -+} -+ - void - PluginAdapter::Restore(guint32 xid) - { -@@ -562,6 +575,7 @@ PluginAdapter::FocusWindowGroup(std::vec - CompWindow* top_win = NULL; - bool any_on_current = false; - bool any_mapped = false; -+ bool forced_unminimize = false; - - /* sort the list */ - CompWindowList windows; -@@ -609,13 +623,29 @@ PluginAdapter::FocusWindowGroup(std::vec - * not going to be accessible by either switcher - * or scale, so unconditionally unminimize those - * windows when the launcher icon is activated */ -- if (focus_visibility == WindowManager::FocusVisibility::ForceUnminimizeInvisible && -- win->mapNum () == 0) -+ if ((focus_visibility == WindowManager::FocusVisibility::ForceUnminimizeOnCurrentDesktop && -+ WindowManager::Default ()->IsWindowOnCurrentDesktop(win->id ())) || -+ (focus_visibility == WindowManager::FocusVisibility::ForceUnminimizeInvisible && -+ win->mapNum () == 0)) -+ { -+ bool is_mapped = win->mapNum () != 0; -+ top_win = win; - win->unminimize (); -+ -+ forced_unminimize = true; -+ -+ /* Initially minimized windows dont get raised */ -+ if (!is_mapped) -+ win->raise (); -+ } - else if ((any_mapped && !win->minimized()) || !any_mapped) - { -- win->raise(); -- top_win = win; -+ if (!forced_unminimize || -+ WindowManager::Default ()->IsWindowOnCurrentDesktop (win->id ())) -+ { -+ win->raise(); -+ top_win = win; -+ } - } - } - } ---- unity-4.24.0.orig/plugins/unityshell/src/WindowManager.h -+++ unity-4.24.0/plugins/unityshell/src/WindowManager.h -@@ -48,7 +48,8 @@ public: - enum class FocusVisibility - { - OnlyVisible, -- ForceUnminimizeInvisible -+ ForceUnminimizeInvisible, -+ ForceUnminimizeOnCurrentDesktop - }; - - static WindowManager* Default(); -@@ -59,6 +60,7 @@ public: - virtual bool IsWindowOnCurrentDesktop(guint32 xid) = 0; - virtual bool IsWindowObscured(guint32 xid) = 0; - virtual bool IsWindowMapped(guint32 xid) = 0; -+ virtual bool IsWindowVisible(guint32 xid) = 0; - - virtual void ShowDesktop() = 0; - ---- unity-4.24.0.orig/plugins/unityshell/src/DashController.cpp -+++ unity-4.24.0/plugins/unityshell/src/DashController.cpp -@@ -131,6 +131,8 @@ void DashController::EnsureDash() - SetupDashView(); - Relayout(); - ensure_id_ = 0; -+ -+ on_realize.emit (); - } - - nux::BaseWindow* DashController::window() const ---- unity-4.24.0.orig/plugins/unityshell/src/LensView.cpp -+++ unity-4.24.0/plugins/unityshell/src/LensView.cpp -@@ -145,7 +145,9 @@ void LensView::SetupViews() - { - layout_ = new nux::HLayout(NUX_TRACKER_LOCATION); - -- layout_->SetHorizontalExternalMargin(8); -+ // Breaks the sizing of the whole dash causing some colums to be clipped from result view. -+ // look in to this for P. -+ // layout_->SetHorizontalExternalMargin(8); - - scroll_view_ = new LensScrollView(new PlacesVScrollBar(NUX_TRACKER_LOCATION), - NUX_TRACKER_LOCATION); ---- unity-4.24.0.orig/plugins/unityshell/src/DashController.h -+++ unity-4.24.0/plugins/unityshell/src/DashController.h -@@ -54,6 +54,8 @@ public: - nux::Property launcher_width; - nux::Property panel_height; - -+ sigc::signal on_realize; -+ - protected: - const gchar* GetName(); - void AddProperties(GVariantBuilder* builder); ---- unity-4.24.0.orig/plugins/unityshell/src/BamfLauncherIcon.cpp -+++ unity-4.24.0/plugins/unityshell/src/BamfLauncherIcon.cpp -@@ -78,6 +78,7 @@ void BamfLauncherIcon::ActivateLauncherI - - if (arg.source != ActionArg::SWITCHER) - { -+ bool any_visible = false; - for (l = bamf_view_get_children(BAMF_VIEW(m_App)); l; l = l->next) - { - view = static_cast (l->data); -@@ -85,13 +86,18 @@ void BamfLauncherIcon::ActivateLauncherI - if (BAMF_IS_WINDOW(view)) - { - Window xid = bamf_window_get_xid(BAMF_WINDOW(view)); -+ -+ if (WindowManager::Default ()->IsWindowOnCurrentDesktop(xid)) -+ any_visible = true; - if (!WindowManager::Default ()->IsWindowMapped(xid)) - { - active = false; -- break; - } - } - } -+ -+ if (!any_visible) -+ active = false; - } - - /* Behaviour: -@@ -566,6 +572,7 @@ void BamfLauncherIcon::Focus(ActionArg a - GList* children, *l; - BamfView* view; - bool any_urgent = false; -+ bool any_visible = false; - - children = bamf_view_get_children(BAMF_VIEW(m_App)); - -@@ -581,6 +588,10 @@ void BamfLauncherIcon::Focus(ActionArg a - Window xid = bamf_window_get_xid(BAMF_WINDOW(view)); - bool urgent = bamf_view_is_urgent(view); - -+ if (WindowManager::Default ()->IsWindowOnCurrentDesktop (xid) && -+ WindowManager::Default ()->IsWindowVisible (xid)) -+ any_visible = true; -+ - if (any_urgent) - { - if (urgent) -@@ -591,17 +602,28 @@ void BamfLauncherIcon::Focus(ActionArg a - if (urgent) - { - windows.clear(); -+ any_visible = false; - any_urgent = true; - } -- windows.push_back(xid); - } -+ windows.push_back(xid); - } - } - - g_list_free(children); - if (arg.source != ActionArg::SWITCHER) -- WindowManager::Default()->FocusWindowGroup(windows, -- WindowManager::FocusVisibility::ForceUnminimizeInvisible); -+ { -+ if (any_visible) -+ { -+ WindowManager::Default()->FocusWindowGroup(windows, -+ WindowManager::FocusVisibility::ForceUnminimizeInvisible); -+ } -+ else -+ { -+ WindowManager::Default()->FocusWindowGroup(windows, -+ WindowManager::FocusVisibility::ForceUnminimizeOnCurrentDesktop); -+ } -+ } - else - WindowManager::Default()->FocusWindowGroup(windows, - WindowManager::FocusVisibility::OnlyVisible); ---- unity-4.24.0.orig/plugins/unityshell/src/unityshell.cpp -+++ unity-4.24.0/plugins/unityshell/src/unityshell.cpp -@@ -2380,6 +2380,20 @@ UnityFBO::~UnityFBO () - glDeleteTextures (1, &mFBTexture); - } - -+void UnityScreen::OnDashRealized () -+{ -+ /* stack any windows named "onboard" above us */ -+ for (CompWindow *w : screen->windows ()) -+ { -+ if (w->resName() == "onboard") -+ { -+ Window xid = dashController->window()->GetInputWindowId(); -+ XSetTransientForHint (screen->dpy(), w->id(), xid); -+ w->raise (); -+ } -+ } -+} -+ - /* Start up the launcher */ - void UnityScreen::initLauncher(nux::NThread* thread, void* InitData) - { -@@ -2436,6 +2450,7 @@ void UnityScreen::initLauncher(nux::NThr - - /* Setup Places */ - self->dashController = DashController::Ptr(new DashController()); -+ self->dashController->on_realize.connect (sigc::mem_fun (self, &UnityScreen::OnDashRealized)); - - /* FIXME: this should not be manual, should be managed with a - show/hide callback like in GAIL -@@ -2491,11 +2506,24 @@ UnityWindow::UnityWindow(CompWindow* win - - if (window->state () & CompWindowStateFullscreenMask) - UnityScreen::get (screen)->fullscreen_windows_.push_back(window); -- -- if (window->resName() == "onboard") -+ -+ /* We might be starting up so make sure that -+ * we don't deref the dashcontroller that doesnt -+ * exist */ -+ DashController::Ptr dp = UnityScreen::get (screen)->dashController; -+ -+ if (dp) - { -- Window xid = UnityScreen::get (screen)->dashController->window()->GetInputWindowId(); -- XSetTransientForHint (screen->dpy(), window->id(), xid); -+ nux::BaseWindow* w = dp->window (); -+ -+ if (w) -+ { -+ if (window->resName() == "onboard") -+ { -+ Window xid = dp->window()->GetInputWindowId(); -+ XSetTransientForHint (screen->dpy(), window->id(), xid); -+ } -+ } - } - } - diff --git a/unity/default-settings.patch b/unity/default-settings.patch index 6ec1e1088..65a50514a 100644 --- a/unity/default-settings.patch +++ b/unity/default-settings.patch @@ -6,7 +6,7 @@ diff -Naur unity-4.24.0.orig/com.canonical.Unity.gschema.xml unity-4.24.0/com.ca - [ 'ubiquity-gtkui.desktop', 'nautilus-home.desktop', 'firefox.desktop', 'libreoffice-writer.desktop', 'libreoffice-calc.desktop', 'libreoffice-impress.desktop', 'ubuntu-software-center.desktop', 'ubuntuone-installer.desktop', 'gnome-control-center.desktop' ] -+ [ 'nautilus-home.desktop', 'firefox.desktop', 'libreoffice-writer.desktop', 'libreoffice-calc.desktop', 'libreoffice-impress.desktop', 'gpk-application.desktop', 'ubuntuone-control-panel.desktop', 'gnome-control-center.desktop' ] ++ [ 'nautilus-home.desktop', 'firefox.desktop', 'libreoffice-writer.desktop', 'libreoffice-calc.desktop', 'libreoffice-impress.desktop', 'gpk-application.desktop', 'ubuntuone-control-panel-gtk.desktop', 'gnome-control-center.desktop' ] List of desktop file ids for favorites on the launcher. These applications are shown in the Launcher by default. diff --git a/unity/disable-multitouch.patch b/unity/disable-multitouch.patch dissimilarity index 90% index 546f6a287..374521893 100644 --- a/unity/disable-multitouch.patch +++ b/unity/disable-multitouch.patch @@ -1,1216 +1,160 @@ -diff -Naur unity-4.24.0.orig/CMakeLists.txt unity-4.24.0/CMakeLists.txt ---- unity-4.24.0.orig/CMakeLists.txt 2011-10-12 14:02:40.000000000 +0200 -+++ unity-4.24.0/CMakeLists.txt 2011-11-12 18:08:29.953890912 +0100 -@@ -121,7 +121,7 @@ - # - # Compiz Plugins - # --set (UNITY_PLUGIN_DEPS "compiz;nux-1.0 >= 1.2.2;libbamf3;dee-1.0;gio-2.0;gio-unix-2.0;dbusmenu-glib-0.4;x11;libstartup-notification-1.0;gthread-2.0;indicator3-0.4;atk;unity-misc >= 0.4.0;gconf-2.0;libutouch-geis;gtk+-3.0 >= 3.1;sigc++-2.0;json-glib-1.0;libnotify;gnome-desktop-3.0") -+set (UNITY_PLUGIN_DEPS "compiz;nux-1.0 >= 1.2.2;libbamf3;dee-1.0;gio-2.0;gio-unix-2.0;dbusmenu-glib-0.4;x11;libstartup-notification-1.0;gthread-2.0;indicator3-0.4;atk;unity-misc >= 0.4.0;gconf-2.0;gtk+-3.0 >= 3.1;sigc++-2.0;json-glib-1.0;libnotify;gnome-desktop-3.0") - - - find_package (Compiz REQUIRED) -diff -Naur unity-4.24.0.orig/plugins/unityshell/src/GeisAdapter.cpp unity-4.24.0/plugins/unityshell/src/GeisAdapter.cpp ---- unity-4.24.0.orig/plugins/unityshell/src/GeisAdapter.cpp 2011-10-12 14:02:40.000000000 +0200 -+++ unity-4.24.0/plugins/unityshell/src/GeisAdapter.cpp 1970-01-01 01:00:00.000000000 +0100 -@@ -1,497 +0,0 @@ --// -*- Mode: C++; indent-tabs-mode: nil; tab-width: 2 -*- --/* -- * Copyright (C) 2010 Canonical Ltd -- * -- * This program is free software: you can redistribute it and/or modify -- * it under the terms of the GNU General Public License version 3 as -- * published by the Free Software Foundation. -- * -- * This program is distributed in the hope that it will be useful, -- * but WITHOUT ANY WARRANTY; without even the implied warranty of -- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -- * GNU General Public License for more details. -- * -- * You should have received a copy of the GNU General Public License -- * along with this program. If not, see . -- * -- * Authored by: Jason Smith -- */ -- --#include --#include --#include "GeisAdapter.h" -- --GeisAdapter* GeisAdapter::_default = 0; -- --/* static */ --GeisAdapter* --GeisAdapter::Default() --{ -- if (!_default) -- return _default = new GeisAdapter(); // should be using a dictionary -- return _default; --} -- --GeisAdapter::GeisAdapter() --{ -- RegisterRootInstance(); --} -- --GeisAdapter::~GeisAdapter() --{ --} -- --void --GeisAdapter::Run() --{ -- int fd = -1; -- GeisStatus status; -- -- status = geis_configuration_get_value(_root_instance, GEIS_CONFIG_UNIX_FD, &fd); -- -- if (status != GEIS_STATUS_SUCCESS) -- return; -- -- _watch_id = g_io_add_watch(g_io_channel_unix_new(fd), -- G_IO_IN, -- &GeisAdapter::OnWatchIn, -- this); --} -- --gboolean --GeisAdapter::OnWatchIn(GIOChannel* source, GIOCondition condition, gpointer data) --{ -- GeisAdapter* self = static_cast(data); -- geis_event_dispatch(self->_root_instance); -- return true; --} -- --void --GeisAdapter::InputDeviceAdded(void* cookie, GeisInputDeviceId device_id, void* attrs) --{ --} -- -- --void --GeisAdapter::InputDeviceChanged(void* cookie, GeisInputDeviceId device_id, void* attrs) --{ --} -- -- --void --GeisAdapter::InputDeviceRemoved(void* cookie, GeisInputDeviceId device_id, void* attrs) --{ --} -- --void --GeisAdapter::GestureAdded(void* cookie, GeisGestureType gesture_type, GeisGestureId gesture_id, GeisSize count, GeisGestureAttr* attrs) --{ --} -- --void --GeisAdapter::GestureRemoved(void* cookie, GeisGestureType gesture_type, GeisGestureId gesture_id, GeisSize count, GeisGestureAttr* attrs) --{ --} -- --void --GeisAdapter::GestureStart(void* cookie, GeisGestureType gesture_type, GeisGestureId gesture_id, GeisSize count, GeisGestureAttr* attrs) --{ -- GeisAdapter* self = static_cast(cookie); -- -- if (gesture_type == GEIS_GESTURE_PRIMITIVE_DRAG) -- { -- GeisDragData* data = self->ProcessDragGesture(count, attrs); -- data->id = gesture_id; -- self->drag_start.emit(data); -- g_free(data); -- } -- else if (gesture_type == GEIS_GESTURE_PRIMITIVE_ROTATE) -- { -- GeisRotateData* data = self->ProcessRotateGesture(count, attrs); -- data->id = gesture_id; -- self->rotate_start.emit(data); -- g_free(data); -- } -- else if (gesture_type == GEIS_GESTURE_PRIMITIVE_PINCH) -- { -- GeisPinchData* data = self->ProcessPinchGesture(count, attrs); -- data->id = gesture_id; -- self->pinch_start.emit(data); -- g_free(data); -- } -- else if (gesture_type == GEIS_GESTURE_PRIMITIVE_TAP) -- { -- GeisTapData* data = self->ProcessTapGesture(count, attrs); -- data->id = gesture_id; -- self->tap.emit(data); -- g_free(data); -- } -- else if (gesture_type == GEIS_GESTURE_PRIMITIVE_TOUCH) -- { -- GeisTouchData* data = self->ProcessTouchGesture(count, attrs); -- data->id = gesture_id; -- self->touch_start.emit(data); -- g_free(data); -- } --} -- --void --GeisAdapter::GestureUpdate(void* cookie, GeisGestureType gesture_type, GeisGestureId gesture_id, GeisSize count, GeisGestureAttr* attrs) --{ -- GeisAdapter* self = static_cast(cookie); -- -- if (gesture_type == GEIS_GESTURE_PRIMITIVE_DRAG) -- { -- GeisDragData* data = self->ProcessDragGesture(count, attrs); -- data->id = gesture_id; -- self->drag_update.emit(data); -- g_free(data); -- } -- else if (gesture_type == GEIS_GESTURE_PRIMITIVE_ROTATE) -- { -- GeisRotateData* data = self->ProcessRotateGesture(count, attrs); -- data->id = gesture_id; -- self->rotate_update.emit(data); -- g_free(data); -- } -- else if (gesture_type == GEIS_GESTURE_PRIMITIVE_PINCH) -- { -- GeisPinchData* data = self->ProcessPinchGesture(count, attrs); -- data->id = gesture_id; -- self->pinch_update.emit(data); -- g_free(data); -- } -- else if (gesture_type == GEIS_GESTURE_PRIMITIVE_TAP) -- { -- GeisTapData* data = self->ProcessTapGesture(count, attrs); -- data->id = gesture_id; -- self->tap.emit(data); -- g_free(data); -- } -- else if (gesture_type == GEIS_GESTURE_PRIMITIVE_TOUCH) -- { -- GeisTouchData* data = self->ProcessTouchGesture(count, attrs); -- data->id = gesture_id; -- self->touch_update.emit(data); -- g_free(data); -- } --} -- --void --GeisAdapter::GestureFinish(void* cookie, GeisGestureType gesture_type, GeisGestureId gesture_id, GeisSize count, GeisGestureAttr* attrs) --{ -- GeisAdapter* self = static_cast(cookie); -- -- if (gesture_type == GEIS_GESTURE_PRIMITIVE_DRAG) -- { -- GeisDragData* data = self->ProcessDragGesture(count, attrs); -- data->id = gesture_id; -- self->drag_finish.emit(data); -- g_free(data); -- } -- else if (gesture_type == GEIS_GESTURE_PRIMITIVE_ROTATE) -- { -- GeisRotateData* data = self->ProcessRotateGesture(count, attrs); -- data->id = gesture_id; -- self->rotate_finish.emit(data); -- g_free(data); -- } -- else if (gesture_type == GEIS_GESTURE_PRIMITIVE_PINCH) -- { -- GeisPinchData* data = self->ProcessPinchGesture(count, attrs); -- data->id = gesture_id; -- self->pinch_finish.emit(data); -- g_free(data); -- } -- else if (gesture_type == GEIS_GESTURE_PRIMITIVE_TAP) -- { -- GeisTapData* data = self->ProcessTapGesture(count, attrs); -- data->id = gesture_id; -- self->tap.emit(data); -- g_free(data); -- } -- else if (gesture_type == GEIS_GESTURE_PRIMITIVE_TOUCH) -- { -- GeisTouchData* data = self->ProcessTouchGesture(count, attrs); -- data->id = gesture_id; -- self->touch_finish.emit(data); -- g_free(data); -- } --} -- --GeisAdapter::GeisTapData* GeisAdapter::ProcessTapGesture(GeisSize count, GeisGestureAttr* attrs) --{ -- GeisTapData* result = (GeisTapData*) g_malloc0(sizeof(GeisTapData)); -- -- int i; -- for (i = 0; i < (int) count; i++) -- { -- GeisGestureAttr attr = attrs[i]; -- if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_DEVICE_ID)) -- result->device_id = attr.integer_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_CHILD_WINDOW_ID)) -- result->window = (Window) attr.integer_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_TIMESTAMP)) -- result->timestamp = attr.integer_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_FOCUS_X)) -- result->focus_x = attr.integer_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_FOCUS_Y)) -- result->focus_y = attr.integer_val; -- else if (g_str_equal (attr.name, GEIS_GESTURE_ATTRIBUTE_TOUCHES)) -- result->touches = attr.integer_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_GESTURE_NAME)) -- { -- if (!g_strcmp0(attr.string_val, GEIS_GESTURE_TYPE_TAP1)) -- result->touches = 1; -- else if (!g_strcmp0(attr.string_val, GEIS_GESTURE_TYPE_TAP2)) -- result->touches = 2; -- else if (!g_strcmp0(attr.string_val, GEIS_GESTURE_TYPE_TAP3)) -- result->touches = 3; -- else if (!g_strcmp0(attr.string_val, GEIS_GESTURE_TYPE_TAP4)) -- result->touches = 4; -- else if (!g_strcmp0(attr.string_val, GEIS_GESTURE_TYPE_TAP5)) -- result->touches = 5; -- } -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_TAP_TIME)) -- result->tap_length_ms = attr.integer_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_POSITION_X)) -- result->position_x = attr.float_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_POSITION_Y)) -- result->position_y = attr.float_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_BOUNDINGBOX_X1)) -- result->bound_x1 = attr.float_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_BOUNDINGBOX_Y1)) -- result->bound_y1 = attr.float_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_BOUNDINGBOX_X2)) -- result->bound_x2 = attr.float_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_BOUNDINGBOX_Y2)) -- result->bound_y2 = attr.float_val; -- } -- -- return result; --} -- --GeisAdapter::GeisTouchData* GeisAdapter::ProcessTouchGesture(GeisSize count, GeisGestureAttr* attrs) --{ -- GeisTouchData* result = (GeisTouchData*) g_malloc0(sizeof(GeisTouchData)); -- -- int i; -- for (i = 0; i < (int) count; i++) -- { -- GeisGestureAttr attr = attrs[i]; -- if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_DEVICE_ID)) -- result->device_id = attr.integer_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_CHILD_WINDOW_ID)) -- result->window = (Window) attr.integer_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_TIMESTAMP)) -- result->timestamp = attr.integer_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_FOCUS_X)) -- result->focus_x = attr.integer_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_FOCUS_Y)) -- result->focus_y = attr.integer_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_TOUCHES)) -- result->touches = attr.integer_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_BOUNDINGBOX_X1)) -- result->bound_x1 = attr.float_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_BOUNDINGBOX_Y1)) -- result->bound_y1 = attr.float_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_BOUNDINGBOX_X2)) -- result->bound_x2 = attr.float_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_BOUNDINGBOX_Y2)) -- result->bound_y2 = attr.float_val; -- } -- -- return result; --} -- --GeisAdapter::GeisDragData* GeisAdapter::ProcessDragGesture(GeisSize count, GeisGestureAttr* attrs) --{ -- GeisDragData* result = (GeisDragData*) g_malloc0(sizeof(GeisDragData)); -- -- int i; -- for (i = 0; i < (int) count; i++) -- { -- GeisGestureAttr attr = attrs[i]; -- if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_DEVICE_ID)) -- result->device_id = attr.integer_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_CHILD_WINDOW_ID)) -- result->window = (Window) attr.integer_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_TIMESTAMP)) -- result->timestamp = attr.integer_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_FOCUS_X)) -- result->focus_x = attr.integer_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_FOCUS_Y)) -- result->focus_y = attr.integer_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_TOUCHES)) -- result->touches = attr.integer_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_POSITION_X)) -- result->position_x = attr.float_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_POSITION_Y)) -- result->position_y = attr.float_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_VELOCITY_X)) -- result->velocity_x = attr.float_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_VELOCITY_Y)) -- result->velocity_y = attr.float_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_DELTA_X)) -- result->delta_x = attr.float_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_DELTA_Y)) -- result->delta_y = attr.float_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_BOUNDINGBOX_X1)) -- result->bound_x1 = attr.float_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_BOUNDINGBOX_Y1)) -- result->bound_y1 = attr.float_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_BOUNDINGBOX_X2)) -- result->bound_x2 = attr.float_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_BOUNDINGBOX_Y2)) -- result->bound_y2 = attr.float_val; -- } -- -- return result; --} -- --GeisAdapter::GeisPinchData* GeisAdapter::ProcessPinchGesture(GeisSize count, GeisGestureAttr* attrs) --{ -- GeisPinchData* result = (GeisPinchData*) g_malloc0(sizeof(GeisPinchData)); -- -- int i; -- for (i = 0; i < (int) count; i++) -- { -- GeisGestureAttr attr = attrs[i]; -- if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_DEVICE_ID)) -- result->device_id = attr.integer_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_CHILD_WINDOW_ID)) -- result->window = (Window) attr.integer_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_TIMESTAMP)) -- result->timestamp = attr.integer_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_FOCUS_X)) -- result->focus_x = attr.integer_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_FOCUS_Y)) -- result->focus_y = attr.integer_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_TOUCHES)) -- result->touches = attr.integer_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_RADIUS)) -- result->radius = attr.float_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_RADIUS_DELTA)) -- result->radius_delta = attr.float_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_RADIAL_VELOCITY)) -- result->radius_velocity = attr.float_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_BOUNDINGBOX_X1)) -- result->bound_x1 = attr.float_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_BOUNDINGBOX_Y1)) -- result->bound_y1 = attr.float_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_BOUNDINGBOX_X2)) -- result->bound_x2 = attr.float_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_BOUNDINGBOX_Y2)) -- result->bound_y2 = attr.float_val; -- } -- -- return result; --} -- --GeisAdapter::GeisRotateData* GeisAdapter::ProcessRotateGesture(GeisSize count, GeisGestureAttr* attrs) --{ -- GeisRotateData* result = (GeisRotateData*) g_malloc0(sizeof(GeisRotateData)); -- -- int i; -- for (i = 0; i < (int) count; i++) -- { -- GeisGestureAttr attr = attrs[i]; -- if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_DEVICE_ID)) -- result->device_id = attr.integer_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_CHILD_WINDOW_ID)) -- result->window = (Window) attr.integer_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_TIMESTAMP)) -- result->timestamp = attr.integer_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_FOCUS_X)) -- result->focus_x = attr.integer_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_FOCUS_Y)) -- result->focus_y = attr.integer_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_TOUCHES)) -- result->touches = attr.integer_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_ANGLE)) -- result->angle = attr.float_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_ANGLE_DELTA)) -- result->angle_delta = attr.float_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_ANGULAR_VELOCITY)) -- result->angle_velocity = attr.float_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_BOUNDINGBOX_X1)) -- result->bound_x1 = attr.float_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_BOUNDINGBOX_Y1)) -- result->bound_y1 = attr.float_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_BOUNDINGBOX_X2)) -- result->bound_x2 = attr.float_val; -- else if (g_str_equal(attr.name, GEIS_GESTURE_ATTRIBUTE_BOUNDINGBOX_Y2)) -- result->bound_y2 = attr.float_val; -- } -- -- return result; --} -- --static const char* s_gestures[] = --{ -- GEIS_GESTURE_TYPE_DRAG3, GEIS_GESTURE_TYPE_TAP3, GEIS_GESTURE_TYPE_ROTATE3, GEIS_GESTURE_TYPE_PINCH3, GEIS_GESTURE_TYPE_TOUCH3, -- GEIS_GESTURE_TYPE_DRAG4, GEIS_GESTURE_TYPE_TAP4, GEIS_GESTURE_TYPE_ROTATE4, GEIS_GESTURE_TYPE_PINCH4, GEIS_GESTURE_TYPE_TOUCH4, -- GEIS_GESTURE_TYPE_SYSTEM, -- NULL --}; -- --void --GeisAdapter::RegisterRootInstance() --{ -- static GeisInputFuncs input_funcs = -- { -- &GeisAdapter::InputDeviceAdded, -- &GeisAdapter::InputDeviceChanged, -- &GeisAdapter::InputDeviceRemoved -- }; -- -- static GeisGestureFuncs gesture_funcs = -- { -- &GeisAdapter::GestureAdded, -- &GeisAdapter::GestureRemoved, -- &GeisAdapter::GestureStart, -- &GeisAdapter::GestureUpdate, -- &GeisAdapter::GestureFinish -- }; -- -- GeisStatus status = GEIS_UNKNOWN_ERROR; -- -- GeisXcbWinInfo xcb_win_info; -- xcb_win_info.display_name = NULL, -- xcb_win_info.screenp = NULL, -- xcb_win_info.window_id = gdk_x11_get_default_root_xwindow(); -- -- GeisWinInfo win_info = -- { -- GEIS_XCB_FULL_WINDOW, -- &xcb_win_info -- }; -- GeisInstance instance; -- -- status = geis_init(&win_info, &instance); -- if (status != GEIS_STATUS_SUCCESS) -- { -- fprintf(stderr, "error in geis_init\n"); -- return; -- } -- -- status = geis_input_devices(instance, &input_funcs, this); -- if (status != GEIS_STATUS_SUCCESS) -- { -- fprintf(stderr, "error subscribing to input devices\n"); -- return;; -- } -- -- status = geis_subscribe(instance, -- GEIS_ALL_INPUT_DEVICES, -- s_gestures, -- &gesture_funcs, -- this); -- if (status != GEIS_STATUS_SUCCESS) -- { -- fprintf(stderr, "error subscribing to gestures\n"); -- return; -- } -- -- _root_instance = instance; --} -diff -Naur unity-4.24.0.orig/plugins/unityshell/src/GeisAdapter.h unity-4.24.0/plugins/unityshell/src/GeisAdapter.h ---- unity-4.24.0.orig/plugins/unityshell/src/GeisAdapter.h 2011-10-12 14:02:40.000000000 +0200 -+++ unity-4.24.0/plugins/unityshell/src/GeisAdapter.h 1970-01-01 01:00:00.000000000 +0100 -@@ -1,177 +0,0 @@ --// -*- Mode: C++; indent-tabs-mode: nil; tab-width: 2 -*- --/* -- * Copyright (C) 2010 Canonical Ltd -- * -- * This program is free software: you can redistribute it and/or modify -- * it under the terms of the GNU General Public License version 3 as -- * published by the Free Software Foundation. -- * -- * This program is distributed in the hope that it will be useful, -- * but WITHOUT ANY WARRANTY; without even the implied warranty of -- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -- * GNU General Public License for more details. -- * -- * You should have received a copy of the GNU General Public License -- * aint with this program. If not, see . -- * -- * Authored by: Jason Smith -- */ -- --#ifndef GEISADAPTER_H --#define GEISADAPTER_H -- --/* Compiz */ --#include --#include --#include -- --class GeisAdapter : public sigc::trackable --{ --public: -- static GeisAdapter* Default(); -- -- ~GeisAdapter(); -- -- void Run(); -- -- typedef struct _GeisTapData -- { -- int id; -- int device_id; -- Window window; -- int touches; -- int timestamp; -- int focus_x; -- int focus_y; -- int tap_length_ms; -- float position_x; -- float position_y; -- float bound_x1; -- float bound_y1; -- float bound_x2; -- float bound_y2; -- } GeisTapData; -- -- typedef struct _GeisDragData -- { -- int id; -- int device_id; -- Window window; -- int touches; -- int timestamp; -- int focus_x; -- int focus_y; -- float delta_x; -- float delta_y; -- float velocity_x; -- float velocity_y; -- float position_x; -- float position_y; -- float bound_x1; -- float bound_y1; -- float bound_x2; -- float bound_y2; -- } GeisDragData; -- -- typedef struct _GeisRotateData -- { -- int id; -- int device_id; -- Window window; -- int touches; -- int timestamp; -- int focus_x; -- int focus_y; -- float angle; -- float angle_delta; -- float angle_velocity; -- float bound_x1; -- float bound_y1; -- float bound_x2; -- float bound_y2; -- } GeisRotateData; -- -- typedef struct _GeisPinchData -- { -- int id; -- int device_id; -- Window window; -- int touches; -- int timestamp; -- int focus_x; -- int focus_y; -- float radius; -- float radius_delta; -- float radius_velocity; -- float bound_x1; -- float bound_y1; -- float bound_x2; -- float bound_y2; -- } GeisPinchData; -- -- typedef struct _GeisTouchData -- { -- int id; -- int device_id; -- Window window; -- int touches; -- int timestamp; -- int focus_x; -- int focus_y; -- float bound_x1; -- float bound_y1; -- float bound_x2; -- float bound_y2; -- } GeisTouchData; -- -- sigc::signal tap; -- -- sigc::signal drag_start; -- sigc::signal drag_update; -- sigc::signal drag_finish; -- -- sigc::signal rotate_start; -- sigc::signal rotate_update; -- sigc::signal rotate_finish; -- -- sigc::signal pinch_start; -- sigc::signal pinch_update; -- sigc::signal pinch_finish; -- -- sigc::signal touch_start; -- sigc::signal touch_update; -- sigc::signal touch_finish; --protected: -- GeisAdapter(); -- -- static gboolean OnWatchIn(GIOChannel* source, GIOCondition condition, gpointer data); -- -- static void InputDeviceAdded(void* cookie, GeisInputDeviceId device_id, void* attrs); -- static void InputDeviceChanged(void* cookie, GeisInputDeviceId device_id, void* attrs); -- static void InputDeviceRemoved(void* cookie, GeisInputDeviceId device_id, void* attrs); -- -- static void GestureAdded(void* cookie, GeisGestureType gesture_type, GeisGestureId gesture_id, GeisSize attr_count, GeisGestureAttr* attrs); -- static void GestureRemoved(void* cookie, GeisGestureType gesture_type, GeisGestureId gesture_id, GeisSize attr_count, GeisGestureAttr* attrs); -- -- static void GestureStart(void* cookie, GeisGestureType gesture_type, GeisGestureId gesture_id, GeisSize attr_count, GeisGestureAttr* attrs); -- static void GestureUpdate(void* cookie, GeisGestureType gesture_type, GeisGestureId gesture_id, GeisSize attr_count, GeisGestureAttr* attrs); -- static void GestureFinish(void* cookie, GeisGestureType gesture_type, GeisGestureId gesture_id, GeisSize attr_count, GeisGestureAttr* attrs); -- -- GeisTapData* ProcessTapGesture(GeisSize attr_count, GeisGestureAttr* attrs); -- GeisDragData* ProcessDragGesture(GeisSize attr_count, GeisGestureAttr* attrs); -- GeisPinchData* ProcessPinchGesture(GeisSize attr_count, GeisGestureAttr* attrs); -- GeisRotateData* ProcessRotateGesture(GeisSize attr_count, GeisGestureAttr* attrs); -- GeisTouchData* ProcessTouchGesture(GeisSize attr_count, GeisGestureAttr* attrs); -- --private: -- void RegisterRootInstance(); -- -- GeisInstance _root_instance; -- -- guint _watch_id; -- -- static GeisAdapter* _default; -- --}; -- --#endif -diff -Naur unity-4.24.0.orig/plugins/unityshell/src/GestureEngine.cpp unity-4.24.0/plugins/unityshell/src/GestureEngine.cpp ---- unity-4.24.0.orig/plugins/unityshell/src/GestureEngine.cpp 2011-10-12 14:02:40.000000000 +0200 -+++ unity-4.24.0/plugins/unityshell/src/GestureEngine.cpp 1970-01-01 01:00:00.000000000 +0100 -@@ -1,296 +0,0 @@ --/* -- * GestureEngine.cpp -- * This file is part of Unity -- * -- * Copyright (C) 2011 - Canonical Ltd. -- * -- * Unity is free software; you can redistribute it and/or modify -- * it under the terms of the GNU General Public License as published by -- * the Free Software Foundation; either version 2 of the License, or -- * (at your option) any later version. -- * -- * Unity is distributed in the hope that it will be useful, -- * but WITHOUT ANY WARRANTY; without even the implied warranty of -- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -- * GNU General Public License for more details. -- * -- * You should have received a copy of the GNU General Public License -- * along with Unity; if not, write to the Free Software -- * Foundation, Inc., 51 Franklin St, Fifth Floor, -- * Boston, MA 02110-1301 USA -- */ -- --#include -- --#include "ubus-server.h" --#include "UBusMessages.h" --#include "GestureEngine.h" --#include "PluginAdapter.h" -- --GestureEngine::GestureEngine(CompScreen* screen) --{ -- _screen = screen; -- -- _drag_id = 0; -- _pinch_id = 0; -- _touch_id = 0; -- _drag_grab = 0; -- _pinch_grab = 0; -- _fleur_cursor = XCreateFontCursor (screen->dpy (), XC_fleur); -- -- GeisAdapter* adapter = GeisAdapter::Default(); -- -- adapter->tap.connect(sigc::mem_fun(this, &GestureEngine::OnTap)); -- -- adapter->drag_start.connect(sigc::mem_fun(this, &GestureEngine::OnDragStart)); -- adapter->drag_update.connect(sigc::mem_fun(this, &GestureEngine::OnDragUpdate)); -- adapter->drag_finish.connect(sigc::mem_fun(this, &GestureEngine::OnDragFinish)); -- -- adapter->rotate_start.connect(sigc::mem_fun(this, &GestureEngine::OnRotateStart)); -- adapter->rotate_update.connect(sigc::mem_fun(this, &GestureEngine::OnRotateUpdate)); -- adapter->rotate_finish.connect(sigc::mem_fun(this, &GestureEngine::OnRotateFinish)); -- -- adapter->pinch_start.connect(sigc::mem_fun(this, &GestureEngine::OnPinchStart)); -- adapter->pinch_update.connect(sigc::mem_fun(this, &GestureEngine::OnPinchUpdate)); -- adapter->pinch_finish.connect(sigc::mem_fun(this, &GestureEngine::OnPinchFinish)); -- -- adapter->touch_start.connect(sigc::mem_fun(this, &GestureEngine::OnTouchStart)); -- adapter->touch_update.connect(sigc::mem_fun(this, &GestureEngine::OnTouchUpdate)); -- adapter->touch_finish.connect(sigc::mem_fun(this, &GestureEngine::OnTouchFinish)); --} -- --GestureEngine::~GestureEngine() --{ -- if (_fleur_cursor) -- XFreeCursor (screen->dpy (), _fleur_cursor); --} -- --void --GestureEngine::OnTap(GeisAdapter::GeisTapData* data) --{ -- if (data->touches == 4) -- { -- UBusServer* ubus = ubus_server_get_default(); -- ubus_server_send_message(ubus, UBUS_DASH_EXTERNAL_ACTIVATION, NULL); -- } --} -- --CompWindow* --GestureEngine::FindCompWindow(Window window) --{ -- CompWindow* result = _screen->findTopLevelWindow(window); -- -- while (!result) -- { -- Window parent, root; -- Window* children = NULL; -- unsigned int nchildren; -- -- XQueryTree(_screen->dpy(), window, &root, &parent, &children, &nchildren); -- -- if (children) -- XFree(children); -- -- if (parent == root) -- break; -- -- window = parent; -- result = _screen->findTopLevelWindow(window); -- } -- -- if (result) -- { -- if (!(result->type() & (CompWindowTypeUtilMask | -- CompWindowTypeNormalMask | -- CompWindowTypeDialogMask | -- CompWindowTypeModalDialogMask))) -- result = 0; -- } -- -- return result; --} -- --void --GestureEngine::OnDragStart(GeisAdapter::GeisDragData* data) --{ -- if (data->touches == 3) -- { -- _drag_window = FindCompWindow(data->window); -- -- -- if (!_drag_window) -- return; -- -- if (!(_drag_window->actions() & CompWindowActionMoveMask)) -- { -- _drag_window = 0; -- return; -- } -- -- /* Don't allow windows to be dragged if completely maximized */ -- if ((_drag_window->state() & MAXIMIZE_STATE) == MAXIMIZE_STATE) -- { -- _drag_window = 0; -- return; -- } -- -- if (_drag_grab) -- _screen->removeGrab(_drag_grab, NULL); -- _drag_id = data->id; -- _drag_grab = _screen->pushGrab(_fleur_cursor, "unity"); -- _drag_window->grabNotify (_drag_window->serverGeometry ().x (), -- _drag_window->serverGeometry ().y (), -- 0, CompWindowGrabMoveMask | CompWindowGrabButtonMask); -- } --} -- --/* FIXME: CompScreen::warpPointer filters out motion events which -- * other plugins may need to process, but for most cases in core -- * they should be filtered out. */ --void --GestureEngine::OnDragUpdate(GeisAdapter::GeisDragData* data) --{ -- if (_drag_id == data->id && _drag_window) -- { -- unsigned int px = std::max (std::min (pointerX + static_cast (data->delta_x), screen->width ()), 0); -- unsigned int py = std::max (std::min (pointerY + static_cast (data->delta_y), screen->height ()), 0); -- -- if (_drag_window->state () & CompWindowStateMaximizedVertMask) -- py = pointerY; -- if (_drag_window->state () & CompWindowStateMaximizedHorzMask) -- px = pointerX; -- -- XWarpPointer(screen->dpy (), -- None, screen->root (), -- 0, 0, 0, 0, -- px, py); -- -- XSync(screen->dpy (), false); -- _drag_window->move(px - pointerX, py - pointerY, false); -- -- pointerX = px; -- pointerY = py; -- } --} -- --void --GestureEngine::OnDragFinish(GeisAdapter::GeisDragData* data) --{ -- if (_drag_id == data->id && _drag_window) -- { -- _drag_window->ungrabNotify (); -- _drag_window->syncPosition(); -- EndDrag(); -- } --} -- --void --GestureEngine::EndDrag() --{ -- if (_drag_id && _drag_window) -- { -- _screen->removeGrab(_drag_grab, NULL); -- _drag_grab = 0; -- _drag_window = 0; -- _drag_id = 0; -- } --} -- --void --GestureEngine::OnRotateStart(GeisAdapter::GeisRotateData* data) --{ -- --} --void --GestureEngine::OnRotateUpdate(GeisAdapter::GeisRotateData* data) --{ -- --} --void --GestureEngine::OnRotateFinish(GeisAdapter::GeisRotateData* data) --{ -- --} -- --void --GestureEngine::OnTouchStart(GeisAdapter::GeisTouchData* data) --{ -- if (data->touches == 3) -- { -- CompWindow* result = FindCompWindow(data->window); -- -- if (result) -- { -- PluginAdapter::Default()->ShowGrabHandles(result, false); -- _touch_id = data->id; -- _touch_window = result; -- } -- } --} -- --void --GestureEngine::OnTouchUpdate(GeisAdapter::GeisTouchData* data) --{ -- --} -- --void --GestureEngine::OnTouchFinish(GeisAdapter::GeisTouchData* data) --{ -- if (_touch_id == data->id) -- { -- if (_touch_window) -- PluginAdapter::Default()->ShowGrabHandles(_touch_window, true); -- _touch_id = 0; -- _touch_window = 0; -- } --} -- --void --GestureEngine::OnPinchStart(GeisAdapter::GeisPinchData* data) --{ -- if (data->touches == 3) -- { -- _pinch_window = FindCompWindow(data->window); -- -- if (!_pinch_window) -- return; -- -- _pinch_id = data->id; -- _pinch_start_radius = data->radius; -- -- if (_pinch_grab) -- _screen->removeGrab(_pinch_grab, NULL); -- _pinch_grab = _screen->pushGrab(_screen->invisibleCursor(), "unity"); -- } --} --void --GestureEngine::OnPinchUpdate(GeisAdapter::GeisPinchData* data) --{ -- if (data->id != _pinch_id) -- return; -- -- float delta_radius = data->radius - _pinch_start_radius; -- if (delta_radius > 110.0f) -- { -- _pinch_window->maximize(MAXIMIZE_STATE); -- _pinch_start_radius = data->radius; -- EndDrag(); -- } -- else if (delta_radius < -110.0f) -- { -- _pinch_window->maximize(0); -- _pinch_start_radius = data->radius; -- EndDrag(); -- } --} --void --GestureEngine::OnPinchFinish(GeisAdapter::GeisPinchData* data) --{ -- if (_pinch_id == data->id && _pinch_window) -- { -- _screen->removeGrab(_pinch_grab, NULL); -- _pinch_grab = 0; -- _pinch_id = 0; -- } --} -diff -Naur unity-4.24.0.orig/plugins/unityshell/src/GestureEngine.h unity-4.24.0/plugins/unityshell/src/GestureEngine.h ---- unity-4.24.0.orig/plugins/unityshell/src/GestureEngine.h 2011-10-12 14:02:40.000000000 +0200 -+++ unity-4.24.0/plugins/unityshell/src/GestureEngine.h 1970-01-01 01:00:00.000000000 +0100 -@@ -1,70 +0,0 @@ --/* -- * GestureEngine.h -- * This file is part of Unity -- * -- * Copyright (C) 2011 - Canonical Ltd. -- * -- * Unity is free software; you can redistribute it and/or modify -- * it under the terms of the GNU General Public License as published by -- * the Free Software Foundation; either version 2 of the License, or -- * (at your option) any later version. -- * -- * Unity is distributed in the hope that it will be useful, -- * but WITHOUT ANY WARRANTY; without even the implied warranty of -- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -- * GNU General Public License for more details. -- * -- * You should have received a copy of the GNU General Public License -- * along with Unity; if not, write to the Free Software -- * Foundation, Inc., 51 Franklin St, Fifth Floor, -- * Boston, MA 02110-1301 USA -- */ -- --#include -- --#include --#include --#include "GeisAdapter.h" -- --class GestureEngine : public sigc::trackable --{ --public: -- GestureEngine(CompScreen* screen); -- virtual ~GestureEngine(); -- -- void OnTap(GeisAdapter::GeisTapData* data); -- -- void OnDragStart(GeisAdapter::GeisDragData* data); -- void OnDragUpdate(GeisAdapter::GeisDragData* data); -- void OnDragFinish(GeisAdapter::GeisDragData* data); -- -- void OnRotateStart(GeisAdapter::GeisRotateData* data); -- void OnRotateUpdate(GeisAdapter::GeisRotateData* data); -- void OnRotateFinish(GeisAdapter::GeisRotateData* data); -- -- void OnPinchStart(GeisAdapter::GeisPinchData* data); -- void OnPinchUpdate(GeisAdapter::GeisPinchData* data); -- void OnPinchFinish(GeisAdapter::GeisPinchData* data); -- -- void OnTouchStart(GeisAdapter::GeisTouchData* data); -- void OnTouchUpdate(GeisAdapter::GeisTouchData* data); -- void OnTouchFinish(GeisAdapter::GeisTouchData* data); -- -- void EndDrag(); --private: -- CompWindow* FindCompWindow(Window window); -- -- CompScreen* _screen; -- CompWindow* _drag_window; -- CompWindow* _pinch_window; -- CompWindow* _touch_window; -- CompScreen::GrabHandle _drag_grab; -- CompScreen::GrabHandle _pinch_grab; -- -- int _drag_id; -- int _pinch_id; -- int _touch_id; -- -- float _pinch_start_radius; -- Cursor _fleur_cursor; --}; -diff -Naur unity-4.24.0.orig/plugins/unityshell/src/Launcher.cpp unity-4.24.0/plugins/unityshell/src/Launcher.cpp ---- unity-4.24.0.orig/plugins/unityshell/src/Launcher.cpp 2011-10-12 14:02:40.000000000 +0200 -+++ unity-4.24.0/plugins/unityshell/src/Launcher.cpp 2011-11-12 18:10:42.702441566 +0100 -@@ -187,11 +187,6 @@ - plugin_adapter.compiz_screen_viewport_switch_started.connect(sigc::mem_fun(this, &Launcher::OnViewPortSwitchStarted)); - plugin_adapter.compiz_screen_viewport_switch_ended.connect(sigc::mem_fun(this, &Launcher::OnViewPortSwitchEnded)); - -- GeisAdapter& adapter = *(GeisAdapter::Default()); -- adapter.drag_start.connect(sigc::mem_fun(this, &Launcher::OnDragStart)); -- adapter.drag_update.connect(sigc::mem_fun(this, &Launcher::OnDragUpdate)); -- adapter.drag_finish.connect(sigc::mem_fun(this, &Launcher::OnDragFinish)); -- - display.changed.connect(sigc::mem_fun(this, &Launcher::OnDisplayChanged)); - - _current_icon = NULL; -@@ -397,50 +392,6 @@ - } - - void --Launcher::OnDragStart(GeisAdapter::GeisDragData* data) --{ -- if (_drag_out_id && _drag_out_id == data->id) -- return; -- -- if (data->touches == 4) -- { -- _drag_out_id = data->id; -- if (_hidden) -- { -- _drag_out_delta_x = 0.0f; -- } -- else -- { -- _drag_out_delta_x = DRAG_OUT_PIXELS; -- _hide_machine->SetQuirk(LauncherHideMachine::MT_DRAG_OUT, false); -- } -- } --} -- --void --Launcher::OnDragUpdate(GeisAdapter::GeisDragData* data) --{ -- if (data->id == _drag_out_id) -- { -- _drag_out_delta_x = CLAMP(_drag_out_delta_x + data->delta_x, 0.0f, DRAG_OUT_PIXELS); -- EnsureAnimation(); -- } --} -- --void --Launcher::OnDragFinish(GeisAdapter::GeisDragData* data) --{ -- if (data->id == _drag_out_id) -- { -- if (_drag_out_delta_x >= DRAG_OUT_PIXELS - 90.0f) -- _hide_machine->SetQuirk(LauncherHideMachine::MT_DRAG_OUT, true); -- SetTimeStruct(&_times[TIME_DRAG_OUT], &_times[TIME_DRAG_OUT], ANIM_DURATION_SHORT); -- _drag_out_id = 0; -- EnsureAnimation(); -- } --} -- --void - Launcher::startKeyNavMode() - { - SetStateKeyNav(true); -diff -Naur unity-4.24.0.orig/plugins/unityshell/src/Launcher.h unity-4.24.0/plugins/unityshell/src/Launcher.h ---- unity-4.24.0.orig/plugins/unityshell/src/Launcher.h 2011-10-12 14:02:40.000000000 +0200 -+++ unity-4.24.0/plugins/unityshell/src/Launcher.h 2011-11-12 18:11:00.897995790 +0100 -@@ -32,7 +32,6 @@ - #include "BackgroundEffectHelper.h" - #include "DNDCollectionWindow.h" - #include "DndData.h" --#include "GeisAdapter.h" - #include "Introspectable.h" - #include "LauncherIcon.h" - #include "LauncherDragWindow.h" -@@ -247,10 +246,6 @@ - void OnWindowMapped(guint32 xid); - void OnWindowUnmapped(guint32 xid); - -- void OnDragStart(GeisAdapter::GeisDragData* data); -- void OnDragUpdate(GeisAdapter::GeisDragData* data); -- void OnDragFinish(GeisAdapter::GeisDragData* data); -- - void OnPluginStateChanged(); - - void OnViewPortSwitchStarted(); -diff -Naur unity-4.24.0.orig/plugins/unityshell/src/unityshell.cpp unity-4.24.0/plugins/unityshell/src/unityshell.cpp ---- unity-4.24.0.orig/plugins/unityshell/src/unityshell.cpp 2011-10-12 14:02:40.000000000 +0200 -+++ unity-4.24.0/plugins/unityshell/src/unityshell.cpp 2011-11-12 18:11:53.241462268 +0100 -@@ -29,7 +29,6 @@ - #include "Launcher.h" - #include "LauncherIcon.h" - #include "LauncherController.h" --#include "GeisAdapter.h" - #include "DevicesSettings.h" - #include "PluginAdapter.h" - #include "QuicklistManager.h" -@@ -96,7 +95,6 @@ - , controller(nullptr) - , panelController(nullptr) - , switcherController(nullptr) -- , gestureEngine(nullptr) - , wt(nullptr) - , launcherWindow(nullptr) - , panelWindow(nullptr) -@@ -294,9 +292,6 @@ - g_timeout_add(0, &UnityScreen::initPluginActions, this); - super_keypressed_ = false; - -- GeisAdapter::Default()->Run(); -- gestureEngine = new GestureEngine(screen); -- - CompString name(PKGDATADIR"/panel-shadow.png"); - CompString pname("unityshell"); - CompSize size(1, 20); -diff -Naur unity-4.24.0.orig/plugins/unityshell/src/unityshell.h unity-4.24.0/plugins/unityshell/src/unityshell.h ---- unity-4.24.0.orig/plugins/unityshell/src/unityshell.h 2011-10-12 14:02:40.000000000 +0200 -+++ unity-4.24.0/plugins/unityshell/src/unityshell.h 2011-11-12 18:12:14.780145431 +0100 -@@ -38,7 +38,6 @@ - #include "PanelController.h" - #include "PlacesStyle.h" - #include "UScreen.h" --#include "GestureEngine.h" - #include "DebugDBusInterface.h" - #include "SwitcherController.h" - #include "UBusWrapper.h" -@@ -281,7 +280,6 @@ - DashController::Ptr dashController; - PanelController* panelController; - SwitcherController* switcherController; -- GestureEngine* gestureEngine; - nux::WindowThread* wt; - nux::BaseWindow* launcherWindow; - nux::BaseWindow* panelWindow; -diff -Naur unity-4.24.0.orig/tests/CMakeLists.txt unity-4.24.0/tests/CMakeLists.txt ---- unity-4.24.0.orig/tests/CMakeLists.txt 2011-10-12 14:02:40.000000000 +0200 -+++ unity-4.24.0/tests/CMakeLists.txt 2011-11-12 18:12:39.441970984 +0100 -@@ -260,8 +260,6 @@ - ${UNITY_SRC}/LauncherHoverMachine.h - ${UNITY_SRC}/LauncherDragWindow.cpp - ${UNITY_SRC}/LauncherDragWindow.h -- ${UNITY_SRC}/GeisAdapter.cpp -- ${UNITY_SRC}/GeisAdapter.h - ${UNITY_SRC}/WindowManager.h - ${UNITY_SRC}/WindowManager.cpp - ${UNITY_SRC}/IconRenderer.cpp +diff -Naur unity-5.0.0.orig/CMakeLists.txt unity-5.0.0/CMakeLists.txt +--- unity-5.0.0.orig/CMakeLists.txt 2012-01-12 17:47:07.000000000 +0100 ++++ unity-5.0.0/CMakeLists.txt 2012-01-15 09:45:17.010953206 +0100 +@@ -119,7 +119,7 @@ + # + # Compiz Plugins + # +-set (UNITY_PLUGIN_DEPS "compiz;nux-2.0 >= 2.0.0;libbamf3;dee-1.0;gio-2.0;gio-unix-2.0;dbusmenu-glib-0.4;x11;libstartup-notification-1.0;gthread-2.0;indicator3-0.4;atk;unity-misc >= 0.4.0;gconf-2.0;libutouch-geis;gtk+-3.0 >= 3.1;sigc++-2.0;json-glib-1.0;libnotify;gnome-desktop-3.0;gdu") ++set (UNITY_PLUGIN_DEPS "compiz;nux-2.0 >= 2.0.0;libbamf3;dee-1.0;gio-2.0;gio-unix-2.0;dbusmenu-glib-0.4;x11;libstartup-notification-1.0;gthread-2.0;indicator3-0.4;atk;unity-misc >= 0.4.0;gconf-2.0;gtk+-3.0 >= 3.1;sigc++-2.0;json-glib-1.0;libnotify;gnome-desktop-3.0;gdu") + + add_subdirectory(plugins/unityshell) + add_subdirectory(plugins/gtkloader) +diff -Naur unity-5.0.0.orig/plugins/unityshell/src/Launcher.cpp unity-5.0.0/plugins/unityshell/src/Launcher.cpp +--- unity-5.0.0.orig/plugins/unityshell/src/Launcher.cpp 2012-01-12 17:47:07.000000000 +0100 ++++ unity-5.0.0/plugins/unityshell/src/Launcher.cpp 2012-01-15 09:55:01.696575516 +0100 +@@ -192,11 +192,6 @@ + plugin_adapter.compiz_screen_viewport_switch_started.connect(sigc::mem_fun(this, &Launcher::OnViewPortSwitchStarted)); + plugin_adapter.compiz_screen_viewport_switch_ended.connect(sigc::mem_fun(this, &Launcher::OnViewPortSwitchEnded)); + +- GeisAdapter& adapter = *(GeisAdapter::Default()); +- adapter.drag_start.connect(sigc::mem_fun(this, &Launcher::OnDragStart)); +- adapter.drag_update.connect(sigc::mem_fun(this, &Launcher::OnDragUpdate)); +- adapter.drag_finish.connect(sigc::mem_fun(this, &Launcher::OnDragFinish)); +- + display.changed.connect(sigc::mem_fun(this, &Launcher::OnDisplayChanged)); + + _current_icon = NULL; +@@ -402,50 +397,6 @@ + } + + void +-Launcher::OnDragStart(GeisAdapter::GeisDragData* data) +-{ +- if (_drag_out_id && _drag_out_id == data->id) +- return; +- +- if (data->touches == 4) +- { +- _drag_out_id = data->id; +- if (_hidden) +- { +- _drag_out_delta_x = 0.0f; +- } +- else +- { +- _drag_out_delta_x = DRAG_OUT_PIXELS; +- _hide_machine->SetQuirk(LauncherHideMachine::MT_DRAG_OUT, false); +- } +- } +-} +- +-void +-Launcher::OnDragUpdate(GeisAdapter::GeisDragData* data) +-{ +- if (data->id == _drag_out_id) +- { +- _drag_out_delta_x = CLAMP(_drag_out_delta_x + data->delta_x, 0.0f, DRAG_OUT_PIXELS); +- EnsureAnimation(); +- } +-} +- +-void +-Launcher::OnDragFinish(GeisAdapter::GeisDragData* data) +-{ +- if (data->id == _drag_out_id) +- { +- if (_drag_out_delta_x >= DRAG_OUT_PIXELS - 90.0f) +- _hide_machine->SetQuirk(LauncherHideMachine::MT_DRAG_OUT, true); +- SetTimeStruct(&_times[TIME_DRAG_OUT], &_times[TIME_DRAG_OUT], ANIM_DURATION_SHORT); +- _drag_out_id = 0; +- EnsureAnimation(); +- } +-} +- +-void + Launcher::startKeyNavMode() + { + SetStateKeyNav(true); +diff -Naur unity-5.0.0.orig/plugins/unityshell/src/Launcher.h unity-5.0.0/plugins/unityshell/src/Launcher.h +--- unity-5.0.0.orig/plugins/unityshell/src/Launcher.h 2012-01-12 17:47:07.000000000 +0100 ++++ unity-5.0.0/plugins/unityshell/src/Launcher.h 2012-01-15 09:51:33.363116092 +0100 +@@ -32,7 +32,6 @@ + #include "BackgroundEffectHelper.h" + #include "DNDCollectionWindow.h" + #include "DndData.h" +-#include "GeisAdapter.h" + #include "Introspectable.h" + #include "LauncherDragWindow.h" + #include "LauncherHideMachine.h" +@@ -246,10 +245,6 @@ + void OnWindowMapped(guint32 xid); + void OnWindowUnmapped(guint32 xid); + +- void OnDragStart(GeisAdapter::GeisDragData* data); +- void OnDragUpdate(GeisAdapter::GeisDragData* data); +- void OnDragFinish(GeisAdapter::GeisDragData* data); +- + void OnPluginStateChanged(); + + void OnViewPortSwitchStarted(); +diff -Naur unity-5.0.0.orig/plugins/unityshell/src/unityshell.cpp unity-5.0.0/plugins/unityshell/src/unityshell.cpp +--- unity-5.0.0.orig/plugins/unityshell/src/unityshell.cpp 2012-01-12 17:47:07.000000000 +0100 ++++ unity-5.0.0/plugins/unityshell/src/unityshell.cpp 2012-01-15 09:49:39.521844903 +0100 +@@ -29,7 +29,6 @@ + #include "Launcher.h" + #include "LauncherIcon.h" + #include "LauncherController.h" +-#include "GeisAdapter.h" + #include "DevicesSettings.h" + #include "PluginAdapter.h" + #include "QuicklistManager.h" +@@ -97,7 +96,6 @@ + , screen(screen) + , cScreen(CompositeScreen::get(screen)) + , gScreen(GLScreen::get(screen)) +- , gestureEngine(nullptr) + , wt(nullptr) + , panelWindow(nullptr) + , debugger(nullptr) +@@ -311,9 +309,6 @@ + g_idle_add_full (G_PRIORITY_DEFAULT, &UnityScreen::initPluginActions, this, NULL); + super_keypressed_ = false; + +- GeisAdapter::Default()->Run(); +- gestureEngine = new GestureEngine(screen); +- + CompString name(PKGDATADIR"/panel-shadow.png"); + CompString pname("unityshell"); + CompSize size(1, 20); +diff -Naur unity-5.0.0.orig/plugins/unityshell/src/unityshell.h unity-5.0.0/plugins/unityshell/src/unityshell.h +--- unity-5.0.0.orig/plugins/unityshell/src/unityshell.h 2012-01-12 17:47:07.000000000 +0100 ++++ unity-5.0.0/plugins/unityshell/src/unityshell.h 2012-01-15 09:49:39.521844903 +0100 +@@ -43,7 +43,6 @@ + #include "PanelController.h" + #include "PanelStyle.h" + #include "UScreen.h" +-#include "GestureEngine.h" + #include "DebugDBusInterface.h" + #include "SwitcherController.h" + #include "UBusWrapper.h" +@@ -253,7 +252,6 @@ + panel::Controller::Ptr panel_controller_; + switcher::Controller::Ptr switcher_controller_; + +- GestureEngine* gestureEngine; + nux::WindowThread* wt; + nux::BaseWindow* panelWindow; + nux::Geometry lastTooltipArea; +diff -Naur unity-5.0.0.orig/standalone-clients/CMakeLists.txt unity-5.0.0/standalone-clients/CMakeLists.txt +--- unity-5.0.0.orig/standalone-clients/CMakeLists.txt 2012-01-12 17:47:07.000000000 +0100 ++++ unity-5.0.0/standalone-clients/CMakeLists.txt 2012-01-15 09:46:58.576139550 +0100 +@@ -235,8 +235,6 @@ + ${UNITY_SRC}/LauncherHoverMachine.h + ${UNITY_SRC}/LauncherDragWindow.cpp + ${UNITY_SRC}/LauncherDragWindow.h +- ${UNITY_SRC}/GeisAdapter.cpp +- ${UNITY_SRC}/GeisAdapter.h + ${UNITY_SRC}/WindowManager.h + ${UNITY_SRC}/WindowManager.cpp + ${UNITY_SRC}/IconRenderer.cpp diff --git a/unity/make-tests-optional.patch b/unity/make-tests-optional.patch dissimilarity index 77% index 19baebf05..2c9f3a7d0 100644 --- a/unity/make-tests-optional.patch +++ b/unity/make-tests-optional.patch @@ -1,17 +1,21 @@ -diff -Naur unity-4.24.0.orig/CMakeLists.txt unity-4.24.0/CMakeLists.txt ---- unity-4.24.0.orig/CMakeLists.txt 2011-10-12 14:02:40.000000000 +0200 -+++ unity-4.24.0/CMakeLists.txt 2011-11-26 06:25:07.839545754 +0100 -@@ -4,7 +4,12 @@ - - include (cmake/Documentation.cmake) - --subdirs (doc services tests tools UnityCore guides) -+subdirs (doc services tools UnityCore guides) -+ -+option( BUILD_TESTS "build tests" ON ) -+if (BUILD_TESTS) -+ add_subdirectory(tests) -+endif (BUILD_TESTS) - - # - # Base bits +diff -Naur unity-5.0.0.orig/CMakeLists.txt unity-5.0.0/CMakeLists.txt +--- unity-5.0.0.orig/CMakeLists.txt 2012-01-15 10:01:44.000000000 +0100 ++++ unity-5.0.0/CMakeLists.txt 2012-01-15 10:02:54.850817158 +0100 +@@ -130,12 +130,16 @@ + # subdirs + add_subdirectory(doc) + add_subdirectory(services) +-add_subdirectory(tests) + add_subdirectory(tools) + add_subdirectory(UnityCore) + add_subdirectory(guides) + add_subdirectory(standalone-clients EXCLUDE_FROM_ALL) + ++option( BUILD_TESTS "build tests" ON ) ++if (BUILD_TESTS) ++ add_subdirectory(tests) ++endif (BUILD_TESTS) ++ + # + # GSettings Schema + # diff --git a/unity/unity.install b/unity/unity.install index 1fb029980..35acc4ddb 100644 --- a/unity/unity.install +++ b/unity/unity.install @@ -2,7 +2,15 @@ pkgname=compiz-unity post_install() { gconfpkg --install ${pkgname} - glib-compile-schemas usr/share/glib-2.0/schemas + echo '$(ENV_UNITY_DEFAULTS_PATH)' >> etc/gconf/2/local-defaults.path + +sed -i '$ a\ +[general_unity]\ +backend = gconf\ +integration = true\ +plugin_list_autosort = true\ +profile = unity\ +' etc/compizconfig/config } pre_upgrade() { @@ -18,5 +26,9 @@ pre_remove() { } post_remove() { - glib-compile-schemas usr/share/glib-2.0/schemas + if [ -e etc/gconf/2/local-defaults.path ]; then + sed -i '/ENV_UNITY_DEFAULTS_PATH/ d' etc/gconf/2/local-defaults.path + fi + + sed -i '/[general_unity]/,+4 d' etc/compizconfig/config } diff --git a/unity/unity.sh b/unity/unity.sh index 18d3fb433..b38251f46 100644 --- a/unity/unity.sh +++ b/unity/unity.sh @@ -1,9 +1,11 @@ # This file is sourced by Xsession(5), not executed. -# Select unity profile if we are in the default session. +# Add additionnal gconf path depending on selected desktop session. +# Select unity profile for compiz if we are in the unity session. # The default profile is used otherwise. +GCONF_PREFIX="/usr/share/gconf" if [ "x$DESKTOP_SESSION" = "xunity" ]; then - COMPIZ_CONFIG_PROFILE="unity" - export COMPIZ_CONFIG_PROFILE + export UNITY_DEFAULTS_PATH='xml:readonly:/etc/gconf/unity.xml.defaults' + export COMPIZ_CONFIG_PROFILE="unity" fi diff --git a/unity/unity.xml.defaults b/unity/unity.xml.defaults new file mode 100644 index 000000000..e492ad943 --- /dev/null +++ b/unity/unity.xml.defaults @@ -0,0 +1,134 @@ + + + + + /apps/compiz-1/plugins/move/screen0/options/constrain_y + /schemas/apps/compiz-1/plugins/move/screen0/options/constrain_y + + true + + + + + /apps/compiz-1/general/screen0/options/hsize + /schemas/apps/compiz-1/plugins/core/screen0/options/hsize + + 2 + + + + + /apps/compiz-1/general/screen0/options/vsize + /schemas/apps/compiz-1/plugins/core/screen0/options/vsize + + 2 + + + + + /schemas/apps/gwd/blur_type + /apps/gwd/blur_type + + true + + + + + /apps/gwd/metacity_theme_opacity + /schemas/apps/gwd/metacity_theme_opacity + + 1.0 + + + + + /apps/gwd/metacity_theme_shade_opacity + /schemas/apps/gwd/metacity_theme_shade_opacity + + true + + + + + /apps/compizconfig-1/profiles/unity/general/screen0/options/active_plugins + /schemas/apps/compizconfig-1/profiles/unity/general/screen0/options/active_plugins + + + + core + + + composite + + + opengl + + + compiztoolbox + + + decor + + + ezoom + + + gnomecompat + + + mousepoll + + + move + + + place + + + regex + + + resize + + + scale + + + session + + + snap + + + staticswitcher + + + vpswitch + + + wall + + + workarounds + + + + + + + /apps/compizconfig-1/profiles/unity/plugins/gnomecompat/screen0/options/main_menu_key + /schemas/apps/compiz-1/plugins/gnomecompat/screen0/options/main_menu_key + + + + + + + /apps/compizconfig-1/profiles/unity/plugins/gnomecompat/screen0/options/run_key + /schemas/apps/compiz-1/plugins/gnomecompat/screen0/options/run_key + + + + + + -- 2.11.4.GIT