make add room button go to create room dialog instead of room directory
This commit is contained in:
parent
4148f1697c
commit
68dde07f49
2 changed files with 1 additions and 12 deletions
|
@ -321,11 +321,6 @@ module.exports = createReactClass({
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
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) {
|
||||||
|
@ -602,17 +597,11 @@ module.exports = createReactClass({
|
||||||
</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 = createReactClass({
|
||||||
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