Merge commit '014acba' into rav/roomview_works
Conflicts: src/components/structures/RoomView.js
This commit is contained in:
commit
3acfab48fc
1 changed files with 12 additions and 8 deletions
|
@ -418,14 +418,6 @@ module.exports = React.createClass({
|
||||||
window.addEventListener('resize', this.onResize);
|
window.addEventListener('resize', this.onResize);
|
||||||
this.onResize();
|
this.onResize();
|
||||||
|
|
||||||
if (this.refs.roomView) {
|
|
||||||
var roomView = ReactDOM.findDOMNode(this.refs.roomView);
|
|
||||||
roomView.addEventListener('drop', this.onDrop);
|
|
||||||
roomView.addEventListener('dragover', this.onDragOver);
|
|
||||||
roomView.addEventListener('dragleave', this.onDragLeaveOrEnd);
|
|
||||||
roomView.addEventListener('dragend', this.onDragLeaveOrEnd);
|
|
||||||
}
|
|
||||||
|
|
||||||
this._updateTabCompleteList();
|
this._updateTabCompleteList();
|
||||||
|
|
||||||
// XXX: EVIL HACK to autofocus inviting on empty rooms.
|
// XXX: EVIL HACK to autofocus inviting on empty rooms.
|
||||||
|
@ -451,6 +443,18 @@ module.exports = React.createClass({
|
||||||
);
|
);
|
||||||
}, 500),
|
}, 500),
|
||||||
|
|
||||||
|
componentDidUpdate: function() {
|
||||||
|
if (this.refs.roomView) {
|
||||||
|
var roomView = ReactDOM.findDOMNode(this.refs.roomView);
|
||||||
|
if (!roomView.ondrop) {
|
||||||
|
roomView.addEventListener('drop', this.onDrop);
|
||||||
|
roomView.addEventListener('dragover', this.onDragOver);
|
||||||
|
roomView.addEventListener('dragleave', this.onDragLeaveOrEnd);
|
||||||
|
roomView.addEventListener('dragend', this.onDragLeaveOrEnd);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
onSearchResultsFillRequest: function(backwards) {
|
onSearchResultsFillRequest: function(backwards) {
|
||||||
if (!backwards)
|
if (!backwards)
|
||||||
return q(false);
|
return q(false);
|
||||||
|
|
Loading…
Reference in a new issue