From a1e5173c8d0bb12ebce1605efae349bfd06ff69a Mon Sep 17 00:00:00 2001 From: ikemo Date: Sun, 7 Dec 2003 08:40:10 +0000 Subject: [PATCH] KURL -> QString git-svn-id: svn+ssh://svn.sourceforge.jp/svnroot/kita/kita/trunk@642 56b19765-1e22-0410-a548-a0f45d66c51a --- kita/src/favoritelistview.cpp | 4 ++-- kita/src/kitasubjectview.cpp | 2 +- kita/src/libkita/tests/threadtest.cpp | 4 ++-- kita/src/libkita/thread.cpp | 10 +++++----- kita/src/libkita/thread.h | 2 +- kita/src/part/kitawritedialog.cpp | 2 +- 6 files changed, 12 insertions(+), 12 deletions(-) diff --git a/kita/src/favoritelistview.cpp b/kita/src/favoritelistview.cpp index 82c4861..032d2d2 100644 --- a/kita/src/favoritelistview.cpp +++ b/kita/src/favoritelistview.cpp @@ -132,7 +132,7 @@ void FavoriteListView::slotContextMenuRequested( QListViewItem* item, const QPoi Kita::Board board = Kita::Board( KURL( datURL, ".." ) ); kdDebug() << "board.url = " << board.url().url() << endl; Kita::Thread thread( board, datURL ); - kdDebug() << "thread.url = %s" << thread.url().url() << endl; + kdDebug() << "thread.url = %s" << thread.url() << endl; thread.setName( item->text( Row_Subject ) ); thread.setResNum( item->text( Row_Read ).toInt() ); @@ -146,7 +146,7 @@ void FavoriteListView::slotContextMenuRequested( QListViewItem* item, const QPoi emit signalShowThreadWithNewTab( thread ); break; case 2: - clipboard->setText( thread.name() + "\n" + thread.url().url() ); + clipboard->setText( thread.name() + "\n" + thread.url() ); break; default: break; diff --git a/kita/src/kitasubjectview.cpp b/kita/src/kitasubjectview.cpp index 994e3a8..c295464 100644 --- a/kita/src/kitasubjectview.cpp +++ b/kita/src/kitasubjectview.cpp @@ -282,7 +282,7 @@ void KitaSubjectView::slotContextMenuRequested( QListViewItem* item, const QPoin emit signalShowThreadWithNewTab( thread ); break; case 2: - clipboard->setText( thread.name() + "\n" + thread.url().url() ); + clipboard->setText( thread.name() + "\n" + thread.url() ); break; default: break; diff --git a/kita/src/libkita/tests/threadtest.cpp b/kita/src/libkita/tests/threadtest.cpp index aeba656..be8028a 100644 --- a/kita/src/libkita/tests/threadtest.cpp +++ b/kita/src/libkita/tests/threadtest.cpp @@ -41,9 +41,9 @@ void ThreadTest::testDatURL() void ThreadTest::testURL() { CPPUNIT_ASSERT_EQUAL( QString( "http://pc.2ch.net/test/read.cgi/linux/1069738960/"), - m_normal->url().url() ); + m_normal->url() ); CPPUNIT_ASSERT_EQUAL( QString( "http://pc.2ch.net/test/read.cgi/linux/1069738960/"), - m_noboard->url().url() ); + m_noboard->url() ); } void ThreadTest::testDatID() diff --git a/kita/src/libkita/thread.cpp b/kita/src/libkita/thread.cpp index 44c55ce..a0530ec 100644 --- a/kita/src/libkita/thread.cpp +++ b/kita/src/libkita/thread.cpp @@ -87,9 +87,9 @@ const KURL& Thread::datURL() const return m_datURL; } -const KURL Thread::url() const +const QString Thread::url() const { - return KURL( datToThread( m_datURL.url() ) ); + return datToThread( m_datURL.url() ); } const QString& Thread::datID() const @@ -173,7 +173,7 @@ bool Thread::test() if( thread.datURL().url() != "http://pc.2ch.net/linux/dat/1022744633.dat" ) { kdError() << "inValid: line=" << __LINE__ << endl; } - if( thread.url().url() != "http://pc.2ch.net/test/read.cgi/linux/1022744633/" ) { + if( thread.url() != "http://pc.2ch.net/test/read.cgi/linux/1022744633/" ) { kdError() << "inValid: line=" << __LINE__ << endl; } if( thread.name() != "2ch browser thread" ) { @@ -194,7 +194,7 @@ bool Thread::test() if( thread2.datURL().url() != "http://pc.2ch.net/linux/dat/1022744633.dat" ) { kdError() << "inValid: line=" << __LINE__ << endl; } - if( thread2.url().url() != "http://pc.2ch.net/test/read.cgi/linux/1022744633/" ) { + if( thread2.url() != "http://pc.2ch.net/test/read.cgi/linux/1022744633/" ) { kdError() << "inValid: line=" << __LINE__ << endl; } if( thread2.name() != "2ch browser thread" ) { @@ -225,7 +225,7 @@ bool Thread::test() if( thread.datURL().url() != "http://pc.2ch.net/linux/dat/1022744633.dat" ) { kdError() << "inValid: line=" << __LINE__ << endl; } - if( thread.url().url() != "http://pc.2ch.net/test/read.cgi/linux/1022744633/" ) { + if( thread.url() != "http://pc.2ch.net/test/read.cgi/linux/1022744633/" ) { kdError() << "inValid: line=" << __LINE__ << endl; } if( thread.name() != "2ch browser thread" ) { diff --git a/kita/src/libkita/thread.h b/kita/src/libkita/thread.h index 96cd2a5..f341144 100644 --- a/kita/src/libkita/thread.h +++ b/kita/src/libkita/thread.h @@ -45,7 +45,7 @@ namespace Kita { ~Thread(); Thread& operator=( const Thread& obj ); const KURL& datURL() const; - const KURL url() const; + const QString url() const; const QString& datID() const; int resNum() const; const QString& name() const; diff --git a/kita/src/part/kitawritedialog.cpp b/kita/src/part/kitawritedialog.cpp index fb3c395..06f1df9 100644 --- a/kita/src/part/kitawritedialog.cpp +++ b/kita/src/part/kitawritedialog.cpp @@ -123,7 +123,7 @@ KitaWriteDialog* KitaWriteDialog::open( const Kita::PostInfo& info, new_dlg->boardNameLabel->setText( thread.boardName() ); new_dlg->threadNameLabel->setText( thread.name() ); - new_dlg->threadURLLabel->setText( thread.url().url() ); + new_dlg->threadURLLabel->setText( thread.url() ); new_dlg->setCaption( i18n("Write in %1").arg( thread.name() ) ); return new_dlg; -- 2.11.0