def on_mouse_drag(self, x, y, dx, dy, button, modifiers):
        bar_x, bar_y, bar_width, bar_height = self._bar.get_content_region()

        absolute_distance = float(y - bar_y)
        relative_distance = absolute_distance/bar_height
        self.set_knob_pos(1 - relative_distance)
        self._scrolled = 10
        self.re_layout()
        return True
dataset/ETHPy150Open jorgecarleitao/pyglet-gui/pyglet_gui/scrollbars.py/VScrollbar.on_mouse_drag/original