There are 2 'famous' Targums. One (the one you're referring to in the question) is known as Targum Yonasan. This is a bit of a 'loose' translation, oftentimes giving explanations in addition to simply translating the words. The Gemara is referring to that Targum, which G-D wanted to remain hidden.
Another Targum (and this is arguably the more famous one, as it's the version that appears on the side of most Chumashim) is known as Targum Onkelos, or more commonly simply Targum. Targum Onkelos is (for the most part) simply a translation of the words into Aramaic, so it can cover the entire Tanach without fear of it revealing 'hidden meanings'.
The Targum on Psalms was likely written by Onkelos together with the rest of his Targum on Tanach. While the Second Temple was standing for the first 35 years of his life, it was not likely that Onkelos wrote his translation while the Temple was still standing.
Additionally, a few lines later in that Gemara (Megilla 3a), it writes that the Aramaic translation was given at Sinai as well, but it was forgotten and then 'reintroduced' by Onkelos. So there likely was a translation prior to the destruction of the Second Temple (before it was forgotten), although I don't know how far back it was that it was forgotten.