Change API enums to enum class, remove now redundant prefixing

* This gives a little nicer syntax, a bit better type safety, and also
  reflects better for SWIG bindings. Overall it's a minor change but
  better.
* We don't update the C# UI at all, since it's soon to be removed and
  not worth the effort/code churn.
* For now so we're ABI compatible with C#, all enums are uint32_t, but
  that is an obvious optimisation in future to reduce struct packing.
* We avoid 'None' as an enum value, because it's a reserved word in
  python so will cause problems generating bindings.
This commit is contained in:
baldurk
2017-04-06 14:09:00 +01:00
parent 71e779a08f
commit d40fc8471d
158 changed files with 6386 additions and 6176 deletions
+6 -6
View File
@@ -35,15 +35,15 @@
void sharedLogOutput(QtMsgType type, const QMessageLogContext &context, const QString &msg)
{
LogMessageType logtype = eLogType_Comment;
LogType logtype = LogType::Comment;
switch(type)
{
case QtDebugMsg: logtype = eLogType_Debug; break;
case QtInfoMsg: logtype = eLogType_Comment; break;
case QtWarningMsg: logtype = eLogType_Warning; break;
case QtCriticalMsg: logtype = eLogType_Error; break;
case QtFatalMsg: logtype = eLogType_Fatal; break;
case QtDebugMsg: logtype = LogType::Debug; break;
case QtInfoMsg: logtype = LogType::Comment; break;
case QtWarningMsg: logtype = LogType::Warning; break;
case QtCriticalMsg: logtype = LogType::Error; break;
case QtFatalMsg: logtype = LogType::Fatal; break;
}
RENDERDOC_LogMessage(logtype, "QTRD", context.file, context.line, msg.toUtf8().data());