• Skip to content
  • Skip to link menu
KDE 4.2 API Reference
  • KDE API Reference
  • kdepim
  • Sitemap
  • Contact Us
 

akregator

akregator_part.h

Go to the documentation of this file.
00001 /*
00002     This file is part of Akregator.
00003 
00004     Copyright (C) 2004 Stanislav Karchebny <Stanislav.Karchebny@kdemail.net>
00005                   2005 Frank Osterfeld <osterfeld@kde.org>
00006 
00007     This program is free software; you can redistribute it and/or modify
00008     it under the terms of the GNU General Public License as published by
00009     the Free Software Foundation; either version 2 of the License, or
00010     (at your option) any later version.
00011 
00012     This program is distributed in the hope that it will be useful,
00013     but WITHOUT ANY WARRANTY; without even the implied warranty of
00014     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
00015     GNU General Public License for more details.
00016 
00017     You should have received a copy of the GNU General Public License
00018     along with this program; if not, write to the Free Software
00019     Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
00020 
00021     As a special exception, permission is given to link this program
00022     with any edition of Qt, and distribute the resulting executable,
00023     without including the source code for Qt in the source distribution.
00024 */
00025 
00026 #ifndef AKREGATOR_PART_H
00027 #define AKREGATOR_PART_H
00028 
00029 #include <kurl.h>
00030 #include <kparts/browserextension.h>
00031 #include <kparts/part.h>
00032 
00033 class KConfigGroup;
00034 class KUrl;
00035 class KCMultiDialog;
00036 
00037 class QDomDocument;
00038 class QTimer;
00039 
00040 namespace Akregator {
00041 
00042 namespace Backend
00043 {
00044     class Storage;
00045 }
00046 
00047 typedef KParts::ReadOnlyPart MyBasePart;
00048 
00049 class ActionManagerImpl;
00050 class Feed;
00051 class MainWidget;
00052 class Part;
00053 class TrayIcon;
00054 
00055 class BrowserExtension : public KParts::BrowserExtension
00056 {
00057     Q_OBJECT
00058 
00059     public:
00060         explicit BrowserExtension(Part *p, const char *name=0);
00061     public slots:
00062         void saveSettings();
00063     private:
00064         Part *m_part;
00065 };
00066 
00071 class Part : public MyBasePart
00072 {
00073     Q_OBJECT
00074     public:
00075         typedef MyBasePart inherited;
00076 
00078         Part(QWidget *parentWidget, QObject *parent, const QVariantList&);
00079 
00081         ~Part();
00082 
00087         bool openUrl(const KUrl& url);
00088 
00090         void openStandardFeedList();
00091 
00092         void fetchFeedUrl(const QString&);
00093 
00095         void fetchAllFeeds();
00096 
00104         void addFeedsToGroup(const QStringList& urls, const QString& group);
00105 
00106         void addFeed();
00107 
00114         virtual void readProperties(const KConfigGroup & config);
00115 
00119         virtual void saveProperties(KConfigGroup & config);
00120 
00123         bool mergePart(KParts::Part*);
00124 
00125         void exportFile(const KUrl& url);
00126 
00127     public slots:
00129         void saveSettings();
00130 
00132         void slotSaveFeedList();
00133 
00134         void fileImport();
00135         void fileExport();
00136 
00138         void showOptions();
00139         void showKNotifyOptions();
00140 
00141     signals:
00142         void showPart();
00143         void signalSettingsChanged();
00144 
00145 
00146     private:
00147 
00149         bool isTrayIconEnabled() const;
00150 
00152         void loadStoragePlugins();
00153 
00155         bool openFile();
00156 
00157         void importFile(const KUrl& url);
00158 
00160         QWidget* getMainWindow();
00161 
00162         KParts::Part *hitTest(QWidget *widget, const QPoint &globalPos);
00163 
00165         void partActivateEvent(KParts::PartActivateEvent* event);
00166 
00167     private slots:
00168         void slotStarted();
00169 
00170         void slotOnShutdown();
00171         void slotSettingsChanged();
00172 
00173     private: // methods
00174 
00175         bool copyFile(const QString& backup);
00176 
00178         void initFonts();
00179 
00181         static QDomDocument createDefaultFeedList();
00182 
00183     private: // attributes
00184 
00185         class ApplyFiltersInterceptor;
00186         ApplyFiltersInterceptor* m_applyFiltersInterceptor;
00187         QString m_standardFeedList;
00188         bool m_standardListLoaded;
00189         bool m_shuttingDown;
00190 
00191         KParts::BrowserExtension *m_extension;
00192         KParts::Part* m_mergedPart;
00193 
00194         QTimer* m_autosaveTimer;
00196         bool m_backedUpList;
00197         MainWidget* m_mainWidget;
00198         Backend::Storage* m_storage;
00199         ActionManagerImpl* m_actionManager;
00200         KCMultiDialog* m_dialog;
00201 };
00202 
00203 } // namespace Akregator
00204 
00205 #endif // AKREGATOR_PART_H

akregator

Skip menu "akregator"
  • Main Page
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Namespace Members
  • Class Members

kdepim

Skip menu "kdepim"
  • akonadi
  •   clients
  •   kabc
  •   kcal
  •   kcm
  • akregator
  • console
  •   kabcclient
  •   konsolekalendar
  • kaddressbook
  • kalarm
  •   lib
  • kdgantt
  • kdgantt1
  • kjots
  • kleopatra
  • kmail
  • kmobiletools
  • knode
  • knotes
  • kontact
  • kontactinterfaces
  • korganizer
  •   korgac
  • kpilot
  • ktimetracker
  •   doc
  • libkdepim
  • libkholidays
  • libkleo
  • libkpgp
  • maildir
Generated for kdepim by doxygen 1.5.4
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal