"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "js/views/react_wrapper_view.js" between
Signal-Desktop-1.35.2.tar.gz and Signal-Desktop-1.36.1.tar.gz

About: Signal-Desktop is a cross-platform encrypted messaging service (also available for mobile devices).

react_wrapper_view.js  (Signal-Desktop-1.35.2):react_wrapper_view.js  (Signal-Desktop-1.36.1)
/* global Backbone: false */ /* global Backbone: false */
/* global i18n: false */ /* global i18n: false */
/* global React: false */ /* global React: false */
/* global ReactDOM: false */ /* global ReactDOM: false */
// eslint-disable-next-line func-names // eslint-disable-next-line func-names
(function() { (function() {
'use strict';
window.Whisper = window.Whisper || {}; window.Whisper = window.Whisper || {};
window.Whisper.ReactWrapperView = Backbone.View.extend({ window.Whisper.ReactWrapperView = Backbone.View.extend({
className: 'react-wrapper', className: 'react-wrapper',
initialize(options) { initialize(options) {
const { const {
Component, Component,
JSX, JSX,
props, props,
onClose, onClose,
skipping to change at line 69 skipping to change at line 67
return; return;
} }
this.hasRendered = true; this.hasRendered = true;
if (this.onInitialRender) { if (this.onInitialRender) {
this.onInitialRender(); this.onInitialRender();
} }
}); });
}, },
augmentProps(props) { augmentProps(props) {
return Object.assign({}, props, { return {
...props,
close: () => { close: () => {
this.remove(); this.remove();
}, },
i18n, i18n,
}); };
}, },
remove() { remove() {
if (this.onClose) { if (this.onClose) {
this.onClose(); this.onClose();
} }
ReactDOM.unmountComponentAtNode(this.el); ReactDOM.unmountComponentAtNode(this.el);
Backbone.View.prototype.remove.call(this); Backbone.View.prototype.remove.call(this);
}, },
}); });
})(); })();
 End of changes. 3 change blocks. 
4 lines changed or deleted 3 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)