Vidalia 0.2.12

BridgeUsageDialog.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 BridgeUsageDialog.h
00013 ** \brief Displays a summary of bridge usage information, including client
00014 ** geographic location history.
00015 */
00016 
00017 #ifndef _BRIDGEUSAGEDIALOG_H
00018 #define _BRIDGEUSAGEDIALOG_H
00019 
00020 #include "ui_BridgeUsageDialog.h"
00021 
00022 #include <QDialog>
00023 #include <QDateTime>
00024 #include <QHash>
00025 
00026 
00027 class BridgeUsageDialog : public QDialog
00028 {
00029   Q_OBJECT
00030 
00031 public:
00032   /** Default constructor.
00033    */
00034   BridgeUsageDialog(QWidget *parent = 0);
00035 
00036   /** Updates the dialog with current bridge usage information.
00037    */
00038   void update(const QDateTime &timeStarted,
00039               const QHash<QString,int> &countrySummary);
00040 
00041 protected:
00042   /** Called when the dialog is displayed. Adjusts the size of the column
00043    * headers.
00044    */
00045   void showEvent(QShowEvent *e);
00046 
00047 private:
00048   Ui::BridgeUsageDialog ui;
00049 };
00050 
00051 #endif
00052