[IMAPx] Prefer graceful IDLE stop than forced reconnect
[IMAPx] Prefer graceful IDLE stop than forced reconnect

There still was an issue with stopping IDLE, the code could have run IDLE
in the preparation, like selecting the right folder, when it received
a request to stop IDLE and start other command. As the preparation was
not distinguished properly two commands could interleave and cause issues.
When in it, the IDLE stop had been done to stop it gracefully, instead
of disconnect the connection when in the middle of some command. It
should make things quicker (reconnect is slow), especially when the connection
is not stale.

tintou/evolution-data-server,matzipan/evolution-data-server,matzipan/evolution-data-server,matzipan/evolution-data-server,tintou/evolution-data-server,matzipan/evolution-data-server,matzipan/evolution-data-server,tintou/evolution-data-server,tintou/evolution-data-server