diff options
| author | Mikhail Osipov <mike.osipov@gmail.com> | 2019-02-18 12:45:40 +0300 |
|---|---|---|
| committer | Mikhail Osipov <mike.osipov@gmail.com> | 2019-02-18 12:45:40 +0300 |
| commit | 6df32ad70a85b9094c4683a7cd867623f4ccbdee (patch) | |
| tree | 152a5aaee15dd72f857b9ebb030071e460e3c44e | |
| parent | f9460d1c8ab20b5ddb14b89a22ab27fd0885bc77 (diff) | |
openbox
| -rw-r--r-- | .gitignore | 1 | ||||
| -rw-r--r-- | openbox/PKGBUILD | 66 | ||||
| -rw-r--r-- | openbox/openbox-3.5.0-title-matching.patch | 11 | ||||
| -rw-r--r-- | openbox/openbox-3.5.0-which-2.20.patch | 11 | ||||
| -rw-r--r-- | openbox/openbox-multihead.patch | 180 |
5 files changed, 269 insertions, 0 deletions
@@ -1,3 +1,4 @@ +*.asc *.tar.xz *.tar.gz *.tar.bz2 diff --git a/openbox/PKGBUILD b/openbox/PKGBUILD new file mode 100644 index 0000000..843dec8 --- /dev/null +++ b/openbox/PKGBUILD @@ -0,0 +1,66 @@ +# Maintainer: Florian pritz <bluewind@xinu.at> +# Contributor: Bartłomiej Piotrowski <nospam@bpiotrowski.pl> +# Contributor: Brad Fanella <bradfanella@archlinux.us> +# Contributor: Andrea Scarpino <andrea@archlinux.org> +# Contributor: tobias <tobias@archlinux.org> + +pkgname=openbox +pkgver=3.6.1 +pkgrel=4 +pkgdesc='Highly configurable and lightweight X11 window manager' +arch=('x86_64') +url='http://openbox.org' +license=('GPL') +provides=(libobrender.so) +depends=('startup-notification' 'libxml2' 'libxinerama' 'libxrandr' + 'libxcursor' 'pango' 'imlib2' 'librsvg' 'libsm') +optdepends=('plasma-workspace: for the KDE/Openbox xsession' + 'python2-xdg: for the openbox-xdg-autostart script') +groups=('lxde' 'lxde-gtk3' 'lxqt') +backup=('etc/xdg/openbox/menu.xml' 'etc/xdg/openbox/rc.xml' + 'etc/xdg/openbox/autostart' 'etc/xdg/openbox/environment') +source=(http://openbox.org/dist/openbox/$pkgname-$pkgver.tar.gz{,.asc} + openbox-3.5.0-title-matching.patch + openbox-3.5.0-which-2.20.patch + openbox-multihead.patch) +md5sums=('b72794996c6a3ad94634727b95f9d204' + 'SKIP' + '0a11d7149da210a31ef88f8a9c717711' + '7ca3b5244bb092d46f5bcf1e2bdf4a18' + 'SKIP') +validpgpkeys=(4B71379A9D5263D112A85620A5A4E99C711D3B61) + +prepare() { + cd $pkgname-$pkgver + + patch -Np1 -i "$srcdir"/openbox-3.5.0-title-matching.patch # OB#5277 + patch -Np1 -i "$srcdir"/openbox-3.5.0-which-2.20.patch # FS#11455 + patch -Np1 -i "$srcdir"/openbox-multihead.patch + + sed -i 's|/usr/bin/env python|/usr/bin/env python2|' \ + data/autostart/openbox-xdg-autostart +} + +build() { + cd $pkgname-$pkgver + ./configure --prefix=/usr \ + --with-x \ + --enable-startup-notification \ + --sysconfdir=/etc \ + --libexecdir=/usr/lib/openbox + make +} + +package() { + cd $pkgname-$pkgver + make DESTDIR="$pkgdir" install + + # GNOME Panel is no longer available in the official repositories + rm -r "$pkgdir"/usr/bin/{gdm-control,gnome-panel-control,openbox-gnome-session} \ + "$pkgdir"/usr/share/gnome{,-session} \ + "$pkgdir"/usr/share/man/man1/openbox-gnome-session.1 \ + "$pkgdir"/usr/share/xsessions/openbox-gnome.desktop + + sed -i 's:startkde:/usr/bin/\0:' \ + "$pkgdir"/usr/share/xsessions/openbox-kde.desktop +} diff --git a/openbox/openbox-3.5.0-title-matching.patch b/openbox/openbox-3.5.0-title-matching.patch new file mode 100644 index 0000000..fdfe28a --- /dev/null +++ b/openbox/openbox-3.5.0-title-matching.patch @@ -0,0 +1,11 @@ +--- openbox-3.5.0/openbox/client.c 2011-08-01 22:14:58.000000000 +0200 ++++ openbox-3.5.0/openbox/client.c 2011-10-22 14:59:56.000000000 +0200 +@@ -883,7 +883,7 @@ + !g_pattern_match(app->role, + strlen(self->role), self->role, NULL)) + match = FALSE; +- else if (app->title && ++ else if (app->title && self->title && + !g_pattern_match(app->title, + strlen(self->title), self->title, NULL)) + match = FALSE; diff --git a/openbox/openbox-3.5.0-which-2.20.patch b/openbox/openbox-3.5.0-which-2.20.patch new file mode 100644 index 0000000..f947d6a --- /dev/null +++ b/openbox/openbox-3.5.0-which-2.20.patch @@ -0,0 +1,11 @@ +--- openbox-3.5.0/data/autostart/autostart.in~ 2011-08-02 15:50:01.963531310 +0000 ++++ openbox-3.5.0/data/autostart/autostart.in 2011-08-02 15:51:57.277879458 +0000 +@@ -8,7 +8,7 @@ + # + #if test -x @libexecdir@/gnome-settings-daemon >/dev/null; then + # @libexecdir@/gnome-settings-daemon & +-#elif which gnome-settings-daemon >/dev/null; then ++#elif which gnome-settings-daemon >/dev/null 2>&1; then + # gnome-settings-daemon & + #fi + diff --git a/openbox/openbox-multihead.patch b/openbox/openbox-multihead.patch new file mode 100644 index 0000000..e7a1a5d --- /dev/null +++ b/openbox/openbox-multihead.patch @@ -0,0 +1,180 @@ +diff -ura openbox-3.6.1/openbox/client.c openbox-3.6.1-multihead/openbox/client.c +--- openbox-3.6.1/openbox/client.c 2018-11-15 12:11:21.211662798 +0300 ++++ openbox-3.6.1-multihead/openbox/client.c 2018-11-15 12:11:34.088329218 +0300 +@@ -324,8 +324,8 @@ + (user_time != 0) && + /* this checks for focus=false for the window */ + settings->focus != 0 && +- focus_valid_target(self, self->desktop, +- FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, ++ focus_valid_target(self, self->desktop, 0, ++ FALSE, FALSE, TRUE, TRUE, TRUE, FALSE, FALSE, + settings->focus == 1)) + { + try_activate = TRUE; +diff -ura openbox-3.6.1/openbox/client_list_combined_menu.c openbox-3.6.1-multihead/openbox/client_list_combined_menu.c +--- openbox-3.6.1/openbox/client_list_combined_menu.c 2014-11-05 18:19:42.000000000 +0300 ++++ openbox-3.6.1-multihead/openbox/client_list_combined_menu.c 2018-11-15 12:11:34.088329218 +0300 +@@ -58,9 +58,9 @@ + menu_add_separator(menu, SEPARATOR, screen_desktop_names[desktop]); + for (it = focus_order; it; it = g_list_next(it)) { + ObClient *c = it->data; +- if (focus_valid_target(c, desktop, ++ if (focus_valid_target(c, desktop, 0, + TRUE, TRUE, +- FALSE, TRUE, FALSE, FALSE, FALSE)) ++ FALSE, TRUE, FALSE, TRUE, FALSE, FALSE)) + { + empty = FALSE; + +diff -ura openbox-3.6.1/openbox/client_list_menu.c openbox-3.6.1-multihead/openbox/client_list_menu.c +--- openbox-3.6.1/openbox/client_list_menu.c 2014-11-05 18:19:42.000000000 +0300 ++++ openbox-3.6.1-multihead/openbox/client_list_menu.c 2018-11-15 12:11:34.088329218 +0300 +@@ -54,8 +54,8 @@ + + for (it = focus_order; it; it = g_list_next(it)) { + ObClient *c = it->data; +- if (focus_valid_target(c, d->desktop, +- TRUE, TRUE, FALSE, TRUE, FALSE, FALSE, FALSE)) { ++ if (focus_valid_target(c, d->desktop, 0, ++ TRUE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE)) { + ObMenuEntry *e; + + empty = FALSE; +diff -ura openbox-3.6.1/openbox/focus.c openbox-3.6.1-multihead/openbox/focus.c +--- openbox-3.6.1/openbox/focus.c 2014-11-05 18:19:42.000000000 +0300 ++++ openbox-3.6.1-multihead/openbox/focus.c 2018-11-15 12:12:11.218328511 +0300 +@@ -136,8 +136,8 @@ + 3. it is not shaded + */ + if ((allow_omnipresent || c->desktop == screen_desktop) && +- focus_valid_target(c, screen_desktop, +- TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, ++ focus_valid_target(c, screen_desktop, 0, ++ TRUE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, + FALSE) && + !c->shaded && + (allow_refocus || client_focus_target(c) != old) && +@@ -158,8 +158,8 @@ + a splashscreen or a desktop window (save the desktop as a + backup fallback though) + */ +- if (focus_valid_target(c, screen_desktop, +- TRUE, FALSE, FALSE, TRUE, FALSE, TRUE, FALSE) && ++ if (focus_valid_target(c, screen_desktop, 0, ++ TRUE, FALSE, FALSE, TRUE, TRUE, FALSE, TRUE, FALSE) && + (allow_refocus || client_focus_target(c) != old) && + client_focus(c)) + { +@@ -291,8 +291,8 @@ + ObClient *c = it->data; + /* check that it's not a helper window to avoid infinite recursion */ + if (c != ft && c->type == OB_CLIENT_TYPE_NORMAL && +- focus_valid_target(c, screen_desktop, +- TRUE, iconic_windows, all_desktops, ++ focus_valid_target(c, screen_desktop, 0, ++ TRUE, iconic_windows, all_desktops, TRUE, + TRUE, FALSE, FALSE, FALSE)) + { + return TRUE; +@@ -303,9 +303,11 @@ + + gboolean focus_valid_target(ObClient *ft, + guint desktop, ++ guint monitor, + gboolean helper_windows, + gboolean iconic_windows, + gboolean all_desktops, ++ gboolean all_monitors, + gboolean nonhilite_windows, + gboolean dock_windows, + gboolean desktop_windows, +@@ -327,6 +329,8 @@ + ok = (all_desktops || ft->desktop == desktop || + ft->desktop == DESKTOP_ALL); + ++ ok = ok && (all_monitors || client_monitor(ft) == monitor); ++ + /* if we only include hilited windows, check if the window is */ + ok = ok && (nonhilite_windows || ft->demands_attention); + +@@ -376,9 +380,11 @@ + ObClient *cft = client_focus_target(ft); + ok = ok && (ft == cft || !focus_valid_target(cft, + screen_desktop, ++ monitor, + TRUE, + iconic_windows, + all_desktops, ++ all_monitors, + nonhilite_windows, + dock_windows, + desktop_windows, +diff -ura openbox-3.6.1/openbox/focus_cycle.c openbox-3.6.1-multihead/openbox/focus_cycle.c +--- openbox-3.6.1/openbox/focus_cycle.c 2014-11-05 18:19:42.000000000 +0300 ++++ openbox-3.6.1-multihead/openbox/focus_cycle.c 2018-11-15 12:12:48.988327773 +0300 +@@ -40,9 +40,11 @@ + static gboolean focus_cycle_linear; + static gboolean focus_cycle_iconic_windows; + static gboolean focus_cycle_all_desktops; ++static gboolean focus_cycle_all_monitors; + static gboolean focus_cycle_nonhilite_windows; + static gboolean focus_cycle_dock_windows; + static gboolean focus_cycle_desktop_windows; ++static guint focus_cycle_monitor; + + static ObClient *focus_find_directional(ObClient *c, + ObDirection dir, +@@ -109,6 +111,7 @@ + GList *it, *start, *list; + ObClient *ft = NULL; + ObClient *ret = NULL; ++ guint monitor = 0; + + if (cancel) { + focus_cycle_target = NULL; +@@ -137,6 +140,9 @@ + start = it = forward ? g_list_last(list) : g_list_first(list); + if (!start) goto done_cycle; + ++ focus_cycle_monitor = client_monitor(it->data); ++ focus_cycle_all_monitors = FALSE; ++ + do { + if (forward) { + it = it->next; +@@ -163,6 +169,7 @@ + + focus_cycle_target = NULL; + focus_cycle_type = OB_CYCLE_NONE; ++ focus_cycle_all_monitors = TRUE; + g_list_free(order); + order = NULL; + +@@ -339,9 +346,10 @@ + + gboolean focus_cycle_valid(struct _ObClient *client) + { +- return focus_valid_target(client, screen_desktop, TRUE, ++ return focus_valid_target(client, screen_desktop, focus_cycle_monitor, TRUE, + focus_cycle_iconic_windows, + focus_cycle_all_desktops, ++ focus_cycle_all_monitors, + focus_cycle_nonhilite_windows, + focus_cycle_dock_windows, + focus_cycle_desktop_windows, +diff -ura openbox-3.6.1/openbox/focus.h openbox-3.6.1-multihead/openbox/focus.h +--- openbox-3.6.1/openbox/focus.h 2014-11-05 18:19:42.000000000 +0300 ++++ openbox-3.6.1-multihead/openbox/focus.h 2018-11-15 12:11:34.088329218 +0300 +@@ -70,9 +70,11 @@ + + gboolean focus_valid_target(struct _ObClient *ft, + guint desktop, ++ guint monitor, + gboolean helper_windows, + gboolean iconic_windows, + gboolean all_desktops, ++ gboolean all_monitors, + gboolean nonhilite_windows, + gboolean dock_windows, + gboolean desktop_windows, |
