Skip to content

Commit

Permalink
AG-NONE Fix eslint errors
Browse files Browse the repository at this point in the history
```
Member 'isDragMoving' is never reassigned; mark it as `readonly`  @typescript-eslint/prefer-readonly
End this switch case with an unconditional break, continue, return or throw statement  sonarjs/sonar-no-fallthrough
Expected a 'break' statement before 'case'                                             no-fallthrough
```
  • Loading branch information
olegat committed Dec 11, 2024
1 parent 08d3c55 commit 76d7238
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -232,6 +232,12 @@ export class RegionManager {
event.sequence = widgetEvent.sequence;
}

if (event.type === 'drag-start') {
this.isDragMoving = true;
} else if (event.type === 'drag-end') {
this.isDragMoving = false;
}

this.debug('Dispatching region event: ', event);
this.allRegionsListeners.dispatch(event.type, event);
current.listeners.dispatch(event.type, event);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -207,13 +207,15 @@ export class WidgetListenerInternal {
handler: initClickSequencing(target, this.endSequencedClick.bind(this)),
};
this.clickSequencing.listeners.push(handler);
break;
}
case 'sequenced-dblclick': {
this.dblClickSequencing ??= {
listeners: [],
handler: initDblClickSequencing(target, this.endSequencedDblClick.bind(this)),
};
this.dblClickSequencing.listeners.push(handler);
break;
}
}
}
Expand Down

0 comments on commit 76d7238

Please sign in to comment.