Fixed enums for older compilers.
Added a missing destructor.