Make the DeviceManager a reference-counted instance
commit9d5dd392f7cf0e9fadf20596add7650a5f7524ae
authorChris Robinson <chris.kcat@gmail.com>
Tue, 28 Nov 2017 01:18:36 +0000 (27 17:18 -0800)
committerChris Robinson <chris.kcat@gmail.com>
Tue, 28 Nov 2017 01:18:36 +0000 (27 17:18 -0800)
treef89b5e3ed31f5b72a6bb40378c91d42d79cb12aa
parente2a402db477e5af3a597e5bf0e35895e123f9045
Make the DeviceManager a reference-counted instance

The DeviceManager is destructed when all user-held instance go out of scope
(are deleted). A WeakPtr is maintained for DeviceManager::getInstance() to
return the same instance as long as there's a pre-existing instance.
examples/alure-dumb.cpp
examples/alure-enum.cpp
examples/alure-hrtf.cpp
examples/alure-physfs.cpp
examples/alure-play.cpp
examples/alure-reverb.cpp
examples/alure-stream.cpp
include/AL/alure2.h
src/device.cpp
src/devicemanager.cpp
src/devicemanager.h