Perhaps I'm wrong (and someone will correct me) but hasn't the Catholic church always held thought as well as action to be within its domain? Haven't they always held the position that to think about something is the same as doing it?I can't speak for the Catholic Church, but I can speak more generally to standard Christian theology.
To understand the question it's important to differentiate between two different actions that often both fall under the umbrella of "thought". Simply put, the main factor to consider is that some thoughts are voluntary and some are not. Voluntary thoughts that dwell on a particular evil are, themselves, evil; involuntary thoughts that speed through our minds before being rejected are not evil alone, but are temptations that may lead us to evil.
Consider the classic passage on the topic; Jesus raises the bar and teaches that keeping the letter of the law isn't sufficient for godliness:
Matthew 5:27-28(Set aside the question of whether an unmarried person can commit "adultery" with another unmarried person.) The point Jesus is making is that it's not only our actions that are important, but also our thoughts and intentions. Good intentions cannot make up for evil acts (although they may, arguably, mitigate them), but bad intentions can certainly corrupt good actions.
"You have heard that it was said, 'Do not commit adultery.' But I tell you that anyone who looks at a woman lustfully has already committed adultery with her in his heart."
Every man has inescapable moments of attraction to beautiful women he sees, but those moments on their own don't constitute "lust". Lust isn't the first glance; lust is when you turn your head to follow your eyes and imagine what it would be like to have sex with the woman you're watching. (This explanation will fit analogously to other sins, as well.)
One common misapplication of this principle is the thought that: "If lust is as bad as adultery, I may as well go all the way!" However, it should be clear that actual adultery will almost always have much more severe temporal consequences than will lust. Adultery destroys families and lives more easily and quickly than "mere" lust does. Both are equally wrong, but past commission of one does not excuse the other.