make add room button go to create room dialog instead of room directory
This commit is contained in:
parent
0a31c2662a
commit
b9421e4269
2 changed files with 1 additions and 12 deletions
|
@ -322,11 +322,6 @@ module.exports = React.createClass({
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
onCreateRoomClicked: function() {
|
|
||||||
this.props.onFinished();
|
|
||||||
dis.dispatch({action: 'view_create_room'});
|
|
||||||
},
|
|
||||||
|
|
||||||
onJoinClick: function(alias) {
|
onJoinClick: function(alias) {
|
||||||
// If we don't have a particular instance id selected, just show that rooms alias
|
// If we don't have a particular instance id selected, just show that rooms alias
|
||||||
if (!this.state.instanceId) {
|
if (!this.state.instanceId) {
|
||||||
|
@ -603,17 +598,11 @@ module.exports = React.createClass({
|
||||||
</div>;
|
</div>;
|
||||||
}
|
}
|
||||||
|
|
||||||
const createRoomButton = (<AccessibleButton
|
|
||||||
onClick={this.onCreateRoomClicked}
|
|
||||||
className="mx_RoomDirectory_createRoom"
|
|
||||||
>{_t("Create new room")}</AccessibleButton>);
|
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<BaseDialog
|
<BaseDialog
|
||||||
className={'mx_RoomDirectory_dialog'}
|
className={'mx_RoomDirectory_dialog'}
|
||||||
hasCancel={true}
|
hasCancel={true}
|
||||||
onFinished={this.props.onFinished}
|
onFinished={this.props.onFinished}
|
||||||
headerButton={createRoomButton}
|
|
||||||
title={_t("Room directory")}
|
title={_t("Room directory")}
|
||||||
>
|
>
|
||||||
<div className="mx_RoomDirectory">
|
<div className="mx_RoomDirectory">
|
||||||
|
|
|
@ -758,7 +758,7 @@ module.exports = React.createClass({
|
||||||
headerItems: this._getHeaderItems('im.vector.fake.recent'),
|
headerItems: this._getHeaderItems('im.vector.fake.recent'),
|
||||||
order: "recent",
|
order: "recent",
|
||||||
incomingCall: incomingCallIfTaggedAs('im.vector.fake.recent'),
|
incomingCall: incomingCallIfTaggedAs('im.vector.fake.recent'),
|
||||||
onAddRoom: () => {dis.dispatch({action: 'view_room_directory'})},
|
onAddRoom: () => {dis.dispatch({action: 'view_create_room'});},
|
||||||
},
|
},
|
||||||
];
|
];
|
||||||
const tagSubLists = Object.keys(this.state.lists)
|
const tagSubLists = Object.keys(this.state.lists)
|
||||||
|
|
Loading…
Reference in a new issue