Refactored the handling of ComboBox item picking to make it faster and more reliable

git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14433 16af8721-9629-0410-8352-f15c8da7e697
This commit is contained in:
Robert Osfield
2014-09-02 17:01:44 +00:00
parent 959d78f755
commit 1e9722601c
2 changed files with 26 additions and 57 deletions

View File

@@ -74,7 +74,7 @@ public:
void setCurrentIndex(unsigned int i);
unsigned int getCurrentIndex() const { return _currentIndex; }
virtual void currrentIndexChanged(unsigned int i);
virtual void currentIndexChangedImplementation(unsigned int i);
@@ -87,8 +87,10 @@ public:
protected:
virtual ~ComboBox() {}
Items _items;
unsigned int _currentIndex;
Items _items;
unsigned int _currentIndex;
osg::Vec3d _popupItemOrigin;
osg::Vec3d _popupItemSize;
osg::ref_ptr<osg::Switch> _buttonSwitch;
osg::ref_ptr<osg::Switch> _backgroundSwitch;