needsRefresh(selected, hover) {
    if (this.refreshNeeded === true) {
      // This is probably not the best location to reset this member.
      // However, in the current logic, it is the most convenient one.
      this.refreshNeeded = false;
      return true;
    }

    return (
      this.width === undefined ||
      this.labelModule.differentState(selected, hover)
    );
  }
Determine if the shape of a node needs to be recalculated.
@param {boolean} selected
@param {boolean} hover
@returns {boolean}
@protected