Step 1: Spot the exact derivative:
The left side of the given equation is $x\sin x\,y' + (x\cos x + \sin x)y$. Since $\frac{d}{dx}(x\sin x) = x\cos x + \sin x$, this is $\frac{d}{dx}(xy\sin x)$.
Step 2: Integrate:
So $\frac{d}{dx}(xy\sin x) = \sin x$ and $xy\sin x = -\cos x + c$, i.e. $xy\sin x + \cos x = c$.
Final Answer:
The solution is option (D).
\[ \boxed{xy\sin x+\cos x=c} \]