History

Fix for sixense debug draw after move to plugin.

static variables used to hold a Singleton cannot be shared across dll boundaries by default. This uses the globalInstance template to store the instance as a property on the QApplication.

Anthony J. Thibault committed 10 years ago

Commit 1af780a1 parent e133bd81 file · +3 −2Browse files

Showing the changes to libraries/shared/src/DebugDraw.cpp (1 of 1 file). Show all

Unified · Split

libraries/shared/src/DebugDraw.cpp+3−2
@@ -8,10 +8,11 @@ · 7 unmodified lines
8//8//
9 9
10#include "DebugDraw.h"10#include "DebugDraw.h"
11#include "SharedUtil.h"
11 12
12DebugDraw& DebugDraw::getInstance() {13DebugDraw& DebugDraw::getInstance() {
13 static DebugDraw instance;14 static DebugDraw* instance = globalInstance<DebugDraw>("com.highfidelity.DebugDraw");
14 return instance;15 return *instance;
15}16}
16 17
17DebugDraw::DebugDraw() {18DebugDraw::DebugDraw() {

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