mirror of
https://github.com/RetroShare/RetroShare.git
synced 2024-10-01 02:35:48 -04:00
Clean up MainWindow removed unused headers and not needed SMPlayer entries
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@1516 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
a2e9054cac
commit
e7b289b367
@ -43,9 +43,6 @@
|
||||
#include "MessengerWindow.h"
|
||||
#include "HelpDialog.h"
|
||||
|
||||
#include "games/qbackgammon/bgwindow.h"
|
||||
//#include "smplayer.h"
|
||||
|
||||
#ifdef TURTLE_HOPPING
|
||||
#include "gui/TurtleSearchDialog.h"
|
||||
#endif
|
||||
@ -102,7 +99,6 @@
|
||||
#define IMAGE_PHOTO ":/images/lphoto.png"
|
||||
#define IMAGE_SMPLAYER ":/images/smplayer_icon32.png"
|
||||
#define IMAGE_ADDFRIEND ":/images/add-friend24.png"
|
||||
//#define IMAGE_INVITEFRIEND ":/images/invite-friend24.png"
|
||||
#define IMAGE_ADDSHARE ":/images/directoryadd_24x24_shadow.png"
|
||||
#define IMAGE_OPTIONS ":/images/settings.png"
|
||||
#define IMAGE_QUIT ":/images/exit_24x24.png"
|
||||
@ -117,9 +113,6 @@
|
||||
#define IMAGE_TWOONLINE ":/images/rstray2.png"
|
||||
|
||||
|
||||
/* Keys for UI Preferences */
|
||||
#define UI_PREF_PROMPT_ON_QUIT "UIOptions/ConfirmOnQuit"
|
||||
|
||||
/** Constructor */
|
||||
MainWindow::MainWindow(QWidget* parent, Qt::WFlags flags)
|
||||
: RWindow("MainWindow", parent, flags)
|
||||
@ -139,8 +132,6 @@ MainWindow::MainWindow(QWidget* parent, Qt::WFlags flags)
|
||||
}
|
||||
setWindowTitle(tr("RetroShare %1 a secure decentralised commmunication platform").arg(version));
|
||||
|
||||
mSMPlayer = NULL;
|
||||
|
||||
// Setting icons
|
||||
this->setWindowIcon(QIcon(QString::fromUtf8(":/images/rstray3.png")));
|
||||
|
||||
@ -180,29 +171,22 @@ MainWindow::MainWindow(QWidget* parent, Qt::WFlags flags)
|
||||
ui.stackPages->add(peersDialog = new PeersDialog(ui.stackPages),
|
||||
createPageAction(QIcon(IMAGE_PEERS), tr("Friends"), grp));
|
||||
|
||||
//PeersFeed *peersFeed = NULL;
|
||||
//ui.stackPages->add(peersFeed = new PeersFeed(ui.stackPages),
|
||||
// createPageAction(QIcon(IMAGE_PEERS), tr("Peers"), grp));
|
||||
#ifdef TURTLE_HOPPING
|
||||
ui.stackPages->add(turtleDialog = new TurtleSearchDialog(ui.stackPages),
|
||||
createPageAction(QIcon(IMAGE_TURTLE), tr("Turtle"), grp));
|
||||
#endif
|
||||
|
||||
ui.stackPages->add(searchDialog = new SearchDialog(ui.stackPages),
|
||||
createPageAction(QIcon(IMAGE_SEARCH), tr("Search"), grp));
|
||||
|
||||
|
||||
ui.stackPages->add(transfersDialog = new TransfersDialog(ui.stackPages),
|
||||
createPageAction(QIcon(IMAGE_TRANSFERS), tr("Transfers"), grp));
|
||||
|
||||
//TransferFeed *transferFeed = NULL;
|
||||
//ui.stackPages->add(transferFeed = new TransferFeed(ui.stackPages),
|
||||
// createPageAction(QIcon(IMAGE_LINKS), tr("Transfers"), grp));
|
||||
|
||||
ui.stackPages->add(sharedfilesDialog = new SharedFilesDialog(ui.stackPages),
|
||||
createPageAction(QIcon(IMAGE_FILES), tr("Files"), grp));
|
||||
|
||||
//MsgFeed *msgFeed = NULL;
|
||||
//ui.stackPages->add(msgFeed = new MsgFeed(ui.stackPages),
|
||||
// createPageAction(QIcon(IMAGE_MESSAGES), tr("Messages"), grp));
|
||||
|
||||
ui.stackPages->add(messagesDialog = new MessagesDialog(ui.stackPages),
|
||||
createPageAction(QIcon(IMAGE_MESSAGES), tr("Messages"), grp));
|
||||
@ -268,7 +252,7 @@ MainWindow::MainWindow(QWidget* parent, Qt::WFlags flags)
|
||||
connect(sharedfilesDialog, SIGNAL(playFiles( QStringList )), this, SLOT(playFiles( QStringList )));
|
||||
connect(transfersDialog, SIGNAL(playFiles( QStringList )), this, SLOT(playFiles( QStringList )));
|
||||
|
||||
/** StatusBar section **/
|
||||
/** StatusBar section ********/
|
||||
peerstatus = new PeerStatus();
|
||||
statusBar()->addWidget(peerstatus);
|
||||
|
||||
@ -299,7 +283,7 @@ MainWindow::MainWindow(QWidget* parent, Qt::WFlags flags)
|
||||
|
||||
ratesstatus = new RatesStatus();
|
||||
statusBar()->addPermanentWidget(ratesstatus);
|
||||
/******* Status Bar end ******/
|
||||
/** Status Bar end ******/
|
||||
|
||||
/* Create the actions that will go in the tray menu */
|
||||
createActions();
|
||||
@ -314,7 +298,7 @@ MainWindow::MainWindow(QWidget* parent, Qt::WFlags flags)
|
||||
tr("System tray unavailable"));
|
||||
******/
|
||||
|
||||
// Tray icon Menu
|
||||
/** Tray icon Menu **/
|
||||
menu = new QMenu(this);
|
||||
QObject::connect(menu, SIGNAL(aboutToShow()), this, SLOT(updateMenu()));
|
||||
toggleVisibilityAction =
|
||||
@ -324,7 +308,6 @@ MainWindow::MainWindow(QWidget* parent, Qt::WFlags flags)
|
||||
menu->addAction(_messagesAct);
|
||||
menu->addAction(_bandwidthAct);
|
||||
|
||||
/* bandwidth only in development version */
|
||||
#ifdef RS_RELEASE_VERSION
|
||||
#else
|
||||
menu->addAction(_appAct);
|
||||
@ -336,7 +319,7 @@ MainWindow::MainWindow(QWidget* parent, Qt::WFlags flags)
|
||||
menu->addAction(QIcon(IMAGE_MAXIMIZE), tr("Maximize"), this, SLOT(showMaximized()));
|
||||
menu->addSeparator();
|
||||
menu->addAction(QIcon(IMAGE_CLOSE), tr("&Quit"), this, SLOT(doQuit()));
|
||||
// End of Icon Menu
|
||||
/** End of Icon Menu **/
|
||||
|
||||
// Create the tray icon
|
||||
trayIcon = new QSystemTrayIcon(this);
|
||||
@ -628,24 +611,6 @@ void MainWindow::loadStyleSheet(const QString &sheetName)
|
||||
|
||||
}
|
||||
|
||||
/** Shows smplayer */
|
||||
void MainWindow::showsmplayer()
|
||||
{
|
||||
return;
|
||||
|
||||
#if 0
|
||||
if (mSMPlayer == 0)
|
||||
{
|
||||
mSMPlayer = new SMPlayer(QString::null, this);
|
||||
mSMPlayer->gui()->hide();
|
||||
}
|
||||
else
|
||||
{
|
||||
mSMPlayer->gui()->show();
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
void MainWindow::playFiles(QStringList files)
|
||||
{
|
||||
std::cerr << "MainWindow::playFiles() Can only play first currently" << std::endl;
|
||||
|
@ -27,7 +27,6 @@
|
||||
#include <QFileDialog>
|
||||
#include <QSystemTrayIcon>
|
||||
|
||||
|
||||
#include "NetworkDialog.h"
|
||||
#include "PeersDialog.h"
|
||||
#include "SearchDialog.h"
|
||||
@ -38,25 +37,20 @@
|
||||
#include "MessengerWindow.h"
|
||||
#include "ApplicationWindow.h"
|
||||
#include "PluginsPage.h"
|
||||
|
||||
#ifdef TURTLE_HOPPING
|
||||
#include "TurtleSearchDialog.h"
|
||||
#endif
|
||||
|
||||
#include "Preferences/PreferencesWindow.h"
|
||||
#include "Preferences/rsharesettings.h"
|
||||
|
||||
#include "bwgraph/bwgraph.h"
|
||||
#include "help/browser/helpbrowser.h"
|
||||
#include "games/qbackgammon/bgwindow.h"
|
||||
|
||||
#include "Preferences/ConfirmQuitDialog.h"
|
||||
|
||||
#include "channels/channelsDialog.h"
|
||||
|
||||
|
||||
#include "ui_MainWindow.h"
|
||||
|
||||
#include "Preferences/rsharesettings.h"
|
||||
|
||||
class SMPlayer;
|
||||
|
||||
class PeerStatus;
|
||||
class DHTStatus;
|
||||
@ -72,15 +66,15 @@ class MainWindow : public RWindow
|
||||
public:
|
||||
/** Main dialog pages. */
|
||||
enum Page {
|
||||
Network = 0, /** Network page. */
|
||||
Friends, /** Peers page. */
|
||||
Search, /** Search page. */
|
||||
Transfers, /** Transfers page. */
|
||||
SharedDirectories, /** Shared Directories page. */
|
||||
Messages, /** Messages page. */
|
||||
Links, /** Links page. */
|
||||
Channels, /** Channels page. */
|
||||
Forums /** Forums page. */
|
||||
Network = 0, /** Network page. */
|
||||
Friends, /** Peers page. */
|
||||
Search, /** Search page. */
|
||||
Transfers, /** Transfers page. */
|
||||
SharedDirectories, /** Shared Directories page. */
|
||||
Messages, /** Messages page. */
|
||||
Links, /** Links page. */
|
||||
Channels, /** Channels page. */
|
||||
Forums /** Forums page. */
|
||||
|
||||
|
||||
};
|
||||
@ -111,7 +105,6 @@ public:
|
||||
ApplicationWindow *applicationWindow;
|
||||
PluginsPage* pluginsPage ;
|
||||
|
||||
SMPlayer * mSMPlayer;
|
||||
|
||||
public slots:
|
||||
/** Called when this dialog is to be displayed */
|
||||
@ -135,7 +128,6 @@ private slots:
|
||||
void addFriend();
|
||||
void showMessengerWindow();
|
||||
void showApplWindow();
|
||||
void showsmplayer();
|
||||
void showabout();
|
||||
void openShareManager();
|
||||
void displaySystrayMsg(const QString&,const QString&) ;
|
||||
@ -203,7 +195,6 @@ private:
|
||||
QAction *toggleVisibilityAction, *toolAct;
|
||||
QMenu *menu;
|
||||
|
||||
//QLabel *statusRates;
|
||||
PeerStatus *peerstatus;
|
||||
DHTStatus *dhtstatus;
|
||||
NATStatus *natstatus;
|
||||
|
Loading…
Reference in New Issue
Block a user