diff options
author | Stefan Malzner <stefan@adlk.io> | 2019-04-12 13:32:19 +0200 |
---|---|---|
committer | Stefan Malzner <stefan@adlk.io> | 2019-04-12 13:32:19 +0200 |
commit | f941074dd7520efb63e9507294df8c420715b9df (patch) | |
tree | 614d03296254f02fe93a67a5c3b2feef1446e3aa /src/components/services/content/ServiceView.js | |
parent | Don't invalidate user request on componentWillMount (diff) | |
parent | feat(App): Update electron to 4.1.4 (diff) | |
download | ferdium-app-f941074dd7520efb63e9507294df8c420715b9df.tar.gz ferdium-app-f941074dd7520efb63e9507294df8c420715b9df.tar.zst ferdium-app-f941074dd7520efb63e9507294df8c420715b9df.zip |
Merge branch 'develop' into chore/streamline-dashboard
Diffstat (limited to 'src/components/services/content/ServiceView.js')
-rw-r--r-- | src/components/services/content/ServiceView.js | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/components/services/content/ServiceView.js b/src/components/services/content/ServiceView.js index 5afc54f9d..13148b9b3 100644 --- a/src/components/services/content/ServiceView.js +++ b/src/components/services/content/ServiceView.js | |||
@@ -35,11 +35,13 @@ export default @observer class ServiceView extends Component { | |||
35 | 35 | ||
36 | autorunDisposer = null; | 36 | autorunDisposer = null; |
37 | 37 | ||
38 | forceRepaintTimeout = null; | ||
39 | |||
38 | componentDidMount() { | 40 | componentDidMount() { |
39 | this.autorunDisposer = autorun(() => { | 41 | this.autorunDisposer = autorun(() => { |
40 | if (this.props.service.isActive) { | 42 | if (this.props.service.isActive) { |
41 | this.setState({ forceRepaint: true }); | 43 | this.setState({ forceRepaint: true }); |
42 | setTimeout(() => { | 44 | this.forceRepaintTimeout = setTimeout(() => { |
43 | this.setState({ forceRepaint: false }); | 45 | this.setState({ forceRepaint: false }); |
44 | }, 100); | 46 | }, 100); |
45 | } | 47 | } |
@@ -48,6 +50,7 @@ export default @observer class ServiceView extends Component { | |||
48 | 50 | ||
49 | componentWillUnmount() { | 51 | componentWillUnmount() { |
50 | this.autorunDisposer(); | 52 | this.autorunDisposer(); |
53 | clearTimeout(this.forceRepaintTimeout); | ||
51 | } | 54 | } |
52 | 55 | ||
53 | updateTargetUrl = (event) => { | 56 | updateTargetUrl = (event) => { |