Replace recursive layout loading with dynamic loading
ClosedPublic

Authored by davidedmundson on Jan 10 2017, 2:21 AM.

Details

Summary

The previous code worked as follows:

  • when we show a menu we would emit aboutToShow on the root item
  • we would then recursively load the /entire/ menu structure before

emitting we were done.

Because we only sent aboutToShow on the root menu, any clients that were connected to
a submenu's aboutToShow never got an aboutToShow signal.

This patch does the (in retrospect far more obvious) fix of just
calling aboutToShow dynamically on each submenu when it's time to show,
then updating the menu whilst it's showing.

Test Plan

Dynamic menus now work, DBus traffic is considerably down

Diff Detail

Repository
R120 Plasma Workspace
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
davidedmundson retitled this revision from to Replace recursive layout loading with dynamic loading.
davidedmundson updated this object.
davidedmundson edited the test plan for this revision. (Show Details)
davidedmundson added a reviewer: Plasma.
Restricted Application added a project: Plasma. · View Herald TranscriptJan 10 2017, 2:21 AM
Restricted Application added a subscriber: plasma-devel. · View Herald Transcript

and to answer the ineviatible question, this one (combined with the other libdbusmenuqt patch) does fix everything.

broulik accepted this revision.Jan 10 2017, 12:40 PM
broulik added a reviewer: broulik.
broulik added a subscriber: broulik.

does fix everything.

I think that's a myth :P

This revision is now accepted and ready to land.Jan 10 2017, 12:40 PM
This revision was automatically updated to reflect the committed changes.