code: function (real_x) {
              if (this.options.type === "single") {
                  return "single";
              } else {
                  var m_point = this.coords.p_from_real + ((this.coords.p_to_real - this.coords.p_from_real) / 2);
                  if (real_x >= m_point) {
                      return this.options.to_fixed ? "from" : "to";
                  } else {
                      return this.options.from_fixed ? "to" : "from";
                  }
              }
          }
docs: Find closest handle to pointer click
  
  @param real_x {Number}
  @returns {String}