Disable and re-enable animations Terminal commands
Try the following to re-enable them:

defaults delete -g QLPanelAnimationDuration
defaults delete -g NSToolbarFullScreenAnimationDuration


Those commands will delete the settings changes that you made, and OS X will reset them to the default settings.

Source: Wikipedia