Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. QSystemTrayIcon Ubuntu 15.10
QtWS25 Last Chance

QSystemTrayIcon Ubuntu 15.10

Scheduled Pinned Locked Moved Solved General and Desktop
qsystemtrayiconubuntu 15.10
12 Posts 2 Posters 4.1k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • P Offline
    P Offline
    Phenom
    wrote on last edited by
    #1

    Hello,
    I'm developing for the Open Source cross-platform RetroShare.
    With new version of Ubuntu (with Unity) 15.10 and compiled with Qt 4.8.6, the QSystemTrayIcon doesn't work properly.
    We have multi icons depends the service notification. When we trigger .show() for service icon, a new main icon appears (with its ContextMenu). And when we trigger .hide() the new icon stay.
    So, to test it, I've wrote a lite application with only SystrayIcon.
    I've tested it with different version of Qt5. Only 5.5.1 works, but with only one icon. When I want to show the second directly, no one appears. If I don't show second, the first take its own and the second's context menu. When I trigger second.show() nothing happens.
    showMessage() is working well (not msecs) with one or two icons.
    contextmenu only works with one icon shown.
    toolTip doesn't work.
    activated signal isn't triggered.

    What can I do to get icons (or something else) in systray?
    I recall that it's a cross-platform application (linux, win and MacOs).

    Thanks.

    1 Reply Last reply
    0
    • SGaistS Offline
      SGaistS Offline
      SGaist
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi and welcome to devnet,

      You should try to build again your application using your Distribution Qt 5 to see if you are still experiencing this.

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      0
      • P Offline
        P Offline
        Phenom
        wrote on last edited by Phenom
        #3

        Hi,
        Thanks.

        I reinstall fresh ubuntu 15.10 (in VirtualBox) with its own qt5.4.2.
        Now main icon appears two time (with same context menu).
        You can find Test Project here.

        1 Reply Last reply
        0
        • SGaistS Offline
          SGaistS Offline
          SGaist
          Lifetime Qt Champion
          wrote on last edited by
          #4

          How many icons do you want ?

          Interested in AI ? www.idiap.ch
          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

          1 Reply Last reply
          0
          • P Offline
            P Offline
            Phenom
            wrote on last edited by
            #5

            We've got near 8 services, and we can add plugin too.
            But restrict the number is not the solution...

            1 Reply Last reply
            0
            • SGaistS Offline
              SGaistS Offline
              SGaist
              Lifetime Qt Champion
              wrote on last edited by
              #6

              While I do agree that a number restriction is not a solution, having a software that adds 8 or more system tray icons is not a good design sign. Personally I would find it strange that I have to check such an amount of icons for status or other things for one software.

              Note that Ubuntu's custom tray management might also add limitations to what you can do.

              Interested in AI ? www.idiap.ch
              Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

              1 Reply Last reply
              0
              • P Offline
                P Offline
                Phenom
                wrote on last edited by Phenom
                #7

                Well we don't have really 8 icons at the same time. But one for each service (mail, lobby, forum, channel, transfer, ...)
                The problem is, now we have only one copied x times...
                I invite you to test this application.

                PS: And if you've got time, maybe (surely) you can improve the code. ;)

                1 Reply Last reply
                0
                • SGaistS Offline
                  SGaistS Offline
                  SGaist
                  Lifetime Qt Champion
                  wrote on last edited by
                  #8

                  I don't have a 15.10 at hand but on OS X I get both tray icons (once I uncomment the call to show) and each has its own menu.

                  Interested in AI ? www.idiap.ch
                  Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                  1 Reply Last reply
                  0
                  • P Offline
                    P Offline
                    Phenom
                    wrote on last edited by
                    #9

                    Yes, it's only on Ubuntu 15.10.
                    You are on OS X? Good, we need developer on it ;)
                    In fact, other subject, we can't link main library (application) to plugins.
                    If you can have a look to RetroShare.

                    1 Reply Last reply
                    0
                    • SGaistS Offline
                      SGaistS Offline
                      SGaist
                      Lifetime Qt Champion
                      wrote on last edited by
                      #10

                      Then you should contact the Ubuntu folks about that matter.

                      Who "we" ? ;)

                      Link application to plugin ? That doesn't sound right.

                      Interested in AI ? www.idiap.ch
                      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                      1 Reply Last reply
                      0
                      • P Offline
                        P Offline
                        Phenom
                        wrote on last edited by Phenom
                        #11

                        Happy new Year,
                        "We" are the RetroShare devs.
                        In fact, RS have plugin using some of its data. For Windows, we have to export symbol for compilation:
                        https://github.com/RetroShare/RetroShare/blob/master/retroshare-gui/src/retroshare-gui.pro#L186
                        In Linux it seems to do it automatically.
                        But on OSX I've got error at end of compilation with:
                        ld: symbol(s) not found for architecture x86_64.
                        All of them are defined from retroshare-gui (main application).

                        PS: Were can I found a link to talk with Ubuntu Qt Folks?

                        P 1 Reply Last reply
                        0
                        • P Phenom

                          Happy new Year,
                          "We" are the RetroShare devs.
                          In fact, RS have plugin using some of its data. For Windows, we have to export symbol for compilation:
                          https://github.com/RetroShare/RetroShare/blob/master/retroshare-gui/src/retroshare-gui.pro#L186
                          In Linux it seems to do it automatically.
                          But on OSX I've got error at end of compilation with:
                          ld: symbol(s) not found for architecture x86_64.
                          All of them are defined from retroshare-gui (main application).

                          PS: Were can I found a link to talk with Ubuntu Qt Folks?

                          P Offline
                          P Offline
                          Phenom
                          wrote on last edited by
                          #12

                          OK, we found how to use -bundle...
                          https://developer.apple.com/library/mac/documentation/Porting/Conceptual/PortingUnix/compiling/compiling.html

                          1 Reply Last reply
                          0

                          • Login

                          • Login or register to search.
                          • First post
                            Last post
                          0
                          • Categories
                          • Recent
                          • Tags
                          • Popular
                          • Users
                          • Groups
                          • Search
                          • Get Qt Extensions
                          • Unsolved