~mateo-salta/nitroshare/nitroshare

« back to all changes in this revision

Viewing changes to include/discovery/CBroadcastServer.h

  • Committer: Nathan Osman
  • Date: 2012-06-29 22:01:55 UTC
  • Revision ID: admin@quickmediasolutions.com-20120629220155-ogwrn9fxxve9wyw1
Moved a TON of the broadcast and discovery code around, creating separate classes for each and partially implementing their use in the first start wizard.

Show diffs side-by-side

added added

removed removed

Lines of Context:
21
21
#include <QMap>
22
22
#include <QTimer>
23
23
#include <QSystemTrayIcon>
 
24
#include <QUdpSocket>
24
25
 
25
 
#include <discovery/CBasicBroadcastServer.h>
26
26
#include <discovery/CMachine.h>
27
27
 
28
 
class CBroadcastServer : public CBasicBroadcastServer
 
28
class CBroadcastServer : public QUdpSocket
29
29
{
30
30
    Q_OBJECT
31
31
 
40
40
        bool MachineExists(QString id) { return m_machines.contains(id); }
41
41
        CMachine GetMachine(QString id) { return m_machines[id]; }
42
42
 
 
43
    signals:
 
44
 
 
45
        // TODO: remove these
 
46
        void Error(QString);
 
47
        void Information(QString);
 
48
 
43
49
    private slots:
44
50
 
45
51
        void OnMessage();