It's an especially impatient way to say, "What are you doing?"
"To be up to something" means to be preparing something in order to cause problems for somebody else, usually in secret. "What's he up to?" is a question you might ask if someone is acting a bit strangely, or has locked himself in his workshop or something, and you suspect that he is preparing something that will cause a nasty surprise for somebody. A few days ago, my wife said she thought it very suspicious that President Bush hadn't said anything for a long time -- she wondered what he was up to, perhaps looking for a new country to invade.
"What do you think...?" is a way of asking a question and at the same time forbidding the person to do what he was hoping to do. It's saying: "You may think you are doing X, but you're mistaken because I am going to stop you." You hear this construction quite a lot: "What do you think you're doing?" -- "Where do you think you're going" etc.
So the whole sentence means something like this: "I know you are planning something that you shouldn't be planning, and I am going to stop you doing it -- but what are you doing?" All that in just one short question.
You'll most often hear parents saying this to their children, or wives to their husbands.