mirror of https://github.com/vector-im/riot-web
Track Notifier events so we know what % have toolbar/enabled/etc
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>pull/21833/head
parent
541cea020e
commit
b9457a0681
|
@ -18,6 +18,7 @@ limitations under the License.
|
||||||
import MatrixClientPeg from './MatrixClientPeg';
|
import MatrixClientPeg from './MatrixClientPeg';
|
||||||
import PlatformPeg from './PlatformPeg';
|
import PlatformPeg from './PlatformPeg';
|
||||||
import TextForEvent from './TextForEvent';
|
import TextForEvent from './TextForEvent';
|
||||||
|
import Analytics from './Analytics';
|
||||||
import Avatar from './Avatar';
|
import Avatar from './Avatar';
|
||||||
import dis from './dispatcher';
|
import dis from './dispatcher';
|
||||||
import sdk from './index';
|
import sdk from './index';
|
||||||
|
@ -121,6 +122,9 @@ const Notifier = {
|
||||||
setEnabled: function(enable, callback) {
|
setEnabled: function(enable, callback) {
|
||||||
const plaf = PlatformPeg.get();
|
const plaf = PlatformPeg.get();
|
||||||
if (!plaf) return;
|
if (!plaf) return;
|
||||||
|
|
||||||
|
Analytics.trackEvent('Notifier', 'Set Enabled', enable);
|
||||||
|
|
||||||
// make sure that we persist the current setting audio_enabled setting
|
// make sure that we persist the current setting audio_enabled setting
|
||||||
// before changing anything
|
// before changing anything
|
||||||
if (global.localStorage) {
|
if (global.localStorage) {
|
||||||
|
@ -199,6 +203,8 @@ const Notifier = {
|
||||||
setToolbarHidden: function(hidden, persistent = true) {
|
setToolbarHidden: function(hidden, persistent = true) {
|
||||||
this.toolbarHidden = hidden;
|
this.toolbarHidden = hidden;
|
||||||
|
|
||||||
|
Analytics.trackEvent('Notifier', 'Set Toolbar Hidden', hidden);
|
||||||
|
|
||||||
// XXX: why are we dispatching this here?
|
// XXX: why are we dispatching this here?
|
||||||
// this is nothing to do with notifier_enabled
|
// this is nothing to do with notifier_enabled
|
||||||
dis.dispatch({
|
dis.dispatch({
|
||||||
|
|
Loading…
Reference in New Issue