[OS X] adaptation(s) to platform limitations

Review Request #126369 - Created Dec. 15, 2015 and submitted

Information
René J.V. Bertin
knotifications
Reviewers
kde-mac, kdeframeworks

OS X has a number of limitations in features used by KNotifications, notably concerning the status notifier item (aka system tray icon).

This RR will likely evolve to address multiple limitations (at least also the NeedsAttention state); at the moment it only proposes an emulation of QMenu::addSection.

QMenu::addSection works by adding a QAction with a "texted separator" at the insertion location. Texted separators do not exist in menu items in the OS X "global" menubar (they become regular separators), and Qt will not provide a platform-specific implementation. Loss of the section title text is maybe not always an issue, but I think it is in the system tray menu. I therefore propose to emulate QMenu::addSection by replacing the texted separator with an inactive (disabled) menu item that shows the text, followed by a standard separator. Menus in the notification area are much less subject to interface guidelines, so the presence of an item icon is acceptable and IMO useful for the titleAction.

Testing the NeedsAttention state with the tests/kstatusnotifieritemtest application leads to disappearance of the menubar icon, i.e. the access to the notifier menu becomes invisible rather than blinking (which is what I get on Linux using the same packaging). Adding a few qDebug statements shows that the attentionIcon is empty.
I'd appreciate a crash course how this feature is supposed to work, so I can see if an OS X implementation might be feasible.

On OS X 10.9.5 with Qt 5.5.1 and frameworks 5.17.0 .

Files


Issues

  • 0
  • 5
  • 2
  • 7
Description From Last Updated
Sebastian Kügler
Martin Klapetek
René J.V. Bertin
Martin Klapetek
René J.V. Bertin
René J.V. Bertin
René J.V. Bertin
René J.V. Bertin
Martin Klapetek
Martin Klapetek
René J.V. Bertin
René J.V. Bertin
Kai Uwe Broulik
René J.V. Bertin
Kai Uwe Broulik
René J.V. Bertin
Kai Uwe Broulik
René J.V. Bertin
René J.V. Bertin
René J.V. Bertin
René J.V. Bertin
René J.V. Bertin
Review request changed

Status: Closed (submitted)

Change Summary:

Submitted with commit a6672ec04eafb7580a6a122806e826f6d5102bdd by R.J.V. Bertin to branch master.
Loading...