This is a very frustrating because the problem is not usually apparent. There are so many issues that can cause this that it can be difficult to sift through all the possible issues that cause this head-meet-wall type of frustration. My issue ended up being completely undocumented and required hours of watching processes to figure out, but I will let you in on what are the most common issues and if those do not work, I will tell how I ended up finding my problem.
First, to give you an idea of what is happening (in case you do not already know) is that in Windows and just about every operating system, there is a concept called focus. The window you are currently working with and view is the window that has focus. Most operating systems have the windows without focus grayed out a bit. Normally shifting focus is not an issue because you just click on the window that you want to focus on and you normally will not even tell the difference. The issues lies is when you are in a full-screen application, like watching a movie or playing a game. When another application requests focus when you are in a full-screen application, it will minimize your application. This is the issue we need to prevent.
Far and above the most common cause of this that I saw researching this issue was AVG Antivirus. Apparently, the new update has some sort of issue and constantly requests focus to the point of instantly minimizing whatever full applications you have. The fix for this is either just uninstall completely or wait for the new update for them to patch it.
The easiest suspect is if you get any notifications in your task bar. If your application minimizes and a notification bubble immediately pops up, you have your suspect there. Try to minimize the amount of applications you have running in your task bar at any given time. If you do not know what something does in your task bar, you can probably just close it.
Give this program a try. It is called Malwarebytes Anti Malware and it looks for malicious programs that can request focus away from the on which program you are working. Download the program; run the scan; fix whatever it finds. That may solve your problem.
Though unlikely your problem, my issue was with the webcam. The software suite for HP Deluxe Webcam, Arcsoft Magic-i, was, for whatever reason, requesting focus away and thus causing my games to minimize. After uninstalling it, the problem went magically away.
And now, if after the aforementioned steps, you still cannot find what is going on, try this. There is a program put out by Microsoft called Process Monitor. Go there and download the program and run it. It literally shows every process that your computer runs, so within seconds, the list will be populated with millions of entries. Needless to say, this can be a bit of a process. Run the program that keeps minimizing until it minimizes again. After it minimizing, click the button on Process Monitor to stop monitoring the processes so you don't get overrun with new processes. Then look at where your game or application stopped running and look at the processes immediately after that. It is more than likely that one of those first three or four programs to run thereafter will be your culprit, in my case the webcam suite. Things likes videocard suites or messenger programs are likely suspects. Try uninstalling and reinstalling stuff to see if it helps.
Anyway, I hope this helps. I was unable to find any useful help when I was encountering this problem, so I hope my post helps you find yours. Good luck!