Bug 199335 - ktimetracker kontact plugin is missing context menu
Summary: ktimetracker kontact plugin is missing context menu
Status: RESOLVED FIXED
Alias: None
Product: ktimetracker
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: Compiled Sources Linux
: NOR normal
Target Milestone: ---
Assignee: Thorsten Staerk
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-07-07 20:46 UTC by Thorsten Staerk
Modified: 2011-02-27 16:47 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Thorsten Staerk 2009-07-07 20:46:43 UTC
Version:            (using Devel)
OS:                Linux
Installed from:    Compiled sources

Since http://websvn.kde.org/?view=rev&revision=991655, made for https://bugs.kde.org/show_bug.cgi?id=198997, the kontact plugin of ktimetracker no longer shows a context menu.
Comment 1 Thorsten Staerk 2011-02-27 09:50:28 UTC
I guess related are lines 106ff in mainwindow.cpp:

    // Setup context menu request handling
    connect( m_part->widget(),
           SIGNAL( contextMenuRequested( const QPoint& ) ),
           this,
           SLOT( taskViewCustomContextMenuRequested( const QPoint& ) ) );
Comment 2 Thorsten Staerk 2011-02-27 11:02:43 UTC
Cannot put the code
 QMenu* pop = dynamic_cast<QMenu*>( factory()->container( i18n( "task_popup" ), this )
into taskview because factory is inherited from KXmlGuiClient
Comment 3 Thorsten Staerk 2011-02-27 11:37:54 UTC
Cannot put the code
 QMenu* pop = dynamic_cast<QMenu*>( factory()->container( i18n( "task_popup" ),
this )
into timetrackerwidget because factory() delivers 0
Comment 4 Thorsten Staerk 2011-02-27 13:56:56 UTC
I find that loadPart() fails. See http://techbase.kde.org/Development/Tutorials/Writing_kontact_plugins.
Comment 5 Thorsten Staerk 2011-02-27 14:32:32 UTC
loadParts uses the XML file to look up its popup menu. 

    kDebug(5970) << "xmlfile" << mPart->xmlFile();

delivers /root/.kde/share/apps/kontact/default-ktimetracker.rc which is EMPTY
Comment 6 Thorsten Staerk 2011-02-27 14:44:11 UTC
/root/.kde/share/apps/kontact/default-ktimetracker.rc is empty. When I copy ktimetrackerui.rc over it, I can run make install and it is still empty. But when I run kontact, it is emptied again.