File indexing completed on 2024-05-19 04:59:18
0001 /* ============================================================ 0002 * Personal Information Manager plugin for Falkon 0003 * Copyright (C) 2012-2014 David Rosca <nowrep@gmail.com> 0004 * Copyright (C) 2012-2014 Mladen Pejaković <pejakm@autistici.org> 0005 * 0006 * This program is free software: you can redistribute it and/or modify 0007 * it under the terms of the GNU General Public License as published by 0008 * the Free Software Foundation, either version 3 of the License, or 0009 * (at your option) any later version. 0010 * 0011 * This program is distributed in the hope that it will be useful, 0012 * but WITHOUT ANY WARRANTY; without even the implied warranty of 0013 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 0014 * GNU General Public License for more details. 0015 * 0016 * You should have received a copy of the GNU General Public License 0017 * along with this program. If not, see <http://www.gnu.org/licenses/>. 0018 * ============================================================ */ 0019 #ifndef PIM_PLUGIN_H 0020 #define PIM_PLUGIN_H 0021 0022 #include "plugininterface.h" 0023 0024 class WebPage; 0025 class BrowserWindow; 0026 class PIM_Handler; 0027 0028 class PIM_Plugin : public QObject, public PluginInterface 0029 { 0030 Q_OBJECT 0031 Q_INTERFACES(PluginInterface) 0032 Q_PLUGIN_METADATA(IID "Falkon.Browser.plugin.PIM" FILE "PIM.json") 0033 0034 public: 0035 PIM_Plugin(); 0036 0037 void init(InitState state, const QString &settingsPath) override; 0038 void unload() override; 0039 bool testPlugin() override; 0040 void showSettings(QWidget *parent) override; 0041 0042 void populateWebViewMenu(QMenu *menu, WebView *view, const WebHitTestResult &r) override; 0043 bool keyPress(Qz::ObjectName type, QObject *obj, QKeyEvent *event) override; 0044 0045 private: 0046 PIM_Handler* m_handler; 0047 }; 0048 0049 #endif // PIM_PLUGIN_H