History

Merged with master

Sam Gateau committed 12 years ago

Commit dbdd5292 parents 6394970 e5c9ad4100 files · +1682 −597Browse files

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

Unified · Split

interface/src/Application.cpp+6−12
@@ -58,7 +58,7 @@ · 57 unmodified lines
5858 #include <HFActionEvent.h>
5959 #include <HFBackEvent.h>
6060 #include <LocalVoxelsList.h>
61−#include <Logging.h>
61+#include <LogHandler.h>
6262 #include <NetworkAccessManager.h>
6363 #include <OctalCode.h>
6464 #include <OctreeSceneStats.h>
@@ -117,12 +117,10 @@ const QString SKIP_FILENAME = QStandardPaths::writableLocation(QStandardPaths::D · 52 unmodified lines
117117 const QString DEFAULT_SCRIPTS_JS_URL = "http://public.highfidelity.io/scripts/defaultScripts.js";
118118
119119 void messageHandler(QtMsgType type, const QMessageLogContext& context, const QString& message) {
120− if (message.size() > 0) {
121− QString dateString = QDateTime::currentDateTime().toTimeSpec(Qt::LocalTime).toString(Qt::ISODate);
122− QString formattedMessage = QString("[%1] %2\n").arg(dateString).arg(message);
123−
124− fprintf(stdout, "%s", qPrintable(formattedMessage));
125− Application::getInstance()->getLogger()->addMessage(qPrintable(formattedMessage));
120+ QString logMessage = LogHandler::getInstance().printMessage((LogMsgType) type, context, message);
121+
122+ if (!logMessage.isEmpty()) {
123+ Application::getInstance()->getLogger()->addMessage(qPrintable(logMessage));
126124 }
127125 }
128126
@@ -582,10 +580,6 @@ void Application::initializeGL() { · 453 unmodified lines
582580 float startupTime = (float)_applicationStartupTime.elapsed() / 1000.0;
583581 _justStarted = false;
584582 qDebug("Startup time: %4.2f seconds.", startupTime);
585− const char LOGSTASH_INTERFACE_START_TIME_KEY[] = "interface-start-time";
586−
587− // ask the Logstash class to record the startup time
588− Logging::stashValue(STAT_TYPE_TIMER, LOGSTASH_INTERFACE_START_TIME_KEY, startupTime);
589583 }
590584
591585 // update before the first render
@@ -3179,7 +3173,7 @@ void Application::renderRearViewMirror(const QRect& region, bool billboard) { · 2587 unmodified lines
31793173 } else {
31803174 // if not rendering the billboard, the region is in device independent coordinates; must convert to device
31813175 QSize size = getTextureCache()->getFrameBufferSize();
3182− float ratio = QApplication::desktop()->windowHandle()->devicePixelRatio();
3176+ float ratio = QApplication::desktop()->windowHandle()->devicePixelRatio() * _renderResolutionScale;
31833177 int x = region.x() * ratio, y = region.y() * ratio, width = region.width() * ratio, height = region.height() * ratio;
31843178 glViewport(x, size.height() - y - height, width, height);
31853179 glScissor(x, size.height() - y - height, width, height);

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