1 /* 2 * Copyright 2009, Alexandre Deckner, alex@zappotek.com 3 * Distributed under the terms of the MIT License. 4 */ 5 #ifndef DRAG_TRACKING_FILTER_H 6 #define DRAG_TRACKING_FILTER_H 7 8 #include <MessageFilter.h> 9 #include <Point.h> 10 11 class BView; 12 class BHandler; 13 14 namespace BPrivate { 15 16 class DragTrackingFilter : public BMessageFilter { 17 public: 18 DragTrackingFilter(BView* targetView, uint32 messageWhat); 19 20 filter_result Filter(BMessage* message, BHandler** _target); 21 22 private: 23 BView* fTargetView; 24 uint32 fMessageWhat; 25 bool fIsTracking; 26 BPoint fClickPoint; 27 uint32 fClickButtons; 28 }; 29 30 } // namespace BPrivate 31 32 using BPrivate::DragTrackingFilter; 33 34 #endif // DRAG_TRACKING_FILTER_H 35