{
setXMLFile( "threadtabwidgetui.rc" );
- connectSignals();
setupActions();
/* default view */
KitaThreadTabWidget::~KitaThreadTabWidget() {}
-
/* show "Main thread" view */ /* public slots */
void KitaThreadTabWidget::slotShowMainThread( const KURL& url )
{
return view;
}
-
-/* private */
-void KitaThreadTabWidget::connectSignals()
-{
- Kita::SignalCollection * signalCollection = Kita::SignalCollection::getInstance();
-
- connect( signalCollection, SIGNAL( updateThreadTab( const KURL& ) ),
- this, SLOT( slotUpdateThreadTab( const KURL& ) ) );
- connect( signalCollection, SIGNAL( threadFaceChanged() ),
- SLOT( slotFontChanged() ) );
-}
-
-
/* private */
KitaThreadView* KitaThreadTabWidget::findMainView( const KURL& url )
{
KitaTabWidgetBase::deleteWidget( w );
if ( count() == 0 ) {
- emit setMainCaption( QString::null );
+ ViewMediator::getInstance()->setMainCaption( QString::null );
ViewMediator::getInstance()->setMainStatusBar( QString::null );
ViewMediator::getInstance()->setMainURLLine( QString::null );
KitaThreadView * view = isThreadView( currentPage() );
if ( view ) view->slotDeleteButtonClicked();
}
-
-
-/*---------------------------------------------------------------------*/
-/*---------------------------------------------------------------------*/
-/*---------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------*/
-/*---------------------------------------------------------------------*/
-/*---------------------------------------------------------------------*/
-
-
-/* Don't forget to call setup later ! */
-KitaThreadDock::KitaThreadDock( KDockManager* dockManager,
- const char* name,
- const QPixmap &pixmap,
- QWidget* parent,
- const QString& strCaption,
- const QString& strTabPageLabel,
- WFlags f )
- : KitaDockWidgetBase( dockManager, name, pixmap, parent, strCaption, strTabPageLabel, f ) {}
-
-
-KitaThreadDock::~KitaThreadDock() {}
-
-
-/*-----------------------------*/
-/* Main Thread View */
-
-/* setup thig dock as main thread view */ /* public */
-KitaThreadTabWidget* KitaThreadDock::setupAsMainView()
-{
- m_threadTab = new KitaThreadTabWidget( this, "Thread View" );
- setWidget( m_threadTab );
-
- return m_threadTab;
-}
-
-/* public slot */
-void KitaThreadDock::slotShowThread( const KURL& url )
-{
- showDock();
-
- if ( m_threadTab ) m_threadTab->slotShowMainThread( url );
-}
-
-/* show Thread Dock */ /* private slot */
-void KitaThreadDock::slotShowThreadDock()
-{
- QWidget * topWidget = topLevelWidget();
- if ( topWidget->isMinimized() ) topWidget->showNormal();
- topWidget->raise();
- topWidget->setActiveWindow();
-
- slotShowDock();
-}