File tree Expand file tree Collapse file tree 1 file changed +13
-1
lines changed
Expand file tree Collapse file tree 1 file changed +13
-1
lines changed Original file line number Diff line number Diff line change @@ -818,12 +818,15 @@ export class TabBar<T> extends Widget {
818818 }
819819
820820 /**
821- * Handle the `'dblclick '` event for the tab bar.
821+ * Handle the `'scroll '` event for the tab bar.
822822 */
823823 private _evtScroll ( event : Event ) : void {
824824 this . updateScrollingHints ( this . _scrollState ) ;
825825 }
826826
827+ /**
828+ * Handle the `'wheel'` event for the tab bar.
829+ */
827830 private _evtWheel ( event : WheelEvent ) : void {
828831 this . scrollBy ( event . deltaY ) ;
829832 }
@@ -905,6 +908,9 @@ export class TabBar<T> extends Widget {
905908 }
906909 }
907910
911+ /**
912+ * Scroll by a fixed number of pixels (sign defines direction).
913+ */
908914 protected scrollBy ( change : number ) {
909915 const orientation = this . orientation ;
910916 const contentNode = this . contentNode ;
@@ -920,6 +926,9 @@ export class TabBar<T> extends Widget {
920926 }
921927 }
922928
929+ /**
930+ * Begin scrolling in given direction.
931+ */
923932 protected beginScrolling ( direction : '-' | '+' ) {
924933 // How many pixels should be scrolled per second initially?
925934 const initialRate = 150 ;
@@ -972,6 +981,9 @@ export class TabBar<T> extends Widget {
972981 }
973982 }
974983
984+ /**
985+ * Stop scrolling which was started with `beginScrolling` method.
986+ */
975987 protected stopScrolling ( ) {
976988 if ( ! this . _scrollData ) {
977989 return ;
You can’t perform that action at this time.
0 commit comments