fix testing UI hack

This commit is contained in:
Matthew Hodgson 2016-04-14 19:11:20 +01:00
parent 81d5e16225
commit 0741e8a5c1
2 changed files with 11 additions and 7 deletions

View file

@ -1282,13 +1282,6 @@ module.exports = React.createClass({
var statusBar; var statusBar;
// for testing UI...
// this.state.upload = {
// uploadedBytes: 123493,
// totalBytes: 347534,
// fileName: "testing_fooble.jpg",
// }
if (ContentMessages.getCurrentUploads().length > 0) { if (ContentMessages.getCurrentUploads().length > 0) {
var UploadBar = sdk.getComponent('structures.UploadBar'); var UploadBar = sdk.getComponent('structures.UploadBar');
statusBar = <UploadBar room={this.state.room} /> statusBar = <UploadBar room={this.state.room} />

View file

@ -45,6 +45,17 @@ module.exports = React.createClass({displayName: 'UploadBar',
render: function() { render: function() {
var uploads = ContentMessages.getCurrentUploads(); var uploads = ContentMessages.getCurrentUploads();
// for testing UI... - also fix up the ContentMessages.getCurrentUploads().length
// check in RoomView
//
// uploads = [{
// roomId: this.props.room.roomId,
// loaded: 123493,
// total: 347534,
// fileName: "testing_fooble.jpg",
// }];
if (uploads.length == 0) { if (uploads.length == 0) {
return <div /> return <div />
} }