+#ifndef FG_PANELNODE_HXX
+#define FG_PANELNODE_HXX
+
+
#include <plib/ssg.h>
class FGPanel;
// many methods, mostly involved with modelling and runtime
// inspection, are unimplemented.
+// Static mouse handler for all FGPanelNodes. Very clumsy; this
+// should really be done through our container (an aircraft model,
+// typically).
+bool fgHandle3DPanelMouseEvent(int button, int updown, int x, int y);
+void fgUpdate3DPanels();
+
class FGPanelNode : public ssgLeaf
{
protected:
virtual ~FGPanelNode();
virtual void draw();
- void mouseEvent(int button, int updown, int x, int y);
+ bool doMouseAction(int button, int updown, int x, int y);
+
+ FGPanel* getPanel() { return _panel; }
virtual void recalcBSphere() { bsphere_is_invalid = 0; }
// even know what many of them do, but they're pure virtual and
// require implementation.
//
- virtual int getNumTriangles() { die(); return 0; }
+ virtual int getNumTriangles() { return 0; }
virtual void getTriangle(int n, short* v1, short* v2, short* v3) { die(); }
virtual int getNumLines() { die(); return 0; }
virtual void getLine(int n, short* v1, short* v2) { die(); }
GLfloat _lastProjection[16];
GLint _lastViewport[4];
};
+
+
+#endif // FG_PANELNODE_HXX