rename onWidgetLoad to onHeightChanged
as it's easy to confuse it with room widgets, but has nothing to do with it.
This commit is contained in:
parent
4a1b723ab5
commit
4e382b1dd9
11 changed files with 34 additions and 34 deletions
|
@ -34,7 +34,7 @@ export default class MImageBody extends React.Component {
|
|||
mxEvent: PropTypes.object.isRequired,
|
||||
|
||||
/* called when the image has loaded */
|
||||
onWidgetLoad: PropTypes.func.isRequired,
|
||||
onHeightChanged: PropTypes.func.isRequired,
|
||||
|
||||
/* the maximum image height to use */
|
||||
maxImageHeight: PropTypes.number,
|
||||
|
@ -144,7 +144,7 @@ export default class MImageBody extends React.Component {
|
|||
}
|
||||
|
||||
onImageLoad() {
|
||||
this.props.onWidgetLoad();
|
||||
this.props.onHeightChanged();
|
||||
|
||||
let loadedImageDimensions;
|
||||
|
||||
|
|
|
@ -33,7 +33,7 @@ module.exports = React.createClass({
|
|||
mxEvent: PropTypes.object.isRequired,
|
||||
|
||||
/* called when the video has loaded */
|
||||
onWidgetLoad: PropTypes.func.isRequired,
|
||||
onHeightChanged: PropTypes.func.isRequired,
|
||||
},
|
||||
|
||||
getInitialState: function() {
|
||||
|
@ -108,7 +108,7 @@ module.exports = React.createClass({
|
|||
decryptedThumbnailUrl: thumbnailUrl,
|
||||
decryptedBlob: decryptedBlob,
|
||||
});
|
||||
this.props.onWidgetLoad();
|
||||
this.props.onHeightChanged();
|
||||
});
|
||||
}).catch((err) => {
|
||||
console.warn("Unable to decrypt attachment: ", err);
|
||||
|
|
|
@ -37,7 +37,7 @@ module.exports = React.createClass({
|
|||
showUrlPreview: PropTypes.bool,
|
||||
|
||||
/* callback called when dynamic content in events are loaded */
|
||||
onWidgetLoad: PropTypes.func,
|
||||
onHeightChanged: PropTypes.func,
|
||||
|
||||
/* the shape of the tile, used */
|
||||
tileShape: PropTypes.string,
|
||||
|
@ -89,6 +89,6 @@ module.exports = React.createClass({
|
|||
showUrlPreview={this.props.showUrlPreview}
|
||||
tileShape={this.props.tileShape}
|
||||
maxImageHeight={this.props.maxImageHeight}
|
||||
onWidgetLoad={this.props.onWidgetLoad} />;
|
||||
onHeightChanged={this.props.onHeightChanged} />;
|
||||
},
|
||||
});
|
||||
|
|
|
@ -52,7 +52,7 @@ module.exports = React.createClass({
|
|||
showUrlPreview: PropTypes.bool,
|
||||
|
||||
/* callback for when our widget has loaded */
|
||||
onWidgetLoad: PropTypes.func,
|
||||
onHeightChanged: PropTypes.func,
|
||||
|
||||
/* the shape of the tile, used */
|
||||
tileShape: PropTypes.string,
|
||||
|
@ -451,7 +451,7 @@ module.exports = React.createClass({
|
|||
link={link}
|
||||
mxEvent={this.props.mxEvent}
|
||||
onCancelClick={this.onCancelClick}
|
||||
onWidgetLoad={this.props.onWidgetLoad} />;
|
||||
onHeightChanged={this.props.onHeightChanged} />;
|
||||
});
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue