From e777db3fc40d09a41eb0dd94b4fb6b73de181bf3 Mon Sep 17 00:00:00 2001
From: Richard van der Hoff <richard@matrix.org>
Date: Thu, 10 Mar 2016 11:01:29 +0000
Subject: [PATCH] Add setting for audio notifications

Expose the enableAudioNotifications setting in the user settings panel.
---
 src/components/views/settings/Notifications.js | 18 ++++++++++++++++++
 .../views/settings/Notifications.css           |  2 +-
 2 files changed, 19 insertions(+), 1 deletion(-)

diff --git a/src/components/views/settings/Notifications.js b/src/components/views/settings/Notifications.js
index 4c880760..3139bf84 100644
--- a/src/components/views/settings/Notifications.js
+++ b/src/components/views/settings/Notifications.js
@@ -1085,6 +1085,24 @@ module.exports = React.createClass({
                         </div>
                     </div>
 
+                    <div className="mx_UserNotifSettings_tableRow">
+                        <div className="mx_UserNotifSettings_inputCell">
+                            <input id="enableDesktopAudioNotifications"
+                                ref="enableDesktopAudioNotifications"
+                                type="checkbox"
+                                checked={ UserSettingsStore.getEnableAudioNotifications() }
+                                onChange={ (e) => {
+                                    UserSettingsStore.setEnableAudioNotifications(e.target.checked);
+                                    this.forceUpdate();
+                                }} />
+                        </div>
+                        <div className="mx_UserNotifSettings_labelCell">
+                            <label htmlFor="enableDesktopAudioNotifications">
+                                Enable audible notifications in web client
+                            </label>
+                        </div>
+                    </div>
+
                     <h3>General use</h3>
 
                     <div className="mx_UserNotifSettings_pushRulesTableWrapper">
diff --git a/src/skins/vector/css/vector-web/views/settings/Notifications.css b/src/skins/vector/css/vector-web/views/settings/Notifications.css
index f0446e43..041958af 100644
--- a/src/skins/vector/css/vector-web/views/settings/Notifications.css
+++ b/src/skins/vector/css/vector-web/views/settings/Notifications.css
@@ -29,7 +29,7 @@ limitations under the License.
 .mx_UserNotifSettings_labelCell
 {
     padding-bottom: 21px;
-    width: 270px;
+    width: 400px;
     display: table-cell;
 }