From b9c3377d8865c3da98171a2538b0df3b9d5839ed Mon Sep 17 00:00:00 2001 From: Robert Osfield Date: Fri, 24 Jun 2016 12:11:09 +0100 Subject: [PATCH] Added initializers --- include/osgGA/Device | 5 +++-- src/osgGA/Device.cpp | 9 +++++---- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/include/osgGA/Device b/include/osgGA/Device index 4f364ead6..6e2c084c1 100644 --- a/include/osgGA/Device +++ b/include/osgGA/Device @@ -24,11 +24,12 @@ namespace osgGA { class OSGGA_EXPORT Device : public osg::Object { public: - enum { + enum Capabilities + { UNKNOWN = 0, RECEIVE_EVENTS = 1, SEND_EVENTS = 2 - } Capabilities; + }; Device(); Device(const Device& es, const osg::CopyOp& copyop); diff --git a/src/osgGA/Device.cpp b/src/osgGA/Device.cpp index 552be3318..b7acf95de 100644 --- a/src/osgGA/Device.cpp +++ b/src/osgGA/Device.cpp @@ -15,15 +15,16 @@ using namespace osgGA; -Device::Device() - : osg::Object() - , _capabilities(UNKNOWN) +Device::Device(): + osg::Object(), + _capabilities(UNKNOWN) { setEventQueue(new EventQueue); } Device::Device(const Device& es, const osg::CopyOp& copyop): - osg::Object(es,copyop) + osg::Object(es,copyop), + _capabilities(es._capabilities) { setEventQueue(new EventQueue); }