File tree Expand file tree Collapse file tree 1 file changed +17
-1
lines changed Expand file tree Collapse file tree 1 file changed +17
-1
lines changed Original file line number Diff line number Diff line change @@ -1675,6 +1675,9 @@ border-radius: ${borderWidth}px;
1675
1675
}
1676
1676
1677
1677
destroy ( ) {
1678
+ this . getWindows ( ) . forEach ( w => {
1679
+ delete w . tiled_on_minimize ;
1680
+ } ) ;
1678
1681
this . signals . destroy ( ) ;
1679
1682
this . signals = null ;
1680
1683
this . background . destroy ( ) ;
@@ -3767,10 +3770,23 @@ var focus_wrapper = Utils.dynamic_function_ref('focus_handler', this);
3767
3770
Push all minimized windows to the scratch layer
3768
3771
*/
3769
3772
function minimizeHandler ( metaWindow ) {
3770
- console . debug ( 'minimized' , metaWindow ?. title ) ;
3771
3773
if ( metaWindow . minimized ) {
3774
+ console . debug ( 'minimized' , metaWindow ?. title ) ;
3775
+ // check if was tiled
3776
+ if ( isTiled ( metaWindow ) ) {
3777
+ metaWindow . tiled_on_minimize = true ;
3778
+ }
3772
3779
Scratch . makeScratch ( metaWindow ) ;
3773
3780
}
3781
+ else {
3782
+ console . debug ( 'unminimized' , metaWindow ?. title ) ;
3783
+ if ( metaWindow . tiled_on_minimize ) {
3784
+ delete metaWindow . tiled_on_minimize ;
3785
+ Utils . later_add ( Meta . LaterType . IDLE , ( ) => {
3786
+ Scratch . unmakeScratch ( metaWindow ) ;
3787
+ } ) ;
3788
+ }
3789
+ }
3774
3790
}
3775
3791
var minimizeWrapper = Utils . dynamic_function_ref ( 'minimizeHandler' , this ) ;
3776
3792
You can’t perform that action at this time.
0 commit comments