OSDN Git Service

refactoring.
authorikemo <ikemo@56b19765-1e22-0410-a548-a0f45d66c51a>
Wed, 5 May 2004 08:10:21 +0000 (08:10 +0000)
committerikemo <ikemo@56b19765-1e22-0410-a548-a0f45d66c51a>
Wed, 5 May 2004 08:10:21 +0000 (08:10 +0000)
git-svn-id: svn+ssh://svn.sourceforge.jp/svnroot/kita/kita/trunk@1026 56b19765-1e22-0410-a548-a0f45d66c51a

kita/src/favoritelistview.cpp
kita/src/kita.cpp
kita/src/kitasubjecttabwidget.cpp
kita/src/kitasubjecttabwidget.h
kita/src/kitasubjectview.cpp
kita/src/threadlistview.cpp
kita/src/threadlistview.h

index 14b668e..e98ee9f 100644 (file)
@@ -93,7 +93,7 @@ void FavoriteListView::loadThread( QListViewItem* item )
         const Kita::Thread* thread = Kita::Thread::getByURL( *it );
 
         if ( thread->datURL() == item->text( Col_DatURL ) ) {
-            emit showThreadRequested( thread, false );
+            emit showThreadRequested( thread->datURL(), false );
         }
     }
 }
@@ -131,7 +131,7 @@ void FavoriteListView::slotContextMenuRequested( QListViewItem* item, const QPoi
         KRun::runURL( thread->url(), "text/html" );
         break;
     case 1:
-        emit showThreadRequested( thread, true );
+        emit showThreadRequested( thread->datURL(), true );
         break;
     case 2:
         clipboard->setText( thread->name() + "\n" + thread->url() );
index 997eed4..90002c8 100644 (file)
@@ -95,8 +95,8 @@ KitaMainWindow::KitaMainWindow()
     connect( m_boardView, SIGNAL( openBoardRequested( const QString&, bool ) ),
              m_subjectTab, SLOT( loadBoard( const QString&, bool ) ) );
 
-    connect( m_subjectTab, SIGNAL( showThreadRequested( const Kita::Thread*, bool ) ),
-             m_threadTab, SLOT( showThread( const Kita::Thread*, bool ) ) );
+    connect( m_subjectTab, SIGNAL( showThreadRequested( const QString&, bool ) ),
+             m_threadTab, SLOT( showThread( const QString&, bool ) ) );
 
     connect( m_threadTab, SIGNAL( thread( const Kita::Thread* ) ),
              m_subjectTab, SLOT( updateThread( const Kita::Thread* ) ) );
index b54dbe4..d69a2d1 100644 (file)
@@ -88,8 +88,8 @@ void KitaSubjectTabWidget::updateThread( const Kita::Thread* thread )
 
 void KitaSubjectTabWidget::connectSignals( Kita::ThreadListView* view )
 {
-    connect( view, SIGNAL( showThreadRequested( const Kita::Thread*, bool ) ),
-             this, SIGNAL( showThreadRequested( const Kita::Thread*, bool ) ) );
+    connect( view, SIGNAL( showThreadRequested( const QString&, bool ) ),
+             this, SIGNAL( showThreadRequested( const QString&, bool ) ) );
 }
 
 KitaSubjectView* KitaSubjectTabWidget::findView( const QString& boardURL )
index a4a8de5..5d39e0a 100644 (file)
@@ -45,7 +45,7 @@ private slots:
     void deleteView( KitaSubjectView* view );
 
 signals:
-    void showThreadRequested( const Kita::Thread*, bool withNewTab );
+    void showThreadRequested( const QString&, bool withNewTab );
     void loadBoardCompleted( const KURL& );
 };
 
index 08e272a..a37e8d6 100644 (file)
@@ -83,9 +83,9 @@ void KitaSubjectView::loadThread( QListViewItem* item )
     Kita::Thread* thread = Kita::Thread::getByURL( datURL.url() );
 
     if ( KitaConfig::alwaysUseTab() ) {
-        emit showThreadRequested( thread, true );
+        emit showThreadRequested( thread->datURL(), true );
     } else {
-        emit showThreadRequested( thread, false );
+        emit showThreadRequested( thread->datURL(), false );
     }
 }
 /*
@@ -236,7 +236,7 @@ void KitaSubjectView::slotContextMenuRequested( QListViewItem* item, const QPoin
         KRun::runURL( thread->url(), "text/html" );
         break;
     case 1:
-        emit showThreadRequested( thread, true );
+        emit showThreadRequested( thread->datURL(), true );
         break;
     case 2:
         clipboard->setText( thread->name() + "\n" + thread->url() );
index ac54b06..9292c10 100644 (file)
@@ -157,13 +157,13 @@ void ThreadListView::slotMouseButtonClicked( int button, QListViewItem* item )
 
     switch ( button ) {
     case MidButton:
-        emit showThreadRequested( thread, true );
+        emit showThreadRequested( thread->datURL(), true );
         break;
     case LeftButton:
         if ( KitaConfig::alwaysUseTab() ) {
-            emit showThreadRequested( thread, true );
+            emit showThreadRequested( thread->datURL(), true );
         } else {
-            emit showThreadRequested( thread, false );
+            emit showThreadRequested( thread->datURL(), false );
         }
         break;
     }
index 741f3f4..ce3814e 100644 (file)
@@ -61,9 +61,9 @@ namespace Kita
     
     signals:
         /**
-        * @param thread É½¼¨¤¹¤ë¥¹¥ì
+        * @param datURL É½¼¨¤¹¤ë¥¹¥ì¤Îdat¤ÎURL
         */
-        void showThreadRequested( const Kita::Thread* thread, bool withNewTab );
+        void showThreadRequested( const QString& datURL, bool withNewTab );
     };
 
     class ThreadListViewItem : public KListViewItem