Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DropDown menu is a window itself #36

Open
Arnaudv6 opened this issue May 1, 2016 · 6 comments
Open

DropDown menu is a window itself #36

Arnaudv6 opened this issue May 1, 2016 · 6 comments

Comments

@Arnaudv6
Copy link

Arnaudv6 commented May 1, 2016

...it's in the title, when I left-click on tray icon,
menu shows, and a new button appears for its window in my taskbar (fbpanel).

This is not the expected behavior I expect, and proper window properties should be set.
With regards
Arnaudv6

@palinek
Copy link
Collaborator

palinek commented Sep 19, 2016

Do we want to make it a pure menu?

With something like this:

diff --git a/src/qlippersystray.cpp b/src/qlippersystray.cpp
index 52ea360..430911c 100644
--- a/src/qlippersystray.cpp
+++ b/src/qlippersystray.cpp
@@ -51,14 +51,6 @@ QlipperSystray::QlipperSystray(QObject *parent)
     m_shortcutMenu->setModel(m_model);
     m_shortcutMenu->setWindowTitle(tr("Qlipper - a clipboard history applet"));

-    // Windows API does not handle well some combinations of flags in custom widgets.
-#ifndef Q_OS_WIN32
-    // This flag is mandatory to get focus when user activates global_key.
-    // OK, window gets a decoration but it works. Menu is displayed without the
-    // the decoration if is the systray icon clicked.
-    m_shortcutMenu->setWindowFlags(Qt::Dialog | Qt::CustomizeWindowHint);
-#endif
-
     connect(m_shortcutMenu, SIGNAL(triggered(QModelIndex)), m_model, SLOT(indexTriggered(QModelIndex)));
     connect(m_shortcutMenu, SIGNAL(triggered(QModelIndex)), m_shortcutMenu, SLOT(close()));

... it is done. It works on linux. This change doesn't change anything for windows (the #ifdef). But I can't test with MacOS.

@Arnaudv6
Copy link
Author

Fixes it for me: thanks palinek !
(using linux here), can't help with OSX or Windows.

@Arnaudv6
Copy link
Author

Arnaudv6 commented Nov 3, 2016

Not closing yet for it is not mainlined...

@palinek
Copy link
Collaborator

palinek commented Nov 3, 2016

I'm not going to make this change into master, because setting the flags seems to be intentional there and I don't know the background...

@pvanek ?

@martinrotter
Copy link
Contributor

@Arnaudv6 What exact Qt version do you use?

@Arnaudv6
Copy link
Author

@martinrotter 5.7.0
...why?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants