5th dnd – If a character drops a magic object that turns on / off, does that object go out when he releases it?

The description of an item will tell you the conditions for "enable / disable".

In the case of one Sunblade, a bonus action is required to make the blade appear (dis) and its fall has no direct effect because it is not indicated in the description:

While grabbing the handle, you can use a bonus action to […] make the blade disappear.

However, in the case of one Flame language sword, dropping would have extinguish the flames:

The flames last […] until you drop or sneak the sword.