Compare commits
47 Commits
trial-rust
...
refactor/r
| Author | SHA1 | Date | |
|---|---|---|---|
| 02d638d1c6 | |||
| 54bd69680a | |||
| a67f7483fd | |||
| cf87f7e83b | |||
| b569889f21 | |||
| 383b3a1a7b | |||
| 4fd7d1e2c1 | |||
| 0131c493c0 | |||
| 5f1317b885 | |||
| 5817c1f032 | |||
| 6d09fbff93 | |||
| b38fa197d7 | |||
| 4c617034b4 | |||
| f5daf2a76a | |||
| 05895b40a2 | |||
| 4f4ef94400 | |||
| 023ab177b2 | |||
| 279f369256 | |||
| 0a2ff4f055 | |||
| 108c913c1d | |||
| 8c669d57b2 | |||
| 83fa8119d9 | |||
| 507e69e209 | |||
| 70814cc235 | |||
| 2ef6720890 | |||
| 493d3c9738 | |||
| 917cc29160 | |||
| 3234e15388 | |||
| 394b4d23cb | |||
| 274d1459aa | |||
| 9a886baef8 | |||
| 7ba66fbc00 | |||
| 289ceb2991 | |||
| ab7e188334 | |||
| 55d34ff0a1 | |||
| 0e7f125494 | |||
| 9404c21fa8 | |||
| 455aa71c19 | |||
| 18db22063c | |||
| b4d1dbe953 | |||
|
|
da676c9e9e | ||
|
|
4edf589a5b | ||
|
|
709eec4bce | ||
|
|
b179803c11 | ||
|
|
5cd40deb20 | ||
|
|
9db1ea580d | ||
|
|
9e56f58742 |
5
.gitignore
vendored
5
.gitignore
vendored
@@ -133,8 +133,13 @@ WPrefs.app/WPrefs.desktop
|
||||
/WPrefs.app/po/*.mo
|
||||
/util/po/*.pot
|
||||
/util/po/*.mo
|
||||
/wrlib/po/*.pot
|
||||
/wrlib/po/*.mo
|
||||
|
||||
# Some text editors generate backup files
|
||||
*~
|
||||
|
||||
.pc
|
||||
|
||||
# Rust stuff.
|
||||
/wmakerlib/target/**
|
||||
|
||||
@@ -21,7 +21,7 @@ Changes since version 0.95.7:
|
||||
- debian: Ignore missing documentation for --runstatedir.
|
||||
- debian: Use dh_autoreconf.
|
||||
- debian: Simplify debian/rules.
|
||||
- debian: Fix typo occured. (Thanks, lintian.)
|
||||
- debian: Fix typo occurred. (Thanks, lintian.)
|
||||
- debian: wmaker manpage moved from 1x to 1.
|
||||
(Andreas Metzler <ametzler@bebt.de>)
|
||||
- debian: Add wmiv to wmaker package.
|
||||
@@ -498,7 +498,7 @@ Changes since version 0.95.6:
|
||||
- doc: Add manpage for wmiv.
|
||||
(Doug Torrance <dtorrance@monmouthcollege.edu>)
|
||||
- wmaker: replaced old email address with the official one
|
||||
- WINGs: Updated news with the API changes that occured between 0.95.6 and
|
||||
- WINGs: Updated news with the API changes that occurred between 0.95.6 and
|
||||
0.95.7
|
||||
- WINGs: ran spell checker on the NEWS file
|
||||
- WINGs: fix non-portable int conversion for printf in font panel size handling
|
||||
@@ -969,7 +969,7 @@ Changes since version 0.95.5:
|
||||
- WMaker: moved XGrab/XUngrabPointer into the conditional code
|
||||
- News: created section dedicated to the changes related to 0.95.3
|
||||
- News: added description of a change that may be interesting to users
|
||||
- News: added section to describe the changes that have occured in 0.95.4
|
||||
- News: added section to describe the changes that have occurred in 0.95.4
|
||||
- News: marked the current changes as part of 0.95.5 and describe the drawers
|
||||
feature
|
||||
- News: described the new features for future 0.95.6 release
|
||||
@@ -1103,7 +1103,7 @@ Changes since version 0.95.5:
|
||||
#50158)
|
||||
- WPrefs: fix NULL pointer handling when getting the Modifiers (Coverity
|
||||
#50200)
|
||||
- WPrefs: add warning when renderTexture encounters some unknow settings
|
||||
- WPrefs: add warning when renderTexture encounters some unknown settings
|
||||
(Christophe CURIS <christophe.curis@free.fr>)
|
||||
- util/wmiv: add image auto orientation detection
|
||||
(David Maciejak <david.maciejak@gmail.com>)
|
||||
|
||||
@@ -140,7 +140,7 @@ Changes since wmaker 0.64.0:
|
||||
- Moved all internal handlers (timer, idle and input) to handlers.c
|
||||
- simplified wevent.c and wutil.c.
|
||||
- fixed handling of input with poll (was broken)
|
||||
- fixed mem leak that occured when input handling was done with poll
|
||||
- fixed mem leak that occurred when input handling was done with poll
|
||||
- simpler and more straightforward event handling for timer, idle, input
|
||||
and X events (also fixed some problems the old handling logic had)
|
||||
- moved timer, idle and input handler definitions and prototypes from
|
||||
|
||||
@@ -9,6 +9,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2003-02-09 12:10+0200\n"
|
||||
"Last-Translator: Anton Zinoviev <zinoviev@debian.org>\n"
|
||||
"Language-Team: Bulgarian <dict@linux.zonebg.com>\n"
|
||||
"Language: bg\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
|
||||
@@ -14,6 +14,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2003-09-16 23:16+0200\n"
|
||||
"Last-Translator: Ernest Adrogué <eadrogue@gmx.net>\n"
|
||||
"Language-Team: Catalan <ca@dodds.net>\n"
|
||||
"Language: ca\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
|
||||
@@ -12,6 +12,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2001-10-11 22:00+0100\n"
|
||||
"Last-Translator: Jiří Hnídek <jiri.hnidek@vslib.cz>\n"
|
||||
"Language-Team: Czech <cz@li.org>\n"
|
||||
"Language: cs\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: unknown\n"
|
||||
|
||||
@@ -15,6 +15,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2004-11-05 23:48+0100\n"
|
||||
"Last-Translator: shlomme@gmx.net\n"
|
||||
"Language-Team: German\n"
|
||||
"Language: de\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
|
||||
@@ -10,6 +10,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2002-01-09 21:20+0100\n"
|
||||
"Last-Translator: Emmanuel Benoit <tseeker@neptune.fr>\n"
|
||||
"Language-Team: Français <fr@li.org>\n"
|
||||
"Language: fr\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: unknown\n"
|
||||
|
||||
@@ -11,7 +11,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2014-02-18 00:25+0100\n"
|
||||
"Last-Translator: BALATON Zoltán <balaton@eik.bme.hu>\n"
|
||||
"Language-Team: Hungarian\n"
|
||||
"Language: \n"
|
||||
"Language: hu\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
|
||||
@@ -843,9 +843,6 @@ msgstr "Kon invoerbestand \"%s\" niet openen"
|
||||
msgid "Could not create target file \"%s\""
|
||||
msgstr "Kon doelbestand \"%s\" niet aanmaken"
|
||||
|
||||
msgid "An error occured browsing '%s'."
|
||||
msgstr "Er trad 'n fout op bij bladeren door '%s'."
|
||||
|
||||
msgid ""
|
||||
"invalid characted '%c' in arg-list for macro \"%s\" while expecting "
|
||||
"parameter name"
|
||||
@@ -860,9 +857,6 @@ msgstr ""
|
||||
"ongeldig letterteken '%c' in arg.-lijst voor macro \"%s\", verwachtte ',' "
|
||||
"of ')'"
|
||||
|
||||
msgid "unknow directive '#%s'"
|
||||
msgstr "onbekende aanwijzing '#%s'"
|
||||
|
||||
msgid "found #%s but have no matching #if"
|
||||
msgstr "#%s gevonden, maar heeft geen bijbehorende #if"
|
||||
|
||||
|
||||
@@ -19,6 +19,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2001-12-20 04:00+0100\n"
|
||||
"Last-Translator: Jan \"judas\" Tomka <judas@linux.sk>\n"
|
||||
"Language-Team: Slovak <sk@li.org>\n"
|
||||
"Language: sk\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
|
||||
@@ -5,7 +5,8 @@ CATALOGS = @WPREFSMOFILES@
|
||||
CLEANFILES = $(DOMAIN).pot $(CATALOGS)
|
||||
|
||||
EXTRA_DIST = bg.po ca.po cs.po de.po es.po et.po fi.po fr.po fy.po hr.po hu.po \
|
||||
it.po ja.po ko.po nl.po pt.po ru.po sk.po tr.po uk.po zh_CN.po zh_TW.po
|
||||
it.po ja.po ko.po nl.po pt.po ru.po sk.po sr.po tr.po uk.po zh_CN.po \
|
||||
zh_TW.po
|
||||
|
||||
POTFILES = \
|
||||
$(top_srcdir)/WPrefs.app/Appearance.c \
|
||||
|
||||
@@ -8,6 +8,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2001-04-18 23:22+03:00\n"
|
||||
"Last-Translator: Anton Zinoviev <zinoviev@debian.org>\n"
|
||||
"Language-Team: Bulgarian <dict@linux.zonebg.com>\n"
|
||||
"Language: bg\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
|
||||
@@ -14,6 +14,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2003-09-16 23:15+0200\n"
|
||||
"Last-Translator: Ernest Adrogué <eadrogue@gmx.net>\n"
|
||||
"Language-Team: Catalan <ca@dodds.net>\n"
|
||||
"Language: ca\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
|
||||
@@ -16,6 +16,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2001-10-14 21:07+0000\n"
|
||||
"Last-Translator: Jiří Hnídek <jiri.hnidek@vslib.cz>\n"
|
||||
"Language-Team: czech <cs@li.org>\n"
|
||||
"Language: cs\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: unknown\n"
|
||||
|
||||
@@ -18,6 +18,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2010-02-02 10:49+0100\n"
|
||||
"Last-Translator: Carlos R. Mafra <crmafra@gmail.com>\n"
|
||||
"Language-Team: German <>\n"
|
||||
"Language: de\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
|
||||
@@ -8,6 +8,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2003-09-19 03:05-0400\n"
|
||||
"Last-Translator: Alberto Giménez <algibe@teleline.es>\n"
|
||||
"Language-Team: Spanish \n"
|
||||
"Language: es\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: unknown\n"
|
||||
|
||||
@@ -8,6 +8,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2001-09-05 09:40+0200\n"
|
||||
"Last-Translator: Ivar Smolin <okul@linux.ee>\n"
|
||||
"Language-Team: Estonian <linux-ee@eenet.ee>\n"
|
||||
"Language: et\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
@@ -475,7 +476,7 @@ msgstr "Window Maker vőttis vastu signaali %i."
|
||||
|
||||
#: ../src/dialog.c:1707
|
||||
msgid ""
|
||||
" This fatal error occured probably due to a bug. Please fill the included "
|
||||
" This fatal error occurred probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it to bugs@windowmaker.info."
|
||||
msgstr ""
|
||||
" See fataalviga on arvatavasti pőhjustatud programmi veast. Palun täitke "
|
||||
@@ -1437,7 +1438,7 @@ msgstr "ei őnnestu käivitada alternatiivset aknahaldurit. Annan alla."
|
||||
|
||||
#: ../src/startup.c:419
|
||||
msgid ""
|
||||
"a fatal error has occured, probably due to a bug. Please fill the included "
|
||||
"a fatal error has occurred, probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it."
|
||||
msgstr ""
|
||||
"aset on leidnud fataalne viga, arvatavasti programmi viga. Palun täida "
|
||||
|
||||
@@ -11,6 +11,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2001-09-03 22:18+03:00\n"
|
||||
"Last-Translator: Tomi Kajala <tomi@iki.fi>\n"
|
||||
"Language-Team: Finnish <fi@li.org>\n"
|
||||
"Language: fi\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8-bit\n"
|
||||
|
||||
@@ -12,6 +12,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 1999-07-28 16:31-0100\n"
|
||||
"Last-Translator: Antoine Hulin <antoine.hulin@origan.fdn.org>\n"
|
||||
"Language-Team: French <fr@li.org>\n"
|
||||
"Language: fr\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8-bit\n"
|
||||
|
||||
@@ -9,6 +9,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 1998-08-24 14:36:41-0300\n"
|
||||
"Last-Translator: Toni Bilić tbilic@oliver.efos.hr \n"
|
||||
"Language-Team: Croatian \n"
|
||||
"Language: hr\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
|
||||
@@ -11,7 +11,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2014-02-18 00:33+0100\n"
|
||||
"Last-Translator: BALATON Zoltán <balaton@eik.bme.hu>\n"
|
||||
"Language-Team: Hungarian\n"
|
||||
"Language: \n"
|
||||
"Language: hu\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
|
||||
@@ -11,6 +11,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2001-05-21\n"
|
||||
"Last-Translator: Michele Campeotto <micampe@f2s.com\n"
|
||||
"Language-Team: Italian\n"
|
||||
"Language: it\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: unknown\n"
|
||||
|
||||
@@ -12,6 +12,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2013-08-13 19:26+0900\n"
|
||||
"Last-Translator: \n"
|
||||
"Language-Team: Korean\n"
|
||||
"Language: ko\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
|
||||
@@ -12,6 +12,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2000-01-04 18:25-0300\n"
|
||||
"Last-Translator: Eliphas Levy Theodoro <eliphas@conectiva.com.br>\n"
|
||||
"Language-Team: Portuguese \n"
|
||||
"Language: pt\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8-bit\n"
|
||||
|
||||
@@ -12,6 +12,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2002-09-12 17:45+0300\n"
|
||||
"Last-Translator: awn@bcs.zp.ua\n"
|
||||
"Language-Team: Russian\n"
|
||||
"Language: ru\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
|
||||
@@ -18,6 +18,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2001-10-15 20:40+0100\n"
|
||||
"Last-Translator: Jan \"judas\" Tomka <judas@linux.sk>\n"
|
||||
"Language-Team: Slovak <sk@li.org>\n"
|
||||
"Language: sk\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
|
||||
@@ -5,6 +5,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2004-09-06 21:42+4000\n"
|
||||
"Last-Translator: Victor Forsyuk <victor@ksi-linux.com>\n"
|
||||
"Language-Team: KSI Linux Ukrainian <uk@ksi-linux.com>\n"
|
||||
"Language: uk\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
|
||||
@@ -9,6 +9,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 1999-07-05 23:20+0800\n"
|
||||
"Last-Translator: Wang Jian <larkw@263.net>\n"
|
||||
"Language-Team: chinese <zh@li.org>\n"
|
||||
"Language: zh_CN\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8-bit\n"
|
||||
|
||||
@@ -10,6 +10,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2005-01-11 17:46+0800\n"
|
||||
"Last-Translator: Li Wei Jih <lwj83@cs.ccu.edu.tw>\n"
|
||||
"Language-Team: chinese <zh@li.org>\n"
|
||||
"Language: zh_TW\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8-bit\n"
|
||||
|
||||
28
autogen.sh
28
autogen.sh
@@ -1,26 +1,16 @@
|
||||
#!/bin/sh
|
||||
|
||||
srcdir=$(dirname $0)
|
||||
test -z "$srcdir" && srcdir=.
|
||||
|
||||
# Generate the documentation about compiling Window Maker
|
||||
./script/generate-txt-from-texi.sh "doc/build/Compilation.texi" -o "INSTALL-WMAKER"
|
||||
./script/generate-txt-from-texi.sh "doc/build/Translations.texi" -o "README.i18n"
|
||||
$srcdir/script/generate-txt-from-texi.sh "$srcdir/doc/build/Compilation.texi" \
|
||||
-o "$srcdir/INSTALL-WMAKER"
|
||||
$srcdir/script/generate-txt-from-texi.sh "$srcdir/doc/build/Translations.texi" \
|
||||
-o "$srcdir/README.i18n"
|
||||
|
||||
# Change date of the files to the past so they will be regenerated by 'make'
|
||||
touch -d '2000-01-01' INSTALL-WMAKER README.i18n
|
||||
touch -d '2000-01-01' $srcdir/INSTALL-WMAKER $srcdir/README.i18n
|
||||
|
||||
# Generate the configure script from the 'configure.ac'
|
||||
autoreconf -vfi -I m4
|
||||
|
||||
exit 0
|
||||
|
||||
if [ -x config.status -a -z "$*" ]; then
|
||||
./config.status --recheck
|
||||
else
|
||||
if test -z "$*"; then
|
||||
echo "I am going to run ./configure with no arguments - if you wish "
|
||||
echo "to pass any to it, please specify them on the $0 command line."
|
||||
echo "If you do not wish to run ./configure, press Ctrl-C now."
|
||||
trap 'echo "configure aborted" ; exit 0' 1 2 15
|
||||
sleep 1
|
||||
fi
|
||||
./configure "$@"
|
||||
fi
|
||||
autoreconf -vfi -I m4 $srcdir
|
||||
|
||||
@@ -97,7 +97,6 @@ dnl ===================
|
||||
AC_PROG_CC
|
||||
WM_PROG_CC_C11
|
||||
AC_PROG_LN_S
|
||||
AC_PROG_GCC_TRADITIONAL
|
||||
LT_INIT
|
||||
|
||||
|
||||
|
||||
5
po/be.po
5
po/be.po
@@ -10,6 +10,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2002-10-17 19:02+0300\n"
|
||||
"Last-Translator: Ihar Viarheichyk <iverg@mail.ru>\n"
|
||||
"Language-Team: Belarusian <be@li.org>\n"
|
||||
"Language: be\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
@@ -472,7 +473,7 @@ msgstr "Window Maker атрымаў сігнал %i."
|
||||
#: ../src/dialog.c:1632
|
||||
#, c-format
|
||||
msgid ""
|
||||
" This fatal error occured probably due to a bug. Please fill the included "
|
||||
" This fatal error occurred probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it to %s."
|
||||
msgstr ""
|
||||
" Гэты крытычны збой магчыма вызваны памылкамі ў WindowMaker."
|
||||
@@ -1433,7 +1434,7 @@ msgstr "не магчыма запусціць іншы ваконны мене
|
||||
|
||||
#: ../src/startup.c:419
|
||||
msgid ""
|
||||
"a fatal error has occured, probably due to a bug. Please fill the included "
|
||||
"a fatal error has occurred, probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it."
|
||||
msgstr ""
|
||||
" Гэты крытычны збой магчыма вызваны памылкамі ў WindowMaker."
|
||||
|
||||
5
po/bg.po
5
po/bg.po
@@ -12,6 +12,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2003-02-09 14:21+0200\n"
|
||||
"Last-Translator: Anton Zinoviev <zinoviev@debian.org>\n"
|
||||
"Language-Team: Bulgarian <dict@linux.zonebg.com>\n"
|
||||
"Language: bg\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
@@ -602,7 +603,7 @@ msgstr "Уиндоу Мейкър получи сигнал %i."
|
||||
#: ../src/dialog.c:1632
|
||||
#, c-format
|
||||
msgid ""
|
||||
" This fatal error occured probably due to a bug. Please fill the included "
|
||||
" This fatal error occurred probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it to %s."
|
||||
msgstr "Възникналата критична грешка вероятно се дължи на програмен дефект. Моля попълнете формуляра от файла BUGFORM и го изпратете на адрес %s."
|
||||
|
||||
@@ -1793,7 +1794,7 @@ msgstr ""
|
||||
# ../src/startup.c:352
|
||||
#: ../src/startup.c:419
|
||||
msgid ""
|
||||
"a fatal error has occured, probably due to a bug. Please fill the included "
|
||||
"a fatal error has occurred, probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it."
|
||||
msgstr "възникна критична грешка, вероятно дължаща се на програмен дефект. Моля попълнете формуляра от файла BUGFORM и ни уведомете "
|
||||
|
||||
|
||||
1
po/bs.po
1
po/bs.po
@@ -8,6 +8,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2004-08-30 00:23+0200\n"
|
||||
"Last-Translator: Ahmet Mulalić <am@lugzdk.ba>\n"
|
||||
"Language-Team: Bosanski <lugzdk@lugzdk.ba>\n"
|
||||
"Language: bs\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
|
||||
5
po/ca.po
5
po/ca.po
@@ -14,6 +14,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2003-09-16 23:13+0200\n"
|
||||
"Last-Translator: Ernest Adrogué <eadrogue@gmx.net>\n"
|
||||
"Language-Team: Catalan <ca@dodds.net>\n"
|
||||
"Language: ca\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
@@ -494,7 +495,7 @@ msgstr "Window Maker ha rebut un senyal %i."
|
||||
#: ../src/dialog.c:1632
|
||||
#, c-format
|
||||
msgid ""
|
||||
" This fatal error occured probably due to a bug. Please fill the included "
|
||||
" This fatal error occurred probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it to %s."
|
||||
msgstr ""
|
||||
" Aquest error fatal probablement ha estat causat per un \"bug\". Si us plau, "
|
||||
@@ -1471,7 +1472,7 @@ msgstr "no s'ha pogut iniciar cap gestor de finestres alternatiu. S'avorta."
|
||||
|
||||
#: ../src/startup.c:419
|
||||
msgid ""
|
||||
"a fatal error has occured, probably due to a bug. Please fill the included "
|
||||
"a fatal error has occurred, probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it."
|
||||
msgstr ""
|
||||
"s'ha produït un error fatal, probablement a causa d'un \"bug\". Si us plau, "
|
||||
|
||||
5
po/cs.po
5
po/cs.po
@@ -15,6 +15,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2001-10-14 20:29+53:00\n"
|
||||
"Last-Translator: Jiří Hnídek <jiri.hnidek@vslib.cz>\n"
|
||||
"Language-Team: czech <cs@li.org>\n"
|
||||
"Language: cs\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: unknown\n"
|
||||
@@ -477,7 +478,7 @@ msgstr "Window Maker přijal signál %i."
|
||||
#: ../src/dialog.c:1632
|
||||
#, c-format
|
||||
msgid ""
|
||||
" This fatal error occured probably due to a bug. Please fill the included "
|
||||
" This fatal error occurred probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it to %s."
|
||||
msgstr ""
|
||||
" Tato závažná chyba se vyskytla pravděpodobně v důsledku chyby v kódu Window "
|
||||
@@ -1392,7 +1393,7 @@ msgstr "alternativního správce oken nelze odstartovat. Konec."
|
||||
|
||||
#: ../src/startup.c:419
|
||||
msgid ""
|
||||
"a fatal error has occured, probably due to a bug. Please fill the included "
|
||||
"a fatal error has occurred, probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it."
|
||||
msgstr ""
|
||||
"fatální chyba, pravděpodobně chyba ve Window Makeru. Prosím vyplňte soubor "
|
||||
|
||||
5
po/da.po
5
po/da.po
@@ -9,6 +9,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2002-02-20 20:56+0100\n"
|
||||
"Last-Translator: Birger Langkjer <birger.langkjer@image.dk>\n"
|
||||
"Language-Team: Danish <sslug-locale@sslug.dk>\n"
|
||||
"Language: da\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8-bit\n"
|
||||
@@ -544,7 +545,7 @@ msgstr "Window Maker modtog signal %i"
|
||||
# ../src/dialog.c:1450
|
||||
#: ../src/dialog.c:1790
|
||||
msgid ""
|
||||
" This fatal error occured probably due to a bug. Please fill the included "
|
||||
" This fatal error occurred probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it to %s."
|
||||
msgstr ""
|
||||
"en fatal fejl er opstået, sikkert pga. en bug. Udfyld venligst den vedlagte "
|
||||
@@ -1685,7 +1686,7 @@ msgstr "det lykkedes ikke at starte alternativ vindueshåndtering. Afbryder."
|
||||
# ../src/startup.c:349
|
||||
#: ../src/startup.c:419
|
||||
msgid ""
|
||||
"a fatal error has occured, probably due to a bug. Please fill the included "
|
||||
"a fatal error has occurred, probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it."
|
||||
msgstr ""
|
||||
"en fatal fejl er opstået, sikkert pga. en bug. Udfyld venligst den vedlagte "
|
||||
|
||||
3
po/de.po
3
po/de.po
@@ -16,6 +16,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2004-11-08 22:58+0100\n"
|
||||
"Last-Translator: shlomme@gmx.net\n"
|
||||
"Language-Team: German\n"
|
||||
"Language: de\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
@@ -471,7 +472,7 @@ msgstr "Window Maker erhielt Signal %i"
|
||||
|
||||
#: ../src/dialog.c:1602
|
||||
msgid ""
|
||||
" This fatal error occured probably due to a bug. Please fill the included "
|
||||
" This fatal error occurred probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it to %s."
|
||||
msgstr ""
|
||||
" Dieser fatale Fehler trat möglicherweise wegen eines Bugs auf. Bitte füllen "
|
||||
|
||||
3
po/el.po
3
po/el.po
@@ -10,6 +10,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 1999-09-04 01:39+0300\n"
|
||||
"Last-Translator: Nikolaos Papagrigoriou <papanikos@freemail.gr>\n"
|
||||
"Language-Team: Greek\n"
|
||||
"Language: el\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8-bit\n"
|
||||
@@ -1173,7 +1174,7 @@ msgstr "αποτυχία εκκίνησης εναλλακτικού διαχε
|
||||
|
||||
#: ../src/startup.c:349
|
||||
msgid ""
|
||||
"a fatal error has occured, probably due to a bug. Please fill the included "
|
||||
"a fatal error has occurred, probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it."
|
||||
msgstr ""
|
||||
|
||||
|
||||
2
po/es.po
2
po/es.po
@@ -491,7 +491,7 @@ msgstr "Window Maker recibió la señal %i."
|
||||
|
||||
#: ../src/dialog.c:1576
|
||||
msgid ""
|
||||
" This fatal error occured probably due to a bug. Please fill the included "
|
||||
" This fatal error occurred probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it to %s."
|
||||
msgstr ""
|
||||
" Este error fatal ocurrió probablemente debido a un fallo.\n"
|
||||
|
||||
2
po/et.po
2
po/et.po
@@ -487,7 +487,7 @@ msgstr "Window Maker võttis vastu signaali %i."
|
||||
|
||||
#: ../src/dialog.c:1573
|
||||
msgid ""
|
||||
" This fatal error occured probably due to a bug. Please fill the included "
|
||||
" This fatal error occurred probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it to %s."
|
||||
msgstr ""
|
||||
" See fataalviga on arvatavasti põhjustatud programmi enese veast. Palun "
|
||||
|
||||
5
po/fi.po
5
po/fi.po
@@ -13,6 +13,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2001-09-03 21:56+03:00\n"
|
||||
"Last-Translator: Tomi Kajala <tomi@iki.fi>\n"
|
||||
"Language-Team: Finnish <fi@li.org>\n"
|
||||
"Language: fi\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8-bit\n"
|
||||
@@ -465,7 +466,7 @@ msgstr "Window Maker vastaanotti signaalin %i."
|
||||
|
||||
#: ../src/dialog.c:1707
|
||||
msgid ""
|
||||
" This fatal error occured probably due to a bug. Please fill the included "
|
||||
" This fatal error occurred probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it to %s."
|
||||
msgstr ""
|
||||
" Tämä vakava virhe tapahtui luultavasti bugin johdosta. Ole hyvä ja täytä "
|
||||
@@ -1389,7 +1390,7 @@ msgstr "vaihtoehtoisen ikkunamanagerin käynnistys epäonnistui. Keskeytetään.
|
||||
|
||||
#: ../src/startup.c:412
|
||||
msgid ""
|
||||
"a fatal error has occured, probably due to a bug. Please fill the included "
|
||||
"a fatal error has occurred, probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it."
|
||||
msgstr ""
|
||||
"vakava virhe on tapahtunut - luultavasti bugin johdosta. Ole hyvä ja täytä "
|
||||
|
||||
3
po/fr.po
3
po/fr.po
@@ -12,6 +12,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2002-01-21 07:08+0100\n"
|
||||
"Last-Translator: Antoine Hulin <antoine.hulin@origan.fdn.org>\n"
|
||||
"Language-Team: French <fr@li.org>\n"
|
||||
"Language: fr\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8-bit\n"
|
||||
@@ -481,7 +482,7 @@ msgstr "Window Maker a reçu le signal %i."
|
||||
#: ../src/dialog.c:1632
|
||||
#, c-format
|
||||
msgid ""
|
||||
" This fatal error occured probably due to a bug. Please fill the included "
|
||||
" This fatal error occurred probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it to %s."
|
||||
msgstr ""
|
||||
" Cette erreur est probablement due à un bogue. Remplissez le formulaire "
|
||||
|
||||
8
po/fy.po
8
po/fy.po
@@ -2086,11 +2086,3 @@ msgstr "toets %s (0x%x) generearret sawol %s as %s, wat ûnsinnich is"
|
||||
#, c-format
|
||||
msgid "Can't convert keymask 0x%04X to a shortcut label"
|
||||
msgstr "Kin 'keymask' 0x%04X net omsette nei fluchtoetsbeneaming"
|
||||
|
||||
# Keep next entry for wmaker-0.95.7
|
||||
msgid ""
|
||||
" This fatal error occured probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it to %s."
|
||||
msgstr ""
|
||||
" Dizze ûnwerstelbere flater trede mooglik op troch in bug. Folje a.j.w. "
|
||||
"bygeand BUGFORM yn, en rapportearje it oan %s."
|
||||
|
||||
5
po/gl.po
5
po/gl.po
@@ -14,6 +14,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2000-10-15 17:57+0200\n"
|
||||
"Last-Translator: Jesús Bravo Álvarez <jba@pobox.com>\n"
|
||||
"Language-Team: Galician <trasno@ceu.fi.udc.es>\n"
|
||||
"Language: gl\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
@@ -359,7 +360,7 @@ msgstr "O Window Maker recibiu un sinal %i."
|
||||
|
||||
#: ../src/dialog.c:1564
|
||||
msgid ""
|
||||
" This fatal error occured probably due to a bug. Please fill the included "
|
||||
" This fatal error occurred probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it to %s."
|
||||
msgstr ""
|
||||
" Este erro grave ocorreu probablemente por mor dun erro do programa. Por "
|
||||
@@ -1240,7 +1241,7 @@ msgstr "fallou o inicio dun xestor de fiestras alternativo. Abortando."
|
||||
|
||||
#: ../src/startup.c:352
|
||||
msgid ""
|
||||
"a fatal error has occured, probably due to a bug. Please fill the included "
|
||||
"a fatal error has occurred, probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it."
|
||||
msgstr ""
|
||||
"ocorreu un erro moi grave, probablemente por mor dun erro de programación. "
|
||||
|
||||
1
po/hr.po
1
po/hr.po
@@ -8,6 +8,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 1998-08-18 16:28:19+0200\n"
|
||||
"Last-Translator: Toni Bilić <tbilic@oliver.efos.hr>\n"
|
||||
"Language-Team: Croatian\n"
|
||||
"Language: hr\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
|
||||
6
po/hu.po
6
po/hu.po
@@ -11,7 +11,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2014-02-18 00:23+0100\n"
|
||||
"Last-Translator: BALATON Zoltán <balaton@eik.bme.hu>\n"
|
||||
"Language-Team: Hungarian\n"
|
||||
"Language: \n"
|
||||
"Language: hu\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
@@ -491,7 +491,7 @@ msgstr "A Window Maker %i jelzést kapott."
|
||||
|
||||
#: ../../wmaker-crm/src/dialog.c:1599
|
||||
msgid ""
|
||||
" This fatal error occured probably due to a bug. Please fill the included "
|
||||
" This fatal error occurred probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it to %s."
|
||||
msgstr " Ezt a végzetes hibát valószínűleg egy programozási hiba okozta. Légy szíves töltsd ki a mellékelt BUGFORM kérdőívet és küldd el a %s e-mail címre!"
|
||||
|
||||
@@ -800,7 +800,7 @@ msgstr "a beállítás adatbázist tartalmazó egységet lecsatolták. \"--stati
|
||||
msgid "Inotify: Reading config files in defaults database."
|
||||
msgstr "Inotify: újraolvasom a konfigurációs fájlokat a beállítás adatbázisból."
|
||||
|
||||
#. an error has occured
|
||||
#. an error has occurred
|
||||
#: ../../wmaker-crm/src/event.c:391
|
||||
msgid ""
|
||||
"select failed. The inotify instance will be closed. Changes to the defaults "
|
||||
|
||||
3
po/it.po
3
po/it.po
@@ -11,6 +11,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2005-03-04 16:33+0000\n"
|
||||
"Last-Translator: Marco Colombo <m.colombo@ed.ac.uk>\n"
|
||||
"Language-Team: Italian <tp@lists.linux.it@li.org>\n"
|
||||
"Language: it\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
@@ -526,7 +527,7 @@ msgstr "Window Maker ha ricevuto il segnale %i."
|
||||
|
||||
#: ../src/dialog.c:1768
|
||||
msgid ""
|
||||
" This fatal error occured probably due to a bug. Please fill the included "
|
||||
" This fatal error occurred probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it to %s."
|
||||
msgstr ""
|
||||
" Questo errore fatale è probabilmente dovuto ad un bug. Si prega di "
|
||||
|
||||
2
po/ja.po
2
po/ja.po
@@ -460,7 +460,7 @@ msgstr "Window Maker は シグナル %i を受けました."
|
||||
|
||||
#: ../src/dialog.c:1576
|
||||
msgid ""
|
||||
" This fatal error occured probably due to a bug. Please fill the included "
|
||||
" This fatal error occurred probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it to %s."
|
||||
msgstr ""
|
||||
"この致命的なエラーはバグによるものかもしれません. 同梱のバグフォームを使って "
|
||||
|
||||
5
po/ko.po
5
po/ko.po
@@ -12,6 +12,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2013-08-12 23:57+0900\n"
|
||||
"Last-Translator: \n"
|
||||
"Language-Team: Korean\n"
|
||||
"Language: ko\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
@@ -471,7 +472,7 @@ msgstr "윈도우 메이커가 %i 신호를 받음."
|
||||
|
||||
#: ../src/dialog.c:1596
|
||||
msgid ""
|
||||
" This fatal error occured probably due to a bug. Please fill the included "
|
||||
" This fatal error occurred probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it to %s."
|
||||
msgstr ""
|
||||
"버그로 인해 치명적인 오류가 발생했습니다. BUGFORM을 작성하여 "
|
||||
@@ -1953,7 +1954,7 @@ msgstr "마지막으로 사용됨"
|
||||
#~ msgstr "대체용 창 관리자를 실행 실패. 종료."
|
||||
|
||||
#~ msgid ""
|
||||
#~ "a fatal error has occured, probably due to a bug. Please fill the "
|
||||
#~ "a fatal error has occurred, probably due to a bug. Please fill the "
|
||||
#~ "included BUGFORM and report it."
|
||||
#~ msgstr ""
|
||||
#~ "치명적인 오류 발생, 아마도 버그인 것 같습니다. BUGFORM을 작성해 보내주시"
|
||||
|
||||
5
po/ms.po
5
po/ms.po
@@ -10,6 +10,7 @@ msgstr ""
|
||||
"Last-Translator: Hasbullah Bin Pit <sebol@ikhlas.com>\n"
|
||||
"Language-Team: Projek Gabai (Bahasa Melayu) <gabai-penyumbang@lists."
|
||||
"sourceforge.net>\n"
|
||||
"Language: ms\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
@@ -456,7 +457,7 @@ msgstr "Window Maker menerima isyarat %i."
|
||||
|
||||
#: ../src/dialog.c:1786
|
||||
msgid ""
|
||||
" This fatal error occured probably due to a bug. Please fill the included "
|
||||
" This fatal error occurred probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it to %s."
|
||||
msgstr ""
|
||||
" Ralat fatal ini berlaku kemungkinan disebabkan pepijat. Sila ini BUGFORM "
|
||||
@@ -1414,7 +1415,7 @@ msgstr "gagl menghidupkan pengurus tetingkap lain. Diabaikan."
|
||||
|
||||
#: ../src/startup.c:419
|
||||
msgid ""
|
||||
"a fatal error has occured, probably due to a bug. Please fill the included "
|
||||
"a fatal error has occurred, probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it."
|
||||
msgstr ""
|
||||
"ralat fatal berlaku, mungkin kerana pepijat. Sila ini BUGFORM yang "
|
||||
|
||||
8
po/nl.po
8
po/nl.po
@@ -2090,11 +2090,3 @@ msgstr "toets %s (0x%x) genereert zowel %s als %s, wat onzinnig is"
|
||||
#, c-format
|
||||
msgid "Can't convert keymask 0x%04X to a shortcut label"
|
||||
msgstr "Kan 'keymask' 0x%04X niet omzetten naar sneltoetsbenaming"
|
||||
|
||||
# Keep next entry for wmaker-0.95.7
|
||||
msgid ""
|
||||
" This fatal error occured probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it to %s."
|
||||
msgstr ""
|
||||
" Deze onherstelbare fout trad mogelijk op door 'n bug. Vul a.u.b. "
|
||||
"bijgaand BUGFORM in, en rapporteer 't aan %s."
|
||||
|
||||
1
po/no.po
1
po/no.po
@@ -9,6 +9,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 1998-05-23 H12:54+0200\n"
|
||||
"Last-Translator: Marcus Ramberg <draven@mo.himolde.no>\n"
|
||||
"Language-Team: Norwegian \n"
|
||||
"Language: no\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8-bit\n"
|
||||
|
||||
3
po/pl.po
3
po/pl.po
@@ -12,6 +12,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2003-04-15 20:21+0200\n"
|
||||
"Last-Translator: Piotr Dembiński <pdemb@fanthom.math.put.poznan.pl>\n"
|
||||
"Language-Team: Polish <pl@li.org>\n"
|
||||
"Language: pl\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8-bit\n"
|
||||
@@ -982,7 +983,7 @@ msgid "crashed while trying to do some post-crash cleanup. Aborting immediatelly
|
||||
msgstr "załamanie podczas próby uporządkowania po załamaniu. Wyjście awaryjne."
|
||||
|
||||
#: ../src/startup.c:304
|
||||
msgid "a fatal error has occured, probably due to a bug. Please fill the included BUGFORM and report it."
|
||||
msgid "a fatal error has occurred, probably due to a bug. Please fill the included BUGFORM and report it."
|
||||
msgstr "wystąpił poważny błąd, prawdopodobnie pluskwa. Prosimy o wypełnienie formularza BUGFORM i wysłanie go do nas."
|
||||
|
||||
#. restart another window manager so that the X session doesn't
|
||||
|
||||
5
po/pt.po
5
po/pt.po
@@ -12,6 +12,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2000-06-06 14:11-03:00\n"
|
||||
"Last-Translator: Marcia Norie Nakaza <norie@conectiva.com.br>\n"
|
||||
"Language-Team: Brazilian Portuguese <ldp-br@bazar.conectiva.com.br> \n"
|
||||
"Language: pt\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8-bit\n"
|
||||
@@ -352,7 +353,7 @@ msgstr "O Window Maker recebeu o sinal %i."
|
||||
|
||||
#: ../src/dialog.c:1564
|
||||
msgid ""
|
||||
" This fatal error occured probably due to a bug. Please fill the included "
|
||||
" This fatal error occurred probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it to %s."
|
||||
msgstr ""
|
||||
" Este erro fatal ocorreu provavelmente devido a uma falha.\n"
|
||||
@@ -1230,7 +1231,7 @@ msgstr "tentativa de iniciar gerenciador alternativo falhou. Abortando."
|
||||
|
||||
#: ../src/startup.c:352
|
||||
msgid ""
|
||||
"a fatal error has occured, probably due to a bug. Please fill the included "
|
||||
"a fatal error has occurred, probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it."
|
||||
msgstr ""
|
||||
"um erro fatal ocorreu, provavelmente devido a uma falha. Por favor preencha "
|
||||
|
||||
1
po/ro.po
1
po/ro.po
@@ -6,6 +6,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 1998-09-08 22:00:00-0300\n"
|
||||
"Last-Translator: AndreiVuta(gigi_man@manag.pub.ro)\n"
|
||||
"Language-Team: Romanian \n"
|
||||
"Language: ro\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8-bit\n"
|
||||
|
||||
5
po/ru.po
5
po/ru.po
@@ -16,6 +16,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2002-10-04 08:56+0300\n"
|
||||
"Last-Translator: awn@bcs.zp.ua\n"
|
||||
"Language-Team: Russian\n"
|
||||
"Language: ru\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
@@ -487,7 +488,7 @@ msgstr "Window Maker: получен сигнал %i."
|
||||
#: ../src/dialog.c:1632
|
||||
#, c-format
|
||||
msgid ""
|
||||
" This fatal error occured probably due to a bug. Please fill the included "
|
||||
" This fatal error occurred probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it to %s."
|
||||
msgstr ""
|
||||
" Эта критическая ошибка, возможно, является результатом ошибки в программе. "
|
||||
@@ -1438,7 +1439,7 @@ msgstr "не удалось запустить альтернативный ди
|
||||
|
||||
#: ../src/startup.c:419
|
||||
msgid ""
|
||||
"a fatal error has occured, probably due to a bug. Please fill the included "
|
||||
"a fatal error has occurred, probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it."
|
||||
msgstr ""
|
||||
"возникла критическая ошибка. Возможно, это результат ошибки в программе. "
|
||||
|
||||
5
po/sk.po
5
po/sk.po
@@ -21,6 +21,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2001-12-20 03:53+0100\n"
|
||||
"Last-Translator: Jan \"judas\" Tomka <judas@linux.sk>\n"
|
||||
"Language-Team: Slovak <sk@li.org>\n"
|
||||
"Language: sk\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
@@ -498,7 +499,7 @@ msgstr "Window Maker prijal signál %i."
|
||||
#: ../src/dialog.c:1632
|
||||
#, c-format
|
||||
msgid ""
|
||||
" This fatal error occured probably due to a bug. Please fill the included "
|
||||
" This fatal error occurred probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it to %s."
|
||||
msgstr ""
|
||||
"Táto fatálna chyba sa vyskytla "
|
||||
@@ -1480,7 +1481,7 @@ msgstr "nepodarilo sa spustiť alternatívny manažér okien. Koniec."
|
||||
|
||||
#: ../src/startup.c:419
|
||||
msgid ""
|
||||
"a fatal error has occured, probably due to a bug. Please fill the included "
|
||||
"a fatal error has occurred, probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it."
|
||||
msgstr ""
|
||||
"fatálna chyba nastala pravdepodobne v dôsledku chyby vo Window Makery. "
|
||||
|
||||
1
po/sv.po
1
po/sv.po
@@ -7,6 +7,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 1997-06-02 18:29:09-0300\n"
|
||||
"Last-Translator: John <forgoil@rsn.hk-r.se>\n"
|
||||
"Language-Team: Swedish \n"
|
||||
"Language: sv\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8-bit\n"
|
||||
|
||||
1
po/tr.po
1
po/tr.po
@@ -4,6 +4,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 1998-03-12 18:29:09+EET\n"
|
||||
"Last-Translator: KGF <kgf@wpi.edu>\n"
|
||||
"Language-Team: Turkish \n"
|
||||
"Language: tr\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8-bit\n"
|
||||
|
||||
5
po/uk.po
5
po/uk.po
@@ -5,6 +5,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2005-09-06 08:56+0300\n"
|
||||
"Last-Translator: Victor Forsyuk <victor@ksi-linux.com>\n"
|
||||
"Language-Team: KSI Linux Ukrainian <uk@ksi-linux.com>\n"
|
||||
"Language: uk\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
@@ -479,7 +480,7 @@ msgstr "Window Maker: отримано сигнал %i."
|
||||
|
||||
#: ../src/dialog.c:1790
|
||||
msgid ""
|
||||
" This fatal error occured probably due to a bug. Please fill the included "
|
||||
" This fatal error occurred probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it to %s."
|
||||
msgstr ""
|
||||
" Ця критична помилка, можливо, є результатом помилки в програмі. Будь ласка, "
|
||||
@@ -1448,7 +1449,7 @@ msgstr "не вдалось запустити альтернативний ме
|
||||
|
||||
#: ../src/startup.c:419
|
||||
msgid ""
|
||||
"a fatal error has occured, probably due to a bug. Please fill the included "
|
||||
"a fatal error has occurred, probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it."
|
||||
msgstr ""
|
||||
"виникла критична помилка. Можливо, це результат помилки в програмі. Будь "
|
||||
|
||||
@@ -9,6 +9,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 1999-07-05 21:30+0800\n"
|
||||
"Last-Translator: Wang Jian <larkw@263.net>\n"
|
||||
"Language-Team: chinese <zh@li.org>\n"
|
||||
"Language: zh_CN\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8-bit\n"
|
||||
@@ -300,7 +301,7 @@ msgstr "Window Maker收到信号%i."
|
||||
|
||||
#: ../src/dialog.c:1450
|
||||
msgid ""
|
||||
" This fatal error occured probably due to a bug. Please fill the included "
|
||||
" This fatal error occurred probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it to %s."
|
||||
msgstr ""
|
||||
"发生一个致命错误,也许是因为一个 bug.请填写好软件中包含的 BUGFORM 并向"
|
||||
@@ -1163,7 +1164,7 @@ msgstr "无法启动替代的窗口管理器.中止."
|
||||
|
||||
#: ../src/startup.c:349
|
||||
msgid ""
|
||||
"a fatal error has occured, probably due to a bug. Please fill the included "
|
||||
"a fatal error has occurred, probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it."
|
||||
msgstr ""
|
||||
"发生一个致命错误,也许是因为一个 bug.请填写好软件中包含的 BUGFORM 并报告 bug."
|
||||
|
||||
@@ -11,6 +11,7 @@ msgstr ""
|
||||
"PO-Revision-Date: 2005-01-11 17:45+0800\n"
|
||||
"Last-Translator: Li Wei Jih <lwj83@cs.ccu.edu.tw>\n"
|
||||
"Language-Team: chinese <zh@li.org>\n"
|
||||
"Language: zh_TW\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8-bit\n"
|
||||
@@ -512,7 +513,7 @@ msgstr "Window Maker 收到訊號 %i。"
|
||||
|
||||
#: ../src/dialog.c:1768
|
||||
msgid ""
|
||||
" This fatal error occured probably due to a bug. Please fill the included "
|
||||
" This fatal error occurred probably due to a bug. Please fill the included "
|
||||
"BUGFORM and report it to %s."
|
||||
msgstr ""
|
||||
"這個嚴重錯誤可能是因為程式錯誤所致。請填寫附帶的 BUGFORM 並向 "
|
||||
@@ -1927,7 +1928,7 @@ msgstr "刪除最後的工作區"
|
||||
#~ msgstr "另一套視窗管理員啟動失敗。放棄中。"
|
||||
|
||||
#~ msgid ""
|
||||
#~ "a fatal error has occured, probably due to a bug. Please fill the "
|
||||
#~ "a fatal error has occurred, probably due to a bug. Please fill the "
|
||||
#~ "included BUGFORM and report it."
|
||||
#~ msgstr "發生嚴重錯誤,可能因為程式錯誤。請填寫 BUGFORM 並提出報告。"
|
||||
|
||||
|
||||
@@ -91,7 +91,7 @@ while [ $# -gt 0 ]; do
|
||||
;;
|
||||
|
||||
-h|-help|--help) print_help ;;
|
||||
-*) arg_error "unknow option '$1'" ;;
|
||||
-*) arg_error "unknown option '$1'" ;;
|
||||
|
||||
*)
|
||||
arg_error "argument '$1' is not understood"
|
||||
|
||||
@@ -75,7 +75,7 @@ while [ $# -gt 0 ]; do
|
||||
;;
|
||||
|
||||
-h|-help|--help) print_help ;;
|
||||
-*) arg_error "unknow option '$1'" ;;
|
||||
-*) arg_error "unknown option '$1'" ;;
|
||||
|
||||
*)
|
||||
[ "x$trans_dir" != "x" ] || arg_error "only 1 directory can be specified for translation"
|
||||
@@ -226,7 +226,7 @@ END {
|
||||
error_count++;
|
||||
}
|
||||
|
||||
# If error(s) occured, use non-zero status to stop 'make'
|
||||
# If error(s) occurred, use non-zero status to stop 'make'
|
||||
# We use 3 to distinguish for awk's possible own problems (status 1 or 2)
|
||||
if (error_count > 0) { exit 3 }
|
||||
}"
|
||||
|
||||
@@ -120,7 +120,7 @@ $1"
|
||||
;;
|
||||
|
||||
-h|-help|--help) print_help ;;
|
||||
-*) arg_error "unknow option '$1'" ;;
|
||||
-*) arg_error "unknown option '$1'" ;;
|
||||
|
||||
*)
|
||||
arg_error "argument '$1' is not understood"
|
||||
|
||||
@@ -119,7 +119,7 @@ while [ $# -gt 0 ]; do
|
||||
;;
|
||||
|
||||
-h|-help|--help) print_help ;;
|
||||
-*) arg_error "unknow option '$1'" ;;
|
||||
-*) arg_error "unknown option '$1'" ;;
|
||||
|
||||
*)
|
||||
[ -z "$input_file" ] || arg_error "only 1 man page can be specified"
|
||||
|
||||
@@ -83,7 +83,7 @@ while [ $# -gt 0 ]; do
|
||||
;;
|
||||
|
||||
-h|-help|--help) print_help ;;
|
||||
-*) arg_error "unknow option '$1'" ;;
|
||||
-*) arg_error "unknown option '$1'" ;;
|
||||
|
||||
*)
|
||||
[ -r "$1" ] || arg_error "source file \"$1\" is not readable"
|
||||
|
||||
@@ -90,7 +90,7 @@ while [ $# -gt 0 ]; do
|
||||
project_version="$1"
|
||||
;;
|
||||
|
||||
-*) arg_error "unknow option '$1'" ;;
|
||||
-*) arg_error "unknown option '$1'" ;;
|
||||
|
||||
*)
|
||||
[ "x$lang_file" = "x" ] || arg_error "only 1 po file can be specified, not \"$lang_file\" and \"$1\""
|
||||
|
||||
@@ -151,7 +151,7 @@ while [ $# -gt 0 ]; do
|
||||
project_version="$1"
|
||||
;;
|
||||
|
||||
-*) arg_error "unknow option '$1'" ;;
|
||||
-*) arg_error "unknown option '$1'" ;;
|
||||
|
||||
*)
|
||||
[ "x$input_file" = "x" ] || arg_error "only 1 input file can be specified, not \"$input_file\" and \"$1\""
|
||||
@@ -903,7 +903,7 @@ function execute_commands(line, replaced_line, command) {
|
||||
# Variable and Conditional commands ########################################
|
||||
} else if (command == "value") {
|
||||
if (variable[cmdargs] == "") {
|
||||
report_error("variable '" cmdargs "' is unknow, for @value at line " NR);
|
||||
report_error("variable '" cmdargs "' is unknown, for @value at line " NR);
|
||||
}
|
||||
line = variable[cmdargs] line;
|
||||
|
||||
@@ -913,7 +913,7 @@ function execute_commands(line, replaced_line, command) {
|
||||
line = "";
|
||||
|
||||
} else {
|
||||
report_error("unknow command @" command " at line " NR);
|
||||
report_error("unknown command @" command " at line " NR);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -971,7 +971,7 @@ function process_end(line) {
|
||||
par_indent = 0;
|
||||
|
||||
} else {
|
||||
report_error("unknow command @end " line " at line " NR);
|
||||
report_error("unknown command @end " line " at line " NR);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -108,7 +108,7 @@ while [ $# -gt 0 ]; do
|
||||
|
||||
-h|-help|--help) print_help ;;
|
||||
-o) shift ; output_file="$1" ;;
|
||||
-*) arg_error "unknow option '$1'" ;;
|
||||
-*) arg_error "unknown option '$1'" ;;
|
||||
|
||||
*)
|
||||
[ "x$input_file" = "x" ] || arg_error "only 1 input file can be specified, not \"$input_file\" and \"$1\""
|
||||
|
||||
@@ -120,7 +120,7 @@ while [ $# -gt 0 ]; do
|
||||
list_replaces="$list_replaces $1"
|
||||
;;
|
||||
|
||||
-*) arg_error "unknow option '$1'" ;;
|
||||
-*) arg_error "unknown option '$1'" ;;
|
||||
|
||||
*)
|
||||
[ "x$input_file" = "x" ] || arg_error "only 1 input file can be specified, not \"$input_file\" and \"$1\""
|
||||
|
||||
@@ -93,7 +93,7 @@ while [ $# -gt 0 ]; do
|
||||
;;
|
||||
|
||||
-h|-help|--help) print_help ;;
|
||||
-*) arg_error "unknow option '$1'" ;;
|
||||
-*) arg_error "unknown option '$1'" ;;
|
||||
|
||||
*)
|
||||
[ -z "$edit_file" ] || arg_error "only 1 file to modify can be specified"
|
||||
|
||||
@@ -6,7 +6,13 @@ bin_PROGRAMS = wmaker
|
||||
|
||||
EXTRA_DIST =
|
||||
|
||||
wmakerlib = $(top_builddir)/wmakerlib/target/debug/libwmakerlib.a
|
||||
|
||||
$(wmakerlib):
|
||||
@(cd $(top_builddir)/wmakerlib && cargo build)
|
||||
|
||||
wmaker_SOURCES = \
|
||||
$(wmakerlib) \
|
||||
GNUstep.h \
|
||||
WindowMaker.h \
|
||||
actions.c \
|
||||
@@ -134,7 +140,7 @@ else
|
||||
nodist_wmaker_SOURCES = misc.hack_nf.c \
|
||||
xmodifier.hack_nf.c
|
||||
|
||||
CLEANFILES = $(nodist_wmaker_SOURCES)
|
||||
CLEANFILES = $(nodist_wmaker_SOURCES) ../wmakerlib/target
|
||||
|
||||
misc.hack_nf.c: misc.c $(top_srcdir)/script/nested-func-to-macro.sh
|
||||
$(AM_V_GEN)$(top_srcdir)/script/nested-func-to-macro.sh \
|
||||
@@ -160,6 +166,7 @@ wmaker_LDADD = \
|
||||
$(top_builddir)/WINGs/libWINGs.la\
|
||||
$(top_builddir)/WINGs/libWUtil.la\
|
||||
$(top_builddir)/wrlib/libwraster.la\
|
||||
$(wmakerlib)\
|
||||
@XLFLAGS@ \
|
||||
@LIBXRANDR@ \
|
||||
@LIBXINERAMA@ \
|
||||
|
||||
@@ -504,6 +504,12 @@ extern struct WPreferences {
|
||||
/****** Global Variables ******/
|
||||
extern Display *dpy;
|
||||
|
||||
struct wmaker_global_variables_context {
|
||||
XContext client_win;
|
||||
XContext app_win;
|
||||
XContext stack;
|
||||
};
|
||||
|
||||
extern struct wmaker_global_variables {
|
||||
/* Tracking of the state of the program */
|
||||
struct {
|
||||
@@ -603,11 +609,7 @@ extern struct wmaker_global_variables {
|
||||
} atom;
|
||||
|
||||
/* X Contexts */
|
||||
struct {
|
||||
XContext client_win;
|
||||
XContext app_win;
|
||||
XContext stack;
|
||||
} context;
|
||||
struct wmaker_global_variables_context context;
|
||||
|
||||
/* X Extensions */
|
||||
struct {
|
||||
@@ -666,4 +668,9 @@ extern const char WMNWorkspaceNameChanged[];
|
||||
|
||||
extern const char WMNResetStacking[];
|
||||
|
||||
|
||||
/****** Accessors/mutators for Rust ******/
|
||||
struct wmaker_global_variables_context *wGlobalGetContext();
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
@@ -148,7 +148,7 @@ void wSetFocusTo(WScreen *scr, WWindow *wwin)
|
||||
wWindowUnfocus(old_focused);
|
||||
|
||||
if (oapp) {
|
||||
wAppMenuUnmap(oapp->menu);
|
||||
wAppMenuUnmap(wApplicationGetMenu(oapp));
|
||||
if (wPreferences.highlight_active_app)
|
||||
wApplicationDeactivate(oapp);
|
||||
}
|
||||
@@ -165,7 +165,7 @@ void wSetFocusTo(WScreen *scr, WWindow *wwin)
|
||||
|
||||
/* remember last workspace where the app has been */
|
||||
if (napp)
|
||||
napp->last_workspace = wwin->frame->workspace;
|
||||
wApplicationSetLastWorkspace(napp, wwin->frame->workspace);
|
||||
|
||||
if (wwin->flags.mapped && !WFLAGP(wwin, no_focusable)) {
|
||||
/* install colormap if colormap mode is lock mode */
|
||||
@@ -212,7 +212,7 @@ void wSetFocusTo(WScreen *scr, WWindow *wwin)
|
||||
scr->focused_window = wwin;
|
||||
|
||||
if (oapp && oapp != napp) {
|
||||
wAppMenuUnmap(oapp->menu);
|
||||
wAppMenuUnmap(wApplicationGetMenu(oapp));
|
||||
if (wPreferences.highlight_active_app)
|
||||
wApplicationDeactivate(oapp);
|
||||
}
|
||||
@@ -226,12 +226,12 @@ void wSetFocusTo(WScreen *scr, WWindow *wwin)
|
||||
|
||||
if (napp && !wasfocused) {
|
||||
#ifdef USER_MENU
|
||||
wUserMenuRefreshInstances(napp->menu, wwin);
|
||||
wUserMenuRefreshInstances(wApplicationGetMenu(napp), wwin);
|
||||
#endif /* USER_MENU */
|
||||
|
||||
/* kix: Only menu map with mouse, not alt+tab! */
|
||||
if (wwin->flags.mapped)
|
||||
wAppMenuMap(napp->menu, wwin);
|
||||
wAppMenuMap(wApplicationGetMenu(napp), wwin);
|
||||
}
|
||||
if (napp && wPreferences.highlight_active_app)
|
||||
wApplicationActivate(napp);
|
||||
@@ -1783,7 +1783,7 @@ void wHideOtherApplications(WWindow *awin)
|
||||
} else if (wwin->main_window != None && awin->main_window != wwin->main_window) {
|
||||
tapp = wApplicationOf(wwin->main_window);
|
||||
if (tapp) {
|
||||
tapp->flags.skip_next_animation = 1;
|
||||
wApplicationSetSkipNextAnimation(tapp, 1);
|
||||
wHideApplication(tapp);
|
||||
} else {
|
||||
if (!WFLAGP(wwin, no_miniaturizable)) {
|
||||
@@ -1811,37 +1811,39 @@ void wHideApplication(WApplication *wapp)
|
||||
wwarning("trying to hide a non grouped window");
|
||||
return;
|
||||
}
|
||||
if (!wapp->main_window_desc) {
|
||||
if (!wApplicationGetMainWindowDesc(wapp)) {
|
||||
wwarning("group leader not found for window group");
|
||||
return;
|
||||
}
|
||||
scr = wapp->main_window_desc->screen_ptr;
|
||||
scr = wApplicationGetMainWindowDesc(wapp)->screen_ptr;
|
||||
hadfocus = 0;
|
||||
wlist = scr->focused_window;
|
||||
if (!wlist)
|
||||
return;
|
||||
|
||||
if (wlist->main_window == wapp->main_window)
|
||||
wapp->last_focused = wlist;
|
||||
if (wlist->main_window == wApplicationGetMainWindow(wapp))
|
||||
wApplicationSetLastFocused(wapp, wlist);
|
||||
else
|
||||
wapp->last_focused = NULL;
|
||||
wApplicationSetLastFocused(wapp, NULL);
|
||||
|
||||
animate = !wapp->flags.skip_next_animation;
|
||||
animate = !wApplicationGetSkipNextAnimation(wapp);
|
||||
|
||||
while (wlist) {
|
||||
if (wlist->main_window == wapp->main_window) {
|
||||
if (wlist->main_window == wApplicationGetMainWindow(wapp)) {
|
||||
if (wlist->flags.focused)
|
||||
hadfocus = 1;
|
||||
if (wapp->app_icon) {
|
||||
hideWindow(wapp->app_icon->icon, wapp->app_icon->x_pos,
|
||||
wapp->app_icon->y_pos, wlist, animate);
|
||||
if (wApplicationGetAppIcon(wapp)) {
|
||||
hideWindow(wAppIconGetIcon(wApplicationGetAppIcon(wapp)),
|
||||
wAppIconGetXPos(wApplicationGetAppIcon(wapp)),
|
||||
wAppIconGetYPos(wApplicationGetAppIcon(wapp)),
|
||||
wlist, animate);
|
||||
animate = False;
|
||||
}
|
||||
}
|
||||
wlist = wlist->prev;
|
||||
}
|
||||
|
||||
wapp->flags.skip_next_animation = 0;
|
||||
wApplicationSetSkipNextAnimation(wapp, 0);
|
||||
|
||||
if (hadfocus) {
|
||||
if (wPreferences.focus_mode == WKF_CLICK) {
|
||||
@@ -1858,14 +1860,14 @@ void wHideApplication(WApplication *wapp)
|
||||
}
|
||||
}
|
||||
|
||||
wapp->flags.hidden = 1;
|
||||
wApplicationSetHidden(wapp, 1);
|
||||
|
||||
if (wPreferences.auto_arrange_icons)
|
||||
wArrangeIcons(scr, True);
|
||||
|
||||
#ifdef HIDDENDOT
|
||||
if (wapp->app_icon)
|
||||
wAppIconPaint(wapp->app_icon);
|
||||
if (wApplicationGetAppIcon(wapp))
|
||||
wAppIconPaint(wApplicationGetAppIcon(wapp));
|
||||
#endif
|
||||
}
|
||||
|
||||
@@ -1914,7 +1916,7 @@ void wUnhideApplication(WApplication *wapp, Bool miniwindows, Bool bringToCurren
|
||||
if (!wapp)
|
||||
return;
|
||||
|
||||
scr = wapp->main_window_desc->screen_ptr;
|
||||
scr = wApplicationGetMainWindowDesc(wapp)->screen_ptr;
|
||||
wlist = scr->focused_window;
|
||||
if (!wlist)
|
||||
return;
|
||||
@@ -1923,12 +1925,12 @@ void wUnhideApplication(WApplication *wapp, Bool miniwindows, Bool bringToCurren
|
||||
while (wlist->prev)
|
||||
wlist = wlist->prev;
|
||||
|
||||
animate = !wapp->flags.skip_next_animation;
|
||||
animate = !wApplicationGetSkipNextAnimation(wapp);
|
||||
|
||||
while (wlist) {
|
||||
next = wlist->next;
|
||||
|
||||
if (wlist->main_window == wapp->main_window) {
|
||||
if (wlist->main_window == wApplicationGetMainWindow(wapp)) {
|
||||
if (wlist->flags.focused)
|
||||
focused = wlist;
|
||||
else if (!focused || !focused->flags.focused)
|
||||
@@ -1968,8 +1970,8 @@ void wUnhideApplication(WApplication *wapp, Bool miniwindows, Bool bringToCurren
|
||||
}
|
||||
WMPostNotificationName(WMNChangedState, wlist, "hide");
|
||||
} else if (wlist->flags.hidden) {
|
||||
unhideWindow(wapp->app_icon->icon, wapp->app_icon->x_pos,
|
||||
wapp->app_icon->y_pos, wlist, animate, bringToCurrentWS);
|
||||
unhideWindow(wAppIconGetIcon(wApplicationGetAppIcon(wapp)), wAppIconGetXPos(wApplicationGetAppIcon(wapp)),
|
||||
wAppIconGetYPos(wApplicationGetAppIcon(wapp)), wlist, animate, bringToCurrentWS);
|
||||
animate = False;
|
||||
} else {
|
||||
if (bringToCurrentWS && wlist->frame->workspace != scr->current_workspace)
|
||||
@@ -1981,21 +1983,21 @@ void wUnhideApplication(WApplication *wapp, Bool miniwindows, Bool bringToCurren
|
||||
wlist = next;
|
||||
}
|
||||
|
||||
wapp->flags.skip_next_animation = 0;
|
||||
wapp->flags.hidden = 0;
|
||||
wApplicationSetSkipNextAnimation(wapp, 0);
|
||||
wApplicationSetHidden(wapp, 0);
|
||||
|
||||
if (wapp->last_focused && wapp->last_focused->flags.mapped) {
|
||||
wRaiseFrame(wapp->last_focused->frame->core);
|
||||
wSetFocusTo(scr, wapp->last_focused);
|
||||
if (wApplicationGetLastWorkspace(wapp) && wApplicationGetLastFocused(wapp)->flags.mapped) {
|
||||
wRaiseFrame(wApplicationGetLastFocused(wapp)->frame->core);
|
||||
wSetFocusTo(scr, wApplicationGetLastFocused(wapp));
|
||||
} else if (focused) {
|
||||
wSetFocusTo(scr, focused);
|
||||
}
|
||||
wapp->last_focused = NULL;
|
||||
wApplicationSetLastFocused(wapp, NULL);
|
||||
if (wPreferences.auto_arrange_icons)
|
||||
wArrangeIcons(scr, True);
|
||||
|
||||
#ifdef HIDDENDOT
|
||||
wAppIconPaint(wapp->app_icon);
|
||||
wAppIconPaint(wApplicationGetAppIcon(wapp));
|
||||
#endif
|
||||
}
|
||||
|
||||
@@ -2073,7 +2075,7 @@ void wArrangeIcons(WScreen *scr, Bool arrangeAll)
|
||||
if (scr->dock) {
|
||||
int offset = wPreferences.icon_size + DOCK_EXTRA_SPACE;
|
||||
|
||||
if (scr->dock->on_right_side)
|
||||
if (wDockIsOnRightSide(scr->dock))
|
||||
area.x2 -= offset;
|
||||
else
|
||||
area.x1 += offset;
|
||||
@@ -2128,20 +2130,20 @@ void wArrangeIcons(WScreen *scr, Bool arrangeAll)
|
||||
/* arrange application icons */
|
||||
aicon = scr->app_icon_list;
|
||||
/* reverse them to avoid unnecessarily sliding of icons */
|
||||
while (aicon && aicon->next)
|
||||
aicon = aicon->next;
|
||||
while (aicon && wAppIconGetNext(aicon))
|
||||
aicon = wAppIconGetNext(aicon);
|
||||
|
||||
while (aicon) {
|
||||
if (!aicon->docked) {
|
||||
if (!wAppIconIsDocked(aicon)) {
|
||||
/* CHECK: can icon be NULL here ? */
|
||||
/* The intention here is to place the AppIcon on the head that
|
||||
* contains most of the applications _main_ window. */
|
||||
head = wGetHeadForWindow(aicon->icon->owner);
|
||||
head = wGetHeadForWindow(wAppIconGetIcon(aicon)->owner);
|
||||
|
||||
if (aicon->x_pos != X || aicon->y_pos != Y) {
|
||||
if (wAppIconGetXPos(aicon) != X || wAppIconGetYPos(aicon) != Y) {
|
||||
#ifdef USE_ANIMATIONS
|
||||
if (!wPreferences.no_animations)
|
||||
slide_window(aicon->icon->core->window, aicon->x_pos, aicon->y_pos, X, Y);
|
||||
slide_window(wAppIconGetIcon(aicon)->core->window, wAppIconGetXPos(aicon), wAppIconGetYPos(aicon), X, Y);
|
||||
#endif /* USE_ANIMATIONS */
|
||||
}
|
||||
wAppIconMove(aicon, X, Y);
|
||||
@@ -2151,7 +2153,7 @@ void wArrangeIcons(WScreen *scr, Bool arrangeAll)
|
||||
vars[head].si++;
|
||||
}
|
||||
}
|
||||
aicon = aicon->prev;
|
||||
aicon = wAppIconGetPrev(aicon);
|
||||
}
|
||||
|
||||
/* arrange miniwindows */
|
||||
@@ -2243,7 +2245,7 @@ void wMakeWindowVisible(WWindow *wwin)
|
||||
app = wApplicationOf(wwin->main_window);
|
||||
if (app) {
|
||||
/* trick to get focus to this window */
|
||||
app->last_focused = wwin;
|
||||
wApplicationSetLastFocused(app, wwin);
|
||||
wUnhideApplication(app, False, False);
|
||||
}
|
||||
}
|
||||
|
||||
469
src/appicon.c
469
src/appicon.c
@@ -55,6 +55,255 @@
|
||||
#include "xdnd.h"
|
||||
#endif
|
||||
|
||||
struct WAppIcon {
|
||||
short xindex;
|
||||
short yindex;
|
||||
struct WAppIcon *next;
|
||||
struct WAppIcon *prev;
|
||||
WIcon *icon;
|
||||
int x_pos, y_pos; /* absolute screen coordinate */
|
||||
char *command; /* command used to launch app */
|
||||
#ifdef USE_DOCK_XDND
|
||||
char *dnd_command; /* command to use when something is */
|
||||
/* dropped on us */
|
||||
#endif
|
||||
char *paste_command; /* command to run when
|
||||
* something is pasted */
|
||||
char *wm_class;
|
||||
char *wm_instance;
|
||||
pid_t pid; /* for apps launched from the dock */
|
||||
Window main_window;
|
||||
struct WDock *dock; /* In which dock is docked. */
|
||||
struct _AppSettingsPanel *panel; /* Settings Panel */
|
||||
unsigned int docked;
|
||||
unsigned int omnipresent; /* If omnipresent when
|
||||
* docked in clip */
|
||||
unsigned int attracted; /* If it was attracted by the clip */
|
||||
unsigned int launching;
|
||||
unsigned int running; /* application is already running */
|
||||
unsigned int relaunching; /* launching 2nd instance */
|
||||
unsigned int forced_dock;
|
||||
unsigned int auto_launch; /* launch app on startup */
|
||||
unsigned int remote_start;
|
||||
unsigned int updated;
|
||||
unsigned int editing; /* editing docked icon */
|
||||
unsigned int drop_launch; /* launching from drop action */
|
||||
unsigned int paste_launch; /* launching from paste action */
|
||||
unsigned int destroyed; /* appicon was destroyed */
|
||||
unsigned int buggy_app; /* do not make dock rely on hints
|
||||
* set by app */
|
||||
unsigned int lock; /* do not allow to be destroyed */
|
||||
};
|
||||
|
||||
/******** Accessors/mutators ********/
|
||||
short wAppIconGetXIndex(WAppIcon *aicon) {
|
||||
return aicon->xindex;
|
||||
}
|
||||
void wAppIconSetXIndex(WAppIcon *aicon, short xindex) {
|
||||
aicon->xindex = xindex;
|
||||
}
|
||||
|
||||
short wAppIconGetYIndex(WAppIcon *aicon) {
|
||||
return aicon->yindex;
|
||||
}
|
||||
void wAppIconSetYIndex(WAppIcon *aicon, short yindex) {
|
||||
aicon->yindex = yindex;
|
||||
}
|
||||
|
||||
struct WAppIcon *wAppIconGetNext(WAppIcon *aicon) {
|
||||
return aicon->next;
|
||||
}
|
||||
|
||||
struct WAppIcon *wAppIconGetPrev(WAppIcon *aicon) {
|
||||
return aicon->prev;
|
||||
}
|
||||
|
||||
int wAppIconGetXPos(WAppIcon *aicon) {
|
||||
return aicon->x_pos;
|
||||
}
|
||||
void wAppIconSetXPos(WAppIcon *aicon, int x_pos) {
|
||||
aicon->x_pos = x_pos;
|
||||
}
|
||||
|
||||
int wAppIconGetYPos(WAppIcon *aicon) {
|
||||
return aicon->y_pos;
|
||||
}
|
||||
void wAppIconSetYPos(WAppIcon *aicon, int y_pos) {
|
||||
aicon->y_pos = y_pos;
|
||||
}
|
||||
|
||||
WIcon *wAppIconGetIcon(WAppIcon *aicon) {
|
||||
return aicon->icon;
|
||||
}
|
||||
|
||||
char *wAppIconGetCommand(WAppIcon *aicon) {
|
||||
return aicon->command;
|
||||
}
|
||||
void wAppIconSetCommand(WAppIcon *aicon, char *command) {
|
||||
if (aicon->command)
|
||||
wfree(aicon->command);
|
||||
if (command && (command[0] == 0 || (command[0] == '-' && command[1] == 0))) {
|
||||
wfree(command);
|
||||
command = NULL;
|
||||
}
|
||||
aicon->command = command;
|
||||
}
|
||||
|
||||
#ifdef USE_DOCK_XDND
|
||||
char *wAppIconGetDnDCommand(WAppIcon *aicon) {
|
||||
return aicon->dnd_command;
|
||||
}
|
||||
void wAppIconSetDnDCommand(WAppIcon *aicon, char *command) {
|
||||
if (aicon->dnd_command)
|
||||
wfree(aicon->dnd_command);
|
||||
if (command && (command[0] == 0 || (command[0] == '-' && command[1] == 0))) {
|
||||
wfree(command);
|
||||
command = NULL;
|
||||
}
|
||||
aicon->dnd_command = command;
|
||||
}
|
||||
#endif // USE_DOCK_XDND
|
||||
|
||||
char *wAppIconGetPasteCommand(WAppIcon *aicon) {
|
||||
return aicon->paste_command;
|
||||
}
|
||||
void wAppIconSetPasteCommand(WAppIcon *aicon, char *command) {
|
||||
if (aicon->paste_command)
|
||||
wfree(aicon->paste_command);
|
||||
if (command && (command[0] == 0 || (command[0] == '-' && command[1] == 0))) {
|
||||
wfree(command);
|
||||
command = NULL;
|
||||
}
|
||||
aicon->paste_command = command;
|
||||
}
|
||||
|
||||
char *wAppIconGetWmClass(WAppIcon *aicon) {
|
||||
return aicon->wm_class;
|
||||
}
|
||||
|
||||
char *wAppIconGetWmInstance(WAppIcon *aicon) {
|
||||
return aicon->wm_instance;
|
||||
}
|
||||
|
||||
pid_t wAppIconGetPid(WAppIcon *aicon) {
|
||||
return aicon->pid;
|
||||
}
|
||||
void wAppIconSetPid(WAppIcon *aicon, pid_t pid) {
|
||||
aicon->pid = pid;
|
||||
}
|
||||
|
||||
Window wAppIconGetMainWindow(WAppIcon *aicon) {
|
||||
return aicon->main_window;
|
||||
}
|
||||
void wAppIconSetMainWindow(WAppIcon *aicon, Window main_window) {
|
||||
aicon->main_window = main_window;
|
||||
}
|
||||
|
||||
struct WDock *wAppIconGetDock(WAppIcon *aicon) {
|
||||
return aicon->dock;
|
||||
}
|
||||
void wAppIconSetDock(WAppIcon *aicon, struct WDock *dock) {
|
||||
aicon->dock = dock;
|
||||
}
|
||||
|
||||
struct _AppSettingsPanel *wAppIconGetPanel(WAppIcon *aicon) {
|
||||
return aicon->panel;
|
||||
}
|
||||
void wAppIconSetPanel(WAppIcon *aicon, struct _AppSettingsPanel *panel) {
|
||||
aicon->panel = panel;
|
||||
}
|
||||
|
||||
int wAppIconIsDocked(WAppIcon *aicon) {
|
||||
return aicon->docked;
|
||||
}
|
||||
void wAppIconSetDocked(WAppIcon *aicon, int docked) {
|
||||
aicon->docked = !!docked;
|
||||
}
|
||||
|
||||
int wAppIconIsOmnipresent(WAppIcon *aicon) {
|
||||
return aicon->omnipresent;
|
||||
}
|
||||
void wAppIconSetOmnipresent(WAppIcon *aicon, int omnipresent) {
|
||||
aicon->omnipresent = !!omnipresent;
|
||||
}
|
||||
|
||||
int wAppIconIsAttracted(WAppIcon *aicon) {
|
||||
return aicon->attracted;
|
||||
}
|
||||
void wAppIconSetAttracted(WAppIcon *aicon, int attracted) {
|
||||
aicon->attracted = !!attracted;
|
||||
}
|
||||
|
||||
int wAppIconIsLaunching(WAppIcon *aicon) {
|
||||
return aicon->launching;
|
||||
}
|
||||
void wAppIconSetLaunching(WAppIcon *aicon, int launching) {
|
||||
aicon->launching = !!launching;
|
||||
}
|
||||
|
||||
int wAppIconIsRunning(WAppIcon *aicon) {
|
||||
return aicon->running;
|
||||
}
|
||||
void wAppIconSetRunning(WAppIcon *aicon, int running) {
|
||||
aicon->running = !!running;
|
||||
}
|
||||
|
||||
int wAppIconIsRelaunching(WAppIcon *aicon) {
|
||||
return aicon->relaunching;
|
||||
}
|
||||
void wAppIconSetRelaunching(WAppIcon *aicon, int relaunching) {
|
||||
aicon->relaunching = !!relaunching;
|
||||
}
|
||||
|
||||
int wAppIconIsForceDocked(WAppIcon *aicon) {
|
||||
return aicon->forced_dock;
|
||||
}
|
||||
void wAppIconSetForceDocked(WAppIcon *aicon, int forced_dock) {
|
||||
aicon->forced_dock = !!forced_dock;
|
||||
}
|
||||
|
||||
int wAppIconIsAutoLaunch(WAppIcon *aicon) {
|
||||
return aicon->auto_launch;
|
||||
}
|
||||
void wAppIconSetAutoLaunch(WAppIcon *aicon, int auto_launch) {
|
||||
aicon->auto_launch = !!auto_launch;
|
||||
}
|
||||
|
||||
int wAppIconIsEditing(WAppIcon *aicon) {
|
||||
return aicon->editing;
|
||||
}
|
||||
void wAppIconSetEditing(WAppIcon *aicon, int editing) {
|
||||
aicon->editing = !!editing;
|
||||
}
|
||||
|
||||
int wAppIconIsDropLaunch(WAppIcon *aicon) {
|
||||
return aicon->drop_launch;
|
||||
}
|
||||
void wAppIconSetDropLaunch(WAppIcon *aicon, int drop_launch) {
|
||||
aicon->drop_launch = !!drop_launch;
|
||||
}
|
||||
|
||||
int wAppIconIsPasteLaunch(WAppIcon *aicon) {
|
||||
return aicon->paste_launch;
|
||||
}
|
||||
void wAppIconSetPasteLaunch(WAppIcon *aicon, int paste_launch) {
|
||||
aicon->paste_launch = !!paste_launch;
|
||||
}
|
||||
|
||||
int wAppIconIsBuggyApp(WAppIcon *aicon) {
|
||||
return aicon->buggy_app;
|
||||
}
|
||||
void wAppIconSetBuggyApp(WAppIcon *aicon, int buggy_app) {
|
||||
aicon->buggy_app = !!buggy_app;
|
||||
}
|
||||
|
||||
int wAppIconIsLocked(WAppIcon *aicon) {
|
||||
return aicon->lock;
|
||||
}
|
||||
void wAppIconSetLocked(WAppIcon *aicon, int lock) {
|
||||
aicon->lock = !!lock;
|
||||
}
|
||||
|
||||
/*
|
||||
* icon_file for the dock is got from the preferences file by
|
||||
* using the classname/instancename
|
||||
@@ -147,16 +396,16 @@ WAppIcon *wAppIconCreateForDock(WScreen *scr, const char *command, const char *w
|
||||
void create_appicon_for_application(WApplication *wapp, WWindow *wwin)
|
||||
{
|
||||
/* Try to create an icon from the dock or clip */
|
||||
create_appicon_from_dock(wwin, wapp, wapp->main_window);
|
||||
create_appicon_from_dock(wwin, wapp, wApplicationGetMainWindow(wapp));
|
||||
|
||||
/* If app_icon was not found, create it */
|
||||
if (!wapp->app_icon) {
|
||||
if (!wApplicationGetAppIcon(wapp)) {
|
||||
/* Create the icon */
|
||||
wapp->app_icon = wAppIconCreate(wapp->main_window_desc);
|
||||
wIconUpdate(wapp->app_icon->icon);
|
||||
wApplicationSetAppIcon(wapp, wAppIconCreate(wApplicationGetMainWindowDesc(wapp)));
|
||||
wIconUpdate(wApplicationGetAppIcon(wapp)->icon);
|
||||
|
||||
/* Now, paint the icon */
|
||||
if (!WFLAGP(wapp->main_window_desc, no_appicon))
|
||||
if (!WFLAGP(wApplicationGetMainWindowDesc(wapp), no_appicon))
|
||||
paint_app_icon(wapp);
|
||||
}
|
||||
|
||||
@@ -164,8 +413,8 @@ void create_appicon_for_application(WApplication *wapp, WWindow *wwin)
|
||||
* window data are known - so try to save the icon file for docked
|
||||
* applications to ensure that the file exists when window maker
|
||||
* starts up next time. */
|
||||
if (wapp->app_icon->docked && !WFLAGP(wapp->main_window_desc, no_appicon))
|
||||
save_appicon(wapp->app_icon);
|
||||
if (wApplicationGetAppIcon(wapp)->docked && !WFLAGP(wApplicationGetMainWindowDesc(wapp), no_appicon))
|
||||
save_appicon(wApplicationGetAppIcon(wapp));
|
||||
}
|
||||
|
||||
void unpaint_app_icon(WApplication *wapp)
|
||||
@@ -174,19 +423,19 @@ void unpaint_app_icon(WApplication *wapp)
|
||||
WScreen *scr;
|
||||
WDock *clip;
|
||||
|
||||
if (!wapp || !wapp->app_icon)
|
||||
if (!wapp || !wApplicationGetAppIcon(wapp))
|
||||
return;
|
||||
|
||||
aicon = wapp->app_icon;
|
||||
aicon = wApplicationGetAppIcon(wapp);
|
||||
|
||||
/* If the icon is docked, don't continue */
|
||||
if (aicon->docked)
|
||||
return;
|
||||
|
||||
scr = wapp->main_window_desc->screen_ptr;
|
||||
scr = wApplicationGetMainWindowDesc(wapp)->screen_ptr;
|
||||
clip = scr->workspaces[scr->current_workspace]->clip;
|
||||
|
||||
if (!clip || !aicon->attracted || !clip->collapsed)
|
||||
if (!clip || !aicon->attracted || !wDockIsCollapsed(clip))
|
||||
XUnmapWindow(dpy, aicon->icon->core->window);
|
||||
|
||||
/* We want to avoid having it on the list because otherwise
|
||||
@@ -206,35 +455,35 @@ void paint_app_icon(WApplication *wapp)
|
||||
int x = 0, y = 0;
|
||||
Bool update_icon = False;
|
||||
|
||||
if (!wapp || !wapp->app_icon || !wapp->main_window_desc)
|
||||
if (!wapp || !wApplicationGetAppIcon(wapp) || !wApplicationGetMainWindowDesc(wapp))
|
||||
return;
|
||||
|
||||
icon = wapp->app_icon->icon;
|
||||
scr = wapp->main_window_desc->screen_ptr;
|
||||
wapp->app_icon->main_window = wapp->main_window;
|
||||
icon = wApplicationGetAppIcon(wapp)->icon;
|
||||
scr = wApplicationGetMainWindowDesc(wapp)->screen_ptr;
|
||||
wApplicationGetAppIcon(wapp)->main_window = wApplicationGetMainWindow(wapp);
|
||||
|
||||
/* If the icon is docked, don't continue */
|
||||
if (wapp->app_icon->docked)
|
||||
if (wApplicationGetAppIcon(wapp)->docked)
|
||||
return;
|
||||
|
||||
attracting_dock = scr->attracting_drawer != NULL ?
|
||||
scr->attracting_drawer :
|
||||
scr->workspaces[scr->current_workspace]->clip;
|
||||
if (attracting_dock && attracting_dock->attract_icons &&
|
||||
if (attracting_dock && wDockGetAttractIcons(attracting_dock) &&
|
||||
wDockFindFreeSlot(attracting_dock, &x, &y)) {
|
||||
wapp->app_icon->attracted = 1;
|
||||
wApplicationGetAppIcon(wapp)->attracted = 1;
|
||||
if (!icon->shadowed) {
|
||||
icon->shadowed = 1;
|
||||
update_icon = True;
|
||||
}
|
||||
wDockAttachIcon(attracting_dock, wapp->app_icon, x, y, update_icon);
|
||||
wDockAttachIcon(attracting_dock, wApplicationGetAppIcon(wapp), x, y, update_icon);
|
||||
} else {
|
||||
/* We must know if the icon is painted in the screen,
|
||||
* because if painted, then PlaceIcon will return the next
|
||||
* space on the screen, and the icon will move */
|
||||
if (wapp->app_icon->next == NULL && wapp->app_icon->prev == NULL) {
|
||||
PlaceIcon(scr, &x, &y, wGetHeadForWindow(wapp->main_window_desc));
|
||||
wAppIconMove(wapp->app_icon, x, y);
|
||||
if (wApplicationGetAppIcon(wapp)->next == NULL && wApplicationGetAppIcon(wapp)->prev == NULL) {
|
||||
PlaceIcon(scr, &x, &y, wGetHeadForWindow(wApplicationGetMainWindowDesc(wapp)));
|
||||
wAppIconMove(wApplicationGetAppIcon(wapp), x, y);
|
||||
wLowerFrame(icon->core);
|
||||
}
|
||||
}
|
||||
@@ -242,57 +491,57 @@ void paint_app_icon(WApplication *wapp)
|
||||
/* If we want appicon (no_appicon is not set) and the icon is not
|
||||
* in the appicon_list, we must add it. Else, we want to avoid
|
||||
* having it on the list */
|
||||
if (!WFLAGP(wapp->main_window_desc, no_appicon) &&
|
||||
wapp->app_icon->next == NULL && wapp->app_icon->prev == NULL)
|
||||
add_to_appicon_list(scr, wapp->app_icon);
|
||||
if (!WFLAGP(wApplicationGetMainWindowDesc(wapp), no_appicon) &&
|
||||
wApplicationGetAppIcon(wapp)->next == NULL && wApplicationGetAppIcon(wapp)->prev == NULL)
|
||||
add_to_appicon_list(scr, wApplicationGetAppIcon(wapp));
|
||||
|
||||
if (!attracting_dock || !wapp->app_icon->attracted || !attracting_dock->collapsed)
|
||||
if (!attracting_dock || !wApplicationGetAppIcon(wapp)->attracted || !wDockIsCollapsed(attracting_dock))
|
||||
XMapWindow(dpy, icon->core->window);
|
||||
|
||||
if (wPreferences.auto_arrange_icons && !wapp->app_icon->attracted)
|
||||
if (wPreferences.auto_arrange_icons && !wApplicationGetAppIcon(wapp)->attracted)
|
||||
wArrangeIcons(scr, True);
|
||||
}
|
||||
|
||||
void removeAppIconFor(WApplication *wapp)
|
||||
{
|
||||
if (!wapp->app_icon)
|
||||
if (!wApplicationGetAppIcon(wapp))
|
||||
return;
|
||||
|
||||
if (wPreferences.highlight_active_app)
|
||||
wIconSetHighlited(wapp->app_icon->icon, False);
|
||||
if (wapp->app_icon->docked && !wapp->app_icon->attracted) {
|
||||
wapp->app_icon->running = 0;
|
||||
wIconSetHighlited(wApplicationGetAppIcon(wapp)->icon, False);
|
||||
if (wApplicationGetAppIcon(wapp)->docked && !wApplicationGetAppIcon(wapp)->attracted) {
|
||||
wApplicationGetAppIcon(wapp)->running = 0;
|
||||
/* since we keep it, we don't care if it was attracted or not */
|
||||
wapp->app_icon->attracted = 0;
|
||||
wapp->app_icon->icon->shadowed = 0;
|
||||
wapp->app_icon->main_window = None;
|
||||
wapp->app_icon->pid = 0;
|
||||
wapp->app_icon->icon->owner = NULL;
|
||||
wapp->app_icon->icon->icon_win = None;
|
||||
wApplicationGetAppIcon(wapp)->attracted = 0;
|
||||
wApplicationGetAppIcon(wapp)->icon->shadowed = 0;
|
||||
wApplicationGetAppIcon(wapp)->main_window = None;
|
||||
wApplicationGetAppIcon(wapp)->pid = 0;
|
||||
wApplicationGetAppIcon(wapp)->icon->owner = NULL;
|
||||
wApplicationGetAppIcon(wapp)->icon->icon_win = None;
|
||||
|
||||
/* Set the icon image */
|
||||
set_icon_image_from_database(wapp->app_icon->icon, wapp->app_icon->wm_instance,
|
||||
wapp->app_icon->wm_class, wapp->app_icon->command);
|
||||
set_icon_image_from_database(wApplicationGetAppIcon(wapp)->icon, wApplicationGetAppIcon(wapp)->wm_instance,
|
||||
wApplicationGetAppIcon(wapp)->wm_class, wApplicationGetAppIcon(wapp)->command);
|
||||
|
||||
/* Update the icon, because wapp->app_icon->icon could be NULL */
|
||||
wIconUpdate(wapp->app_icon->icon);
|
||||
/* Update the icon, because wApplicationGetAppIcon(wapp)->icon could be NULL */
|
||||
wIconUpdate(wApplicationGetAppIcon(wapp)->icon);
|
||||
|
||||
/* Paint it */
|
||||
wAppIconPaint(wapp->app_icon);
|
||||
} else if (wapp->app_icon->docked) {
|
||||
wapp->app_icon->running = 0;
|
||||
if (wapp->app_icon->dock->type == WM_DRAWER) {
|
||||
wDrawerFillTheGap(wapp->app_icon->dock, wapp->app_icon, True);
|
||||
wAppIconPaint(wApplicationGetAppIcon(wapp));
|
||||
} else if (wApplicationGetAppIcon(wapp)->docked) {
|
||||
wApplicationGetAppIcon(wapp)->running = 0;
|
||||
if (wDockGetType(wApplicationGetAppIcon(wapp)->dock) == WM_DRAWER) {
|
||||
wDrawerFillTheGap(wApplicationGetAppIcon(wapp)->dock, wApplicationGetAppIcon(wapp), True);
|
||||
}
|
||||
wDockDetach(wapp->app_icon->dock, wapp->app_icon);
|
||||
wDockDetach(wApplicationGetAppIcon(wapp)->dock, wApplicationGetAppIcon(wapp));
|
||||
} else {
|
||||
wAppIconDestroy(wapp->app_icon);
|
||||
wAppIconDestroy(wApplicationGetAppIcon(wapp));
|
||||
}
|
||||
|
||||
wapp->app_icon = NULL;
|
||||
wApplicationSetAppIcon(wapp, NULL);
|
||||
|
||||
if (wPreferences.auto_arrange_icons)
|
||||
wArrangeIcons(wapp->main_window_desc->screen_ptr, True);
|
||||
wArrangeIcons(wApplicationGetMainWindowDesc(wapp)->screen_ptr, True);
|
||||
}
|
||||
|
||||
static WAppIcon *wAppIconCreate(WWindow *leader_win)
|
||||
@@ -381,7 +630,7 @@ static void updateDockNumbers(WScreen *scr)
|
||||
{
|
||||
int length;
|
||||
char ws_numbers[20];
|
||||
WAppIcon *dicon = scr->dock->icon_array[0];
|
||||
WAppIcon *dicon = wDockGetIcon(scr->dock, 0);
|
||||
|
||||
snprintf(ws_numbers, sizeof(ws_numbers), "%i [ %i ]", scr->current_workspace + 1, ((scr->current_workspace / 10) + 1));
|
||||
length = strlen(ws_numbers);
|
||||
@@ -419,7 +668,7 @@ void wAppIconPaint(WAppIcon *aicon)
|
||||
scr->copy_gc, 0, 0, scr->dock_dots->width, scr->dock_dots->height, 0, 0);
|
||||
}
|
||||
#ifdef HIDDENDOT
|
||||
if (wapp && wapp->flags.hidden) {
|
||||
if (wapp && wApplicationIsHidden(wapp)) {
|
||||
XSetClipMask(dpy, scr->copy_gc, scr->dock_dots->mask);
|
||||
XSetClipOrigin(dpy, scr->copy_gc, 0, 0);
|
||||
XCopyArea(dpy, scr->dock_dots->image,
|
||||
@@ -463,7 +712,7 @@ static void relaunchApplication(WApplication *wapp)
|
||||
WScreen *scr;
|
||||
WWindow *wlist, *next;
|
||||
|
||||
scr = wapp->main_window_desc->screen_ptr;
|
||||
scr = wApplicationGetMainWindowDesc(wapp)->screen_ptr;
|
||||
wlist = scr->focused_window;
|
||||
if (! wlist)
|
||||
return;
|
||||
@@ -474,7 +723,7 @@ static void relaunchApplication(WApplication *wapp)
|
||||
while (wlist) {
|
||||
next = wlist->next;
|
||||
|
||||
if (wlist->main_window == wapp->main_window) {
|
||||
if (wlist->main_window == wApplicationGetMainWindow(wapp)) {
|
||||
if (RelaunchWindow(wlist))
|
||||
return;
|
||||
}
|
||||
@@ -497,8 +746,8 @@ static void hideCallback(WMenu * menu, WMenuEntry * entry)
|
||||
{
|
||||
WApplication *wapp = (WApplication *) entry->clientdata;
|
||||
|
||||
if (wapp->flags.hidden) {
|
||||
wWorkspaceChange(menu->menu->screen_ptr, wapp->last_workspace);
|
||||
if (wApplicationIsHidden(wapp)) {
|
||||
wWorkspaceChange(menu->menu->screen_ptr, wApplicationGetLastWorkspace(wapp));
|
||||
wUnhideApplication(wapp, False, False);
|
||||
} else {
|
||||
wHideApplication(wapp);
|
||||
@@ -517,7 +766,7 @@ static void unhideHereCallback(WMenu * menu, WMenuEntry * entry)
|
||||
|
||||
static void setIconCallback(WMenu *menu, WMenuEntry *entry)
|
||||
{
|
||||
WAppIcon *icon = ((WApplication *) entry->clientdata)->app_icon;
|
||||
WAppIcon *icon = wApplicationGetAppIcon((WApplication *) entry->clientdata);
|
||||
char *file = NULL;
|
||||
WScreen *scr;
|
||||
int result;
|
||||
@@ -569,33 +818,33 @@ static void killCallback(WMenu * menu, WMenuEntry * entry)
|
||||
|
||||
assert(entry->clientdata != NULL);
|
||||
|
||||
shortname = basename(wapp->app_icon->wm_instance);
|
||||
shortname = basename(wApplicationGetAppIcon(wapp)->wm_instance);
|
||||
|
||||
buffer = wstrconcat(wapp->app_icon ? shortname : NULL,
|
||||
buffer = wstrconcat(wApplicationGetAppIcon(wapp) ? shortname : NULL,
|
||||
_(" will be forcibly closed.\n"
|
||||
"Any unsaved changes will be lost.\n" "Please confirm."));
|
||||
|
||||
fPtr = wapp->main_window_desc->fake_group;
|
||||
fPtr = wApplicationGetMainWindowDesc(wapp)->fake_group;
|
||||
|
||||
wretain(wapp->main_window_desc);
|
||||
wretain(wApplicationGetMainWindowDesc(wapp));
|
||||
if (wPreferences.dont_confirm_kill
|
||||
|| wMessageDialog(menu->frame->screen_ptr, _("Kill Application"),
|
||||
buffer, _("Yes"), _("No"), NULL) == WAPRDefault) {
|
||||
if (fPtr != NULL) {
|
||||
WWindow *wwin, *twin;
|
||||
|
||||
wwin = wapp->main_window_desc->screen_ptr->focused_window;
|
||||
wwin = wApplicationGetMainWindowDesc(wapp)->screen_ptr->focused_window;
|
||||
while (wwin) {
|
||||
twin = wwin->prev;
|
||||
if (wwin->fake_group == fPtr)
|
||||
wClientKill(wwin);
|
||||
wwin = twin;
|
||||
}
|
||||
} else if (!wapp->main_window_desc->flags.destroyed) {
|
||||
wClientKill(wapp->main_window_desc);
|
||||
} else if (!wApplicationGetMainWindowDesc(wapp)->flags.destroyed) {
|
||||
wClientKill(wApplicationGetMainWindowDesc(wapp));
|
||||
}
|
||||
}
|
||||
wrelease(wapp->main_window_desc);
|
||||
wrelease(wApplicationGetMainWindowDesc(wapp));
|
||||
wfree(buffer);
|
||||
WCHANGE_STATE(WSTATE_NORMAL);
|
||||
}
|
||||
@@ -617,7 +866,7 @@ static WMenu *createApplicationMenu(WScreen *scr)
|
||||
static void openApplicationMenu(WApplication * wapp, int x, int y)
|
||||
{
|
||||
WMenu *menu;
|
||||
WScreen *scr = wapp->main_window_desc->screen_ptr;
|
||||
WScreen *scr = wApplicationGetMainWindowDesc(wapp)->screen_ptr;
|
||||
int i;
|
||||
|
||||
if (!scr->icon_menu) {
|
||||
@@ -627,7 +876,7 @@ static void openApplicationMenu(WApplication * wapp, int x, int y)
|
||||
|
||||
menu = scr->icon_menu;
|
||||
|
||||
if (wapp->flags.hidden)
|
||||
if (wApplicationIsHidden(wapp))
|
||||
menu->entries[1]->text = _("Unhide");
|
||||
else
|
||||
menu->entries[1]->text = _("Hide");
|
||||
@@ -677,8 +926,8 @@ static void iconDblClick(WObjDescriptor *desc, XEvent *event)
|
||||
|
||||
unhideHere = (event->xbutton.state & ShiftMask);
|
||||
/* go to the last workspace that the user worked on the app */
|
||||
if (!unhideHere && wapp->last_workspace != scr->current_workspace)
|
||||
wWorkspaceChange(scr, wapp->last_workspace);
|
||||
if (!unhideHere && wApplicationGetLastWorkspace(wapp) != scr->current_workspace)
|
||||
wWorkspaceChange(scr, wApplicationGetLastWorkspace(wapp));
|
||||
|
||||
wUnhideApplication(wapp, event->xbutton.button == Button2, unhideHere);
|
||||
|
||||
@@ -905,26 +1154,26 @@ Bool wHandleAppIconMove(WAppIcon *aicon, XEvent *event)
|
||||
}
|
||||
if (lastDock != NULL && lastDock != theNewDock) {
|
||||
/* Leave lastDock in the state we found it */
|
||||
if (lastDock->type == WM_DRAWER) {
|
||||
if (wDockGetType(lastDock) == WM_DRAWER) {
|
||||
wDrawerFillTheGap(lastDock, aicon, (lastDock == originalDock));
|
||||
}
|
||||
if (collapsed) {
|
||||
lastDock->collapsed = 1;
|
||||
wDockSetCollapsed(lastDock, 1);
|
||||
wDockHideIcons(lastDock);
|
||||
collapsed = False;
|
||||
}
|
||||
if (lastDock->auto_raise_lower) {
|
||||
if (wDockIsAutoRaiseLower(lastDock)) {
|
||||
wDockLower(lastDock);
|
||||
}
|
||||
}
|
||||
if (theNewDock != NULL) {
|
||||
if (lastDock != theNewDock) {
|
||||
collapsed = theNewDock->collapsed;
|
||||
collapsed = wDockIsCollapsed(theNewDock);
|
||||
if (collapsed) {
|
||||
theNewDock->collapsed = 0;
|
||||
wDockSetCollapsed(theNewDock, 0);
|
||||
wDockShowIcons(theNewDock);
|
||||
}
|
||||
if (theNewDock->auto_raise_lower) {
|
||||
if (wDockIsAutoRaiseLower(theNewDock)) {
|
||||
wDockRaise(theNewDock);
|
||||
/* And raise the moving tile above it */
|
||||
wRaiseFrame(aicon->icon->core);
|
||||
@@ -932,8 +1181,8 @@ Bool wHandleAppIconMove(WAppIcon *aicon, XEvent *event)
|
||||
lastDock = theNewDock;
|
||||
}
|
||||
|
||||
shad_x = lastDock->x_pos + ix*wPreferences.icon_size;
|
||||
shad_y = lastDock->y_pos + iy*wPreferences.icon_size;
|
||||
shad_x = wDockGetXPos(lastDock) + ix*wPreferences.icon_size;
|
||||
shad_y = wDockGetYPos(lastDock) + iy*wPreferences.icon_size;
|
||||
|
||||
XMoveWindow(dpy, scr->dock_shadow, shad_x, shad_y);
|
||||
|
||||
@@ -977,7 +1226,7 @@ Bool wHandleAppIconMove(WAppIcon *aicon, XEvent *event)
|
||||
command for that appicon, and the user cancels the
|
||||
wInputDialog asking for one). Make the rejection obvious by
|
||||
sliding the icon to its old position */
|
||||
if (lastDock->type == WM_DRAWER) {
|
||||
if (wDockGetType(lastDock) == WM_DRAWER) {
|
||||
// Also fill the gap left in the drawer
|
||||
wDrawerFillTheGap(lastDock, aicon, False);
|
||||
}
|
||||
@@ -995,25 +1244,25 @@ Bool wHandleAppIconMove(WAppIcon *aicon, XEvent *event)
|
||||
/* Possible scenario: user moved an auto-attracted appicon
|
||||
from the clip to the dock, and cancelled the wInputDialog
|
||||
asking for a command */
|
||||
if (lastDock->type == WM_DRAWER) {
|
||||
if (wDockGetType(lastDock) == WM_DRAWER) {
|
||||
wDrawerFillTheGap(lastDock, aicon, False);
|
||||
}
|
||||
/* If aicon comes from a drawer, make some room to reattach it */
|
||||
if (originalDock->type == WM_DRAWER) {
|
||||
WAppIcon *aiconsToShift[ originalDock->icon_count ];
|
||||
if (wDockGetType(originalDock) == WM_DRAWER) {
|
||||
WAppIcon *aiconsToShift[ wDockGetIconCount(originalDock) ];
|
||||
int j = 0;
|
||||
|
||||
for (i = 0; i < originalDock->max_icons; i++) {
|
||||
WAppIcon *ai = originalDock->icon_array[ i ];
|
||||
for (i = 0; i < wDockGetMaxIcons(originalDock); i++) {
|
||||
WAppIcon *ai = wDockGetIcon(originalDock, i);
|
||||
if (ai && ai != aicon &&
|
||||
abs(ai->xindex) >= abs(aicon->xindex))
|
||||
aiconsToShift[j++] = ai;
|
||||
}
|
||||
if (j != originalDock->icon_count - abs(aicon->xindex) - 1)
|
||||
if (j != wDockGetIconCount(originalDock) - abs(aicon->xindex) - 1)
|
||||
// Trust this never happens?
|
||||
wwarning("Shifting j=%d appicons (instead of %d!) to reinsert aicon at index %d.",
|
||||
j, originalDock->icon_count - abs(aicon->xindex) - 1, aicon->xindex);
|
||||
wSlideAppicons(aiconsToShift, j, originalDock->on_right_side);
|
||||
j, wDockGetIconCount(originalDock) - abs(aicon->xindex) - 1, aicon->xindex);
|
||||
wSlideAppicons(aiconsToShift, j, wDockIsOnRightSide(originalDock));
|
||||
// Trust the appicon is inserted at exactly the same place, so its oldX/oldY are consistent with its "new" location?
|
||||
}
|
||||
|
||||
@@ -1021,11 +1270,11 @@ Bool wHandleAppIconMove(WAppIcon *aicon, XEvent *event)
|
||||
wDockReattachIcon(originalDock, aicon, aicon->xindex, aicon->yindex);
|
||||
}
|
||||
else {
|
||||
if (originalDock->auto_collapse && !originalDock->collapsed) {
|
||||
originalDock->collapsed = 1;
|
||||
if (wDockIsAutoCollapse(originalDock) && !wDockIsCollapsed(originalDock)) {
|
||||
wDockSetCollapsed(originalDock, 1);
|
||||
wDockHideIcons(originalDock);
|
||||
}
|
||||
if (originalDock->auto_raise_lower)
|
||||
if (wDockIsAutoRaiseLower(originalDock))
|
||||
wDockLower(originalDock);
|
||||
}
|
||||
}
|
||||
@@ -1037,7 +1286,7 @@ Bool wHandleAppIconMove(WAppIcon *aicon, XEvent *event)
|
||||
/* If docked (or tried to dock) to a auto_collapsing dock, unset
|
||||
* collapsed, so that wHandleAppIconMove doesn't collapse it
|
||||
* right away (the timer will take care of it) */
|
||||
if (lastDock->auto_collapse)
|
||||
if (wDockIsAutoCollapse(lastDock))
|
||||
collapsed = 0;
|
||||
}
|
||||
else {
|
||||
@@ -1053,11 +1302,11 @@ Bool wHandleAppIconMove(WAppIcon *aicon, XEvent *event)
|
||||
}
|
||||
}
|
||||
wDockDetach(originalDock, aicon);
|
||||
if (originalDock->auto_collapse && !originalDock->collapsed) {
|
||||
originalDock->collapsed = 1;
|
||||
if (wDockIsAutoCollapse(originalDock) && !wDockIsCollapsed(originalDock)) {
|
||||
wDockSetCollapsed(originalDock, 1);
|
||||
wDockHideIcons(originalDock);
|
||||
}
|
||||
if (originalDock->auto_raise_lower)
|
||||
if (wDockIsAutoRaiseLower(originalDock))
|
||||
wDockLower(originalDock);
|
||||
}
|
||||
}
|
||||
@@ -1147,53 +1396,53 @@ static WAppIcon *findDockIconFor(WDock *dock, Window main_window)
|
||||
static void create_appicon_from_dock(WWindow *wwin, WApplication *wapp, Window main_window)
|
||||
{
|
||||
WScreen *scr = wwin->screen_ptr;
|
||||
wapp->app_icon = NULL;
|
||||
wApplicationSetAppIcon(wapp, NULL);
|
||||
|
||||
if (scr->last_dock)
|
||||
wapp->app_icon = findDockIconFor(scr->last_dock, main_window);
|
||||
wApplicationSetAppIcon(wapp, findDockIconFor(scr->last_dock, main_window));
|
||||
|
||||
/* check main dock if we did not find it in last dock */
|
||||
if (!wapp->app_icon && scr->dock)
|
||||
wapp->app_icon = findDockIconFor(scr->dock, main_window);
|
||||
if (!wApplicationGetAppIcon(wapp) && scr->dock)
|
||||
wApplicationSetAppIcon(wapp, findDockIconFor(scr->dock, main_window));
|
||||
|
||||
/* check clips */
|
||||
if (!wapp->app_icon) {
|
||||
if (!wApplicationGetAppIcon(wapp)) {
|
||||
int i;
|
||||
for (i = 0; i < scr->workspace_count; i++) {
|
||||
WDock *dock = scr->workspaces[i]->clip;
|
||||
|
||||
if (dock)
|
||||
wapp->app_icon = findDockIconFor(dock, main_window);
|
||||
wApplicationSetAppIcon(wapp, findDockIconFor(dock, main_window));
|
||||
|
||||
if (wapp->app_icon)
|
||||
if (wApplicationGetAppIcon(wapp))
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
/* Finally check drawers */
|
||||
if (!wapp->app_icon) {
|
||||
if (!wApplicationGetAppIcon(wapp)) {
|
||||
WDrawerChain *dc;
|
||||
for (dc = scr->drawers; dc != NULL; dc = dc->next) {
|
||||
wapp->app_icon = findDockIconFor(dc->adrawer, main_window);
|
||||
if (wapp->app_icon)
|
||||
wApplicationSetAppIcon(wapp, findDockIconFor(dc->adrawer, main_window));
|
||||
if (wApplicationGetAppIcon(wapp))
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
/* If created, then set some flags */
|
||||
if (wapp->app_icon && !WFLAGP(wapp->main_window_desc, no_appicon)) {
|
||||
WWindow *mainw = wapp->main_window_desc;
|
||||
if (wApplicationGetAppIcon(wapp) && !WFLAGP(wApplicationGetMainWindowDesc(wapp), no_appicon)) {
|
||||
WWindow *mainw = wApplicationGetMainWindowDesc(wapp);
|
||||
|
||||
wapp->app_icon->running = 1;
|
||||
wapp->app_icon->icon->owner = mainw;
|
||||
wApplicationGetAppIcon(wapp)->running = 1;
|
||||
wApplicationGetAppIcon(wapp)->icon->owner = mainw;
|
||||
if (mainw->wm_hints && (mainw->wm_hints->flags & IconWindowHint))
|
||||
wapp->app_icon->icon->icon_win = mainw->wm_hints->icon_window;
|
||||
wApplicationGetAppIcon(wapp)->icon->icon_win = mainw->wm_hints->icon_window;
|
||||
|
||||
/* Update the icon images */
|
||||
wIconUpdate(wapp->app_icon->icon);
|
||||
wIconUpdate(wApplicationGetAppIcon(wapp)->icon);
|
||||
|
||||
/* Paint it */
|
||||
wAppIconPaint(wapp->app_icon);
|
||||
wAppIconPaint(wApplicationGetAppIcon(wapp));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
126
src/appicon.h
126
src/appicon.h
@@ -29,46 +29,94 @@
|
||||
#include "icon.h"
|
||||
#include "application.h"
|
||||
|
||||
typedef struct WAppIcon {
|
||||
short xindex;
|
||||
short yindex;
|
||||
struct WAppIcon *next;
|
||||
struct WAppIcon *prev;
|
||||
WIcon *icon;
|
||||
int x_pos, y_pos; /* absolute screen coordinate */
|
||||
char *command; /* command used to launch app */
|
||||
#ifdef USE_DOCK_XDND
|
||||
char *dnd_command; /* command to use when something is */
|
||||
/* dropped on us */
|
||||
#endif
|
||||
char *paste_command; /* command to run when
|
||||
* something is pasted */
|
||||
char *wm_class;
|
||||
char *wm_instance;
|
||||
pid_t pid; /* for apps launched from the dock */
|
||||
Window main_window;
|
||||
struct WDock *dock; /* In which dock is docked. */
|
||||
struct _AppSettingsPanel *panel; /* Settings Panel */
|
||||
unsigned int docked:1;
|
||||
unsigned int omnipresent:1; /* If omnipresent when
|
||||
* docked in clip */
|
||||
unsigned int attracted:1; /* If it was attracted by the clip */
|
||||
unsigned int launching:1;
|
||||
unsigned int running:1; /* application is already running */
|
||||
unsigned int relaunching:1; /* launching 2nd instance */
|
||||
unsigned int forced_dock:1;
|
||||
unsigned int auto_launch:1; /* launch app on startup */
|
||||
unsigned int remote_start:1;
|
||||
unsigned int updated:1;
|
||||
unsigned int editing:1; /* editing docked icon */
|
||||
unsigned int drop_launch:1; /* launching from drop action */
|
||||
unsigned int paste_launch:1; /* launching from paste action */
|
||||
unsigned int destroyed:1; /* appicon was destroyed */
|
||||
unsigned int buggy_app:1; /* do not make dock rely on hints
|
||||
* set by app */
|
||||
unsigned int lock:1; /* do not allow to be destroyed */
|
||||
} WAppIcon;
|
||||
typedef struct WAppIcon WAppIcon;
|
||||
|
||||
/******** Accessors/mutators ********/
|
||||
short wAppIconGetXIndex(WAppIcon *aicon);
|
||||
void wAppIconSetXIndex(WAppIcon *aicon, short x_index);
|
||||
|
||||
short wAppIconGetYIndex(WAppIcon *aicon);
|
||||
void wAppIconSetYIndex(WAppIcon *aicon, short y_index);
|
||||
|
||||
struct WAppIcon *wAppIconGetNext(WAppIcon *aicon);
|
||||
|
||||
struct WAppIcon *wAppIconGetPrev(WAppIcon *aicon);
|
||||
|
||||
int wAppIconGetXPos(WAppIcon *aicon);
|
||||
void wAppIconSetXPos(WAppIcon *aicon, int x_pos);
|
||||
|
||||
int wAppIconGetYPos(WAppIcon *aicon);
|
||||
void wAppIconSetYPos(WAppIcon *aicon, int y_pos);
|
||||
|
||||
WIcon *wAppIconGetIcon(WAppIcon *aicon);
|
||||
|
||||
char *wAppIconGetCommand(WAppIcon *aicon);
|
||||
void wAppIconSetCommand(WAppIcon *aicon, char *command);
|
||||
|
||||
#ifdef USE_DOCK_XDND
|
||||
char *wAppIconGetDnDCommand(WAppIcon *aicon);
|
||||
void wAppIconSetDnDCommand(WAppIcon *aicon, char *command);
|
||||
#endif // USE_DOCK_XDND
|
||||
|
||||
char *wAppIconGetPasteCommand(WAppIcon *aicon);
|
||||
void wAppIconSetPasteCommand(WAppIcon *aicon, char *command);
|
||||
|
||||
char *wAppIconGetWmClass(WAppIcon *aicon);
|
||||
|
||||
char *wAppIconGetWmInstance(WAppIcon *aicon);
|
||||
|
||||
pid_t wAppIconGetPid(WAppIcon *aicon);
|
||||
void wAppIconSetPid(WAppIcon *aicon, pid_t pid);
|
||||
|
||||
Window wAppIconGetMainWindow(WAppIcon *aicon);
|
||||
void wAppIconSetMainWindow(WAppIcon *aicon, Window main_window);
|
||||
|
||||
struct WDock *wAppIconGetDock(WAppIcon *aicon);
|
||||
void wAppIconSetDock(WAppIcon *aicon, struct WDock *dock);
|
||||
|
||||
struct _AppSettingsPanel *wAppIconGetPanel(WAppIcon *aicon);
|
||||
void wAppIconSetPanel(WAppIcon *aicon, struct _AppSettingsPanel *panel);
|
||||
|
||||
int wAppIconIsDocked(WAppIcon *aicon);
|
||||
void wAppIconSetDocked(WAppIcon *aicon, int docked);
|
||||
|
||||
int wAppIconIsOmnipresent(WAppIcon *aicon);
|
||||
void wAppIconSetOmnipresent(WAppIcon *aicon, int omnipresent);
|
||||
|
||||
int wAppIconIsAttracted(WAppIcon *aicon);
|
||||
void wAppIconSetAttracted(WAppIcon *aicon, int attracted);
|
||||
|
||||
int wAppIconIsLaunching(WAppIcon *aicon);
|
||||
void wAppIconSetLaunching(WAppIcon *aicon, int launching);
|
||||
|
||||
int wAppIconIsRunning(WAppIcon *aicon);
|
||||
void wAppIconSetRunning(WAppIcon *aicon, int running);
|
||||
|
||||
int wAppIconIsRelaunching(WAppIcon *aicon);
|
||||
void wAppIconSetRelaunching(WAppIcon *aicon, int relaunching);
|
||||
|
||||
int wAppIconIsForceDocked(WAppIcon *aicon);
|
||||
void wAppIconSetForceDocked(WAppIcon *aicon, int forced_dock);
|
||||
|
||||
int wAppIconIsAutoLaunch(WAppIcon *aicon);
|
||||
void wAppIconSetAutoLaunch(WAppIcon *aicon, int auto_launch);
|
||||
|
||||
int wAppIconIsEditing(WAppIcon *aicon);
|
||||
void wAppIconSetEditing(WAppIcon *aicon, int editing);
|
||||
|
||||
int wAppIconIsDropLaunch(WAppIcon *aicon);
|
||||
void wAppIconSetDropLaunch(WAppIcon *aicon, int drop_launch);
|
||||
|
||||
int wAppIconIsPasteLaunch(WAppIcon *aicon);
|
||||
void wAppIconSetPasteLaunch(WAppIcon *aicon, int paste_launch);
|
||||
|
||||
int wAppIconIsBuggyApp(WAppIcon *aicon);
|
||||
void wAppIconSetBuggyApp(WAppIcon *aicon, int buggy_app);
|
||||
|
||||
int wAppIconIsLocked(WAppIcon *aicon);
|
||||
void wAppIconSetLocked(WAppIcon *aicon, int locked);
|
||||
|
||||
/******** Lifecycle/resource management ********/
|
||||
WAppIcon *wAppIconCreateForDock(WScreen *scr, const char *command, const char *wm_instance,
|
||||
const char *wm_class, int tile);
|
||||
Bool wHandleAppIconMove(WAppIcon *aicon, XEvent *event);
|
||||
|
||||
@@ -37,179 +37,33 @@
|
||||
#include "dock.h"
|
||||
#include "defaults.h"
|
||||
|
||||
/******** Decls of functions defined in application.rs. ********/
|
||||
WApplication* wApplicationOfRust(Display *dpy, Window window);
|
||||
|
||||
/******** Local variables ********/
|
||||
WApplication *wApplicationCreateRust(Display *dpy, WWindow *wwin, int enable_user_menu);
|
||||
|
||||
static WWindow *makeMainWindow(WScreen * scr, Window window)
|
||||
{
|
||||
WWindow *wwin;
|
||||
XWindowAttributes attr;
|
||||
void wApplicationDestroyRust(Display *dpy, WApplication *wapp);
|
||||
|
||||
if (!XGetWindowAttributes(dpy, window, &attr))
|
||||
return NULL;
|
||||
|
||||
wwin = wWindowCreate();
|
||||
wwin->screen_ptr = scr;
|
||||
wwin->client_win = window;
|
||||
wwin->main_window = window;
|
||||
wwin->wm_hints = XGetWMHints(dpy, window);
|
||||
|
||||
PropGetWMClass(window, &wwin->wm_class, &wwin->wm_instance);
|
||||
|
||||
wDefaultFillAttributes(wwin->wm_instance, wwin->wm_class, &wwin->user_flags,
|
||||
&wwin->defined_user_flags, True);
|
||||
|
||||
XSelectInput(dpy, window, attr.your_event_mask | PropertyChangeMask | StructureNotifyMask);
|
||||
return wwin;
|
||||
}
|
||||
/******** Lifecycle/etc. ********/
|
||||
|
||||
WApplication *wApplicationOf(Window window)
|
||||
{
|
||||
WApplication *wapp;
|
||||
|
||||
if (window == None)
|
||||
return NULL;
|
||||
if (XFindContext(dpy, window, w_global.context.app_win, (XPointer *) & wapp) != XCSUCCESS)
|
||||
return NULL;
|
||||
return wapp;
|
||||
return wApplicationOfRust(dpy, window);
|
||||
}
|
||||
|
||||
WApplication *wApplicationCreate(WWindow * wwin)
|
||||
{
|
||||
WScreen *scr = wwin->screen_ptr;
|
||||
Window main_window = wwin->main_window;
|
||||
WApplication *wapp;
|
||||
WWindow *leader;
|
||||
|
||||
if (main_window == None || main_window == scr->root_win)
|
||||
return NULL;
|
||||
|
||||
{
|
||||
Window root;
|
||||
int foo;
|
||||
unsigned int bar;
|
||||
/* check if the window is valid */
|
||||
if (!XGetGeometry(dpy, main_window, &root, &foo, &foo, &bar, &bar, &bar, &bar))
|
||||
return NULL;
|
||||
}
|
||||
|
||||
wapp = wApplicationOf(main_window);
|
||||
if (wapp) {
|
||||
wapp->refcount++;
|
||||
if (wapp->app_icon && wapp->app_icon->docked &&
|
||||
wapp->app_icon->relaunching && wapp->main_window_desc->fake_group)
|
||||
wDockFinishLaunch(wapp->app_icon);
|
||||
|
||||
return wapp;
|
||||
}
|
||||
|
||||
wapp = wmalloc(sizeof(WApplication));
|
||||
|
||||
wapp->refcount = 1;
|
||||
wapp->last_focused = NULL;
|
||||
wapp->urgent_bounce_timer = NULL;
|
||||
|
||||
wapp->last_workspace = 0;
|
||||
|
||||
wapp->main_window = main_window;
|
||||
wapp->main_window_desc = makeMainWindow(scr, main_window);
|
||||
if (!wapp->main_window_desc) {
|
||||
wfree(wapp);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
wapp->main_window_desc->fake_group = wwin->fake_group;
|
||||
wapp->main_window_desc->net_icon_image = RRetainImage(wwin->net_icon_image);
|
||||
|
||||
leader = wWindowFor(main_window);
|
||||
if (leader)
|
||||
leader->main_window = main_window;
|
||||
|
||||
wapp->menu = wAppMenuGet(scr, main_window);
|
||||
#ifdef USER_MENU
|
||||
if (!wapp->menu)
|
||||
wapp->menu = wUserMenuGet(scr, wapp->main_window_desc);
|
||||
|
||||
wAppMenuMap(wapp->menu, wwin);
|
||||
#endif
|
||||
|
||||
/* Set application wide attributes from the leader */
|
||||
wapp->flags.hidden = WFLAGP(wapp->main_window_desc, start_hidden);
|
||||
wapp->flags.emulated = WFLAGP(wapp->main_window_desc, emulate_appicon);
|
||||
|
||||
/* application descriptor */
|
||||
XSaveContext(dpy, main_window, w_global.context.app_win, (XPointer) wapp);
|
||||
|
||||
create_appicon_for_application(wapp, wwin);
|
||||
|
||||
return wapp;
|
||||
return wApplicationCreateRust(dpy, wwin, 1);
|
||||
#else
|
||||
return wApplicationCreateRust(dpy, wwin, 0);
|
||||
#endif // USER_MENU
|
||||
}
|
||||
|
||||
void wApplicationDestroy(WApplication *wapp)
|
||||
{
|
||||
WWindow *wwin;
|
||||
WScreen *scr;
|
||||
|
||||
if (!wapp)
|
||||
return;
|
||||
|
||||
wapp->refcount--;
|
||||
if (wapp->refcount > 0)
|
||||
return;
|
||||
|
||||
if (wapp->urgent_bounce_timer) {
|
||||
WMDeleteTimerHandler(wapp->urgent_bounce_timer);
|
||||
wapp->urgent_bounce_timer = NULL;
|
||||
}
|
||||
if (wapp->flags.bouncing) {
|
||||
/* event.c:handleDestroyNotify forced this destroy
|
||||
and thereby overlooked the bounce callback */
|
||||
wapp->refcount = 1;
|
||||
return;
|
||||
}
|
||||
|
||||
scr = wapp->main_window_desc->screen_ptr;
|
||||
|
||||
if (wapp == scr->wapp_list) {
|
||||
if (wapp->next)
|
||||
wapp->next->prev = NULL;
|
||||
scr->wapp_list = wapp->next;
|
||||
} else {
|
||||
if (wapp->next)
|
||||
wapp->next->prev = wapp->prev;
|
||||
if (wapp->prev)
|
||||
wapp->prev->next = wapp->next;
|
||||
}
|
||||
|
||||
XDeleteContext(dpy, wapp->main_window, w_global.context.app_win);
|
||||
wAppMenuDestroy(wapp->menu);
|
||||
|
||||
/* Remove application icon */
|
||||
removeAppIconFor(wapp);
|
||||
|
||||
wwin = wWindowFor(wapp->main_window_desc->client_win);
|
||||
|
||||
wWindowDestroy(wapp->main_window_desc);
|
||||
if (wwin) {
|
||||
/* undelete client window context that was deleted in
|
||||
* wWindowDestroy */
|
||||
XSaveContext(dpy, wwin->client_win, w_global.context.client_win, (XPointer) & wwin->client_descriptor);
|
||||
}
|
||||
wfree(wapp);
|
||||
}
|
||||
|
||||
void wApplicationActivate(WApplication *wapp)
|
||||
{
|
||||
if (wapp->app_icon) {
|
||||
wIconSetHighlited(wapp->app_icon->icon, True);
|
||||
wAppIconPaint(wapp->app_icon);
|
||||
}
|
||||
}
|
||||
|
||||
void wApplicationDeactivate(WApplication *wapp)
|
||||
{
|
||||
if (wapp->app_icon) {
|
||||
wIconSetHighlited(wapp->app_icon->icon, False);
|
||||
wAppIconPaint(wapp->app_icon);
|
||||
}
|
||||
wApplicationDestroyRust(dpy, wapp);
|
||||
}
|
||||
|
||||
@@ -23,32 +23,52 @@
|
||||
#define WMAPPLICATION_H_
|
||||
|
||||
/* for tracking single application instances */
|
||||
typedef struct WApplication {
|
||||
struct WApplication *next;
|
||||
struct WApplication *prev;
|
||||
// This is now defined in application.rs.
|
||||
typedef struct WApplication WApplication;
|
||||
|
||||
Window main_window; /* ID of the group leader */
|
||||
struct WWindow *main_window_desc; /* main (leader) window descriptor */
|
||||
WMenu *menu; /* application menu */
|
||||
struct WAppIcon *app_icon;
|
||||
int refcount;
|
||||
struct WWindow *last_focused; /* focused window before hide */
|
||||
int last_workspace; /* last workspace used to work on the
|
||||
* app */
|
||||
WMHandlerID *urgent_bounce_timer;
|
||||
struct {
|
||||
unsigned int skip_next_animation:1;
|
||||
unsigned int hidden:1;
|
||||
unsigned int emulated:1;
|
||||
unsigned int bouncing:1;
|
||||
} flags;
|
||||
} WApplication;
|
||||
/******** Accessors/mutators ********/
|
||||
Window wApplicationGetMainWindow(WApplication *wapp);
|
||||
|
||||
struct WWindow *wApplicationGetMainWindowDesc(WApplication *wapp);
|
||||
|
||||
WMenu *wApplicationGetMenu(WApplication *wapp);
|
||||
void wApplicationSetMenu(WApplication *wapp, WMenu *menu);
|
||||
|
||||
struct WAppIcon *wApplicationGetAppIcon(WApplication *wapp);
|
||||
void wApplicationSetAppIcon(WApplication *wapp, struct WAppIcon *icon);
|
||||
|
||||
int wApplicationGetLastWorkspace(WApplication *wapp);
|
||||
void wApplicationSetLastWorkspace(WApplication *wapp, int workspace);
|
||||
|
||||
struct WWindow *wApplicationGetLastFocused(WApplication *wapp);
|
||||
void wApplicationSetLastFocused(WApplication *wapp, struct WWindow *win);
|
||||
|
||||
WMHandlerID *wApplicationGetUrgentBounceTimer(WApplication *wapp);
|
||||
int wApplicationHasUrgentBounceTimer(WApplication *wapp);
|
||||
void wApplicationClearUrgentBounceTimer(WApplication *wapp);
|
||||
void wApplicationSetUrgentBounceTimer(WApplication *wapp, WMHandlerID *timer);
|
||||
|
||||
int wApplicationGetSkipNextAnimation(WApplication *wapp);
|
||||
void wApplicationSetSkipNextAnimation(WApplication *wapp, int skip);
|
||||
|
||||
int wApplicationIsHidden(WApplication *wapp);
|
||||
void wApplicationSetHidden(WApplication *wapp, int hidden);
|
||||
|
||||
int wApplicationIsEmulated(WApplication *wapp);
|
||||
void wApplicationSetEmulated(WApplication *wapp, int emulated);
|
||||
|
||||
int wApplicationIsBouncing(WApplication *wapp);
|
||||
void wApplicationSetBouncing(WApplication *wapp, int bouncing);
|
||||
|
||||
/******** Lifecycle/resource management ********/
|
||||
WApplication *wApplicationCreate(struct WWindow *wwin);
|
||||
WApplication *wApplicationOf(Window window);
|
||||
void wApplicationDestroy(WApplication *wapp);
|
||||
|
||||
void wApplicationIncrementRefcount(WApplication *wapp);
|
||||
int wApplicationHasLiveRefcount(WApplication *wapp);
|
||||
void wApplicationClearRefcount(WApplication *wapp);
|
||||
|
||||
void wAppBounce(WApplication *);
|
||||
void wAppBounceWhileUrgent(WApplication *);
|
||||
void wApplicationActivate(WApplication *);
|
||||
|
||||
@@ -507,7 +507,7 @@ static void miniwindowBalloon(WObjDescriptor *object)
|
||||
static void appiconBalloon(WObjDescriptor *object)
|
||||
{
|
||||
WAppIcon *aicon = (WAppIcon *) object->parent;
|
||||
WScreen *scr = aicon->icon->core->screen_ptr;
|
||||
WScreen *scr = wAppIconGetIcon(aicon)->core->screen_ptr;
|
||||
char *tmp;
|
||||
|
||||
/* Show balloon if it is the Clip and the workspace name is > 5 chars */
|
||||
@@ -518,17 +518,17 @@ static void appiconBalloon(WObjDescriptor *object)
|
||||
wBalloonHide(scr);
|
||||
return;
|
||||
}
|
||||
} else if (aicon->command && aicon->wm_class) {
|
||||
} else if (wAppIconGetCommand(aicon) && wAppIconGetWmClass(aicon)) {
|
||||
int len;
|
||||
WApplication *app;
|
||||
unsigned int app_win_cnt = 0;
|
||||
const char *display_name;
|
||||
|
||||
if (object->parent_type == WCLASS_DOCK_ICON) {
|
||||
if (aicon->main_window) {
|
||||
app = wApplicationOf(aicon->main_window);
|
||||
if (app && app->main_window_desc && app->main_window_desc->fake_group)
|
||||
app_win_cnt = app->main_window_desc->fake_group->retainCount - 1;
|
||||
if (wAppIconGetMainWindow(aicon)) {
|
||||
app = wApplicationOf(wAppIconGetMainWindow(aicon));
|
||||
if (app && wApplicationGetMainWindowDesc(app) && wApplicationGetMainWindowDesc(app)->fake_group)
|
||||
app_win_cnt = wApplicationGetMainWindowDesc(app)->fake_group->retainCount - 1;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -537,38 +537,38 @@ static void appiconBalloon(WObjDescriptor *object)
|
||||
* instead of the class, otherwise the user will not be able to distinguish what
|
||||
* is being referred.
|
||||
*/
|
||||
if (strcmp(aicon->wm_class, "GNUstep") == 0)
|
||||
display_name = aicon->wm_instance;
|
||||
if (strcmp(wAppIconGetWmClass(aicon), "GNUstep") == 0)
|
||||
display_name = wAppIconGetWmInstance(aicon);
|
||||
else
|
||||
display_name = aicon->wm_class;
|
||||
display_name = wAppIconGetWmClass(aicon);
|
||||
|
||||
len = strlen(aicon->command) + strlen(display_name) + 8;
|
||||
len = strlen(wAppIconGetCommand(aicon)) + strlen(display_name) + 8;
|
||||
|
||||
if (app_win_cnt > 0)
|
||||
len += 1 + snprintf(NULL, 0, "%u", app_win_cnt);
|
||||
|
||||
tmp = wmalloc(len);
|
||||
if (app_win_cnt > 0)
|
||||
snprintf(tmp, len, "%u %s\n(%s)", app_win_cnt, display_name, aicon->command);
|
||||
snprintf(tmp, len, "%u %s\n(%s)", app_win_cnt, display_name, wAppIconGetCommand(aicon));
|
||||
else
|
||||
snprintf(tmp, len, "%s\n(%s)", aicon->wm_instance, aicon->command);
|
||||
snprintf(tmp, len, "%s\n(%s)", wAppIconGetWmInstance(aicon), wAppIconGetCommand(aicon));
|
||||
scr->balloon->text = tmp;
|
||||
|
||||
} else if (aicon->command) {
|
||||
scr->balloon->text = wstrdup(aicon->command);
|
||||
} else if (aicon->wm_class) {
|
||||
} else if (wAppIconGetCommand(aicon)) {
|
||||
scr->balloon->text = wstrdup(wAppIconGetCommand(aicon));
|
||||
} else if (wAppIconGetWmClass(aicon)) {
|
||||
/* Check to see if it is a GNUstep App */
|
||||
if (strcmp(aicon->wm_class, "GNUstep") == 0)
|
||||
scr->balloon->text = wstrdup(aicon->wm_instance);
|
||||
if (strcmp(wAppIconGetWmClass(aicon), "GNUstep") == 0)
|
||||
scr->balloon->text = wstrdup(wAppIconGetWmInstance(aicon));
|
||||
else
|
||||
scr->balloon->text = wstrdup(aicon->wm_class);
|
||||
scr->balloon->text = wstrdup(wAppIconGetWmClass(aicon));
|
||||
} else {
|
||||
wBalloonHide(scr);
|
||||
return;
|
||||
}
|
||||
scr->balloon->h = aicon->icon->core->height - 2;
|
||||
scr->balloon->h = wAppIconGetIcon(aicon)->core->height - 2;
|
||||
|
||||
scr->balloon->objectWindow = aicon->icon->core->window;
|
||||
scr->balloon->objectWindow = wAppIconGetIcon(aicon)->core->window;
|
||||
if ((scr->balloon->prevType == object->parent_type || scr->balloon->prevType == WCLASS_MINIWINDOW)
|
||||
&& scr->balloon->ignoreTimer) {
|
||||
XUnmapWindow(dpy, scr->balloon->window);
|
||||
|
||||
20
src/client.c
20
src/client.c
@@ -324,14 +324,12 @@ void wClientCheckProperty(WWindow * wwin, XPropertyEvent * event)
|
||||
WApplication *wapp = wApplicationOf(wwin->main_window);
|
||||
char *command;
|
||||
|
||||
if (!wapp || !wapp->app_icon || wapp->app_icon->docked)
|
||||
if (!wapp || !wApplicationGetAppIcon(wapp) || wAppIconIsDocked(wApplicationGetAppIcon(wapp)))
|
||||
break;
|
||||
|
||||
command = GetCommandForWindow(wwin->main_window);
|
||||
if (command) {
|
||||
if (wapp->app_icon->command)
|
||||
wfree(wapp->app_icon->command);
|
||||
wapp->app_icon->command = command;
|
||||
wAppIconSetCommand(wApplicationGetAppIcon(wapp), command);
|
||||
}
|
||||
}
|
||||
break;
|
||||
@@ -460,9 +458,9 @@ void wClientCheckProperty(WWindow * wwin, XPropertyEvent * event)
|
||||
wIconUpdate(wwin->icon);
|
||||
|
||||
wapp = wApplicationOf(wwin->main_window);
|
||||
if (wapp && wapp->app_icon) {
|
||||
wIconUpdate(wapp->app_icon->icon);
|
||||
wAppIconPaint(wapp->app_icon);
|
||||
if (wapp && wApplicationGetAppIcon(wapp)) {
|
||||
wIconUpdate(wAppIconGetIcon(wApplicationGetAppIcon(wapp)));
|
||||
wAppIconPaint(wApplicationGetAppIcon(wapp));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -560,10 +558,10 @@ void wClientCheckProperty(WWindow * wwin, XPropertyEvent * event)
|
||||
|
||||
wapp = wApplicationOf(wwin->main_window);
|
||||
if (wapp) {
|
||||
if (wapp->menu) {
|
||||
if (wApplicationGetMenu(wapp)) {
|
||||
/* update menu */
|
||||
/* TODO: remake appmenu update */
|
||||
wAppMenuDestroy(wapp->menu);
|
||||
wAppMenuDestroy(wApplicationGetMenu(wapp));
|
||||
}
|
||||
if (wwin->fake_group) {
|
||||
WScreen *scr = wwin->screen_ptr;
|
||||
@@ -599,13 +597,13 @@ void wClientCheckProperty(WWindow * wwin, XPropertyEvent * event)
|
||||
|
||||
wapp = wApplicationOf(wwin->main_window);
|
||||
if (wapp) {
|
||||
wapp->menu = wAppMenuGet(scr, wwin->main_window);
|
||||
wApplicationSetMenu(wapp, wAppMenuGet(scr, wwin->main_window));
|
||||
}
|
||||
if (wPreferences.auto_arrange_icons) {
|
||||
wArrangeIcons(wwin->screen_ptr, True);
|
||||
}
|
||||
} else {
|
||||
wapp->menu = wAppMenuGet(wwin->screen_ptr, wwin->main_window);
|
||||
wApplicationSetMenu(wapp, wAppMenuGet(wwin->screen_ptr, wwin->main_window));
|
||||
}
|
||||
/* make the appmenu be mapped */
|
||||
wSetFocusTo(wwin->screen_ptr, NULL);
|
||||
|
||||
@@ -1309,16 +1309,16 @@ void wDefaultUpdateIcons(WScreen *scr)
|
||||
|
||||
while (aicon) {
|
||||
/* Get the application icon, default included */
|
||||
wIconChangeImageFile(aicon->icon, NULL);
|
||||
wIconChangeImageFile(wAppIconGetIcon(aicon), NULL);
|
||||
wAppIconPaint(aicon);
|
||||
aicon = aicon->next;
|
||||
aicon = wAppIconGetNext(aicon);
|
||||
}
|
||||
|
||||
if (!wPreferences.flags.noclip || wPreferences.flags.clip_merged_in_dock)
|
||||
wClipIconPaint(scr->clip_icon);
|
||||
|
||||
for (dc = scr->drawers; dc != NULL; dc = dc->next)
|
||||
wDrawerIconPaint(dc->adrawer->icon_array[0]);
|
||||
wDrawerIconPaint(wDockGetIcon(dc->adrawer, 0));
|
||||
|
||||
while (wwin) {
|
||||
if (wwin->icon && wwin->flags.miniaturized)
|
||||
|
||||
1149
src/dock.c
1149
src/dock.c
File diff suppressed because it is too large
Load Diff
47
src/dock.h
47
src/dock.h
@@ -25,45 +25,38 @@
|
||||
|
||||
#include "appicon.h"
|
||||
|
||||
typedef struct WDock {
|
||||
WScreen *screen_ptr;
|
||||
int x_pos, y_pos; /* position of the first icon */
|
||||
|
||||
WAppIcon **icon_array; /* array of docked icons */
|
||||
int max_icons;
|
||||
|
||||
int icon_count;
|
||||
|
||||
#define WM_DOCK 0
|
||||
#define WM_CLIP 1
|
||||
#define WM_DRAWER 2
|
||||
int type;
|
||||
|
||||
WMagicNumber auto_expand_magic;
|
||||
WMagicNumber auto_collapse_magic;
|
||||
WMagicNumber auto_raise_magic;
|
||||
WMagicNumber auto_lower_magic;
|
||||
unsigned int auto_collapse:1; /* if clip auto-collapse itself */
|
||||
unsigned int auto_raise_lower:1; /* if clip should raise/lower when
|
||||
* entered/leaved */
|
||||
unsigned int on_right_side:1;
|
||||
unsigned int collapsed:1;
|
||||
unsigned int mapped:1;
|
||||
unsigned int lowered:1;
|
||||
unsigned int attract_icons:1; /* If clip should attract app-icons */
|
||||
typedef struct WDock WDock;
|
||||
|
||||
unsigned int lclip_button_pushed:1;
|
||||
unsigned int rclip_button_pushed:1;
|
||||
/******** Accessors/mutators ********/
|
||||
int wDockGetXPos(WDock *dock);
|
||||
int wDockGetYPos(WDock *dock);
|
||||
|
||||
struct WMenu *menu;
|
||||
int wDockGetMaxIcons(WDock *dock);
|
||||
int wDockGetIconCount(WDock *dock);
|
||||
void wDockAddIconCount(WDock *dock, int count);
|
||||
WAppIcon *wDockGetIcon(WDock *dock, int index);
|
||||
void wDockSetIcon(WDock *doc, int index, WAppIcon *icon);
|
||||
void wDockClearIcon(WDock *dock, int index);
|
||||
|
||||
struct WDDomain *defaults;
|
||||
} WDock;
|
||||
int wDockGetType(WDock *dock);
|
||||
|
||||
int wDockIsAutoCollapse(WDock *dock);
|
||||
|
||||
int wDockIsAutoRaiseLower(WDock *dock);
|
||||
|
||||
int wDockIsOnRightSide(WDock *dock);
|
||||
|
||||
int wDockIsCollapsed(WDock *dock);
|
||||
void wDockSetCollapsed(WDock *dock, int collapsed);
|
||||
|
||||
int wDockGetAttractIcons(WDock *dock);
|
||||
void wDockSetAttractIcons(WDock *dock, int attract_icons);
|
||||
|
||||
/******** Lifecycle/resource management ********/
|
||||
WDock *wDockCreate(WScreen *scr, int type, const char *name);
|
||||
WDock *wDockRestoreState(WScreen *scr, WMPropList *dock_state, int type);
|
||||
|
||||
|
||||
@@ -42,43 +42,13 @@
|
||||
|
||||
static void updateCommand(WAppIcon * icon, char *command)
|
||||
{
|
||||
if (icon->command)
|
||||
wfree(icon->command);
|
||||
if (command && (command[0] == 0 || (command[0] == '-' && command[1] == 0))) {
|
||||
wfree(command);
|
||||
command = NULL;
|
||||
}
|
||||
icon->command = command;
|
||||
wAppIconSetCommand(icon, command);
|
||||
|
||||
if (!icon->wm_class && !icon->wm_instance && icon->command && strlen(icon->command) > 0) {
|
||||
icon->forced_dock = 1;
|
||||
if (!wAppIconGetWmClass(icon) && !wAppIconGetWmInstance(icon) && wAppIconGetCommand(icon) && strlen(wAppIconGetCommand(icon)) > 0) {
|
||||
wAppIconSetForceDocked(icon, 1);
|
||||
}
|
||||
}
|
||||
|
||||
static void updatePasteCommand(WAppIcon * icon, char *command)
|
||||
{
|
||||
if (icon->paste_command)
|
||||
wfree(icon->paste_command);
|
||||
if (command && (command[0] == 0 || (command[0] == '-' && command[1] == 0))) {
|
||||
wfree(command);
|
||||
command = NULL;
|
||||
}
|
||||
icon->paste_command = command;
|
||||
}
|
||||
|
||||
#ifdef USE_DOCK_XDND
|
||||
static void updateDNDCommand(WAppIcon * icon, char *command)
|
||||
{
|
||||
if (icon->dnd_command)
|
||||
wfree(icon->dnd_command);
|
||||
if (command && (command[0] == 0 || (command[0] == '-' && command[1] == 0))) {
|
||||
wfree(command);
|
||||
command = NULL;
|
||||
}
|
||||
icon->dnd_command = command;
|
||||
}
|
||||
#endif /* USE_DOCK_XDND */
|
||||
|
||||
static void updateSettingsPanelIcon(AppSettingsPanel * panel)
|
||||
{
|
||||
char *file;
|
||||
@@ -132,7 +102,7 @@ static void chooseIconCallback(WMWidget * self, void *clientData)
|
||||
WMSetButtonEnabled(panel->browseBtn, False);
|
||||
|
||||
result = wIconChooserDialog(panel->wwin->screen_ptr, &file,
|
||||
panel->editedIcon->wm_instance, panel->editedIcon->wm_class);
|
||||
wAppIconGetWmInstance(panel->editedIcon), wAppIconGetWmClass(panel->editedIcon));
|
||||
|
||||
panel->choosingIcon = 0;
|
||||
if (!panel->destroyed) {
|
||||
@@ -164,7 +134,7 @@ static void panelBtnCallback(WMWidget * self, void *data)
|
||||
text = NULL;
|
||||
}
|
||||
|
||||
if (!wIconChangeImageFile(panel->editedIcon->icon, text)) {
|
||||
if (!wIconChangeImageFile(wAppIconGetIcon(panel->editedIcon), text)) {
|
||||
char *buf;
|
||||
int len = strlen(text) + 64;
|
||||
|
||||
@@ -181,14 +151,14 @@ static void panelBtnCallback(WMWidget * self, void *data)
|
||||
WAppIcon *aicon = panel->editedIcon;
|
||||
|
||||
// Cf dock.c:dockIconPaint(WAppIcon *aicon)?
|
||||
if (aicon == aicon->icon->core->screen_ptr->clip_icon)
|
||||
if (aicon == wAppIconGetIcon(aicon)->core->screen_ptr->clip_icon)
|
||||
wClipIconPaint(aicon);
|
||||
else if (wIsADrawer(aicon))
|
||||
wDrawerIconPaint(aicon);
|
||||
else
|
||||
wAppIconPaint(aicon);
|
||||
|
||||
wDefaultChangeIcon(aicon->wm_instance, aicon->wm_class, text);
|
||||
wDefaultChangeIcon(wAppIconGetWmInstance(aicon), wAppIconGetWmClass(aicon), text);
|
||||
}
|
||||
if (text)
|
||||
wfree(text);
|
||||
@@ -203,16 +173,16 @@ static void panelBtnCallback(WMWidget * self, void *data)
|
||||
updateCommand(panel->editedIcon, text);
|
||||
#ifdef USE_DOCK_XDND
|
||||
/* cannot free text from this, because it will be not be duplicated
|
||||
* in updateDNDCommand */
|
||||
* in wAppIconSetDnDCommand */
|
||||
text = WMGetTextFieldText(panel->dndCommandField);
|
||||
updateDNDCommand(panel->editedIcon, text);
|
||||
wAppIconSetDnDCommand(panel->editedIcon, text);
|
||||
#endif
|
||||
text = WMGetTextFieldText(panel->pasteCommandField);
|
||||
updatePasteCommand(panel->editedIcon, text);
|
||||
wAppIconSetPasteCommand(panel->editedIcon, text);
|
||||
|
||||
panel->editedIcon->auto_launch = WMGetButtonSelected(panel->autoLaunchBtn);
|
||||
wAppIconSetAutoLaunch(panel->editedIcon, WMGetButtonSelected(panel->autoLaunchBtn));
|
||||
|
||||
panel->editedIcon->lock = WMGetButtonSelected(panel->lockBtn);
|
||||
wAppIconSetLocked(panel->editedIcon, WMGetButtonSelected(panel->lockBtn));
|
||||
}
|
||||
|
||||
DestroyDockAppSettingsPanel(panel);
|
||||
@@ -221,7 +191,7 @@ static void panelBtnCallback(WMWidget * self, void *data)
|
||||
void ShowDockAppSettingsPanel(WAppIcon * aicon)
|
||||
{
|
||||
AppSettingsPanel *panel;
|
||||
WScreen *scr = aicon->icon->core->screen_ptr;
|
||||
WScreen *scr = wAppIconGetIcon(aicon)->core->screen_ptr;
|
||||
Window parent;
|
||||
WMFont *font;
|
||||
int x, y;
|
||||
@@ -252,8 +222,8 @@ void ShowDockAppSettingsPanel(WAppIcon * aicon)
|
||||
|
||||
panel->editedIcon = aicon;
|
||||
|
||||
aicon->panel = panel;
|
||||
aicon->editing = 1;
|
||||
wAppIconSetPanel(aicon, panel);
|
||||
wAppIconSetEditing(aicon, 1);
|
||||
|
||||
panel->win = WMCreateWindow(scr->wmscreen, "applicationSettings");
|
||||
WMResizeWidget(panel->win, pwidth, pheight);
|
||||
@@ -270,10 +240,10 @@ void ShowDockAppSettingsPanel(WAppIcon * aicon)
|
||||
WMSetLabelTextAlignment(panel->nameLabel, WALeft);
|
||||
WMSetLabelFont(panel->nameLabel, font);
|
||||
WMReleaseFont(font);
|
||||
if (aicon->wm_class && strcmp(aicon->wm_class, "DockApp") == 0)
|
||||
WMSetLabelText(panel->nameLabel, aicon->wm_instance);
|
||||
if (wAppIconGetWmClass(aicon) && strcmp(wAppIconGetWmClass(aicon), "DockApp") == 0)
|
||||
WMSetLabelText(panel->nameLabel, wAppIconGetWmInstance(aicon));
|
||||
else
|
||||
WMSetLabelText(panel->nameLabel, aicon->wm_class);
|
||||
WMSetLabelText(panel->nameLabel, wAppIconGetWmClass(aicon));
|
||||
|
||||
vbox = WMCreateBox(panel->win);
|
||||
WMResizeWidget(vbox, pwidth - 2 * WMScaleX(10), pheight - iconSize - 3 * WMScaleY(10));
|
||||
@@ -282,12 +252,12 @@ void ShowDockAppSettingsPanel(WAppIcon * aicon)
|
||||
panel->autoLaunchBtn = WMCreateSwitchButton(vbox);
|
||||
WMAddBoxSubview(vbox, WMWidgetView(panel->autoLaunchBtn), False, True, WMScaleY(20), WMScaleY(20), WMScaleY(2));
|
||||
WMSetButtonText(panel->autoLaunchBtn, _("Start when Window Maker is started"));
|
||||
WMSetButtonSelected(panel->autoLaunchBtn, aicon->auto_launch);
|
||||
WMSetButtonSelected(panel->autoLaunchBtn, wAppIconIsAutoLaunch(aicon));
|
||||
|
||||
panel->lockBtn = WMCreateSwitchButton(vbox);
|
||||
WMAddBoxSubview(vbox, WMWidgetView(panel->lockBtn), False, True, WMScaleY(20), WMScaleY(20), WMScaleY(5));
|
||||
WMSetButtonText(panel->lockBtn, _("Lock (prevent accidental removal)"));
|
||||
WMSetButtonSelected(panel->lockBtn, aicon->lock);
|
||||
WMSetButtonSelected(panel->lockBtn, wAppIconIsLocked(aicon));
|
||||
|
||||
panel->commandFrame = WMCreateFrame(vbox);
|
||||
WMSetFrameTitle(panel->commandFrame, _("Application path and arguments"));
|
||||
@@ -296,7 +266,7 @@ void ShowDockAppSettingsPanel(WAppIcon * aicon)
|
||||
panel->commandField = WMCreateTextField(panel->commandFrame);
|
||||
WMResizeWidget(panel->commandField, WMScaleX(260), WMScaleY(20));
|
||||
WMMoveWidget(panel->commandField, WMScaleX(10), WMScaleY(20));
|
||||
WMSetTextFieldText(panel->commandField, aicon->command);
|
||||
WMSetTextFieldText(panel->commandField, wAppIconGetCommand(aicon));
|
||||
|
||||
WMMapSubwidgets(panel->commandFrame);
|
||||
|
||||
@@ -312,7 +282,7 @@ void ShowDockAppSettingsPanel(WAppIcon * aicon)
|
||||
WMResizeWidget(panel->pasteCommandLabel, WMScaleX(260), WMScaleY(18));
|
||||
WMMoveWidget(panel->pasteCommandLabel, WMScaleX(10), WMScaleY(45));
|
||||
|
||||
WMSetTextFieldText(panel->pasteCommandField, aicon->paste_command);
|
||||
WMSetTextFieldText(panel->pasteCommandField, wAppIconGetPasteCommand(aicon));
|
||||
WMSetLabelText(panel->pasteCommandLabel, _("%s will be replaced with current selection"));
|
||||
WMMapSubwidgets(panel->pasteCommandFrame);
|
||||
|
||||
@@ -328,7 +298,7 @@ void ShowDockAppSettingsPanel(WAppIcon * aicon)
|
||||
WMResizeWidget(panel->dndCommandLabel, WMScaleX(260), WMScaleY(18));
|
||||
WMMoveWidget(panel->dndCommandLabel, WMScaleX(10), WMScaleY(45));
|
||||
#ifdef USE_DOCK_XDND
|
||||
WMSetTextFieldText(panel->dndCommandField, aicon->dnd_command);
|
||||
WMSetTextFieldText(panel->dndCommandField, wAppIconGetDnDCommand(aicon));
|
||||
WMSetLabelText(panel->dndCommandLabel, _("%d will be replaced with the file name"));
|
||||
#else
|
||||
WMSetTextFieldEditable(panel->dndCommandField, False);
|
||||
@@ -346,7 +316,7 @@ void ShowDockAppSettingsPanel(WAppIcon * aicon)
|
||||
panel->iconField = WMCreateTextField(panel->iconFrame);
|
||||
WMResizeWidget(panel->iconField, WMScaleX(180), WMScaleY(20));
|
||||
WMMoveWidget(panel->iconField, WMScaleX(10), WMScaleY(20));
|
||||
WMSetTextFieldText(panel->iconField, wDefaultGetIconFile(aicon->wm_instance, aicon->wm_class, False));
|
||||
WMSetTextFieldText(panel->iconField, wDefaultGetIconFile(wAppIconGetWmInstance(aicon), wAppIconGetWmClass(aicon), False));
|
||||
|
||||
panel->browseBtn = WMCreateCommandButton(panel->iconFrame);
|
||||
WMResizeWidget(panel->browseBtn, WMScaleX(70), WMScaleY(24));
|
||||
@@ -392,14 +362,14 @@ void ShowDockAppSettingsPanel(WAppIcon * aicon)
|
||||
{
|
||||
WMRect rect = wGetRectForHead(scr, wGetHeadForPointerLocation(scr));
|
||||
|
||||
y = aicon->y_pos;
|
||||
y = wAppIconGetYPos(aicon);
|
||||
if (y < 0)
|
||||
y = 0;
|
||||
else if (y + pheight > rect.pos.y + rect.size.height)
|
||||
y = rect.pos.y + rect.size.height - pheight - 3 * WMScaleY(10);
|
||||
|
||||
if (aicon->dock && aicon->dock->type == WM_DOCK) {
|
||||
if (aicon->dock->on_right_side)
|
||||
if (wAppIconGetDock(aicon) && wDockGetType(wAppIconGetDock(aicon)) == WM_DOCK) {
|
||||
if (wDockIsOnRightSide(wAppIconGetDock(aicon)))
|
||||
x = rect.pos.x + rect.size.width / 2;
|
||||
else
|
||||
x = rect.pos.x + rect.size.width / 2 - pwidth - WMScaleX(2);
|
||||
@@ -443,9 +413,9 @@ void DestroyDockAppSettingsPanel(AppSettingsPanel * panel)
|
||||
|
||||
XDestroyWindow(dpy, panel->parent);
|
||||
|
||||
panel->editedIcon->panel = NULL;
|
||||
wAppIconSetPanel(panel->editedIcon, NULL);
|
||||
|
||||
panel->editedIcon->editing = 0;
|
||||
wAppIconSetEditing(panel->editedIcon, 0);
|
||||
|
||||
wfree(panel);
|
||||
}
|
||||
|
||||
16
src/event.c
16
src/event.c
@@ -605,7 +605,7 @@ static void handleMapRequest(XEvent * ev)
|
||||
WApplication *wapp = wApplicationOf(wwin->main_window);
|
||||
/* go to the last workspace that the user worked on the app */
|
||||
if (wapp) {
|
||||
wWorkspaceChange(wwin->screen_ptr, wapp->last_workspace);
|
||||
wWorkspaceChange(wwin->screen_ptr, wApplicationGetLastWorkspace(wapp));
|
||||
}
|
||||
wUnhideApplication(wapp, False, False);
|
||||
}
|
||||
@@ -693,9 +693,9 @@ static void handleDestroyNotify(XEvent * event)
|
||||
|
||||
app = wApplicationOf(window);
|
||||
if (app) {
|
||||
if (window == app->main_window) {
|
||||
app->refcount = 0;
|
||||
wwin = app->main_window_desc->screen_ptr->focused_window;
|
||||
if (window == wApplicationGetMainWindow(app)) {
|
||||
wApplicationClearRefcount(app);
|
||||
wwin = wApplicationGetMainWindowDesc(app)->screen_ptr->focused_window;
|
||||
while (wwin) {
|
||||
if (wwin->main_window == window) {
|
||||
wwin->main_window = None;
|
||||
@@ -984,7 +984,7 @@ static void handlePropertyNotify(XEvent * event)
|
||||
}
|
||||
wapp = wApplicationOf(event->xproperty.window);
|
||||
if (wapp) {
|
||||
wClientCheckProperty(wapp->main_window_desc, &event->xproperty);
|
||||
wClientCheckProperty(wApplicationGetMainWindowDesc(wapp), &event->xproperty);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1038,7 +1038,7 @@ static void handleClientMessage(XEvent * event)
|
||||
if (wapp) {
|
||||
switch (event->xclient.data.l[0]) {
|
||||
case WMFHideOtherApplications:
|
||||
wHideOtherApplications(wapp->main_window_desc);
|
||||
wHideOtherApplications(wApplicationGetMainWindowDesc(wapp));
|
||||
done = 1;
|
||||
break;
|
||||
|
||||
@@ -1115,7 +1115,7 @@ static void handleClientMessage(XEvent * event)
|
||||
if (desc->parent_type == WCLASS_MINIWINDOW) {
|
||||
icon = (WIcon *) desc->parent;
|
||||
} else if (desc->parent_type == WCLASS_DOCK_ICON || desc->parent_type == WCLASS_APPICON) {
|
||||
icon = ((WAppIcon *) desc->parent)->icon;
|
||||
icon = wAppIconGetIcon((WAppIcon *) desc->parent);
|
||||
}
|
||||
if (icon && (wwin = icon->owner)) {
|
||||
if (wwin->client_win != event->xclient.window) {
|
||||
@@ -1481,7 +1481,7 @@ static void handleKeyPress(XEvent * event)
|
||||
WApplication *wapp = wApplicationOf(wwin->main_window);
|
||||
CloseWindowMenu(scr);
|
||||
|
||||
if (wapp && !WFLAGP(wapp->main_window_desc, no_appicon)) {
|
||||
if (wapp && !WFLAGP(wApplicationGetMainWindowDesc(wapp), no_appicon)) {
|
||||
wHideApplication(wapp);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -60,6 +60,11 @@ static void miniwindowDblClick(WObjDescriptor *desc, XEvent *event);
|
||||
|
||||
static WIcon *icon_create_core(WScreen *scr, int coord_x, int coord_y);
|
||||
|
||||
/****** Accessors/mutators ******/
|
||||
void wIconSetHighlighted(WIcon *icon, int highlighted) {
|
||||
icon->highlighted = highlighted;
|
||||
}
|
||||
|
||||
static void set_dockapp_in_icon(WIcon *icon);
|
||||
static void get_rimage_icon_from_icon_win(WIcon *icon);
|
||||
static void get_rimage_icon_from_user_icon(WIcon *icon);
|
||||
@@ -125,7 +130,7 @@ WIcon *icon_create_for_wwindow(WWindow *wwin)
|
||||
WApplication *wapp;
|
||||
/* do not let miniwindow steal app-icon's icon window */
|
||||
wapp = wApplicationOf(wwin->client_win);
|
||||
if (!wapp || wapp->app_icon == NULL)
|
||||
if (!wapp || wApplicationGetAppIcon(wapp) == NULL)
|
||||
icon->icon_win = wwin->wm_hints->icon_window;
|
||||
} else {
|
||||
icon->icon_win = wwin->wm_hints->icon_window;
|
||||
|
||||
@@ -57,6 +57,9 @@ typedef struct WIcon {
|
||||
* color */
|
||||
} WIcon;
|
||||
|
||||
/****** Accessors/mutators ******/
|
||||
void wIconSetHighlighted(WIcon *icon, int highlighted);
|
||||
|
||||
WIcon *icon_create_for_dock(WScreen *scr, const char *command, const char *wm_instance, const char *wm_class, int tile);
|
||||
WIcon *icon_create_for_wwindow(WWindow *wwin);
|
||||
|
||||
|
||||
@@ -63,6 +63,12 @@
|
||||
/****** Global Variables ******/
|
||||
struct wmaker_global_variables w_global;
|
||||
|
||||
struct wmaker_global_variables_context *wGlobalGetContext()
|
||||
{
|
||||
return &w_global.context;
|
||||
}
|
||||
|
||||
|
||||
/* general info */
|
||||
|
||||
Display *dpy;
|
||||
|
||||
@@ -57,9 +57,9 @@ iconPosition(WCoreWindow *wcore, int sx1, int sy1, int sx2, int sy2,
|
||||
parent = wcore->descriptor.parent;
|
||||
|
||||
/* if it is an application icon */
|
||||
if (wcore->descriptor.parent_type == WCLASS_APPICON && !((WAppIcon *) parent)->docked) {
|
||||
*retX = ((WAppIcon *) parent)->x_pos;
|
||||
*retY = ((WAppIcon *) parent)->y_pos;
|
||||
if (wcore->descriptor.parent_type == WCLASS_APPICON && !wAppIconIsDocked((WAppIcon *) parent)) {
|
||||
*retX = wAppIconGetXPos((WAppIcon *) parent);
|
||||
*retY = wAppIconGetYPos((WAppIcon *) parent);
|
||||
|
||||
ok = 1;
|
||||
} else if (wcore->descriptor.parent_type == WCLASS_MINIWINDOW &&
|
||||
@@ -121,7 +121,7 @@ void PlaceIcon(WScreen *scr, int *x_ret, int *y_ret, int head)
|
||||
if (scr->dock) {
|
||||
int offset = wPreferences.icon_size + DOCK_EXTRA_SPACE;
|
||||
|
||||
if (scr->dock->on_right_side)
|
||||
if (wDockIsOnRightSide(scr->dock))
|
||||
area.x2 -= offset;
|
||||
else
|
||||
area.x1 += offset;
|
||||
|
||||
@@ -591,6 +591,11 @@ static void createInternalWindows(WScreen * scr)
|
||||
scr->mini_screenshot_timeout = 0;
|
||||
}
|
||||
|
||||
/****** Accessors/mutators ******/
|
||||
Window wScreenGetRootWin(WScreen *scr) {
|
||||
return scr->root_win;
|
||||
}
|
||||
|
||||
/*
|
||||
*----------------------------------------------------------------------
|
||||
* wScreenInit--
|
||||
@@ -927,7 +932,7 @@ void wScreenRestoreState(WScreen * scr)
|
||||
}
|
||||
|
||||
if (!wPreferences.flags.nodrawer) {
|
||||
if (!scr->dock->on_right_side) {
|
||||
if (!wDockIsOnRightSide(scr->dock)) {
|
||||
/* Drawer tile was created early in wScreenInit() -> wReadDefaults(). At
|
||||
* that time, scr->dock was NULL and the tile was created as if we were on
|
||||
* the right side. If we aren't, redo it now. */
|
||||
|
||||
@@ -106,8 +106,6 @@ typedef struct _WScreen {
|
||||
|
||||
struct WAppIcon *app_icon_list; /* list of all app-icons on screen */
|
||||
|
||||
struct WApplication *wapp_list; /* list of all aplications */
|
||||
|
||||
WMBag *stacking_list; /* bag of lists of windows
|
||||
* in stacking order.
|
||||
* Indexed by window level
|
||||
@@ -331,6 +329,8 @@ typedef struct _WScreen {
|
||||
} WScreen;
|
||||
|
||||
|
||||
/****** Accessors/mutators ******/
|
||||
Window wScreenGetRootWin(WScreen *scr);
|
||||
|
||||
WScreen *wScreenInit(int screen_number);
|
||||
void wScreenSaveState(WScreen *scr);
|
||||
|
||||
@@ -202,9 +202,9 @@ static WMPropList *makeWindowState(WWindow * wwin, WApplication * wapp)
|
||||
|
||||
command = GetCommandForWindow(win);
|
||||
if (!command) {
|
||||
if (wapp->app_icon && wapp->app_icon->command) {
|
||||
command = wmalloc(strlen(wapp->app_icon->command) + 1);
|
||||
strcpy(command, wapp->app_icon->command);
|
||||
if (wApplicationGetAppIcon(wapp) && wAppIconGetCommand(wApplicationGetAppIcon(wapp))) {
|
||||
command = wmalloc(strlen(wAppIconGetCommand(wApplicationGetAppIcon(wapp))) + 1);
|
||||
strcpy(command, wAppIconGetCommand(wApplicationGetAppIcon(wapp)));
|
||||
} else
|
||||
return NULL;
|
||||
}
|
||||
@@ -256,16 +256,16 @@ static WMPropList *makeWindowState(WWindow * wwin, WApplication * wapp)
|
||||
WMReleasePropList(maximized);
|
||||
WMReleasePropList(geometry);
|
||||
WMReleasePropList(shortcut);
|
||||
if (wapp && wapp->app_icon && wapp->app_icon->dock) {
|
||||
if (wapp && wApplicationGetAppIcon(wapp) && wAppIconGetDock(wApplicationGetAppIcon(wapp))) {
|
||||
int i;
|
||||
char *name = NULL;
|
||||
if (wapp->app_icon->dock == scr->dock)
|
||||
if (wAppIconGetDock(wApplicationGetAppIcon(wapp)) == scr->dock)
|
||||
name = "Dock";
|
||||
|
||||
/* Try the clips */
|
||||
if (name == NULL) {
|
||||
for (i = 0; i < scr->workspace_count; i++)
|
||||
if (scr->workspaces[i]->clip == wapp->app_icon->dock)
|
||||
if (scr->workspaces[i]->clip == wAppIconGetDock(wApplicationGetAppIcon(wapp)))
|
||||
break;
|
||||
if (i < scr->workspace_count)
|
||||
name = scr->workspaces[i]->name;
|
||||
@@ -274,11 +274,11 @@ static WMPropList *makeWindowState(WWindow * wwin, WApplication * wapp)
|
||||
if (name == NULL) {
|
||||
WDrawerChain *dc;
|
||||
for (dc = scr->drawers; dc != NULL; dc = dc->next) {
|
||||
if (dc->adrawer == wapp->app_icon->dock)
|
||||
if (dc->adrawer == wAppIconGetDock(wApplicationGetAppIcon(wapp)))
|
||||
break;
|
||||
}
|
||||
assert(dc != NULL);
|
||||
name = dc->adrawer->icon_array[0]->wm_instance;
|
||||
name = wAppIconGetWmInstance(wDockGetIcon(dc->adrawer, 0));
|
||||
}
|
||||
dock = WMCreatePLString(name);
|
||||
WMPutInPLDictionary(win_state, sDock, dock);
|
||||
@@ -536,7 +536,7 @@ void wSessionRestoreState(WScreen *scr)
|
||||
WDrawerChain *dc;
|
||||
for (dc = scr->drawers; dc != NULL; dc = dc->next)
|
||||
{
|
||||
if (strcmp(dc->adrawer->icon_array[0]->wm_instance, tmp) == 0)
|
||||
if (strcmp(wAppIconGetWmInstance(wDockGetIcon(dc->adrawer, 0)), tmp) == 0)
|
||||
{
|
||||
dock = dc->adrawer;
|
||||
break;
|
||||
@@ -554,12 +554,12 @@ void wSessionRestoreState(WScreen *scr)
|
||||
|
||||
found = 0;
|
||||
if (dock != NULL) {
|
||||
for (j = 0; j < dock->max_icons; j++) {
|
||||
btn = dock->icon_array[j];
|
||||
if (btn && is_same(instance, btn->wm_instance) &&
|
||||
is_same(class, btn->wm_class) &&
|
||||
is_same(command, btn->command) &&
|
||||
!btn->launching) {
|
||||
for (j = 0; j < wDockGetMaxIcons(dock); j++) {
|
||||
btn = wDockGetIcon(dock, j);
|
||||
if (btn && is_same(instance, wAppIconGetWmInstance(btn)) &&
|
||||
is_same(class, wAppIconGetWmClass(btn)) &&
|
||||
is_same(command, wAppIconGetCommand(btn)) &&
|
||||
!wAppIconIsLaunching(btn)) {
|
||||
found = 1;
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -193,15 +193,15 @@ typedef struct AppBouncerData {
|
||||
static void doAppBounce(void *arg)
|
||||
{
|
||||
AppBouncerData *data = (AppBouncerData*)arg;
|
||||
WAppIcon *aicon = data->wapp->app_icon;
|
||||
WAppIcon *aicon = wApplicationGetAppIcon(data->wapp);
|
||||
|
||||
if (!aicon)
|
||||
return;
|
||||
|
||||
reinit:
|
||||
if (data->wapp->refcount > 1) {
|
||||
if (wApplicationHasLiveRefcount(data->wapp)) {
|
||||
if (wPreferences.raise_appicons_when_bouncing)
|
||||
XRaiseWindow(dpy, aicon->icon->core->window);
|
||||
XRaiseWindow(dpy, wAppIconGetIcon(aicon)->core->window);
|
||||
|
||||
const double ticks = BOUNCE_HZ * BOUNCE_LENGTH;
|
||||
const double s = sqrt(BOUNCE_HEIGHT)/(ticks/2);
|
||||
@@ -218,30 +218,30 @@ reinit:
|
||||
|
||||
switch (data->dir) {
|
||||
case 0: /* left, bounce to right */
|
||||
XMoveWindow(dpy, aicon->icon->core->window,
|
||||
aicon->x_pos + (int)offset, aicon->y_pos);
|
||||
XMoveWindow(dpy, wAppIconGetIcon(aicon)->core->window,
|
||||
wAppIconGetXPos(aicon) + (int)offset, wAppIconGetYPos(aicon));
|
||||
break;
|
||||
case 1: /* right, bounce to left */
|
||||
XMoveWindow(dpy, aicon->icon->core->window,
|
||||
aicon->x_pos - (int)offset, aicon->y_pos);
|
||||
XMoveWindow(dpy, wAppIconGetIcon(aicon)->core->window,
|
||||
wAppIconGetXPos(aicon) - (int)offset, wAppIconGetYPos(aicon));
|
||||
break;
|
||||
case 2: /* top, bounce down */
|
||||
XMoveWindow(dpy, aicon->icon->core->window,
|
||||
aicon->x_pos, aicon->y_pos + (int)offset);
|
||||
XMoveWindow(dpy, wAppIconGetIcon(aicon)->core->window,
|
||||
wAppIconGetXPos(aicon), wAppIconGetYPos(aicon) + (int)offset);
|
||||
break;
|
||||
case 3: /* bottom, bounce up */
|
||||
XMoveWindow(dpy, aicon->icon->core->window,
|
||||
aicon->x_pos, aicon->y_pos - (int)offset);
|
||||
XMoveWindow(dpy, wAppIconGetIcon(aicon)->core->window,
|
||||
wAppIconGetXPos(aicon), wAppIconGetYPos(aicon) - (int)offset);
|
||||
break;
|
||||
}
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
XMoveWindow(dpy, aicon->icon->core->window,
|
||||
aicon->x_pos, aicon->y_pos);
|
||||
CommitStackingForWindow(aicon->icon->core);
|
||||
data->wapp->flags.bouncing = 0;
|
||||
XMoveWindow(dpy, wAppIconGetIcon(aicon)->core->window,
|
||||
wAppIconGetXPos(aicon), wAppIconGetYPos(aicon));
|
||||
CommitStackingForWindow(wAppIconGetIcon(aicon)->core);
|
||||
wApplicationSetBouncing(data->wapp, 0);
|
||||
WMDeleteTimerHandler(data->timer);
|
||||
wApplicationDestroy(data->wapp);
|
||||
free(data);
|
||||
@@ -251,13 +251,13 @@ static int bounceDirection(WAppIcon *aicon)
|
||||
{
|
||||
enum { left_e = 1, right_e = 2, top_e = 4, bottom_e = 8 };
|
||||
|
||||
WScreen *scr = aicon->icon->core->screen_ptr;
|
||||
WScreen *scr = wAppIconGetIcon(aicon)->core->screen_ptr;
|
||||
WMRect rr, sr;
|
||||
int l, r, t, b, h, v;
|
||||
int dir = 0;
|
||||
|
||||
rr.pos.x = aicon->x_pos;
|
||||
rr.pos.y = aicon->y_pos;
|
||||
rr.pos.x = wAppIconGetXPos(aicon);
|
||||
rr.pos.y = wAppIconGetYPos(aicon);
|
||||
rr.size.width = rr.size.height = 64;
|
||||
|
||||
sr = wGetRectForHead(scr, wGetHeadForRect(scr, rr));
|
||||
@@ -283,8 +283,8 @@ static int bounceDirection(WAppIcon *aicon)
|
||||
v = b;
|
||||
}
|
||||
|
||||
if (aicon->dock && abs(aicon->xindex) != abs(aicon->yindex)) {
|
||||
if (abs(aicon->xindex) < abs(aicon->yindex)) dir &= ~(top_e | bottom_e);
|
||||
if (wAppIconGetDock(aicon) && abs(wAppIconGetXIndex(aicon)) != abs(wAppIconGetYIndex(aicon))) {
|
||||
if (abs(wAppIconGetXIndex(aicon)) < abs(wAppIconGetYIndex(aicon))) dir &= ~(top_e | bottom_e);
|
||||
else dir &= ~(left_e | right_e);
|
||||
} else {
|
||||
if (h < v) dir &= ~(top_e | bottom_e);
|
||||
@@ -319,15 +319,15 @@ static int bounceDirection(WAppIcon *aicon)
|
||||
|
||||
void wAppBounce(WApplication *wapp)
|
||||
{
|
||||
if (!wPreferences.no_animations && wapp->app_icon && !wapp->flags.bouncing
|
||||
if (!wPreferences.no_animations && wApplicationGetAppIcon(wapp) && !wApplicationIsBouncing(wapp)
|
||||
&& !wPreferences.do_not_make_appicons_bounce) {
|
||||
++wapp->refcount;
|
||||
wapp->flags.bouncing = 1;
|
||||
wApplicationIncrementRefcount(wapp);
|
||||
wApplicationSetBouncing(wapp, 1);
|
||||
|
||||
AppBouncerData *data = (AppBouncerData *)malloc(sizeof(AppBouncerData));
|
||||
data->wapp = wapp;
|
||||
data->count = data->pow = 0;
|
||||
data->dir = bounceDirection(wapp->app_icon);
|
||||
data->dir = bounceDirection(wApplicationGetAppIcon(wapp));
|
||||
data->timer = WMAddPersistentTimerHandler(BOUNCE_DELAY, doAppBounce, data);
|
||||
}
|
||||
}
|
||||
@@ -337,17 +337,17 @@ static int appIsUrgent(WApplication *wapp)
|
||||
WScreen *scr;
|
||||
WWindow *wlist;
|
||||
|
||||
if (!wapp->main_window_desc) {
|
||||
if (!wApplicationGetMainWindowDesc(wapp)) {
|
||||
wwarning("group leader not found for window group");
|
||||
return 0;
|
||||
}
|
||||
scr = wapp->main_window_desc->screen_ptr;
|
||||
scr = wApplicationGetMainWindowDesc(wapp)->screen_ptr;
|
||||
wlist = scr->focused_window;
|
||||
if (!wlist)
|
||||
return 0;
|
||||
|
||||
while (wlist) {
|
||||
if (wlist->main_window == wapp->main_window) {
|
||||
if (wlist->main_window == wApplicationGetMainWindow(wapp)) {
|
||||
if (wlist->flags.urgent)
|
||||
return 1;
|
||||
}
|
||||
@@ -364,8 +364,7 @@ static void doAppUrgentBounce(void *arg)
|
||||
if (appIsUrgent(wapp)) {
|
||||
if(wPreferences.bounce_appicons_when_urgent) wAppBounce(wapp);
|
||||
} else {
|
||||
WMDeleteTimerHandler(wapp->urgent_bounce_timer);
|
||||
wapp->urgent_bounce_timer = NULL;
|
||||
wApplicationClearUrgentBounceTimer(wapp);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -373,14 +372,13 @@ void wAppBounceWhileUrgent(WApplication *wapp)
|
||||
{
|
||||
if (!wapp) return;
|
||||
if (appIsUrgent(wapp)) {
|
||||
if (!wapp->urgent_bounce_timer) {
|
||||
wapp->urgent_bounce_timer = WMAddPersistentTimerHandler(URGENT_BOUNCE_DELAY, doAppUrgentBounce, wapp);
|
||||
if (!wApplicationHasUrgentBounceTimer(wapp)) {
|
||||
wApplicationSetUrgentBounceTimer(wapp, WMAddPersistentTimerHandler(URGENT_BOUNCE_DELAY, doAppUrgentBounce, wapp));
|
||||
doAppUrgentBounce(wapp);
|
||||
}
|
||||
} else {
|
||||
if (wapp->urgent_bounce_timer) {
|
||||
WMDeleteTimerHandler(wapp->urgent_bounce_timer);
|
||||
wapp->urgent_bounce_timer = NULL;
|
||||
if (wApplicationHasUrgentBounceTimer(wapp)) {
|
||||
wApplicationClearUrgentBounceTimer(wapp);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
89
src/window.c
89
src/window.c
@@ -132,6 +132,79 @@ static void appearanceObserver(void *self, WMNotification * notif)
|
||||
}
|
||||
}
|
||||
|
||||
/****** Accessors/mutators ******/
|
||||
WFakeGroupLeader *wWindowGetFakeGroup(WWindow *wwin) {
|
||||
return wwin->fake_group;
|
||||
}
|
||||
void wWindowSetFakeGroup(WWindow *wwin, WFakeGroupLeader *fake_group) {
|
||||
wwin->fake_group = fake_group;
|
||||
}
|
||||
|
||||
Window wWindowGetMainWindow(WWindow *wwin) {
|
||||
return wwin->main_window;
|
||||
}
|
||||
|
||||
void wWindowSetMainWindow(WWindow *wwin, Window main_window) {
|
||||
wwin->main_window = main_window;
|
||||
}
|
||||
|
||||
RImage *wWindowGetNetIconImage(WWindow *wwin) {
|
||||
return wwin->net_icon_image;
|
||||
}
|
||||
void wWindowSetNetIconImage(WWindow *wwin, RImage *image) {
|
||||
wwin->net_icon_image = image;
|
||||
}
|
||||
|
||||
Window wWindowGetClientWin(WWindow *wwin) {
|
||||
return wwin->client_win;
|
||||
}
|
||||
|
||||
WScreen *wWindowGetScreenPtr(WWindow *wwin) {
|
||||
return wwin->screen_ptr;
|
||||
}
|
||||
void wWindowSetScreenPtr(WWindow *wwin, WScreen *screen_ptr) {
|
||||
wwin->screen_ptr = screen_ptr;
|
||||
}
|
||||
|
||||
void wWindowSetWmHints(WWindow *wwin, XWMHints *wm_hints) {
|
||||
wwin->wm_hints = wm_hints;
|
||||
}
|
||||
|
||||
void wWindowSetWmClass(WWindow *wwin, char *wm_class) {
|
||||
wwin->wm_class = wm_class;
|
||||
}
|
||||
|
||||
void wWindowSetWmInstance(WWindow *wwin, char *wm_instance) {
|
||||
wwin->wm_instance = wm_instance;
|
||||
}
|
||||
|
||||
const WWindowAttributes *wWindowGetUserFlags(WWindow *wwin) {
|
||||
return &wwin->user_flags;
|
||||
}
|
||||
|
||||
WWindowAttributes *wWindowGetUserFlagsMut(WWindow *wwin) {
|
||||
return &wwin->user_flags;
|
||||
}
|
||||
|
||||
const WWindowAttributes *wWindowGetDefinedUserFlags(WWindow *wwin) {
|
||||
return &wwin->defined_user_flags;
|
||||
}
|
||||
|
||||
WWindowAttributes *wWindowGetDefinedUserFlagsMut(WWindow *wwin) {
|
||||
return &wwin->defined_user_flags;
|
||||
}
|
||||
|
||||
const WWindowAttributes *wWindowGetClientFlags(WWindow *wwin) {
|
||||
return &wwin->client_flags;
|
||||
}
|
||||
|
||||
int wWindowAttributesGetStartHidden(WWindowAttributes *attrs) {
|
||||
return attrs->start_hidden;
|
||||
}
|
||||
|
||||
int wWindowAttributesGetEmulated(WWindowAttributes *attrs) {
|
||||
return attrs->emulate_appicon;
|
||||
}
|
||||
|
||||
/* Return the WWindow associated with a given (Xlib) Window. */
|
||||
WWindow *wWindowFor(Window window)
|
||||
@@ -438,7 +511,7 @@ void wWindowSetupInitialAttributes(WWindow *wwin, int *level, int *workspace)
|
||||
|
||||
if (wwin->main_window != None) {
|
||||
WApplication *wapp = wApplicationOf(wwin->main_window);
|
||||
if (wapp && !wapp->flags.emulated)
|
||||
if (wapp && !wApplicationIsEmulated(wapp))
|
||||
wwin->user_flags.emulate_appicon = 0;
|
||||
}
|
||||
|
||||
@@ -826,7 +899,7 @@ WWindow *wManageWindow(WScreen *scr, Window window)
|
||||
|
||||
if (wwin->main_window) {
|
||||
WApplication *app = wApplicationOf(wwin->main_window);
|
||||
if (app && app->app_icon)
|
||||
if (app && wApplicationGetAppIcon(app))
|
||||
wwin->client_flags.shared_appicon = 0;
|
||||
}
|
||||
|
||||
@@ -1241,7 +1314,7 @@ WWindow *wManageWindow(WScreen *scr, Window window)
|
||||
|
||||
app = wApplicationCreate(wwin);
|
||||
if (app) {
|
||||
app->last_workspace = workspace;
|
||||
wApplicationSetLastWorkspace(app, workspace);
|
||||
|
||||
/* Do application specific stuff, like setting application
|
||||
* wide attributes. */
|
||||
@@ -1249,9 +1322,9 @@ WWindow *wManageWindow(WScreen *scr, Window window)
|
||||
if (wwin->flags.hidden) {
|
||||
/* if the window was set to hidden because it was hidden
|
||||
* in a previous incarnation and that state was restored */
|
||||
app->flags.hidden = 1;
|
||||
} else if (app->flags.hidden) {
|
||||
if (WFLAGP(app->main_window_desc, start_hidden)) {
|
||||
wApplicationSetHidden(app, 1);
|
||||
} else if (wApplicationIsHidden(app)) {
|
||||
if (WFLAGP(wApplicationGetMainWindowDesc(app), start_hidden)) {
|
||||
wwin->flags.hidden = 1;
|
||||
} else {
|
||||
wUnhideApplication(app, False, False);
|
||||
@@ -1683,7 +1756,7 @@ void wUnmanageWindow(WWindow *wwin, Bool restore, Bool destroyed)
|
||||
WApplication *oapp = wApplicationOf(wwin->main_window);
|
||||
WApplication *napp = scr->focused_window ? wApplicationOf(scr->focused_window->main_window) : NULL;
|
||||
if (oapp && oapp != napp) {
|
||||
wAppMenuUnmap(oapp->menu);
|
||||
wAppMenuUnmap(wApplicationGetMenu(oapp));
|
||||
if (wPreferences.highlight_active_app)
|
||||
wApplicationDeactivate(oapp);
|
||||
}
|
||||
@@ -2037,7 +2110,7 @@ void wWindowChangeWorkspace(WWindow *wwin, int workspace)
|
||||
|
||||
wapp = wApplicationOf(wwin->main_window);
|
||||
if (wapp)
|
||||
wapp->last_workspace = workspace;
|
||||
wApplicationSetLastWorkspace(wapp, workspace);
|
||||
|
||||
if (wwin->flags.miniaturized) {
|
||||
if (wwin->icon) {
|
||||
|
||||
32
src/window.h
32
src/window.h
@@ -330,6 +330,38 @@ typedef struct WWindowState {
|
||||
|
||||
typedef void* WMagicNumber;
|
||||
|
||||
/****** Accessors/mutators ******/
|
||||
WFakeGroupLeader *wWindowGetFakeGroup(WWindow *wwin);
|
||||
void wWindowSetFakeGroup(WWindow *wwin, WFakeGroupLeader *fake_group);
|
||||
|
||||
/****** Lifecycle/etc. ******/
|
||||
Window wWindowGetMainWindow(WWindow *wwin);
|
||||
void wWindowSetMainWindow(WWindow *wwin, Window main_window);
|
||||
|
||||
RImage *wWindowGetNetIconImage(WWindow *wwin);
|
||||
void wWindowSetNetIconImage(WWindow *wwin, RImage *image);
|
||||
|
||||
Window wWindowGetClientWin(WWindow *wwin);
|
||||
|
||||
WScreen *wWindowGetScreenPtr(WWindow *wwin);
|
||||
void wWindowSetScreenPtr(WWindow *wwin, WScreen *screen_ptr);
|
||||
|
||||
void wWindowSetWmHints(WWindow *wwin, XWMHints *wm_hints);
|
||||
|
||||
void wWindowSetWmClass(WWindow *wwin, char *wm_hints);
|
||||
|
||||
void wWindowSetWmInstance(WWindow *wwin, char *wm_hints);
|
||||
|
||||
const WWindowAttributes *wWindowGetUserFlags(WWindow *wwin);
|
||||
WWindowAttributes *wWindowGetUserFlagsMut(WWindow *wwin);
|
||||
|
||||
const WWindowAttributes *wWindowGetDefinedUserFlags(WWindow *wwin);
|
||||
WWindowAttributes *wWindowGetDefinedUserFlagsMut(WWindow *wwin);
|
||||
|
||||
const WWindowAttributes *wWindowGetClientFlags(WWindow *wwin);
|
||||
|
||||
/****** Lifecycle/etc. ******/
|
||||
|
||||
void wWindowDestroy(WWindow *wwin);
|
||||
WWindow *wWindowCreate(void);
|
||||
|
||||
|
||||
@@ -636,7 +636,7 @@ static void updateMenuForWindow(WMenu * menu, WWindow * wwin)
|
||||
|
||||
updateMakeShortcutMenu(menu, wwin);
|
||||
|
||||
wMenuSetEnabled(menu, MC_HIDE, wapp != NULL && !WFLAGP(wapp->main_window_desc, no_appicon));
|
||||
wMenuSetEnabled(menu, MC_HIDE, wapp != NULL && !WFLAGP(wApplicationGetMainWindowDesc(wapp), no_appicon));
|
||||
|
||||
wMenuSetEnabled(menu, MC_CLOSE, (wwin->protocols.DELETE_WINDOW && !WFLAGP(wwin, no_closable)));
|
||||
|
||||
|
||||
@@ -679,8 +679,8 @@ static void saveSettings(WMWidget *button, void *client_data)
|
||||
WApplication *wapp = wApplicationOf(wwin->main_window);
|
||||
|
||||
if (wapp) {
|
||||
buf2 = StrConcatDot(wapp->main_window_desc->wm_instance,
|
||||
wapp->main_window_desc->wm_class);
|
||||
buf2 = StrConcatDot(wApplicationGetMainWindowDesc(wapp)->wm_instance,
|
||||
wApplicationGetMainWindowDesc(wapp)->wm_class);
|
||||
key2 = WMCreatePLString(buf2);
|
||||
wfree(buf2);
|
||||
|
||||
@@ -795,14 +795,14 @@ static void applySettings(WMWidget *button, void *client_data)
|
||||
/* do application wide stuff */
|
||||
for (i = 0; i < wlengthof(application_attr); i++) {
|
||||
if (WMGetButtonSelected(panel->appChk[i]))
|
||||
set_attr_flag(&wapp->main_window_desc->user_flags, &application_attr[i].flag);
|
||||
set_attr_flag(&wApplicationGetMainWindowDesc(wapp)->user_flags, &application_attr[i].flag);
|
||||
else
|
||||
clear_attr_flag(&wapp->main_window_desc->user_flags, &application_attr[i].flag);
|
||||
clear_attr_flag(&wApplicationGetMainWindowDesc(wapp)->user_flags, &application_attr[i].flag);
|
||||
|
||||
set_attr_flag(&wapp->main_window_desc->defined_user_flags, &application_attr[i].flag);
|
||||
set_attr_flag(&wApplicationGetMainWindowDesc(wapp)->defined_user_flags, &application_attr[i].flag);
|
||||
}
|
||||
|
||||
if (WFLAGP(wapp->main_window_desc, no_appicon))
|
||||
if (WFLAGP(wApplicationGetMainWindowDesc(wapp), no_appicon))
|
||||
unpaint_app_icon(wapp);
|
||||
else
|
||||
paint_app_icon(wapp);
|
||||
@@ -836,13 +836,13 @@ static void applySettings(WMWidget *button, void *client_data)
|
||||
* the icon text box has an icon path */
|
||||
if (!WFLAGP(wwin, always_user_icon)) {
|
||||
/* Change App Icon image, using the icon provided by the client */
|
||||
if (wapp->app_icon) {
|
||||
RImage *image = get_rimage_icon_from_wm_hints(wapp->app_icon->icon);
|
||||
if (wApplicationGetAppIcon(wapp)) {
|
||||
RImage *image = get_rimage_icon_from_wm_hints(wAppIconGetIcon(wApplicationGetAppIcon(wapp)));
|
||||
if (image) {
|
||||
set_icon_image_from_image(wapp->app_icon->icon, image);
|
||||
update_icon_pixmap(wapp->app_icon->icon);
|
||||
set_icon_image_from_image(wAppIconGetIcon(wApplicationGetAppIcon(wapp)), image);
|
||||
update_icon_pixmap(wAppIconGetIcon(wApplicationGetAppIcon(wapp)));
|
||||
} else {
|
||||
wIconUpdate(wapp->app_icon->icon);
|
||||
wIconUpdate(wAppIconGetIcon(wApplicationGetAppIcon(wapp)));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -859,8 +859,8 @@ static void applySettings(WMWidget *button, void *client_data)
|
||||
}
|
||||
} else {
|
||||
/* Change App Icon image */
|
||||
if (wapp->app_icon)
|
||||
wIconChangeImageFile(wapp->app_icon->icon, file);
|
||||
if (wApplicationGetAppIcon(wapp))
|
||||
wIconChangeImageFile(wAppIconGetIcon(wApplicationGetAppIcon(wapp)), file);
|
||||
|
||||
/* Change icon image if the app is minimized */
|
||||
if (wwin->icon)
|
||||
@@ -931,11 +931,11 @@ static void revertSettings(WMWidget *button, void *client_data)
|
||||
for (i = 0; i < wlengthof(application_attr); i++) {
|
||||
int is_userdef, flag = 0;
|
||||
|
||||
is_userdef = get_attr_flag(&wapp->main_window_desc->defined_user_flags, &application_attr[i].flag);
|
||||
is_userdef = get_attr_flag(&wApplicationGetMainWindowDesc(wapp)->defined_user_flags, &application_attr[i].flag);
|
||||
if (is_userdef)
|
||||
flag = get_attr_flag(&wapp->main_window_desc->user_flags, &application_attr[i].flag);
|
||||
flag = get_attr_flag(&wApplicationGetMainWindowDesc(wapp)->user_flags, &application_attr[i].flag);
|
||||
else
|
||||
flag = get_attr_flag(&wapp->main_window_desc->client_flags, &application_attr[i].flag);
|
||||
flag = get_attr_flag(&wApplicationGetMainWindowDesc(wapp)->client_flags, &application_attr[i].flag);
|
||||
|
||||
WMSetButtonSelected(panel->appChk[i], flag);
|
||||
}
|
||||
@@ -1444,11 +1444,11 @@ static void create_tab_app_specific(WWindow *wwin, InspectorPanel *panel, int fr
|
||||
for (i = 0; i < wlengthof(application_attr); i++) {
|
||||
int is_userdef, flag;
|
||||
|
||||
is_userdef = get_attr_flag(&wapp->main_window_desc->defined_user_flags, &application_attr[i].flag);
|
||||
is_userdef = get_attr_flag(&wApplicationGetMainWindowDesc(wapp)->defined_user_flags, &application_attr[i].flag);
|
||||
if (is_userdef)
|
||||
flag = get_attr_flag(&wapp->main_window_desc->user_flags, &application_attr[i].flag);
|
||||
flag = get_attr_flag(&wApplicationGetMainWindowDesc(wapp)->user_flags, &application_attr[i].flag);
|
||||
else
|
||||
flag = get_attr_flag(&wapp->main_window_desc->client_flags, &application_attr[i].flag);
|
||||
flag = get_attr_flag(&wApplicationGetMainWindowDesc(wapp)->client_flags, &application_attr[i].flag);
|
||||
|
||||
panel->appChk[i] = WMCreateSwitchButton(panel->appFrm);
|
||||
WMMoveWidget(panel->appChk[i], 10, 20 * (i + 1));
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user