Integration by parts (just to simplify the evaluation) gives $$\int_0^\infty\frac{\sinh ax\sinh bx}{(\cosh ax+\cos t)^2}\,dx=\frac{b}{a}\int_0^\infty\frac{\cosh bx\,dx}{\cosh ax+\cos t}.$$ This can be evaluated using the residue theorem. Consider $I_R=\displaystyle\int_{C_R}\frac{e^{bz}\,dz}{\cosh az-\cos t}$ where $C_R$ is the rectangular contour with vertices at $\pm R\pm i\pi/a$; the integrand has simple poles at $z=\pm it/a$, thus $$I_R=2\pi i\left(\operatorname*{Res}_{z=it/a}+\operatorname*{Res}_{z=-it/a}\right)\frac{e^{bz}}{\cosh az-\cos t}=\frac{4\pi i}{a}\frac{\sin(bt/a)}{\sin t},$$ and on the other hand, $\lim\limits_{R\to\infty}I_R$ is equal to $$\int_{-\infty}^\infty\frac{e^{b(x-i\pi/a)}\,dx}{-\cosh ax-\cos t}+\int_\infty^{-\infty}\frac{e^{b(x+i\pi/a)}\,dx}{-\cosh ax-\cos t}=4i\sin\frac{b\pi}{a}\int_0^\infty\frac{\cosh bx\,dx}{\cosh ax+\cos t}.$$
I will concentrate on this part of your proof, the calculation of this integral (the other steps of your proof are correct):
$$\int_{0}^{\infty} \frac{\Big|\sin\left(x+\frac{\pi}{4}\right)\Big| - \Big|\sin\left(x-\frac{\pi}{4}\right)\Big|}{x} dx$$
We will make use of the Lobachevsky integral formula:
Let $f(x)$ a $\pi$-periodic function (continous or integrable over its period). with
$\displaystyle f(x+\pi) = f(x)$ and $f(\pi-x) = f(x)$, for $0\leq x <\infty$. Then
$\displaystyle \int_{0}^{\infty} \frac{\sin x}{x} f(x) dx = \int_{0}^{\frac{\pi}{2}} f(x) dx. $
Now, for your integral:
If you make the change of variable $\displaystyle x=\frac{w}{2}$
$\displaystyle I=\int_{0}^{\infty} \frac{\Big|\sin\left(x+\frac{\pi}{4}\right)\Big| - \Big|\sin\left(x-\frac{\pi}{4}\right)\Big|}{x} dx = \int_{0}^{\infty} \frac{\Big|\sin\left(\frac{w}{2}+\frac{\pi}{4}\right)\Big| - \Big|\sin\left(\frac{w}{2}-\frac{\pi}{4}\right)\Big|}{w} dw $
Multiplying and dividing by $\sin w$:
$$I= \int_{0}^{\infty} \frac{\sin w}{w} \frac{\Big|\sin\left(\frac{w}{2}+\frac{\pi}{4}\right)\Big| - \Big|\sin\left(\frac{w}{2}-\frac{\pi}{4}\right)\Big|}{\sin w} dw$$
The function
$$f(w) = \frac{\Big|\sin\left(\frac{w}{2}+\frac{\pi}{4}\right)\Big| - \Big|\sin\left(\frac{w}{2}-\frac{\pi}{4}\right)\Big|}{\sin w}$$
is $\pi$-periodic
By the Lobachevsky integral formula:
$$\displaystyle I=\int_{0}^{\infty} \frac{\sin w}{w} \frac{\Big|\sin\left(\frac{w}{2}+\frac{\pi}{4}\right)\Big| - \Big|\sin\left(\frac{w}{2}-\frac{\pi}{4}\right)\Big|}{\sin w} dw = \int_{0}^{\frac{\pi}{2}}\frac{\Big|\sin\left(\frac{w}{2}+\frac{\pi}{4}\right)\Big| - \Big|\sin\left(\frac{w}{2}-\frac{\pi}{4}\right)\Big|}{\sin w}dw $$
Note that for $w\in\left(0,\frac{\pi}{2}\right)$
$$\Big|\sin\left(\frac{w}{2}+\frac{\pi}{4}\right)\Big|= \sin\left(\frac{w}{2}+\frac{\pi}{4}\right)$$
$$\Big|\sin\left(\frac{w}{2}-\frac{\pi}{4}\right)\Big|= -\sin\left(\frac{w}{2}-\frac{\pi}{4}\right)$$
Hence
$$\displaystyle\Big|\sin\left(\frac{w}{2}+\frac{\pi}{4}\right)\Big| - \Big|\sin\left(\frac{w}{2}-\frac{\pi}{4}\right)\Big| = \sqrt{2}\sin\left(\frac{w}{2}\right)\displaystyle $$
Therefore
$$ I = \int_{0}^{\frac{\pi}{2}}\frac{\Big|\sin\left(\frac{w}{2}+\frac{\pi}{4}\right)\Big| - \Big|\sin\left(\frac{w}{2}-\frac{\pi}{4}\right)\Big|}{\sin w}dw = \sqrt{2}\int_{0}^{\frac{\pi}{2}}\frac{\sin\left(\frac{w}{2}\right)}{\sin w}dw$$
Using $\displaystyle \frac{\sin\left(\frac{w}{2}\right)}{\sin w} = \frac{1}{2}\sec\left(\frac{w}{2}\right)$
we have
$$I = \sqrt{2}\int_{0}^{\frac{\pi}{2}}\frac{\sin\left(\frac{w}{2}\right)}{\sin w}dw = \frac{\sqrt{2}}{2}\int_{0}^{\frac{\pi}{2}} \sec\left(\frac{w}{2} \right)dw = \sqrt{2} \operatorname{arctanh}\left(\frac{1}{\sqrt{2}}\right)$$
We can conclude
$$\boxed{\int_{0}^{\infty} \frac{\Big|\sin\left(x+\frac{\pi}{4}\right)\Big| - \Big|\sin\left(x-\frac{\pi}{4}\right)\Big|}{x} dx = \sqrt{2} \operatorname{arctanh}\left(\frac{1}{\sqrt{2}}\right)}$$
Therefore
$$\boxed{\int_{-\infty}^0 \max\left(\frac{\cos(x)}{x},\frac{\sin(x)}{x}\right)dx+ \int_0^\infty \min\left(\frac{\cos(x)}{x},\frac{\sin(x)}{x}\right)dx = \frac{\pi}{2} +\operatorname{arctanh}\left(\frac{1}{\sqrt{2}}\right)} $$
Some numerical approximations from Wolfram:
The sum is 2.44206
while
$$\frac{\pi}{2} + \operatorname{arctanh}\left(\frac{1}{\sqrt{2}}\right)\approx 2.45216..$$
Best Answer
Because the function is periodic, the integral over any interval of length $2 \pi$ leads to the same result. With that said, rewrite this as $$ \int_{\pi/4}^{9 \pi /4} f(x)\,dx = \int_{\pi/4}^{5\pi/4} f(x)\,dx + \int_{5 \pi/4}^{9\pi/4} f(x)\,dx\\ = \int_{\pi/4}^{5 \pi/4} \frac{\cos(x)}{e^{\sin(x)}}\,dx + \int_{\pi/4}^{5 \pi/4} \frac{\sin(x)}{e^{\cos(x)}}\,dx\\ = \int_{\pi/4}^{5 \pi/4} e^{- \sin(x)}\cos(x)\,dx + \int_{\pi/4}^{5 \pi/4} e^{- \cos(x)}\sin(x)\,dx. $$ The integrals can be handled separately, via $u$-substitution.