File tree 1 file changed +18
-7
lines changed
1 file changed +18
-7
lines changed Original file line number Diff line number Diff line change @@ -10,7 +10,8 @@ import {
10
10
Runner ,
11
11
WineVersionInfo ,
12
12
LibraryTopSectionOptions ,
13
- ExperimentalFeatures
13
+ ExperimentalFeatures ,
14
+ Status
14
15
} from 'common/types'
15
16
import {
16
17
DialogModalOptions ,
@@ -920,17 +921,27 @@ class GlobalState extends PureComponent<Props> {
920
921
storage . setItem ( 'hide_changelogs' , JSON . stringify ( hideChangelogsOnStartup ) )
921
922
storage . setItem ( 'last_changelog' , JSON . stringify ( lastChangelogShown ) )
922
923
923
- const pendingOps = libraryStatus . filter (
924
- ( game ) => game . status !== 'playing' && game . status !== 'done'
925
- ) . length
924
+ const allowedPendingOps : Status [ ] = [
925
+ 'installing' ,
926
+ 'updating' ,
927
+ 'launching' ,
928
+ 'playing' ,
929
+ 'redist' ,
930
+ 'winetricks' ,
931
+ 'extracting' ,
932
+ 'repairing' ,
933
+ 'moving' ,
934
+ 'syncing-saves' ,
935
+ 'uninstalling'
936
+ ]
926
937
927
- const isPlaying = libraryStatus . filter (
928
- ( game ) => game . status === 'playing'
938
+ const pendingOps = libraryStatus . filter ( ( game ) =>
939
+ allowedPendingOps . includes ( game . status )
929
940
) . length
930
941
931
942
if ( pendingOps ) {
932
943
window . api . lock ( )
933
- } else if ( ! isPlaying ) {
944
+ } else {
934
945
window . api . unlock ( )
935
946
}
936
947
}
You can’t perform that action at this time.
0 commit comments