Remove sound notification. This is the platform's job in an app.

Lorenz Hübschle-Schneider 11 years ago
parent 10949323b6
commit c0395b334b
  1. BIN
      assets/audio/sonar.mp3
  2. BIN
      assets/audio/sonar.ogg
  3. 11
      index.html
  4. 9
      js/glowingbear.js

Binary file not shown.

Binary file not shown.

@ -247,7 +247,6 @@ $ openssl req -nodes -newkey rsa:4096 -keyout relay.pem -x509 -days 365 -out rel
<div input-bar input-id="sendMessage"></div>
</div>
</div>
<div id="soundNotification"></div>
<div id="settingsModal" class="modal fade">
<div class="modal-dialog">
<div class="modal-content">
@ -318,16 +317,6 @@ $ openssl req -nodes -newkey rsa:4096 -keyout relay.pem -x509 -days 365 -out rel
</div>
</form>
</li>
<li>
<form class="form-inline" role="form">
<div class="checkbox">
<label>
<input type="checkbox" ng-model="soundnotification">
Play sound on notification
</label>
</div>
</form>
</li>
<li>
<form class="form-inline" role="form">
<div class="checkbox">

@ -804,8 +804,6 @@ weechat.controller('WeechatCtrl', ['$rootScope', '$scope', '$store', '$timeout',
$store.bind($scope, "orderbyserver", false);
// Save setting for notimestamp
$store.bind($scope, "notimestamp", notimestamp);
// Save setting for playing sound on notification
$store.bind($scope, "soundnotification", false);
// Save setting for displaying embeds in rootScope so it can be used from service
$rootScope.visible = $scope.noembed === false;
@ -1039,13 +1037,6 @@ weechat.controller('WeechatCtrl', ['$rootScope', '$scope', '$store', '$timeout',
json: JSON.stringify({ buffer: buffer.id }) // remember buffer id for when the notification is clicked
});
}
if ($scope.soundnotification) {
// TODO fill in a sound file
var audioFile = "assets/audio/sonar";
var soundHTML = '<audio autoplay="autoplay"><source src="' + audioFile + '.ogg" type="audio/ogg" /><source src="' + audioFile + '.mp3" type="audio/mpeg" /></audio>';
document.getElementById("soundNotification").innerHTML = soundHTML;
}
};
$scope.hasUnread = function(buffer) {

Loading…
Cancel
Save