File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed
projects/igniteui-angular/src/lib/tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change 1
- import { Injectable } from '@angular/core' ;
1
+ import { Injectable , OnDestroy } from '@angular/core' ;
2
2
import { IgxTree , IgxTreeNode , IGX_TREE_SELECTION_TYPE } from './common' ;
3
3
import { NAVIGATION_KEYS } from '../core/utils' ;
4
4
import { IgxTreeService } from './tree.service' ;
5
5
import { IgxTreeSelectionService } from './tree-selection.service' ;
6
6
import { Subject } from 'rxjs' ;
7
7
8
8
@Injectable ( )
9
- export class IgxTreeNavigationService {
9
+ export class IgxTreeNavigationService implements OnDestroy {
10
10
private tree : IgxTree ;
11
11
12
12
private _focusedNode : IgxTreeNode < any > = null ;
@@ -131,6 +131,11 @@ export class IgxTreeNavigationService {
131
131
}
132
132
}
133
133
134
+ public ngOnDestroy ( ) {
135
+ this . _cacheChange . next ( ) ;
136
+ this . _cacheChange . complete ( ) ;
137
+ }
138
+
134
139
private handleNavigation ( event : KeyboardEvent ) {
135
140
switch ( event . key . toLowerCase ( ) ) {
136
141
case 'home' :
You can’t perform that action at this time.
0 commit comments