12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879 |
- /*****************************************************************************
- * settingsdialog.h - QStarDict, a dictionary for learning foreign languages *
- * Copyright (C) 2007-2023 Alexander Rodin *
- * *
- * This program is free software; you can redistribute it and/or modify *
- * it under the terms of the GNU General Public License as published by *
- * the Free Software Foundation; either version 2 of the License, or *
- * (at your option) any later version. *
- * *
- * This program is distributed in the hope that it will be useful, *
- * but WITHOUT ANY WARRANTY; without even the implied warranty of *
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
- * GNU General Public License for more details. *
- * *
- * You should have received a copy of the GNU General Public License along *
- * with this program; if not, write to the Free Software Foundation, Inc., *
- * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. *
- *****************************************************************************/
- #ifndef SETTINGSDIALOG_H
- #define SETTINGSDIALOG_H
- #include <QDialog>
- #include "ui_settingsdialog.h"
- #include "dictcore.h"
- class QStandardItemModel;
- class QStandardItem;
- class QTimer;
- namespace QStarDict
- {
- class MainWindow;
- class PluginsModel;
- /**
- * The settings dialog.
- */
- class SettingsDialog: public QDialog, private Ui::SettingsDialog
- {
- Q_OBJECT
- public:
- /**
- * Construct new SettingsDialog widget with parent MainWindow.
- */
- SettingsDialog(QWidget *parent = 0);
- void accept();
- void reject();
- private slots:
- void on_dictsMoveUpButton_clicked();
- void on_dictsMoveDownButton_clicked();
- void on_dictsShowInfoButton_clicked();
- void on_dictsAddButton_clicked();
- void on_dictsRemoveButton_clicked();
- void loadDictsList();
- void dictLoadedPluginsChanged();
- void pluginClicked(const QModelIndex &index);
- void dictSelected();
- private:
- QStringList m_oldPlugins;
- QList<DictCore::Dictionary> m_oldDicts;
- QStandardItemModel *m_dictsModel;
- QTimer *m_dictsTimer;
- PluginsModel *m_dictPluginsModel;
- PluginsModel *m_miscPluginsModel;
- };
- }
- #endif // SETTINGSDIALOG_H
- // vim: tabstop=4 softtabstop=4 shiftwidth=4 expandtab cindent textwidth=120 formatoptions=tc
|