DevHeads.net

Review Request 111345: KParts::StatusBarExtension: Remember activated state

Review request for kdelibs and David Faure.

Description
When the StatusBarExtension receives a GUIActivateEvent, it shows or hides its statusbar items accordingly, but it does not remember it: if an item is added after receiving a GUIActivateEvent(false), the item will be shown. This patch adds a bool m_activated field to keep track of the state and take it into account when a new item is added.

This change is needed for an Akregator fix: <a href="https://git.reviewboard.kde.org/r/111346/" title="https://git.reviewboard.kde.org/r/111346/">https://git.reviewboard.kde.org/r/111346/</a> . Without the patch, when Akregator restores its session at startup, the statubar items for all background tabs appear.

Diffs
kparts/statusbarextension.cpp db7e4197dd42497f91c66d1654e9b1c8cc45d793

Diff: <a href="http://git.reviewboard.kde.org/r/111345/diff/" title="http://git.reviewboard.kde.org/r/111345/diff/">http://git.reviewboard.kde.org/r/111345/diff/</a>

Testing
Akregator startup: statusbar items do not appear when the main tab is focused and other tabs are loaded. Statusbar items do appear when the corresponding tab is focused.

Konqueror: played around with tabs and splitted views, did not notice any behavior change in the statusbar.

Thanks,

Aurélien Gâteau

Comments

Re: Review Request 111345: KParts::StatusBarExtension: Remember

By David Faure at 07/02/2013 - 04:51

Ship it!

Makes sense.

- David Faure

On July 1, 2013, 4:01 p.m., Aurélien Gâteau wrote:

Re: Review Request 111345: KParts::StatusBarExtension: Remember

By Commit Hook at 07/02/2013 - 10:05

This review has been submitted with commit 4c3b5a452b4090019852d1691ad91f12cf91d362 by Aurélien Gâteau to branch master.

- Commit Hook

On July 1, 2013, 4:01 p.m., Aurélien Gâteau wrote:

Re: Review Request 111345: KParts::StatusBarExtension: Remember

By Commit Hook at 07/02/2013 - 10:05

(Updated July 2, 2013, 2:05 p.m.)

Status
This change has been marked as submitted.

Review request for kdelibs and David Faure.

Description
When the StatusBarExtension receives a GUIActivateEvent, it shows or hides its statusbar items accordingly, but it does not remember it: if an item is added after receiving a GUIActivateEvent(false), the item will be shown. This patch adds a bool m_activated field to keep track of the state and take it into account when a new item is added.

This change is needed for an Akregator fix: <a href="https://git.reviewboard.kde.org/r/111346/" title="https://git.reviewboard.kde.org/r/111346/">https://git.reviewboard.kde.org/r/111346/</a> . Without the patch, when Akregator restores its session at startup, the statubar items for all background tabs appear.

Diffs
kparts/statusbarextension.cpp db7e4197dd42497f91c66d1654e9b1c8cc45d793

Diff: <a href="http://git.reviewboard.kde.org/r/111345/diff/" title="http://git.reviewboard.kde.org/r/111345/diff/">http://git.reviewboard.kde.org/r/111345/diff/</a>

Testing
Akregator startup: statusbar items do not appear when the main tab is focused and other tabs are loaded. Statusbar items do appear when the corresponding tab is focused.

Konqueror: played around with tabs and splitted views, did not notice any behavior change in the statusbar.

Thanks,

Aurélien Gâteau