Added dragging functionality (I think, can't test without a button) to gates.