Modified Files:
Makefile.am SGPickCallback.hxx: add proirities for pick callbacks.
This commit is contained in:
@@ -5,15 +5,15 @@ lib_LIBRARIES = libsgutil.a
|
|||||||
noinst_HEADERS =
|
noinst_HEADERS =
|
||||||
|
|
||||||
include_HEADERS = \
|
include_HEADERS = \
|
||||||
SGNodeMasks.hxx \
|
|
||||||
SGUpdateVisitor.hxx \
|
|
||||||
SGEnlargeBoundingBox.hxx \
|
|
||||||
SGDebugDrawCallback.hxx \
|
SGDebugDrawCallback.hxx \
|
||||||
|
SGEnlargeBoundingBox.hxx \
|
||||||
|
SGNodeMasks.hxx \
|
||||||
SGPickCallback.hxx \
|
SGPickCallback.hxx \
|
||||||
SGSceneFeatures.hxx \
|
SGSceneFeatures.hxx \
|
||||||
SGSceneUserData.hxx \
|
SGSceneUserData.hxx \
|
||||||
SGStateAttributeVisitor.hxx \
|
SGStateAttributeVisitor.hxx \
|
||||||
SGTextureStateAttributeVisitor.hxx \
|
SGTextureStateAttributeVisitor.hxx \
|
||||||
|
SGUpdateVisitor.hxx \
|
||||||
RenderConstants.hxx \
|
RenderConstants.hxx \
|
||||||
StateAttributeFactory.hxx \
|
StateAttributeFactory.hxx \
|
||||||
VectorArrayAdapter.hxx
|
VectorArrayAdapter.hxx
|
||||||
|
|||||||
@@ -30,11 +30,21 @@
|
|||||||
// The interface is still under development
|
// The interface is still under development
|
||||||
class SGPickCallback : public SGReferenced {
|
class SGPickCallback : public SGReferenced {
|
||||||
public:
|
public:
|
||||||
|
enum Priority {
|
||||||
|
PriorityGUI = 0,
|
||||||
|
PriorityPanel = 1,
|
||||||
|
PriorityOther = 2
|
||||||
|
};
|
||||||
|
|
||||||
struct Info {
|
struct Info {
|
||||||
SGVec3d wgs84;
|
SGVec3d wgs84;
|
||||||
SGVec3d local;
|
SGVec3d local;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
SGPickCallback(Priority priority = PriorityOther) :
|
||||||
|
_priority(priority)
|
||||||
|
{ }
|
||||||
|
|
||||||
virtual ~SGPickCallback() {}
|
virtual ~SGPickCallback() {}
|
||||||
virtual bool buttonPressed(int button, const Info& info)
|
virtual bool buttonPressed(int button, const Info& info)
|
||||||
{ return false; }
|
{ return false; }
|
||||||
@@ -42,6 +52,12 @@ public:
|
|||||||
{ }
|
{ }
|
||||||
virtual void buttonReleased(void)
|
virtual void buttonReleased(void)
|
||||||
{ }
|
{ }
|
||||||
|
|
||||||
|
Priority getPriority() const
|
||||||
|
{ return _priority; }
|
||||||
|
|
||||||
|
private:
|
||||||
|
Priority _priority;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct SGSceneryPick {
|
struct SGSceneryPick {
|
||||||
|
|||||||
Reference in New Issue
Block a user