diff --git a/app/com/gitpitch/models/SlideshowModel.java b/app/com/gitpitch/models/SlideshowModel.java index 4e26ac9..e9057e5 100644 --- a/app/com/gitpitch/models/SlideshowModel.java +++ b/app/com/gitpitch/models/SlideshowModel.java @@ -296,6 +296,13 @@ public class SlideshowModel { return (_yOpts != null) ? _yOpts.fetchLoop(params()) : false; } + /* + * Return "remote-control" defined in PITCHME.yaml. + */ + public boolean remoteControlEnabled() { + return (_yOpts != null) ? _yOpts.fetchRemoteControl(params()) : false; + } + /* * Return "rtl" defined in PITCHME.yaml. */ diff --git a/app/com/gitpitch/utils/YAMLOptions.java b/app/com/gitpitch/utils/YAMLOptions.java index 1c1c3f6..5cae764 100644 --- a/app/com/gitpitch/utils/YAMLOptions.java +++ b/app/com/gitpitch/utils/YAMLOptions.java @@ -195,6 +195,10 @@ public final class YAMLOptions { return fetchBooleanOption(pp, LOOP_OPTION); } + public Boolean fetchRemoteControl(PitchParams pp) { + return fetchBooleanOption(pp, REMOTE_CONTROL_OPTION); + } + public Boolean fetchRTL(PitchParams pp) { return fetchBooleanOption(pp, RTL_OPTION); } @@ -352,6 +356,7 @@ public final class YAMLOptions { private static final String TRANSITION_OPTION = "transition"; private static final String AUTOSLIDE_OPTION = "autoslide"; private static final String LOOP_OPTION = "loop"; + private static final String REMOTE_CONTROL_OPTION = "remote-control"; private static final String RTL_OPTION = "rtl"; private static final String SHUFFLE_OPTION = "shuffle"; private static final String MOUSE_WHEEL_OPTION = "mousewheel"; diff --git a/app/com/gitpitch/views/frags/SlideshowReveal.scala.html b/app/com/gitpitch/views/frags/SlideshowReveal.scala.html index 7f51165..ae8b0aa 100644 --- a/app/com/gitpitch/views/frags/SlideshowReveal.scala.html +++ b/app/com/gitpitch/views/frags/SlideshowReveal.scala.html @@ -75,3 +75,14 @@ }; + + @if(ssm.remoteControlEnabled()) { + + }