Interesting thread... typically the issue is users who click on the "ok" button on those malware pop-ups rather than dismiss them. Secondarily is the use of Windows and IE, which top all OS's in security holes.. it's just flat out easier to exploit than a *nix environment like Mac and Linux.
Anyway I've had Java installed on my PCs continuously since it was invented... never had a virus/trojan using it. Vid's point is fine, if you don't need java, uninstall it. Flash on the other hand is flawed bloatware... good riddance.