src/tools/base/BaseTool.js
/**
   * Function responsible for changing the Cursor, according to the strategy.
   * @param {HTMLElement} element
   * @param {string} strategy The strategy to be used on Tool
   * @public
   * @returns {void}
   */
Function responsible for changing the Cursor, according to the strategy.
@param {HTMLElement} element
@param {string} strategy The strategy to be used on Tool
@public
@returns {void}
Function responsible for changing the Cursor according to the strategy . @param { HTMLElement } element @param { string } strategy The strategy to be used on Tool @public @returns { void }
changeCursor(element, strategy) {
    if (!element) {
      return;
    }
    const cursor = this._cursors[strategy];
    if (cursor) {
      this.svgCursor = cursor;
      if (this.mode === 'active') {
        setToolCursor(element, cursor);
      }
    }
  }
changeCursor ( element , strategy ) { if ( ! element ) { return ; } const cursor = this . _cursors [ strategy ] ; if ( cursor ) { this . svgCursor = cursor ; if ( this . mode === 'active' ) { setToolCursor ( element , cursor ) ; } } }
Function responsible for changing the Cursor, according to the strategy.
Function responsible for changing the Cursor according to the strategy .
// Necessary to avoid setToolCursor call without elements, which throws an error. // If there are cursors set per strategy, change the cursor. // External.cornerstone.updateImage(element);