1 |
commit: 9831f08ca067fab97a619811280d00670fa6f8e8 |
2 |
Author: Jimi Huotari <chiitoo <AT> gentoo <DOT> org> |
3 |
AuthorDate: Mon Nov 6 18:47:37 2017 +0000 |
4 |
Commit: NP Hardass <np-hardass <AT> gentoo <DOT> org> |
5 |
CommitDate: Tue Nov 7 02:39:34 2017 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9831f08c |
7 |
|
8 |
lxqt-base/lxqt-panel: Move oversize patch to dev-space. |
9 |
|
10 |
Package-Manager: Portage-2.3.13, Repoman-2.3.4 |
11 |
|
12 |
Signed-off-by: NP-Hardass <NP-Hardass <AT> gentoo.org> |
13 |
|
14 |
lxqt-base/lxqt-panel/Manifest | 1 + |
15 |
.../files/lxqt-panel-0.10.0-autohide.patch | 625 --------------------- |
16 |
lxqt-base/lxqt-panel/lxqt-panel-0.10.0-r1.ebuild | 7 +- |
17 |
3 files changed, 5 insertions(+), 628 deletions(-) |
18 |
|
19 |
diff --git a/lxqt-base/lxqt-panel/Manifest b/lxqt-base/lxqt-panel/Manifest |
20 |
index af123ca3534..d17b3e22644 100644 |
21 |
--- a/lxqt-base/lxqt-panel/Manifest |
22 |
+++ b/lxqt-base/lxqt-panel/Manifest |
23 |
@@ -1,2 +1,3 @@ |
24 |
+DIST lxqt-panel-0.10.0-autohide-patch.tar.bz2 5812 SHA256 e590c2ed4554c27e3fc640197cd48ccce1dfba75139669eb2e1cae71d6f5c82b SHA512 04b2dcfa107e6cedd8347b399e254c193f2f245ce796c6f2b26f3b47a7969da5d673d30f2dd08ad66a9815394e4a8baf72191c14ec58652a2f71005240b3844d WHIRLPOOL c256b404c9daaf5b8d59f7fc88760180fe1643801e92c30fd25c3514083fc531d27ee29ffe3dd8476dae7df524566b5e9430ece9f71c2607a47d976d89658351 |
25 |
DIST lxqt-panel-0.10.0.tar.xz 329984 SHA256 df83db7789daecd358f074db2100d7b251c00e48aa3aa62957d5a657a4309d5e SHA512 59a25593beeabbd02a451e00db479617612d63ba5579560ab4b1c60d6ad1878728cc079a848b9437968c7246f257b53c775de2cb9e87f3e153049e6dbeee2ab4 WHIRLPOOL 6d49c0d78f66ff4d6a0fe026915e72bf6ca9c5b73f198866402c6e82ffd10b53a22f9ef1a583d05ae47918d90ccc08b1230582ccd86948d77079e2b2fdf3af6b |
26 |
DIST lxqt-panel-0.11.0.tar.xz 262964 SHA256 18415624d862b9b269fd1f74b2b6a51776852babd057e701e5d5b48ce46e777c SHA512 875ec28868bb68dff8c4e3be0adb5e5c88213f9ebdeb83eb0df9d5c31a7b4cb70a4d9b347f1ed9526a1eef7adb07f92c36263e12a6455291ec7022901abd100c WHIRLPOOL 9a9f6ff92afbf598d6a1f29d083e3fc85f3282f644508d1bc03683eb9bbe06048d65688e016bb17e7553aba23b10de251949000e2da65c3b5e547e9f273e7cd1 |
27 |
|
28 |
diff --git a/lxqt-base/lxqt-panel/files/lxqt-panel-0.10.0-autohide.patch b/lxqt-base/lxqt-panel/files/lxqt-panel-0.10.0-autohide.patch |
29 |
deleted file mode 100644 |
30 |
index 5f2bbdae6f2..00000000000 |
31 |
--- a/lxqt-base/lxqt-panel/files/lxqt-panel-0.10.0-autohide.patch |
32 |
+++ /dev/null |
33 |
@@ -1,625 +0,0 @@ |
34 |
-Patch for autohide issue https://github.com/lxde/lxqt/issues/871 |
35 |
-taken from https://github.com/lxde/lxqt-panel/pull/275 |
36 |
- |
37 |
-diff --git panel/CMakeLists.txt panel/CMakeLists.txt |
38 |
-index 4e23b53..a7f8176 100644 |
39 |
---- panel/CMakeLists.txt |
40 |
-+++ panel/CMakeLists.txt |
41 |
-@@ -2,6 +2,7 @@ set(PROJECT lxqt-panel) |
42 |
- |
43 |
- set(PRIV_HEADERS |
44 |
- panelpluginsmodel.h |
45 |
-+ windownotifier.h |
46 |
- lxqtpanel.h |
47 |
- lxqtpanelapplication.h |
48 |
- lxqtpanellayout.h |
49 |
-@@ -26,6 +27,7 @@ set(PUB_HEADERS |
50 |
- set(SOURCES |
51 |
- main.cpp |
52 |
- panelpluginsmodel.cpp |
53 |
-+ windownotifier.cpp |
54 |
- lxqtpanel.cpp |
55 |
- lxqtpanelapplication.cpp |
56 |
- lxqtpanellayout.cpp |
57 |
-diff --git panel/ilxqtpanel.h panel/ilxqtpanel.h |
58 |
-index e7b2844..71e4990 100644 |
59 |
---- panel/ilxqtpanel.h |
60 |
-+++ panel/ilxqtpanel.h |
61 |
-@@ -32,6 +32,7 @@ |
62 |
- #include "lxqtpanelglobals.h" |
63 |
- |
64 |
- class ILXQtPanelPlugin; |
65 |
-+class QWidget; |
66 |
- |
67 |
- /** |
68 |
- **/ |
69 |
-@@ -74,6 +75,17 @@ public: |
70 |
- **/ |
71 |
- virtual QRect calculatePopupWindowPos(const QPoint &absolutePos, const QSize &windowSize) const = 0; |
72 |
- virtual QRect calculatePopupWindowPos(const ILXQtPanelPlugin *plugin, const QSize &windowSize) const = 0; |
73 |
-+ |
74 |
-+ /*! |
75 |
-+ * \brief By calling this function plugin (or any other object) notifies the panel |
76 |
-+ * about showing a (standalone) window/menu -> panel needs this to avoid "hiding" in case any |
77 |
-+ * standalone window is shown. The widget must be shown later than this notification call because |
78 |
-+ * panel need to observe it's show/hide/close events. |
79 |
-+ * |
80 |
-+ * \param w the shown window |
81 |
-+ * |
82 |
-+ */ |
83 |
-+ virtual void willShowWindow(QWidget * w) = 0; |
84 |
- }; |
85 |
- |
86 |
- #endif // ILXQTPANEL_H |
87 |
-diff --git panel/ilxqtpanelplugin.h panel/ilxqtpanelplugin.h |
88 |
-index 1503923..3a09def 100644 |
89 |
---- panel/ilxqtpanelplugin.h |
90 |
-+++ panel/ilxqtpanelplugin.h |
91 |
-@@ -186,6 +186,16 @@ public: |
92 |
- return mPanel->calculatePopupWindowPos(this, windowSize); |
93 |
- } |
94 |
- |
95 |
-+ /*! |
96 |
-+ * \brief By calling this function plugin notifies the panel about showing a (standalone) window/menu. |
97 |
-+ * |
98 |
-+ * \param w the shown window |
99 |
-+ * |
100 |
-+ */ |
101 |
-+ inline void willShowWindow(QWidget * w) |
102 |
-+ { |
103 |
-+ mPanel->willShowWindow(w); |
104 |
-+ } |
105 |
- |
106 |
- virtual bool isSeparate() const { return false; } |
107 |
- virtual bool isExpandable() const { return false; } |
108 |
-diff --git panel/lxqtpanel.cpp panel/lxqtpanel.cpp |
109 |
-index 5159c15..d6b70ca 100644 |
110 |
---- panel/lxqtpanel.cpp |
111 |
-+++ panel/lxqtpanel.cpp |
112 |
-@@ -35,6 +35,7 @@ |
113 |
- #include "popupmenu.h" |
114 |
- #include "plugin.h" |
115 |
- #include "panelpluginsmodel.h" |
116 |
-+#include "windownotifier.h" |
117 |
- #include <LXQt/PluginInfo> |
118 |
- |
119 |
- #include <QScreen> |
120 |
-@@ -116,6 +117,7 @@ LXQtPanel::LXQtPanel(const QString &configGroup, LXQt::Settings *settings, QWidg |
121 |
- mSettings(settings), |
122 |
- mConfigGroup(configGroup), |
123 |
- mPlugins{nullptr}, |
124 |
-+ mStandaloneWindows{new WindowNotifier}, |
125 |
- mPanelSize(0), |
126 |
- mIconSize(0), |
127 |
- mLineCount(0), |
128 |
-@@ -175,6 +177,9 @@ LXQtPanel::LXQtPanel(const QString &configGroup, LXQt::Settings *settings, QWidg |
129 |
- connect(LXQt::Settings::globalSettings(), SIGNAL(settingsChanged()), this, SLOT(update())); |
130 |
- connect(lxqtApp, SIGNAL(themeChanged()), this, SLOT(realign())); |
131 |
- |
132 |
-+ connect(mStandaloneWindows.data(), &WindowNotifier::firstShown, this, &LXQtPanel::showPanel); |
133 |
-+ connect(mStandaloneWindows.data(), &WindowNotifier::lastHidden, this, &LXQtPanel::hidePanel); |
134 |
-+ |
135 |
- readSettings(); |
136 |
- // the old position might be on a visible screen |
137 |
- ensureVisible(); |
138 |
-@@ -589,6 +594,7 @@ void LXQtPanel::showConfigDialog() |
139 |
- mConfigDialog = new ConfigPanelDialog(this, nullptr /*make it top level window*/); |
140 |
- |
141 |
- mConfigDialog->showConfigPanelPage(); |
142 |
-+ mStandaloneWindows->observeWindow(mConfigDialog.data()); |
143 |
- mConfigDialog->show(); |
144 |
- mConfigDialog->raise(); |
145 |
- mConfigDialog->activateWindow(); |
146 |
-@@ -608,6 +614,7 @@ void LXQtPanel::showAddPluginDialog() |
147 |
- mConfigDialog = new ConfigPanelDialog(this, nullptr /*make it top level window*/); |
148 |
- |
149 |
- mConfigDialog->showConfigPluginsPage(); |
150 |
-+ mStandaloneWindows->observeWindow(mConfigDialog.data()); |
151 |
- mConfigDialog->show(); |
152 |
- mConfigDialog->raise(); |
153 |
- mConfigDialog->activateWindow(); |
154 |
-@@ -967,6 +974,7 @@ void LXQtPanel::showPopupMenu(Plugin *plugin) |
155 |
- * of QDesktopWidget::availableGeometry) |
156 |
- */ |
157 |
- menu->setGeometry(calculatePopupWindowPos(QCursor::pos(), menu->sizeHint())); |
158 |
-+ willShowWindow(menu); |
159 |
- menu->show(); |
160 |
- } |
161 |
- |
162 |
-@@ -1043,6 +1051,14 @@ QRect LXQtPanel::calculatePopupWindowPos(const ILXQtPanelPlugin *plugin, const Q |
163 |
- /************************************************ |
164 |
- |
165 |
- ************************************************/ |
166 |
-+void LXQtPanel::willShowWindow(QWidget * w) |
167 |
-+{ |
168 |
-+ mStandaloneWindows->observeWindow(w); |
169 |
-+} |
170 |
-+ |
171 |
-+/************************************************ |
172 |
-+ |
173 |
-+ ************************************************/ |
174 |
- QString LXQtPanel::qssPosition() const |
175 |
- { |
176 |
- return positionToStr(position()); |
177 |
-@@ -1107,20 +1123,17 @@ void LXQtPanel::showPanel() |
178 |
- |
179 |
- void LXQtPanel::hidePanel() |
180 |
- { |
181 |
-- if (mHidable && !mHidden) |
182 |
-+ if (mHidable && !mHidden |
183 |
-+ && !geometry().contains(QCursor::pos()) |
184 |
-+ && !mStandaloneWindows->isAnyWindowShown() |
185 |
-+ ) |
186 |
- mHideTimer.start(); |
187 |
- } |
188 |
- |
189 |
- void LXQtPanel::hidePanelWork() |
190 |
- { |
191 |
-- if (mHidable && !mHidden && !geometry().contains(QCursor::pos())) |
192 |
-- { |
193 |
-- mHidden = true; |
194 |
-- setPanelGeometry(); |
195 |
-- } else |
196 |
-- { |
197 |
-- mHideTimer.start(); |
198 |
-- } |
199 |
-+ mHidden = true; |
200 |
-+ setPanelGeometry(); |
201 |
- } |
202 |
- |
203 |
- void LXQtPanel::setHidable(bool hidable, bool save) |
204 |
-@@ -1128,7 +1141,7 @@ void LXQtPanel::setHidable(bool hidable, bool save) |
205 |
- if (mHidable == hidable) |
206 |
- return; |
207 |
- |
208 |
-- mHidable = mHidden = hidable; |
209 |
-+ mHidable = hidable; |
210 |
- |
211 |
- if (save) |
212 |
- saveSettings(true); |
213 |
-diff --git panel/lxqtpanel.h panel/lxqtpanel.h |
214 |
-index 8ff4b8c..990063f 100644 |
215 |
---- panel/lxqtpanel.h |
216 |
-+++ panel/lxqtpanel.h |
217 |
-@@ -48,6 +48,7 @@ class PluginInfo; |
218 |
- class LXQtPanelLayout; |
219 |
- class ConfigPanelDialog; |
220 |
- class PanelPluginsModel; |
221 |
-+class WindowNotifier; |
222 |
- |
223 |
- /*! \brief The LXQtPanel class provides a single lxqt-panel. |
224 |
- */ |
225 |
-@@ -80,11 +81,12 @@ public: |
226 |
- void showPopupMenu(Plugin *plugin = 0); |
227 |
- |
228 |
- // ILXQtPanel ......................... |
229 |
-- ILXQtPanel::Position position() const { return mPosition; } |
230 |
-- QRect globalGometry() const; |
231 |
-+ ILXQtPanel::Position position() const override { return mPosition; } |
232 |
-+ QRect globalGometry() const override; |
233 |
- Plugin *findPlugin(const ILXQtPanelPlugin *iPlugin) const; |
234 |
-- QRect calculatePopupWindowPos(QPoint const & absolutePos, QSize const & windowSize) const; |
235 |
-- QRect calculatePopupWindowPos(const ILXQtPanelPlugin *plugin, const QSize &windowSize) const; |
236 |
-+ QRect calculatePopupWindowPos(QPoint const & absolutePos, QSize const & windowSize) const override; |
237 |
-+ QRect calculatePopupWindowPos(const ILXQtPanelPlugin *plugin, const QSize &windowSize) const override; |
238 |
-+ void willShowWindow(QWidget * w) override; |
239 |
- |
240 |
- // For QSS properties .................. |
241 |
- QString qssPosition() const; |
242 |
-@@ -95,8 +97,8 @@ public: |
243 |
- |
244 |
- // Settings |
245 |
- int panelSize() const { return mPanelSize; } |
246 |
-- int iconSize() const { return mIconSize; } |
247 |
-- int lineCount() const { return mLineCount; } |
248 |
-+ int iconSize() const override { return mIconSize; } |
249 |
-+ int lineCount() const override { return mLineCount; } |
250 |
- int length() const { return mLength; } |
251 |
- bool lengthInPercents() const { return mLengthInPercents; } |
252 |
- LXQtPanel::Alignment alignment() const { return mAlignment; } |
253 |
-@@ -138,8 +140,8 @@ signals: |
254 |
- void pluginRemoved(); |
255 |
- |
256 |
- protected: |
257 |
-- bool event(QEvent *event); |
258 |
-- void showEvent(QShowEvent *event); |
259 |
-+ bool event(QEvent *event) override; |
260 |
-+ void showEvent(QShowEvent *event) override; |
261 |
- |
262 |
- public slots: |
263 |
- void showConfigDialog(); |
264 |
-@@ -156,6 +158,7 @@ private: |
265 |
- QFrame *LXQtPanelWidget; |
266 |
- QString mConfigGroup; |
267 |
- QScopedPointer<PanelPluginsModel> mPlugins; |
268 |
-+ QScopedPointer<WindowNotifier> mStandaloneWindows; //!< object for storing info if some standalone window is shown (for preventing hide) |
269 |
- |
270 |
- int findAvailableScreen(LXQtPanel::Position position); |
271 |
- void updateWmStrut(); |
272 |
-diff --git panel/plugin.cpp panel/plugin.cpp |
273 |
-index a4acc78..be23a8e 100644 |
274 |
---- panel/plugin.cpp |
275 |
-+++ panel/plugin.cpp |
276 |
-@@ -477,6 +477,7 @@ void Plugin::showConfigureDialog() |
277 |
- if (!dialog) |
278 |
- return; |
279 |
- |
280 |
-+ mPanel->willShowWindow(dialog); |
281 |
- dialog->show(); |
282 |
- dialog->raise(); |
283 |
- dialog->activateWindow(); |
284 |
-diff --git panel/windownotifier.cpp panel/windownotifier.cpp |
285 |
-new file mode 100644 |
286 |
-index 0000000..0b41057 |
287 |
---- /dev/null |
288 |
-+++ panel/windownotifier.cpp |
289 |
-@@ -0,0 +1,65 @@ |
290 |
-+/* BEGIN_COMMON_COPYRIGHT_HEADER |
291 |
-+ * (c)LGPL2+ |
292 |
-+ * |
293 |
-+ * LXQt - a lightweight, Qt based, desktop toolset |
294 |
-+ * http://lxqt.org |
295 |
-+ * |
296 |
-+ * Copyright: 2015 LXQt team |
297 |
-+ * Authors: |
298 |
-+ * Palo Kisa <palo.kisa@×××××.com> |
299 |
-+ * |
300 |
-+ * This program or library is free software; you can redistribute it |
301 |
-+ * and/or modify it under the terms of the GNU Lesser General Public |
302 |
-+ * License as published by the Free Software Foundation; either |
303 |
-+ * version 2.1 of the License, or (at your option) any later version. |
304 |
-+ * |
305 |
-+ * This library is distributed in the hope that it will be useful, |
306 |
-+ * but WITHOUT ANY WARRANTY; without even the implied warranty of |
307 |
-+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
308 |
-+ * Lesser General Public License for more details. |
309 |
-+ |
310 |
-+ * You should have received a copy of the GNU Lesser General |
311 |
-+ * Public License along with this library; if not, write to the |
312 |
-+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, |
313 |
-+ * Boston, MA 02110-1301 USA |
314 |
-+ * |
315 |
-+ * END_COMMON_COPYRIGHT_HEADER */ |
316 |
-+ |
317 |
-+#include "windownotifier.h" |
318 |
-+#include <QWidget> |
319 |
-+#include <QEvent> |
320 |
-+ |
321 |
-+void WindowNotifier::observeWindow(QWidget * w) |
322 |
-+{ |
323 |
-+ //installing the same filter object multiple times doesn't harm |
324 |
-+ w->installEventFilter(this); |
325 |
-+} |
326 |
-+ |
327 |
-+ |
328 |
-+bool WindowNotifier::eventFilter(QObject * watched, QEvent * event) |
329 |
-+{ |
330 |
-+ QWidget * widget = qobject_cast<QWidget *>(watched); //we're observing only QWidgetw |
331 |
-+ auto it = std::lower_bound(mShownWindows.begin(), mShownWindows.end(), widget); |
332 |
-+ switch (event->type()) |
333 |
-+ { |
334 |
-+ case QEvent::Close: |
335 |
-+ watched->removeEventFilter(this); |
336 |
-+ //no break |
337 |
-+ case QEvent::Hide: |
338 |
-+ Q_ASSERT(mShownWindows.end() != it); |
339 |
-+ mShownWindows.erase(it); |
340 |
-+ if (mShownWindows.isEmpty()) |
341 |
-+ emit lastHidden(); |
342 |
-+ break; |
343 |
-+ case QEvent::Show: |
344 |
-+ { |
345 |
-+ const bool first_shown = mShownWindows.isEmpty(); |
346 |
-+ mShownWindows.insert(it, widget); //we keep the mShownWindows sorted |
347 |
-+ if (first_shown) |
348 |
-+ emit firstShown(); |
349 |
-+ } |
350 |
-+ default: |
351 |
-+ break; |
352 |
-+ } |
353 |
-+ return false; |
354 |
-+} |
355 |
-diff --git panel/windownotifier.h panel/windownotifier.h |
356 |
-new file mode 100644 |
357 |
-index 0000000..53f2f3f |
358 |
---- /dev/null |
359 |
-+++ panel/windownotifier.h |
360 |
-@@ -0,0 +1,53 @@ |
361 |
-+/* BEGIN_COMMON_COPYRIGHT_HEADER |
362 |
-+ * (c)LGPL2+ |
363 |
-+ * |
364 |
-+ * LXQt - a lightweight, Qt based, desktop toolset |
365 |
-+ * http://lxqt.org |
366 |
-+ * |
367 |
-+ * Copyright: 2015 LXQt team |
368 |
-+ * Authors: |
369 |
-+ * Palo Kisa <palo.kisa@×××××.com> |
370 |
-+ * |
371 |
-+ * This program or library is free software; you can redistribute it |
372 |
-+ * and/or modify it under the terms of the GNU Lesser General Public |
373 |
-+ * License as published by the Free Software Foundation; either |
374 |
-+ * version 2.1 of the License, or (at your option) any later version. |
375 |
-+ * |
376 |
-+ * This library is distributed in the hope that it will be useful, |
377 |
-+ * but WITHOUT ANY WARRANTY; without even the implied warranty of |
378 |
-+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
379 |
-+ * Lesser General Public License for more details. |
380 |
-+ |
381 |
-+ * You should have received a copy of the GNU Lesser General |
382 |
-+ * Public License along with this library; if not, write to the |
383 |
-+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, |
384 |
-+ * Boston, MA 02110-1301 USA |
385 |
-+ * |
386 |
-+ * END_COMMON_COPYRIGHT_HEADER */ |
387 |
-+ |
388 |
-+#if !defined(WINDOWNOTIFIER_H) |
389 |
-+#define WINDOWNOTIFIER_H |
390 |
-+ |
391 |
-+#include <QObject> |
392 |
-+ |
393 |
-+class QWidget; |
394 |
-+ |
395 |
-+class WindowNotifier : public QObject |
396 |
-+{ |
397 |
-+ Q_OBJECT |
398 |
-+public: |
399 |
-+ using QObject::QObject; |
400 |
-+ |
401 |
-+ void observeWindow(QWidget * w); |
402 |
-+ inline bool isAnyWindowShown() const { return !mShownWindows.isEmpty(); } |
403 |
-+ |
404 |
-+ virtual bool eventFilter(QObject * watched, QEvent * event) override; |
405 |
-+signals: |
406 |
-+ void lastHidden(); |
407 |
-+ void firstShown(); |
408 |
-+ |
409 |
-+private: |
410 |
-+ QList<QWidget *> mShownWindows; //!< known shown windows (sorted) |
411 |
-+}; |
412 |
-+ |
413 |
-+#endif |
414 |
-diff --git plugin-clock/lxqtclock.cpp plugin-clock/lxqtclock.cpp |
415 |
-index 79c2c17..d4603de 100644 |
416 |
---- plugin-clock/lxqtclock.cpp |
417 |
-+++ plugin-clock/lxqtclock.cpp |
418 |
-@@ -286,6 +286,7 @@ void LXQtClock::activated(ActivationReason reason) |
419 |
- { |
420 |
- QRect pos = calculatePopupWindowPos(mCalendarPopup->size()); |
421 |
- mCalendarPopup->move(pos.topLeft()); |
422 |
-+ willShowWindow(mCalendarPopup); |
423 |
- mCalendarPopup->show(); |
424 |
- } |
425 |
- else |
426 |
-diff --git plugin-directorymenu/directorymenu.cpp plugin-directorymenu/directorymenu.cpp |
427 |
-index 8c5ec28..e332e05 100644 |
428 |
---- plugin-directorymenu/directorymenu.cpp |
429 |
-+++ plugin-directorymenu/directorymenu.cpp |
430 |
-@@ -58,11 +58,11 @@ DirectoryMenu::DirectoryMenu(const ILXQtPanelPluginStartupInfo &startupInfo) : |
431 |
- |
432 |
- DirectoryMenu::~DirectoryMenu() |
433 |
- { |
434 |
-- if(mMenu) |
435 |
-- { |
436 |
-- delete mMenu; |
437 |
-- mMenu = 0; |
438 |
-- } |
439 |
-+ if(mMenu) |
440 |
-+ { |
441 |
-+ delete mMenu; |
442 |
-+ mMenu = 0; |
443 |
-+ } |
444 |
- } |
445 |
- |
446 |
- void DirectoryMenu::showMenu() |
447 |
-@@ -102,67 +102,67 @@ void DirectoryMenu::showMenu() |
448 |
- break; |
449 |
- } |
450 |
- |
451 |
-+ willShowWindow(mMenu); |
452 |
- // Just using Qt`s activateWindow() won't work on some WMs like Kwin. |
453 |
- // Solution is to execute menu 1ms later using timer |
454 |
-- mButton.activateWindow(); |
455 |
-- mMenu->exec(QPoint(x, y)); |
456 |
-+ mMenu->popup(calculatePopupWindowPos(mMenu->sizeHint()).topLeft()); |
457 |
- } |
458 |
- |
459 |
- void DirectoryMenu::buildMenu(const QString& path) |
460 |
- { |
461 |
-- if(mMenu) |
462 |
-- { |
463 |
-- delete mMenu; |
464 |
-- mMenu = 0; |
465 |
-- } |
466 |
-+ if(mMenu) |
467 |
-+ { |
468 |
-+ delete mMenu; |
469 |
-+ mMenu = 0; |
470 |
-+ } |
471 |
- |
472 |
-- mPathStrings.clear(); |
473 |
-+ mPathStrings.clear(); |
474 |
- |
475 |
-- mMenu = new QMenu(); |
476 |
-+ mMenu = new QMenu(); |
477 |
- |
478 |
-- addActions(mMenu, path); |
479 |
-+ addActions(mMenu, path); |
480 |
- } |
481 |
- |
482 |
- void DirectoryMenu::openDirectory(const QString& path) |
483 |
- { |
484 |
-- QDesktopServices::openUrl(QUrl("file://" + QDir::toNativeSeparators(path))); |
485 |
-+ QDesktopServices::openUrl(QUrl("file://" + QDir::toNativeSeparators(path))); |
486 |
- } |
487 |
- |
488 |
- void DirectoryMenu::addMenu(QString path) |
489 |
- { |
490 |
-- QSignalMapper* sender = (QSignalMapper* )QObject::sender(); |
491 |
-- QMenu* parentMenu = (QMenu*) sender->mapping(path); |
492 |
-+ QSignalMapper* sender = (QSignalMapper* )QObject::sender(); |
493 |
-+ QMenu* parentMenu = (QMenu*) sender->mapping(path); |
494 |
- |
495 |
-- if(parentMenu->isEmpty()) |
496 |
-- { |
497 |
-- addActions(parentMenu, path); |
498 |
-- } |
499 |
-+ if(parentMenu->isEmpty()) |
500 |
-+ { |
501 |
-+ addActions(parentMenu, path); |
502 |
-+ } |
503 |
- } |
504 |
- |
505 |
- void DirectoryMenu::addActions(QMenu* menu, const QString& path) |
506 |
- { |
507 |
-- mPathStrings.push_back(path); |
508 |
-+ mPathStrings.push_back(path); |
509 |
- |
510 |
-- QAction* openDirectoryAction = menu->addAction(XdgIcon::fromTheme("folder"), tr("Open")); |
511 |
-- connect(openDirectoryAction, SIGNAL(triggered()), mOpenDirectorySignalMapper, SLOT(map())); |
512 |
-- mOpenDirectorySignalMapper->setMapping(openDirectoryAction, mPathStrings.back()); |
513 |
-+ QAction* openDirectoryAction = menu->addAction(XdgIcon::fromTheme("folder"), tr("Open")); |
514 |
-+ connect(openDirectoryAction, SIGNAL(triggered()), mOpenDirectorySignalMapper, SLOT(map())); |
515 |
-+ mOpenDirectorySignalMapper->setMapping(openDirectoryAction, mPathStrings.back()); |
516 |
- |
517 |
-- menu->addSeparator(); |
518 |
-+ menu->addSeparator(); |
519 |
- |
520 |
-- QDir dir(path); |
521 |
-- QFileInfoList list = dir.entryInfoList(); |
522 |
-+ QDir dir(path); |
523 |
-+ QFileInfoList list = dir.entryInfoList(); |
524 |
- |
525 |
-- foreach (const QFileInfo& entry, list) |
526 |
-+ foreach (const QFileInfo& entry, list) |
527 |
- { |
528 |
-- if(entry.isDir() && !entry.isHidden()) |
529 |
-- { |
530 |
-- mPathStrings.push_back(entry.fileName()); |
531 |
-+ if(entry.isDir() && !entry.isHidden()) |
532 |
-+ { |
533 |
-+ mPathStrings.push_back(entry.fileName()); |
534 |
- |
535 |
-- QMenu* subMenu = menu->addMenu(XdgIcon::fromTheme("folder"), mPathStrings.back()); |
536 |
-+ QMenu* subMenu = menu->addMenu(XdgIcon::fromTheme("folder"), mPathStrings.back()); |
537 |
- |
538 |
-- connect(subMenu, SIGNAL(aboutToShow()), mMenuSignalMapper, SLOT(map())); |
539 |
-- mMenuSignalMapper->setMapping(subMenu, entry.absoluteFilePath()); |
540 |
-- } |
541 |
-+ connect(subMenu, SIGNAL(aboutToShow()), mMenuSignalMapper, SLOT(map())); |
542 |
-+ mMenuSignalMapper->setMapping(subMenu, entry.absoluteFilePath()); |
543 |
-+ } |
544 |
- } |
545 |
- } |
546 |
- |
547 |
-diff --git plugin-dom/domplugin.cpp plugin-dom/domplugin.cpp |
548 |
-index ffd05c6..0988a2b 100644 |
549 |
---- plugin-dom/domplugin.cpp |
550 |
-+++ plugin-dom/domplugin.cpp |
551 |
-@@ -51,6 +51,7 @@ void DomPlugin::showDialog() |
552 |
- dialog->setAttribute(Qt::WA_DeleteOnClose); |
553 |
- } |
554 |
- |
555 |
-+ willShowWindow(dialog); |
556 |
- dialog->show(); |
557 |
- dialog->activateWindow(); |
558 |
- } |
559 |
-diff --git plugin-mainmenu/lxqtmainmenu.cpp plugin-mainmenu/lxqtmainmenu.cpp |
560 |
-index 9673a4f..b9ff6e4 100644 |
561 |
---- plugin-mainmenu/lxqtmainmenu.cpp |
562 |
-+++ plugin-mainmenu/lxqtmainmenu.cpp |
563 |
-@@ -130,6 +130,7 @@ void LXQtMainMenu::showMenu() |
564 |
- if (!mMenu) |
565 |
- return; |
566 |
- |
567 |
-+ willShowWindow(mMenu); |
568 |
- // Just using Qt`s activateWindow() won't work on some WMs like Kwin. |
569 |
- // Solution is to execute menu 1ms later using timer |
570 |
- mMenu->popup(calculatePopupWindowPos(mMenu->sizeHint()).topLeft()); |
571 |
-@@ -227,8 +228,6 @@ void LXQtMainMenu::buildMenu() |
572 |
- menu->installEventFilter(this); |
573 |
- connect(menu, &QMenu::aboutToHide, &mHideTimer, static_cast<void (QTimer::*)()>(&QTimer::start)); |
574 |
- connect(menu, &QMenu::aboutToShow, &mHideTimer, &QTimer::stop); |
575 |
-- // panel notification (needed in case of auto-hide) |
576 |
-- connect(menu, &QMenu::aboutToHide, dynamic_cast<LXQtPanel *>(panel()), &LXQtPanel::hidePanel); |
577 |
- |
578 |
- QMenu *oldMenu = mMenu; |
579 |
- mMenu = menu; |
580 |
-diff --git plugin-mount/popup.cpp plugin-mount/popup.cpp |
581 |
-index 1c3e7c1..7993681 100644 |
582 |
---- plugin-mount/popup.cpp |
583 |
-+++ plugin-mount/popup.cpp |
584 |
-@@ -90,7 +90,12 @@ Popup::Popup(ILXQtPanelPlugin * plugin, QWidget* parent): |
585 |
- |
586 |
- void Popup::showHide() |
587 |
- { |
588 |
-- setVisible(isHidden()); |
589 |
-+ if (isHidden()) |
590 |
-+ { |
591 |
-+ mPlugin->willShowWindow(this); |
592 |
-+ show(); |
593 |
-+ } else |
594 |
-+ close(); |
595 |
- } |
596 |
- |
597 |
- void Popup::onDeviceAdded(QString const & udi) |
598 |
-diff --git plugin-statusnotifier/statusnotifierbutton.cpp plugin-statusnotifier/statusnotifierbutton.cpp |
599 |
-index fb124c6..71cf78f 100644 |
600 |
---- plugin-statusnotifier/statusnotifierbutton.cpp |
601 |
-+++ plugin-statusnotifier/statusnotifierbutton.cpp |
602 |
-@@ -249,8 +249,10 @@ void StatusNotifierButton::mouseReleaseEvent(QMouseEvent *event) |
603 |
- else if (Qt::RightButton == event->button()) |
604 |
- { |
605 |
- if (mMenu) |
606 |
-- mMenu->popup(QCursor::pos()); |
607 |
-- else |
608 |
-+ { |
609 |
-+ mPlugin->willShowWindow(mMenu); |
610 |
-+ mMenu->popup(mPlugin->calculatePopupWindowPos(mMenu->sizeHint()).topLeft()); |
611 |
-+ } else |
612 |
- interface->ContextMenu(QCursor::pos().x(), QCursor::pos().y()); |
613 |
- } |
614 |
- |
615 |
-diff --git plugin-taskbar/lxqttaskgroup.cpp plugin-taskbar/lxqttaskgroup.cpp |
616 |
-index 6828216..79e27f5 100644 |
617 |
---- plugin-taskbar/lxqttaskgroup.cpp |
618 |
-+++ plugin-taskbar/lxqttaskgroup.cpp |
619 |
-@@ -84,6 +84,7 @@ void LXQtTaskGroup::contextMenuEvent(QContextMenuEvent *event) |
620 |
- mPreventPopup = false; |
621 |
- }); |
622 |
- menu->setGeometry(mPlugin->panel()->calculatePopupWindowPos(mapToGlobal(event->pos()), menu->sizeHint())); |
623 |
-+ mPlugin->willShowWindow(menu); |
624 |
- menu->show(); |
625 |
- } |
626 |
- |
627 |
-@@ -418,6 +419,7 @@ void LXQtTaskGroup::setPopupVisible(bool visible, bool fast) |
628 |
- recalculateFramePosition(); |
629 |
- } |
630 |
- |
631 |
-+ mPlugin->willShowWindow(mPopup); |
632 |
- mPopup->show(); |
633 |
- emit popupShown(this); |
634 |
- } |
635 |
-diff --git plugin-volume/volumebutton.cpp plugin-volume/volumebutton.cpp |
636 |
-index a738a1a..98b3f10 100644 |
637 |
---- plugin-volume/volumebutton.cpp |
638 |
-+++ plugin-volume/volumebutton.cpp |
639 |
-@@ -133,6 +133,7 @@ void VolumeButton::showVolumeSlider() |
640 |
- m_volumePopup->updateGeometry(); |
641 |
- m_volumePopup->adjustSize(); |
642 |
- QRect pos = mPlugin->calculatePopupWindowPos(m_volumePopup->size()); |
643 |
-+ mPlugin->willShowWindow(m_volumePopup); |
644 |
- m_volumePopup->openAt(pos.topLeft(), Qt::TopLeftCorner); |
645 |
- m_volumePopup->activateWindow(); |
646 |
- } |
647 |
-diff --git plugin-worldclock/lxqtworldclock.cpp plugin-worldclock/lxqtworldclock.cpp |
648 |
-index 7386049..8fa795d 100644 |
649 |
---- plugin-worldclock/lxqtworldclock.cpp |
650 |
-+++ plugin-worldclock/lxqtworldclock.cpp |
651 |
-@@ -356,6 +356,7 @@ void LXQtWorldClock::activated(ActivationReason reason) |
652 |
- mPopup->adjustSize(); |
653 |
- mPopup->setGeometry(calculatePopupWindowPos(mPopup->size())); |
654 |
- |
655 |
-+ willShowWindow(mPopup); |
656 |
- mPopup->show(); |
657 |
- } |
658 |
- else |
659 |
|
660 |
diff --git a/lxqt-base/lxqt-panel/lxqt-panel-0.10.0-r1.ebuild b/lxqt-base/lxqt-panel/lxqt-panel-0.10.0-r1.ebuild |
661 |
index b342e0bc9d2..3ae6d34161e 100644 |
662 |
--- a/lxqt-base/lxqt-panel/lxqt-panel-0.10.0-r1.ebuild |
663 |
+++ b/lxqt-base/lxqt-panel/lxqt-panel-0.10.0-r1.ebuild |
664 |
@@ -1,4 +1,4 @@ |
665 |
-# Copyright 1999-2016 Gentoo Foundation |
666 |
+# Copyright 1999-2017 Gentoo Foundation |
667 |
# Distributed under the terms of the GNU General Public License v2 |
668 |
|
669 |
EAPI=5 |
670 |
@@ -11,7 +11,8 @@ if [[ ${PV} = *9999* ]]; then |
671 |
inherit git-r3 |
672 |
EGIT_REPO_URI="git://git.lxde.org/git/lxde/${PN}.git" |
673 |
else |
674 |
- SRC_URI="https://downloads.lxqt.org/lxqt/${PV}/${P}.tar.xz" |
675 |
+ SRC_URI="https://downloads.lxqt.org/lxqt/${PV}/${P}.tar.xz |
676 |
+ https://dev.gentoo.org/~chiitoo/distfiles/lxqt-panel-0.10.0-autohide-patch.tar.bz2" |
677 |
KEYWORDS="~amd64 ~arm ~arm64 ~x86" |
678 |
fi |
679 |
|
680 |
@@ -55,7 +56,7 @@ RDEPEND="${CDEPEND} |
681 |
dev-qt/qtsvg:5 |
682 |
>=lxde-base/lxmenu-data-0.1.2" |
683 |
|
684 |
-PATCHES=( "${FILESDIR}/${P}-autohide.patch" ) |
685 |
+PATCHES=( "${WORKDIR}/${P}-autohide.patch" ) |
686 |
|
687 |
src_configure() { |
688 |
local mycmakeargs i y |