00001 /*========================================================================= 00002 00003 Program: Medical Imaging & Interaction Toolkit 00004 Language: C++ 00005 Date: $Date$ 00006 Version: $Revision$ 00007 00008 Copyright (c) German Cancer Research Center, Division of Medical and 00009 Biological Informatics. All rights reserved. 00010 See MITKCopyright.txt or https://www.mitk.org/copyright.html for details. 00011 00012 This software is distributed WITHOUT ANY WARRANTY; without even 00013 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 00014 PURPOSE. See the above copyright notices for more information. 00015 00016 =========================================================================*/ 00017 00018 00019 #ifndef DISPLAYPOSITIONEVENT_H_HEADER_INCLUDED_C184F366 00020 #define DISPLAYPOSITIONEVENT_H_HEADER_INCLUDED_C184F366 00021 00022 #include "mitkCommon.h" 00023 #include "mitkEvent.h" 00024 #include "mitkVector.h" 00025 #include "mitkDataNode.h" 00026 00027 00028 namespace mitk { 00029 00041 class MITK_CORE_EXPORT DisplayPositionEvent : public Event 00042 { 00043 public: 00050 DisplayPositionEvent(BaseRenderer* sender, int type, int button, int buttonState, int key, const Point2D& displPosition); 00051 00052 const Point2D& GetDisplayPosition() const 00053 { 00054 return m_DisplayPosition; 00055 } 00056 00057 void SetDisplayPosition(const Point2D& displPosition) { m_DisplayPosition = displPosition; } 00058 00059 const Point3D& GetWorldPosition() const; 00060 00062 mitk::DataNode *GetPickedObjectNode() const; 00063 00065 mitk::BaseData *GetPickedObject() const; 00066 00067 00068 protected: 00069 Point2D m_DisplayPosition; 00070 mutable Point3D m_WorldPosition; 00071 mutable bool m_WorldPositionIsSet; 00072 00073 mutable mitk::DataNode::Pointer m_PickedObjectNode; 00074 mutable bool m_PickedObjectIsSet; 00075 }; 00076 00077 typedef DisplayPositionEvent MouseEvent; 00078 00079 } // namespace mitk 00080 00081 #endif /* DISPLAYPOSITIONozsiEVENT_H_HEADER_INCLUDED_C184F366 */