@@ -153,6 +153,7 @@ export class NativeCell extends React.Component<INativeCellProps, INativeCellSta
153153 return (
154154 < div className = { cellWrapperClass } role = { this . props . role } ref = { this . wrapperRef } tabIndex = { 0 } onKeyDown = { this . onOuterKeyDown } onClick = { this . onMouseClick } onDoubleClick = { this . onMouseDoubleClick } >
155155 < div className = { cellOuterClass } >
156+ { this . renderNavbar ( ) }
156157 { this . renderControls ( ) }
157158 < div className = 'content-div' >
158159 { content }
@@ -473,6 +474,35 @@ export class NativeCell extends React.Component<INativeCellProps, INativeCellSta
473474 }
474475 }
475476
477+ private renderNavbar = ( ) => {
478+ const cellId = this . props . cellVM . cell . id ;
479+
480+ const moveUp = ( ) => {
481+ this . moveCellUp ( ) ;
482+ this . props . stateController . sendCommand ( NativeCommandType . MoveCellUp , 'mouse' ) ;
483+ } ;
484+ const moveDown = ( ) => {
485+ this . moveCellDown ( ) ;
486+ this . props . stateController . sendCommand ( NativeCommandType . MoveCellDown , 'mouse' ) ;
487+ } ;
488+ const canMoveUp = this . props . stateController . canMoveUp ( cellId ) ;
489+ const canMoveDown = this . props . stateController . canMoveDown ( cellId ) ;
490+
491+ return (
492+ < div className = 'navbar-div' >
493+ < div >
494+ < ImageButton baseTheme = { this . props . baseTheme } onClick = { moveUp } disabled = { ! canMoveUp } tooltip = { getLocString ( 'DataScience.moveCellUp' , 'Move cell up' ) } >
495+ < Image baseTheme = { this . props . baseTheme } class = 'image-button-image' image = { ImageName . Up } />
496+ </ ImageButton >
497+ </ div >
498+ < div >
499+ < ImageButton baseTheme = { this . props . baseTheme } onClick = { moveDown } disabled = { ! canMoveDown } tooltip = { getLocString ( 'DataScience.moveCellDown' , 'Move cell down' ) } >
500+ < Image baseTheme = { this . props . baseTheme } class = 'image-button-image' image = { ImageName . Down } />
501+ </ ImageButton >
502+ </ div >
503+ </ div >
504+ ) ;
505+ }
476506 private renderMiddleToolbar = ( ) => {
477507 const cellId = this . props . cellVM . cell . id ;
478508 const deleteCell = ( ) => {
0 commit comments