-// dragEnterEvent and dragLeaveEvent are needed to keep track of the active
-// view when customizing them via drag and drop
-void BufferView::dragEnterEvent(QDragEnterEvent *event) {
- emit dragEnter();
- QTreeView::dragEnterEvent(event);
+void BufferView::select(const QModelIndex ¤t) {
+ emit selectionChanged(current, QItemSelectionModel::ClearAndSelect);
+}
+
+void BufferView::dropEvent(QDropEvent *event) {
+ if(event->source() != this) {
+ // another view(?) or widget is the source. maybe it's a drag 'n drop
+ // view customization -> we tell our friend the filter:
+ emit eventDropped(event);
+ }
+ // in the case that the filter did not accept the event or if it's a merge
+ QTreeView::dropEvent(event);