ViewBase *SplitterView::findView( const QPoint &pos ) const { for ( int i = 0; i < m_splitter->count(); ++i ) { ViewBase *w = dynamic_cast<ViewBase*>( m_splitter->widget( i ) ); if ( w && w->frameGeometry().contains( pos ) ) { kDebug(planDbg())<<pos<<" in "<<w->frameGeometry(); return w; } QTabWidget *tw = dynamic_cast<QTabWidget*>( m_splitter->widget( i ) ); if (tw && tw->frameGeometry().contains( pos ) ) { w = dynamic_cast<ViewBase*>( tw->currentWidget() ); if ( w ) { kDebug(planDbg())<<pos<<" in "<<w->frameGeometry(); return w; } } } return const_cast<SplitterView*>( this ); }