mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-07-21 05:39:11 -04:00
added Tor status icon in the status bar
This commit is contained in:
parent
9a54205add
commit
8534147313
7 changed files with 177 additions and 0 deletions
|
@ -83,6 +83,7 @@
|
|||
#include "statusbar/SoundStatus.h"
|
||||
#include "statusbar/ToasterDisable.h"
|
||||
#include "statusbar/SysTrayStatus.h"
|
||||
#include "statusbar/torstatus.h"
|
||||
#include <retroshare/rsstatus.h>
|
||||
|
||||
#include <retroshare/rsiface.h>
|
||||
|
@ -244,6 +245,17 @@ MainWindow::MainWindow(QWidget* parent, Qt::WindowFlags flags)
|
|||
peerstatus->setVisible(Settings->valueFromGroup("StatusBar", "ShowPeer", QVariant(true)).toBool());
|
||||
statusBar()->addWidget(peerstatus);
|
||||
|
||||
if(hiddenmode)
|
||||
{
|
||||
torstatus = new TorStatus();
|
||||
torstatus->setVisible(Settings->valueFromGroup("StatusBar", "ShowTor", QVariant(true)).toBool());
|
||||
statusBar()->addWidget(torstatus);
|
||||
torstatus->getTorStatus();
|
||||
}
|
||||
else
|
||||
torstatus = NULL ;
|
||||
|
||||
#ifndef RETROTOR
|
||||
natstatus = new NATStatus();
|
||||
if(hiddenmode) natstatus->setVisible(false);
|
||||
else natstatus->setVisible(Settings->valueFromGroup("StatusBar", "ShowNAT", QVariant(true)).toBool());
|
||||
|
@ -255,6 +267,7 @@ MainWindow::MainWindow(QWidget* parent, Qt::WindowFlags flags)
|
|||
else dhtstatus->setVisible(Settings->valueFromGroup("StatusBar", "ShowDHT", QVariant(true)).toBool());
|
||||
statusBar()->addWidget(dhtstatus);
|
||||
dhtstatus->getDHTStatus();
|
||||
#endif
|
||||
|
||||
hashingstatus = new HashingStatus();
|
||||
hashingstatus->setVisible(Settings->valueFromGroup("StatusBar", "ShowHashing", QVariant(true)).toBool());
|
||||
|
@ -710,6 +723,9 @@ void MainWindow::updateStatus()
|
|||
if (ratesstatus)
|
||||
ratesstatus->getRatesStatus(downKb, upKb);
|
||||
|
||||
if(torstatus)
|
||||
torstatus->getTorStatus();
|
||||
|
||||
if(!hiddenmode)
|
||||
{
|
||||
if (natstatus)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue