Skip to content

Commit

Permalink
swipe support added #48 #49
Browse files Browse the repository at this point in the history
  • Loading branch information
pliablepixels committed Nov 5, 2015
1 parent 359dfc4 commit 33e441f
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 6 deletions.
8 changes: 8 additions & 0 deletions www/js/EventCtrl.js
Original file line number Diff line number Diff line change
Expand Up @@ -1247,6 +1247,14 @@ angular.module('zmApp.controllers')
//Navigate to next/prev event in full screen mode
//--------------------------------------------------------

$scope.onSwipe = function(eid,dirn)
{
var ld = ZMDataModel.getLogin();
if (!ld.canSwipeMonitors) return;
jumpToEvent(eid,dirn);

};

$scope.jumpToEvent = function (eid, dirn) {

jumpToEvent(eid, dirn);
Expand Down
12 changes: 6 additions & 6 deletions www/templates/events-modal.html
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,10 @@
<img imageonload="finishedLoadingImage($index)"
image-spinner-src="{{playbackURL}}/index.php?view=image&rand={{$root.rand}}&path={{relativePath}}{{slide.img}}&scale={{loginData.singleImageQuality}}"
image-spinner-loader="lines"
ng-class="{'zm-image-fit':imageFit==true, 'zm-image-crop':imageFit==false}" />
ng-class="{'zm-image-fit':imageFit==true, 'zm-image-crop':imageFit==false}"
on-swipe-left="onSwipe(nextId,1)"
on-swipe-right="onSwipe(prevId,-1)"
/>
</div>
<div ng-if="animationInProgress">
<img imageonload="finishedLoadingImage($index)"
Expand All @@ -25,10 +28,7 @@
</div>


<!--<img id="hello" imageonload="finishedLoadingImage($index)"
image-spinner-src="{{eventBasePath}}{{slide.img}}?rand={{rand}}"
image-spinner-loader="lines"
ng-class="{'zm-image-fit':imageFit==true, 'zm-image-crop':imageFit==false}";/>-->


</li>
</ul>
Expand Down Expand Up @@ -103,7 +103,7 @@

<span class="events-modal-gapless-icon">
<a ng-class="loginData.gapless? 'button button-small button-stable' : 'button button-small button-assertive' " href="" ng-click="toggleGapless()">gapless: {{loginData.gapless?"on":"off"}}</a>
</span>
</span>

<!--
<nav mfb-menu position="bl" effect="zoomin" label="collapse"
Expand Down

0 comments on commit 33e441f

Please sign in to comment.