Specially controlled locking actions in case of open doors or in case of doors moved from an open to a closed position