If the object is not moving then the resultant force must be equal to 0.
Resolving the forces horizontally:
As there is no horizontal force on the mass then that is equal to 0
Again, as there is no overall force these two are equal
To find T1 and T2 solve the simultaneous equations