1 /*******************************************************************************
3 This file is part of mDictionary.
5 mDictionary is free software: you can redistribute it and/or modify
6 it under the terms of the GNU General Public License as published by
7 the Free Software Foundation, either version 3 of the License, or
8 (at your option) any later version.
10 mDictionary is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU General Public License for more details.
15 You should have received a copy of the GNU General Public License
16 along with mDictionary. If not, see <http://www.gnu.org/licenses/>.
18 Copyright 2010 Comarch S.A.
20 *******************************************************************************/
22 /*! \file GoogleSettingsDialog.h
23 \brief Class create dialog to get or change settings for Google Plagin
24 \author Jakub Jaszczynski <j.j.jaszczynski@gmail.com>
27 #ifndef GOOGLESETTINGSDIALOG_H
28 #define GOOGLESETTINGSDIALOG_H
31 #include "../../../includes/settings.h"
33 #include "GooglePlugin.h"
37 class GoogleSettingsDialog : public QDialog
41 explicit GoogleSettingsDialog(QWidget *parent = 0,QString langTo ="",QString langFrom ="");
44 \param parent parent widget on which will be displayed dialog
45 \param langTo language witch is display in the comboBox as a startup item
46 \param langFrom language witch is display in the comboBox as a startup item
47 \returns function return settings to GooglePlugin
49 static Settings* getSettings(QWidget *parent,QString langTo ="",QString langFrom ="");
52 function set a new settings in plugin;
53 \param plugin plugin whose settings you will change
54 \param parent parent widget on which will be displayed dialog
56 static void changeSettings(GooglePlugin* plugin, QWidget *parent);
58 //! \return source language code iso 639-2
61 //! \return destination language code iso 639-2
65 void activatedFrom(int);
66 void activatedTo(int);
67 void changeLangButtonClicked();
71 QLabel* langFromLabel;
73 QLabel* connectInfoLabel;
74 QPushButton* saveButton;
75 QPushButton* changeLangButton;
76 QComboBox *langFromComboBox;
77 QComboBox *langToComboBox;
79 QVBoxLayout* verticalLayout;
80 QVBoxLayout* langLayout;
81 QHBoxLayout* langFromLayout;
82 QHBoxLayout* langToLayout;
83 QHBoxLayout* changelangLayout;
89 /* QPushButton* browseButton;
91 QCheckBox* cacheCheckBox;
93 QHBoxLayout* browseLayout;
94 QHBoxLayout* cacheLayout;
98 #endif // GOOGLESETTINGSDIALOG_H