Add notification to group chat rooms with ongoing conf calls

This notification disappears when in the conf call / when the call is over.
CSS stolen from the desktop notification bar.
This commit is contained in:
Kegan Dougal 2015-09-15 14:18:17 +01:00
parent 353269370f
commit f384aa7d9e
5 changed files with 68 additions and 10 deletions

View file

@ -176,6 +176,15 @@ module.exports = React.createClass({
roomEdit = <Loader/>;
}
var conferenceCallNotification = null;
if (this.state.displayConfCallNotification) {
conferenceCallNotification = (
<div className="mx_RoomView_ongoingConfCallNotification">
Ongoing conference call
</div>
);
}
var fileDropTarget = null;
if (this.state.draggingFile) {
fileDropTarget = <div className="mx_RoomView_fileDropTarget">
@ -192,6 +201,7 @@ module.exports = React.createClass({
onSettingsClick={this.onSettingsClick} onSaveClick={this.onSaveClick} onCancelClick={this.onCancelClick} />
<div className="mx_RoomView_auxPanel">
<CallView room={this.state.room}/>
{ conferenceCallNotification }
{ roomEdit }
</div>
<div ref="messageWrapper" className="mx_RoomView_messagePanel" onScroll={ this.onMessageListScroll }>

View file

@ -89,6 +89,7 @@ module.exports = React.createClass({
call_element = <CallView className="mx_MatrixChat_callView"/>
}
// TODO: Fix duplication here and do conditionals like we do above
if (Notifier.supportsDesktopNotifications() && !Notifier.isEnabled() && !Notifier.isToolbarHidden()) {
return (
<div className="mx_MatrixChat_wrapper">