[kde-doc-english] [kdepim] ktimetracker: GUI:removing KRecentFilesAction (menu entry "recent files")
Thorsten Staerk
dev at staerk.de
Thu Sep 22 05:38:18 UTC 2011
Git commit 1ab91124d8743999d2fa2c3328acfa37e8bb42ba by Thorsten Staerk.
Committed on 22/09/2011 at 07:36.
Pushed by tstaerk into branch 'master'.
GUI:removing KRecentFilesAction (menu entry "recent files")
M +1 -18 ktimetracker/timetrackerwidget.cpp
http://commits.kde.org/kdepim/1ab91124d8743999d2fa2c3328acfa37e8bb42ba
diff --git a/ktimetracker/timetrackerwidget.cpp b/ktimetracker/timetrackerwidget.cpp
index 4b66c82..c97b0e4 100644
--- a/ktimetracker/timetrackerwidget.cpp
+++ b/ktimetracker/timetrackerwidget.cpp
@@ -66,13 +66,12 @@ class TimetrackerWidget::Private
{
public:
Private() :
- mTaskView( 0 ), mRecentFilesAction( 0 ) {}
+ mTaskView( 0 ) {}
QWidget *mSearchLine;
KTreeWidgetSearchLine *mSearchWidget;
TaskView *mTaskView;
QMap<QString, KAction*> mActions;
- KRecentFilesAction *mRecentFilesAction;
struct ActionData
{
@@ -118,10 +117,6 @@ TimetrackerWidget::TimetrackerWidget( QWidget *parent ) : QWidget( parent ),
TimetrackerWidget::~TimetrackerWidget()
{
- if ( d->mRecentFilesAction )
- {
- d->mRecentFilesAction->saveEntries( KGlobal::config()->group( "Recent Files" ) );
- }
delete d;
}
@@ -200,13 +195,6 @@ void TimetrackerWidget::setupActions( KActionCollection *actionCollection )
{
d->mActions.insert ("file_open",
KStandardAction::open( this, SLOT(openFile()), actionCollection ) );
-
- d->mRecentFilesAction = KStandardAction::openRecent(
- this, SLOT(openFile(KUrl)), this );
- actionCollection->addAction( d->mRecentFilesAction->objectName(),
- d->mRecentFilesAction );
- d->mRecentFilesAction->loadEntries( KGlobal::config()->group( "Recent Files" ) );
-
d->mActions.insert ("file_save",
KStandardAction::save( this, SLOT(saveFile()), actionCollection ) );
d->mActions.insert ("file_quit",
@@ -358,11 +346,6 @@ void TimetrackerWidget::openFile( const QString &fileName )
return;
}
}
-
- if ( d->mRecentFilesAction )
- {
- d->mRecentFilesAction->addUrl( newFileName );
- }
addTaskView( newFileName );
}
More information about the kde-doc-english
mailing list