On the Thermodynamic Stability of Confined Thin Films Under Shear