mirror of
https://github.com/obsproject/obs-studio.git
synced 2026-09-01 15:49:51 +08:00
UI: Convert QTStr macro to inline function
Using inline functions improves IDE integration and avoids potential pitfalls of that using macros has.
This commit is contained in:
+4
-1
@@ -250,7 +250,10 @@ inline const char *Str(const char *lookup)
|
||||
{
|
||||
return App()->GetString(lookup);
|
||||
}
|
||||
#define QTStr(lookupVal) QString::fromUtf8(Str(lookupVal))
|
||||
inline QString QTStr(const char *lookupVal)
|
||||
{
|
||||
return QString::fromUtf8(Str(lookupVal));
|
||||
}
|
||||
|
||||
bool GetFileSafeName(const char *name, std::string &file);
|
||||
bool GetClosestUnusedFileName(std::string &path, const char *extension);
|
||||
|
||||
Reference in New Issue
Block a user