Replaced remaining RefCounter derived classes with smart pointers and removed it