Split TLS callbacks into a data callback and an alert callback.

In practice applications treated these two cases completely differently,
so there was no reason to combine them into a single callback.