generalpage.h

Go to the documentation of this file.
00001 /*
00002 **  This file is part of Vidalia, and is subject to the license terms in the
00003 **  LICENSE file, found in the top level directory of this distribution. If you
00004 **  did not receive the LICENSE file with this file, you may obtain it from the
00005 **  Vidalia source package distributed by the Vidalia Project at
00006 **  http://www.vidalia-project.net/. No part of Vidalia, including this file,
00007 **  may be copied, modified, propagated, or distributed except according to the
00008 **  terms described in the LICENSE file.
00009 */
00010 
00011 /*
00012 ** \file generalpage.h
00013 ** \version $Id: generalpage.h 2484 2008-04-05 04:09:20Z edmanm $
00014 ** \brief General Tor and Vidalia configuration options
00015 */
00016 
00017 #ifndef _GENERALPAGE_H
00018 #define _GENERALPAGE_H
00019 
00020 #include <QFileDialog>
00021 #include <config/vidaliasettings.h>
00022 #include <config/torsettings.h>
00023 
00024 #include "configpage.h"
00025 #include "ui_generalpage.h"
00026 
00027 class GeneralPage : public ConfigPage
00028 {
00029   Q_OBJECT
00030 
00031 public:
00032   /** Default Constructor */
00033   GeneralPage(QWidget *parent = 0);
00034   /** Default Destructor */
00035   ~GeneralPage();
00036   /** Saves the changes on this page */
00037   bool save(QString &errmsg);
00038   /** Loads the settings for this page */
00039   void load();
00040 
00041 private slots:
00042   /** Open a QFileDialog to browse for a Tor executable file. */
00043   void browseTorExecutable();
00044   /** Open a QFileDialog to browse for a proxy executable file. */
00045   void browseProxyExecutable();
00046   
00047 private:
00048   /** Displays a file dialog allowing the user to browse for an executable
00049    * file. <b>caption</b> will be displayed in the dialog's title bar and <b>
00050    * file</b>, if specified, is the default file selected in the dialog. */
00051   QString browseExecutable(const QString &caption,
00052                            const QString &file = QString());
00053 
00054   /** A VidaliaSettings object used for saving/loading vidalia settings */
00055   VidaliaSettings *_vidaliaSettings;
00056   /** A TorSettings ovject used for saving/loading tor settings */
00057   TorSettings *_torSettings;
00058   /** Qt Designer generated object */
00059   Ui::GeneralPage ui;
00060 };
00061 
00062 #endif
00063 

Generated on Wed Nov 26 21:03:58 2008 for Vidalia by  doxygen 1.5.6