That's kinda the point of the lawsuit: they can't. Redbox is buying Disney movies at retail. The only way for Disney to stop Redbox from doing what they're doing is to stop selling physical copies of movies.
They are working on their own streaming service so they could stop selling retail copies. I'll admit this won't happen in the next 5 years (depending on the success of their streaming service).
They can stop selling the retail copies with the code included. That would pinch off Redbox, but upset customers.
They could stop offering download codes and instead allow people to register their retail copy to the streaming service with a copy of their receipt. Again, not very consumer friendly, but Disney is big enough to possibly get away with it.
I can see that happening in the next few decades. Once sufficient amount of people have reliable access to internet, the physical option can be dropped completely.
Which ends up hurting us (the consumers) in the end. I will be sad to see digital download codes go the way of the dodo so some corporate fat cat at Redbox can double dip into their profits.