Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Jan 17, 2016, 10:29:21 PM (8 years ago)
Author:
landauf
Message:

merged branch cpp11_v3 back to trunk

Location:
code/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • code/trunk

  • code/trunk/src/libraries/network/Connection.h

    r8327 r11071  
    4646#include <map>
    4747#include <enet/enet.h>
    48 #include <boost/concept_check.hpp>
    4948
    5049namespace boost
     
    6160  const unsigned int NETWORK_MAX_QUEUE_PROCESS_TIME = 5;
    6261 
    63   namespace incomingEventType
     62  enum class IncomingEventType
    6463  {
    65     enum Value
    66     {
    67       receivePacket   = 1,  // incoming packet
    68       peerConnect     = 2,  // incoming connect request
    69       peerDisconnect  = 3   // incoming disconnect request
    70     };
    71    
    72   }
     64    receivePacket   = 1,  // incoming packet
     65    peerConnect     = 2,  // incoming connect request
     66    peerDisconnect  = 3   // incoming disconnect request
     67  };
    7368 
    74   namespace outgoingEventType
     69  enum class OutgoingEventType
    7570  {
    76     enum Value
    77     {
    78       sendPacket      = 1,  // outgoing packet
    79       broadcastPacket = 2,  // outgoing broadcast packet
    80       disconnectPeer  = 3,  // outgoing disconnect request
    81       disconnectPeers = 4   // outgoing disconnect request
    82     };
    83    
    84   }
     71    sendPacket      = 1,  // outgoing packet
     72    broadcastPacket = 2,  // outgoing broadcast packet
     73    disconnectPeer  = 3,  // outgoing disconnect request
     74    disconnectPeers = 4   // outgoing disconnect request
     75  };
    8576 
    8677  struct _NetworkExport incomingEvent
    8778  {
    88     uint32_t                  peerID;
    89     incomingEventType::Value type;
    90     packet::Packet*           packet;
     79    uint32_t          peerID;
     80    IncomingEventType type;
     81    packet::Packet*   packet;
    9182  };
    9283 
    9384  struct _NetworkExport outgoingEvent
    9485  {
    95     uint32_t                  peerID;
    96     outgoingEventType::Value type;
    97     ENetPacket*               packet;
    98     ENetChannelID             channelID;
     86    uint32_t          peerID;
     87    OutgoingEventType type;
     88    ENetPacket*       packet;
     89    ENetChannelID     channelID;
    9990  };
    10091 
Note: See TracChangeset for help on using the changeset viewer.