History

move all silent node timers into LimitedNodeList

Stephen Birarda committed 11 years ago

Commit 9f754e41 parent d3bc5405 files · +7 −17Browse files

Showing the changes to interface/src/Application.cpp (1 of 5 files). Show all

Unified · Split

interface/src/Application.cpp+0−9
@@ -146,7 +146,6 @@ const qint64 MAXIMUM_CACHE_SIZE = 10 * BYTES_PER_GIGABYTES; // 10GB · 145 unmodified lines
146 146
147static QTimer* locationUpdateTimer = NULL;147static QTimer* locationUpdateTimer = NULL;
148static QTimer* balanceUpdateTimer = NULL;148static QTimer* balanceUpdateTimer = NULL;
149static QTimer* silentNodeTimer = NULL;
150static QTimer* identityPacketTimer = NULL;149static QTimer* identityPacketTimer = NULL;
151static QTimer* billboardPacketTimer = NULL;150static QTimer* billboardPacketTimer = NULL;
152static QTimer* checkFPStimer = NULL;151static QTimer* checkFPStimer = NULL;
@@ -426,12 +425,6 @@ Application::Application(int& argc, char** argv, QElapsedTimer &startup_time) : · 273 unmodified lines
426 // connect to the packet sent signal of the _entityEditSender425 // connect to the packet sent signal of the _entityEditSender
427 connect(&_entityEditSender, &EntityEditPacketSender::packetSent, this, &Application::packetSent);426 connect(&_entityEditSender, &EntityEditPacketSender::packetSent, this, &Application::packetSent);
428 427
429 // move the silentNodeTimer to the _nodeThread
430 silentNodeTimer = new QTimer();
431 connect(silentNodeTimer, SIGNAL(timeout()), nodeList.data(), SLOT(removeSilentNodes()));
432 silentNodeTimer->start(NODE_SILENCE_THRESHOLD_MSECS);
433 silentNodeTimer->moveToThread(_nodeThread);
434
435 // send the identity packet for our avatar each second to our avatar mixer428 // send the identity packet for our avatar each second to our avatar mixer
436 identityPacketTimer = new QTimer();429 identityPacketTimer = new QTimer();
437 connect(identityPacketTimer, &QTimer::timeout, _myAvatar, &MyAvatar::sendIdentityPacket);430 connect(identityPacketTimer, &QTimer::timeout, _myAvatar, &MyAvatar::sendIdentityPacket);
@@ -548,7 +541,6 @@ void Application::cleanupBeforeQuit() { · 110 unmodified lines
548 // depending on what thread they run in541 // depending on what thread they run in
549 locationUpdateTimer->stop();542 locationUpdateTimer->stop();
550 balanceUpdateTimer->stop();543 balanceUpdateTimer->stop();
551 QMetaObject::invokeMethod(silentNodeTimer, "stop", Qt::BlockingQueuedConnection);
552 identityPacketTimer->stop();544 identityPacketTimer->stop();
553 billboardPacketTimer->stop();545 billboardPacketTimer->stop();
554 checkFPStimer->stop();546 checkFPStimer->stop();
@@ -558,7 +550,6 @@ void Application::cleanupBeforeQuit() { · 3 unmodified lines
558 // and then delete those that got created by "new"550 // and then delete those that got created by "new"
559 delete locationUpdateTimer;551 delete locationUpdateTimer;
560 delete balanceUpdateTimer;552 delete balanceUpdateTimer;
561 delete silentNodeTimer;
562 delete identityPacketTimer;553 delete identityPacketTimer;
563 delete billboardPacketTimer;554 delete billboardPacketTimer;
564 delete checkFPStimer;555 delete checkFPStimer;

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t