That would require a small circuit to be built inside the drone, but is really just 3 or 4 discrete components, to make a latch. When the drone is connected to power, the latch circuit would come on, powering down the drone and allowing charge to flow to the battery. A couple of transistors, a...