修订版 | 2fb6dc935ea9d7dab59609afc9234a08bc1b67f3 (tree) |
---|---|
时间 | 2007-08-08 01:19:03 |
作者 | ikemo <ikemo@56b1...> |
Commiter | ikemo |
remove unused? code.
git-svn-id: svn+ssh://svn.sourceforge.jp/svnroot/kita/kita/trunk@2067 56b19765-1e22-0410-a548-a0f45d66c51a
@@ -93,37 +93,6 @@ void KitaTabWidgetBase::slotCurrentChanged( QWidget * w ) | ||
93 | 93 | } |
94 | 94 | |
95 | 95 | |
96 | -/* show url with part. */ /* public slot */ | |
97 | -void KitaTabWidgetBase::slotShowPart( const KURL& url, const QString& libName, const QString& mimetype ) | |
98 | -{ | |
99 | - if ( m_manager == NULL ) return ; | |
100 | - | |
101 | - KLibFactory *factory = KLibLoader::self() ->factory( libName ); | |
102 | - if ( !factory ) { | |
103 | - QMessageBox::critical( parentWidget(), i18n( " Load Error" ), | |
104 | - QString( i18n( "can't load %1." ) ).arg( libName ) ); | |
105 | - return ; | |
106 | - } | |
107 | - | |
108 | - if ( factory->inherits( "KParts::Factory" ) ) { | |
109 | - KParts::Part * part | |
110 | - = static_cast< KParts::Factory* >( factory ) ->createPart( this ); | |
111 | - m_manager->addPart( part ); | |
112 | - addTab( part->widget(), url.url() ); | |
113 | - showPage( part->widget() ); | |
114 | - setTabToolTip( currentPage(), url.url() ); | |
115 | - | |
116 | - KParts::BrowserExtension *ext = KParts::BrowserExtension::childObject( part ); | |
117 | - if ( ext ) { | |
118 | - KParts::URLArgs arg( FALSE, 0, 0, mimetype ); | |
119 | - ext->setURLArgs( arg ); | |
120 | - } | |
121 | - | |
122 | - static_cast<KParts::ReadOnlyPart*>( part ) ->openURL( url ); | |
123 | - } | |
124 | -} | |
125 | - | |
126 | - | |
127 | 96 | /* close num-th tab */ |
128 | 97 | /* see also customEvent */ /* public slot */ |
129 | 98 | void KitaTabWidgetBase::slotCloseTab( int num ) |
@@ -58,7 +58,6 @@ public: | ||
58 | 58 | |
59 | 59 | public slots: |
60 | 60 | void slotCurrentChanged( QWidget* w ); |
61 | - void slotShowPart( const KURL&, const QString&, const QString& ); | |
62 | 61 | void slotCloseTab( int num ); |
63 | 62 | |
64 | 63 |
@@ -220,27 +220,6 @@ void KitaThreadTabWidget::setupActions() | ||
220 | 220 | { |
221 | 221 | KStdAction::copy( this, SLOT( slotCopyText() ), actionCollection() ); |
222 | 222 | |
223 | - new KAction( i18n( "Open with Web Browser" ), | |
224 | - 0, | |
225 | - this, | |
226 | - SLOT( slotOpenBrowser() ), | |
227 | - actionCollection(), | |
228 | - "threadview_openbrowser" ); | |
229 | - | |
230 | - new KAction( i18n( "copy URL" ), | |
231 | - 0, | |
232 | - this, | |
233 | - SLOT( slotCopyURL() ), | |
234 | - actionCollection(), | |
235 | - "threadview_copyurl" ); | |
236 | - | |
237 | - new KAction( i18n( "Copy title and URL" ), | |
238 | - 0, | |
239 | - this, | |
240 | - SLOT( slotCopyTitleURL() ), | |
241 | - actionCollection(), | |
242 | - "threadview_copytitleurl" ); | |
243 | - | |
244 | 223 | new KAction( i18n( "Find" ), |
245 | 224 | "find", |
246 | 225 | KStdAccel::find(), |
@@ -324,70 +303,6 @@ void KitaThreadTabWidget::slotCopyText() | ||
324 | 303 | } |
325 | 304 | } |
326 | 305 | |
327 | -/* public slot */ | |
328 | -void KitaThreadTabWidget::slotOpenBrowser( int idx ) | |
329 | -{ | |
330 | - QWidget * w = currentPage(); | |
331 | - if ( idx != -1 ) w = page( idx ); | |
332 | - KURL url; | |
333 | - | |
334 | - if ( w ) { | |
335 | - | |
336 | - KitaThreadView * view = isThreadView( w ); | |
337 | - if ( view ) { | |
338 | - new KRun( view->threadURL() ); | |
339 | - return ; | |
340 | - } | |
341 | - | |
342 | - KParts::Part* part = findPartFromWidget( w ); | |
343 | - if ( part && part->inherits( "KParts::ReadOnlyPart" ) ) { | |
344 | - url = static_cast<KParts::ReadOnlyPart*>( part ) ->url(); | |
345 | - new KRun( url ); | |
346 | - return ; | |
347 | - } | |
348 | - } | |
349 | -} | |
350 | - | |
351 | - | |
352 | -/* public slot */ | |
353 | -void KitaThreadTabWidget::slotCopyURL( int idx ) | |
354 | -{ | |
355 | - QWidget * w = currentPage(); | |
356 | - if ( idx != -1 ) w = page( idx ); | |
357 | - | |
358 | - QClipboard* clipboard = QApplication::clipboard(); | |
359 | - | |
360 | - KitaThreadView * view = isThreadView( w ); | |
361 | - if ( view ) { | |
362 | - KURL datURL = view->datURL(); | |
363 | - | |
364 | - QString cliptxt = Kita::DatManager::threadURL( datURL ); | |
365 | - clipboard->setText( cliptxt , QClipboard::Clipboard ); | |
366 | - clipboard->setText( cliptxt , QClipboard::Selection ); | |
367 | - } | |
368 | -} | |
369 | - | |
370 | - | |
371 | -/* public slot */ | |
372 | -void KitaThreadTabWidget::slotCopyTitleURL( int idx ) | |
373 | -{ | |
374 | - QWidget * w = currentPage(); | |
375 | - if ( idx != -1 ) w = page( idx ); | |
376 | - | |
377 | - QClipboard* clipboard = QApplication::clipboard(); | |
378 | - | |
379 | - KitaThreadView * view = isThreadView( w ); | |
380 | - if ( view ) { | |
381 | - KURL datURL = view->datURL(); | |
382 | - | |
383 | - QString cliptxt = Kita::DatManager::threadName( datURL ) | |
384 | - + "\n" + Kita::DatManager::threadURL( datURL ); | |
385 | - clipboard->setText( cliptxt , QClipboard::Clipboard ); | |
386 | - clipboard->setText( cliptxt , QClipboard::Selection ); | |
387 | - } | |
388 | -} | |
389 | - | |
390 | - | |
391 | 306 | /* public slot */ |
392 | 307 | void KitaThreadTabWidget::slotFocusSearchCombo() |
393 | 308 | { |
@@ -52,9 +52,6 @@ private: | ||
52 | 52 | |
53 | 53 | public slots: |
54 | 54 | void slotCopyText(); |
55 | - void slotOpenBrowser( int idx = -1 ); | |
56 | - void slotCopyURL( int idx = -1 ); | |
57 | - void slotCopyTitleURL( int idx = -1 ); | |
58 | 55 | void slotFocusSearchCombo(); |
59 | 56 | void slotSearchNext(); |
60 | 57 | void slotSearchPrev(); |