diff options
author | Stefan Malzner <stefan@adlk.io> | 2019-03-18 03:28:03 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-03-18 03:28:03 -0700 |
commit | 6134c1b49f919dd2c578bc490829d68e4d210f4e (patch) | |
tree | 1ad6530fbb7f19e4e9c9a235c6b44e0dfdbc47d4 /src/stores/ServicesStore.js | |
parent | Add missing bracket in brew install help (#1205) (diff) | |
download | ferdium-app-6134c1b49f919dd2c578bc490829d68e4d210f4e.tar.gz ferdium-app-6134c1b49f919dd2c578bc490829d68e4d210f4e.tar.zst ferdium-app-6134c1b49f919dd2c578bc490829d68e4d210f4e.zip |
Release/5.0.1 beta.1 (#1344)
* Add lerna
* Add theme
* Add forms
* Add misty config to build theme & forms
* reset packages version
* Publish
- @meetfranz/forms@1.0.0
- @meetfranz/theme@1.0.0
* Reset package version
* restructure packages
* try ci with lerna
* Fix missing packages in build
* move storybook to root + typescript
TODO: fix modules
* Add lerna instructions
* Merge
* wip
* Make packages work in electron, node and web
* Finalize packages & replace storybook with homegrown `uidev`
* Bring package-lock back in sync
* Publish
- @meetfranz/forms@1.0.1
- @meetfranz/theme@1.0.1
* fix webpack issue
* expose legacy styles
* Add toggle element to @meetfranz/forms
* start typings package
* Update package.json
* Add buttons
* Update theme
* add types
* Add mdi icons to buttons
* Publish
- @meetfranz/forms@1.0.2
- @meetfranz/theme@1.0.2
- @meetfranz/typings@0.0.1
* Button, add missing success state
* Update lerna packages
* Try to disable automatic npm ci
* Try to get a working bundle
* Add href and type to button component
* Update packages
* update versions
* cleanup
* Update package versions
[ci skip]
* Update versions
* Add withTheme context to button
* Update & reuse electron-rebuild
* feat(Windows): Add option to quit Franz from Taskbar icon
* Add missing withTheme
* Fix package versions
* Update versions
* Add pageview event
* Simplify analytics calls
* Pin gulp-sass-variables to 1.1.1
* Add onFocus event
* Add modal overlay color
* remove legacy theme files
* remove code
* Add dialog to share franz on social media
* Fix service count
* remove ping
* replace ms time strings with ms module
* remove unused packages
* fix value setter
* new payment flow
* fix module reference
* feat(Spell check): Add en-gb spell check languages (#1306)
* move devmode info
* fix(Windows): Fix losing window when "Keep Franz in background" is enabled
* fix(Service): Fix service zoom (cmd/ctrl+ & cmd/ctrl-)
* fixes appveyor build issue
* feat(App): Update electron to 4.0.7
* ignore intellij idea project files
* Automatic i18n update (i18n.meetfranz.com)
* feat(App): Add security checks for external URLs
* setup react-intl translations managing script
* use same zooming logic for all os
* feat(Linux): Add auto updater for Linux AppImage builds
* Add ctrl+ for zoom in on Windows
* move translation scripts into src/i18n folder
* only manage en-US translations
* manage translations before git pushes
* Fix unused i18n strings
* Bump version to 5.0.1-beta.1
* fix(Service) shortcuts for activating prev/next service fixes #1298
* fix(Service): Fix shortcut for (un)muting notifications & audio
* add missing react-intl files
* correctly update services submenu on language change
* fix(Windows): Fix copy & paste in service context menus
Closes #1316
* fix(Linux): Fix minimized window focusing (#1304) (@skoruppa)
* trigger build
* Check if window is minimized before restoring it
* restore() should be executed only when window is minimized
* fix(Notifications): Fix notifications & notification click when icon is blob
* Fix/service webview unmounting (#1328)
* detach service when underlying webview unmounts
* disable no-param-reassign eslint rule
* Add notification debug events
* Update electron to 4.0.8
Update required in order to fix performance degradation due to memory leak issue https://github.com/electron/electron/pull/16772.
* Automatic i18n update (i18n.meetfranz.com)
* Automatic i18n update (i18n.meetfranz.com)
* 5.0.1-beta.1
Diffstat (limited to 'src/stores/ServicesStore.js')
-rw-r--r-- | src/stores/ServicesStore.js | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/src/stores/ServicesStore.js b/src/stores/ServicesStore.js index efd57a09d..69e616f0c 100644 --- a/src/stores/ServicesStore.js +++ b/src/stores/ServicesStore.js | |||
@@ -5,6 +5,7 @@ import { | |||
5 | observable, | 5 | observable, |
6 | } from 'mobx'; | 6 | } from 'mobx'; |
7 | import { debounce, remove } from 'lodash'; | 7 | import { debounce, remove } from 'lodash'; |
8 | import ms from 'ms'; | ||
8 | 9 | ||
9 | import Store from './lib/Store'; | 10 | import Store from './lib/Store'; |
10 | import Request from './lib/Request'; | 11 | import Request from './lib/Request'; |
@@ -43,6 +44,7 @@ export default class ServicesStore extends Store { | |||
43 | this.actions.service.deleteService.listen(this._deleteService.bind(this)); | 44 | this.actions.service.deleteService.listen(this._deleteService.bind(this)); |
44 | this.actions.service.clearCache.listen(this._clearCache.bind(this)); | 45 | this.actions.service.clearCache.listen(this._clearCache.bind(this)); |
45 | this.actions.service.setWebviewReference.listen(this._setWebviewReference.bind(this)); | 46 | this.actions.service.setWebviewReference.listen(this._setWebviewReference.bind(this)); |
47 | this.actions.service.detachService.listen(this._detachService.bind(this)); | ||
46 | this.actions.service.focusService.listen(this._focusService.bind(this)); | 48 | this.actions.service.focusService.listen(this._focusService.bind(this)); |
47 | this.actions.service.focusActiveService.listen(this._focusActiveService.bind(this)); | 49 | this.actions.service.focusActiveService.listen(this._focusActiveService.bind(this)); |
48 | this.actions.service.toggleService.listen(this._toggleService.bind(this)); | 50 | this.actions.service.toggleService.listen(this._toggleService.bind(this)); |
@@ -340,6 +342,11 @@ export default class ServicesStore extends Store { | |||
340 | service.isAttached = true; | 342 | service.isAttached = true; |
341 | } | 343 | } |
342 | 344 | ||
345 | @action _detachService({ service }) { | ||
346 | service.webview = null; | ||
347 | service.isAttached = false; | ||
348 | } | ||
349 | |||
343 | @action _focusService({ serviceId }) { | 350 | @action _focusService({ serviceId }) { |
344 | const service = this.one(serviceId); | 351 | const service = this.one(serviceId); |
345 | 352 | ||
@@ -679,7 +686,7 @@ export default class ServicesStore extends Store { | |||
679 | _initRecipePolling(serviceId) { | 686 | _initRecipePolling(serviceId) { |
680 | const service = this.one(serviceId); | 687 | const service = this.one(serviceId); |
681 | 688 | ||
682 | const delay = 2000; | 689 | const delay = ms('2s'); |
683 | 690 | ||
684 | if (service) { | 691 | if (service) { |
685 | if (service.timer !== null) { | 692 | if (service.timer !== null) { |
@@ -700,7 +707,7 @@ export default class ServicesStore extends Store { | |||
700 | 707 | ||
701 | _reorderAnalytics = debounce(() => { | 708 | _reorderAnalytics = debounce(() => { |
702 | gaEvent('Service', 'order'); | 709 | gaEvent('Service', 'order'); |
703 | }, 5000); | 710 | }, ms('5s')); |
704 | 711 | ||
705 | _wrapIndex(index, delta, size) { | 712 | _wrapIndex(index, delta, size) { |
706 | return (((index + delta) % size) + size) % size; | 713 | return (((index + delta) % size) + size) % size; |