Merge lp://qastaging/~suutari-olli/openlp/click-slide-to-go-live-from-blank into lp://qastaging/openlp

Proposed by Azaziah
Status: Merged
Merged at revision: 2689
Proposed branch: lp://qastaging/~suutari-olli/openlp/click-slide-to-go-live-from-blank
Merge into: lp://qastaging/openlp
Diff against target: 247 lines (+85/-6)
6 files modified
openlp/core/common/settings.py (+1/-0)
openlp/core/lib/mediamanageritem.py (+1/-0)
openlp/core/ui/generaltab.py (+7/-0)
openlp/core/ui/slidecontroller.py (+25/-5)
openlp/plugins/presentations/lib/messagelistener.py (+5/-1)
tests/functional/openlp_core_ui/test_slidecontroller.py (+46/-0)
To merge this branch: bzr merge lp://qastaging/~suutari-olli/openlp/click-slide-to-go-live-from-blank
Reviewer Review Type Date Requested Status
Tim Bentley Approve
Raoul Snyman Approve
Tomas Groth Pending
Review via email: mp+302587@code.qastaging.launchpad.net

This proposal supersedes a proposal from 2016-07-17.

Description of the change

This branch introduces the functionality of unblanking
display from Blank to Black/Theme/Desktop for:

a) Clicking slide in "Live panel"
b) Next/Previous shortcuts (Green arrows)
c) Go to verse x.
d) When starting automatic playback (To end or Loop)
Also added "Unblank display when changing slide in Live" to general
options tab for disabling/enabling this behavior for a-c.

Additionally this branch also includes fix for bug
https://bugs.launchpad.net/openlp/+bug/1531691
Do note that this branch does not fix this for Escape item blanking,
creating yet an another Escape exclusive bug.

-----------------------------------------------------------------------------
The only reason Escape item has been a good alternative for other
blank to methods is the functionality of resuming Live by clicking
slides and the fact it worked in single screen scenarios.
I can’t see any reason why it should not be removed after this branch
is merged since the single screen issue was already fixed earlier.

-----------------------------------------------------------------------------

lp:~suutari-olli/openlp/click-slide-to-go-live-from-blank (revision 2664)
[SUCCESS] https://ci.openlp.io/job/Branch-01-Pull/1712/
[SUCCESS] https://ci.openlp.io/job/Branch-02-Functional-Tests/1623/
[SUCCESS] https://ci.openlp.io/job/Branch-03-Interface-Tests/1561/
[SUCCESS] https://ci.openlp.io/job/Branch-04a-Windows_Functional_Tests/1323/
[SUCCESS] https://ci.openlp.io/job/Branch-04b-Windows_Interface_Tests/913/
[SUCCESS] https://ci.openlp.io/job/Branch-05a-Code_Analysis/981/
[SUCCESS] https://ci.openlp.io/job/Branch-05b-Test_Coverage/849/
[SUCCESS] https://ci.openlp.io/job/Branch-05c-Code_Analysis2/26/

To post a comment you must log in.
Revision history for this message
Tomas Groth (tomasgroth) wrote : Posted in a previous version of this proposal

Just tested a bit.
You have introduced the "Click live slide to unblank" setting, but a "Unblank display when adding new item" also exists in the general tab. You should probably move yours to be under the exiting one to keep similar settings in the same place. Currently your code doesn't honor the "Unblank display when adding new item", which it will have to do. As it is now the item goes live no matter if the setting is enabled or not.
Also the new setting should be "false" as default, this is new behavior, so users should enabled it if they want it.
Also added a code-comment below.

review: Needs Fixing
Revision history for this message
Azaziah (suutari-olli) wrote : Posted in a previous version of this proposal

Hi Tomas and thank you for your comments!

"Unblank display when adding new item" also exists in the general tab. You should probably move yours to be under the exiting one to keep similar settings in the same place. Currently your code doesn't honor the "Unblank display when adding new item

# Done and Done, now also honoring double clicking preview

Also the new setting should be "false" as default, this is new behavior, so users should enabled it if they want it.

# Done
# Currently this is default behavior for Escape item and probably easier
to use than our current blank to modes. I think this and some other settings
should eventually be changed to be more user friendly by default.

Revision history for this message
Tomas Groth (tomasgroth) wrote : Posted in a previous version of this proposal

Looks good now. As you mention in one of your source-comments the previous slide is shortly visible when display is unblanked. Don't know if it can be helped.
Added a comment to the code below.
Besides that, you need tests :)

review: Needs Fixing
Revision history for this message
Azaziah (suutari-olli) wrote : Posted in a previous version of this proposal

Thanks again,

if by previous slide being shortly visible you mean it happens once you change slide inside the Live Panel
and the transition effect is applied, yes that can be changed. I've heard people complaining there's no transition effects when unblanking or changing items so maybe it should be left as it is since it would mean loosing effects.

If you were talking about this happening on song edit:
Think it would be possible but would require quite a effort,
maybe we can let it pass for the time being, it's still mostly fixed.

I really suck at writing tests, is one enough for a rookie?

I also replied to the code comment.

Revision history for this message
Raoul Snyman (raoul-snyman) wrote : Posted in a previous version of this proposal

Looks good to me. Nice tests.

review: Approve
Revision history for this message
Tim Bentley (trb143) wrote : Posted in a previous version of this proposal

Couple of tests and some tests are needed.

review: Needs Fixing
Revision history for this message
Azaziah (suutari-olli) wrote : Posted in a previous version of this proposal

I need to start working on tests...

Fixed the diff comments.

Revision history for this message
Raoul Snyman (raoul-snyman) wrote : Posted in a previous version of this proposal

Check my comment. I'll try to look at this more in-depth over the weekend and give you more feedback.

review: Needs Fixing
Revision history for this message
Azaziah (suutari-olli) wrote : Posted in a previous version of this proposal

> Check my comment. I'll try to look at this more in-depth over the weekend and
> give you more feedback.

Thank you for checking this out, I've replied to your comment.

I'm away from my coding station until next week, so no new commits
(if required) will be made until then.

I wish you all the best for your day.

Revision history for this message
Azaziah (suutari-olli) wrote : Posted in a previous version of this proposal

I noticed the comment was not saved, so here it is. ^^ Sorry about that :/

Revision history for this message
Azaziah (suutari-olli) wrote : Posted in a previous version of this proposal

I commented on replace live item function and resetting the setting.

Revision history for this message
Raoul Snyman (raoul-snyman) wrote : Posted in a previous version of this proposal

I still do not agree with using settings for temporary flags. Find another way.

review: Needs Fixing
Revision history for this message
Azaziah (suutari-olli) wrote : Posted in a previous version of this proposal

"I still do not agree with using settings for temporary flags. Find another way."

Well I can't think of an other way.

I tried to fix: https://bugs.launchpad.net/openlp/+bug/1531691 without settings,
but it didn't work properly and was way more complex.

Since we need to trigger actions in many files/functions based on temporary flags,
what would be a proper solution without the use of settings?

Also replied to diff comments.

Thank you for your review.

Revision history for this message
Raoul Snyman (raoul-snyman) wrote : Posted in a previous version of this proposal

I've just merged the flags section of the Registry object.

Having said that, and looking at your branch, I'm not entirely convinced this is the way to go about this. While you can explain to me what the difference is between this and the other auto-unblank setting, you can't explain it to our users, and I refuse to be lumped with the problem (I'm about the only person who actually actively deals with our users).

I recommend rather merging this with the current "auto-unblank" setting and make a single setting with a set of modes instead.

review: Needs Information
Revision history for this message
Azaziah (suutari-olli) wrote : Posted in a previous version of this proposal

> I've just merged the flags section of the Registry object.
>
> Having said that, and looking at your branch, I'm not entirely convinced this
> is the way to go about this. While you can explain to me what the difference
> is between this and the other auto-unblank setting, you can't explain it to
> our users, and I refuse to be lumped with the problem (I'm about the only
> person who actually actively deals with our users).
>
> I recommend rather merging this with the current "auto-unblank" setting and
> make a single setting with a set of modes instead.

I'll be looking forward to moving the flags to registry.

This branch adds the unblanking of display by clicking slides in Live.

Currently this is possible when using Escape item, but not while using the real blank to modes.
The current behavior is highly confusing.
This setting will make things more understandable and easier to manage.

So ultimately this just makes it possible for users to easily resume Live presentation by clicking a slide they wish to show.

It's not related to sending items to Live, It's more about unblanking display and resuming the projection of the current Live item. Thus they are a very different thing.

After this is merged, I think we should begin working on removing the Escape item,
It's very much a broken and confusing format.

I am sorry about the current user support situation, hope things will be better someday.
Ultimately it would be great if the customer support would be something you wouldn't have to do.

Revision history for this message
Tim Bentley (trb143) wrote : Posted in a previous version of this proposal

Traceback (most recent call last):
  File "/home/tim/Projects/OpenLP/openlp/click-slide-to-go-live-from-blank/openlp/core/ui/slidecontroller.py", line 1401, in on_preview_double_click
    elif not Registry().get_flag('has doubleclick added item to service') is True:
  File "/home/tim/Projects/OpenLP/openlp/click-slide-to-go-live-from-blank/openlp/core/common/registry.py", line 160, in get_flag
    raise KeyError('Working Flag {key} not found in list'.format(key=key))
KeyError: 'Working Flag has doubleclick added item to service not found in list'

Blank live and double click on a preview slide.

review: Needs Fixing
Revision history for this message
Azaziah (suutari-olli) wrote : Posted in a previous version of this proposal

I am unable to reproduce this traceback,
need to investigate further.

Fixed the commented stuff.

Thank you for the review.

Revision history for this message
Azaziah (suutari-olli) wrote : Posted in a previous version of this proposal

> Traceback (most recent call last):
> File "/home/tim/Projects/OpenLP/openlp/click-slide-to-go-live-from-
> blank/openlp/core/ui/slidecontroller.py", line 1401, in
> on_preview_double_click
> elif not Registry().get_flag('has doubleclick added item to service') is
> True:
> File "/home/tim/Projects/OpenLP/openlp/click-slide-to-go-live-from-
> blank/openlp/core/common/registry.py", line 160, in get_flag
> raise KeyError('Working Flag {key} not found in list'.format(key=key))
> KeyError: 'Working Flag has doubleclick added item to service not found in
> list'
>
> Blank live and double click on a preview slide.

Fixed this,
also removed the ??? if statement.

Revision history for this message
Raoul Snyman (raoul-snyman) : Posted in a previous version of this proposal
review: Approve
Revision history for this message
Tim Bentley (trb143) : Posted in a previous version of this proposal
review: Approve
Revision history for this message
Tim Bentley (trb143) wrote : Posted in a previous version of this proposal

Sorry but needs to respin and other merges have broken this

review: Needs Fixing
Revision history for this message
Raoul Snyman (raoul-snyman) :
review: Approve
Revision history for this message
Tim Bentley (trb143) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
The diff is not available at this time. You can reload the page or download it.