[patch] konqi using searchline

Martin Koller m.koller at surfeu.at
Sun Dec 12 21:10:26 GMT 2004


On Sunday 12 December 2004 17:53, Datschge wrote:
> If for better or worse I
> don't know, it just isn't consistent. ;)

You're right. So I'm looking into adding it to the dirfilter konq-plugin.

But I have 2 questions:

The searchbar plugin does the following in the ctor:
 //Grab the part manager. Don't know of any other way, and neither does 
Tronical, so..
 KParts::PartManager *partMan = 
static_cast<KParts::PartManager*>(mainWin->child(0, "KParts::PartManager"));
 if (partMan)
 {
  connect(partMan, SIGNAL(activePartChanged(KParts::Part*)),
                   SLOT  (partChanged      (KParts::Part*)));
  partChanged(partMan->activePart());
 }


I thought I need that too, and added it, but the partMan pointer is always 
0 ...

So how can the plugin get triggered when the part is activated ?
I need to know which type of view is active (IconView or ListView).
The problem here is that the ctor seems to be called whenever the viewmode is 
changed, but using the IconView the part has already a widget, but using the 
ListView, the widget is always 0.

Activating debugflag 1202 (konqueror) gives the following:

First opening a ListView

konqueror: serviceName=konq_textview
konqueror: changeViewMode: serviceType is inode/directory serviceName is 
konq_textview current service name is khtml
konqueror: Switching view modes...
konqueror: Trying to create view for "inode/directory"
konqueror: Found requested service konq_textview
konqueror: Trying to open lib for requested service konq_textview
konqueror: KonqView::switchView
konq-plugins (dirfilter): DirFilterPlugin: partMan:(nil)
konq-plugins (dirfilter): DirFilterPlugin: m_part:0x86c23d0
konqueror: Creating KonqTextViewWidget
#### konqueror: +KonqBaseListViewWidget
konqueror: +KonqTextViewWidget
konqueror: KonqMainWindow::slotPartChanged

now changing to IconView

konqueror: changeViewMode: serviceType is inode/directory serviceName is 
konq_iconview current service name is konq_textview
konqueror: Switching view modes...
konqueror: Trying to create view for "inode/directory"
konqueror: Found requested service konq_iconview
konqueror: Trying to open lib for requested service konq_iconview
konqueror: KonqView::switchView
#### konqueror: +KonqKfmIconView
konq-plugins (dirfilter): DirFilterPlugin: partMan:(nil)
konq-plugins (dirfilter): DirFilterPlugin: m_part:0x84c4898
konq-plugins (dirfilter): DirFilterPlugin: widget:[KonqIconViewWidget pointer 
(0x84fd8d8) to widget qiconview, geometry=100x30+0+0]
konqueror: KonqMainWindow::slotPartChanged


I marked the creation of the widget with ####

-- 
Best regards/Schöne Grüße

Martin    ()  ascii ribbon campaign - against html mail 
          /\                        - against microsoft attachments

       Some operating systems are called 'user friendly',
             Linux however is 'expert friendly'.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <https://mail.kde.org/mailman/private/kfm-devel/attachments/20041212/f27864a1/attachment.sig>


More information about the kfm-devel mailing list