The TextEdit behavior might actually be the OS silently closing an unused application that implements the necessary hooks for saving state and indicating when clean-up is required on termination. That behavior was introduced in 10.7, but IIRC, can be disabled by the user.