Skip to content

Commit

Permalink
updated
Browse files Browse the repository at this point in the history
  • Loading branch information
shehan committed Mar 9, 2017
1 parent 0b486fa commit 0c1a753
Showing 1 changed file with 6 additions and 7 deletions.
13 changes: 6 additions & 7 deletions client/js/group-chat-controller.js
Original file line number Diff line number Diff line change
Expand Up @@ -82,15 +82,14 @@

var pos='';
setInterval(function(){
if($scope.deviceOrientation.alpha >= 40 && $scope.deviceOrientation.alpha<=66)
if($scope.deviceOrientation.beta >= 40 && $scope.deviceOrientation.beta<=66)
pos = "UP";
if($scope.deviceOrientation.alpha >= -30 && $scope.deviceOrientation.alpha<=-15)
pos = "DOWN";
if($scope.deviceOrientation.beta >= 30 && $scope.deviceOrientation.beta<=80)
pos = "DOWN" +
"";
if($scope.deviceOrientation.beta >= -80 && $scope.deviceOrientation.beta<=-30)
if($scope.deviceOrientation.beta >= -30 && $scope.deviceOrientation.beta<=-15)
pos = "DOWN";
if($scope.deviceOrientation.gamma >= 30 && $scope.deviceOrientation.gamma<=80)
pos = "LEFT";
if($scope.deviceOrientation.gamma >= -80 && $scope.deviceOrientation.gamma<=-30)
pos = "RIGHT";

if (pos != ''){
if(pos != $scope.prevAction)
Expand Down

0 comments on commit 0c1a753

Please sign in to comment.