diff options
| author | 2014-04-18 17:52:49 -0400 | |
|---|---|---|
| committer | 2014-04-18 17:52:49 -0400 | |
| commit | 958bca606e80110e05d7c142dda3097fddc96503 (patch) | |
| tree | 576917751444b4dfdb476d040b4e075bde431b7b /src/common | |
| parent | Init window size from VideoCore. Start changing the default window behavior... (diff) | |
| parent | renamed hw_lcd module to just lcd (diff) | |
| download | yuzu-958bca606e80110e05d7c142dda3097fddc96503.tar.gz yuzu-958bca606e80110e05d7c142dda3097fddc96503.tar.xz yuzu-958bca606e80110e05d7c142dda3097fddc96503.zip | |
Merge branch 'hle-interface'
Diffstat (limited to 'src/common')
| -rw-r--r-- | src/common/log.h | 4 | ||||
| -rw-r--r-- | src/common/log_manager.cpp | 6 | ||||
| -rw-r--r-- | src/common/string_util.cpp | 16 | ||||
| -rw-r--r-- | src/common/string_util.h | 6 |
4 files changed, 27 insertions, 5 deletions
diff --git a/src/common/log.h b/src/common/log.h index 432a307f0..02db8bd55 100644 --- a/src/common/log.h +++ b/src/common/log.h | |||
| @@ -55,8 +55,8 @@ enum LOG_TYPE { | |||
| 55 | WII_IPC_HID, | 55 | WII_IPC_HID, |
| 56 | WII_IPC_HLE, | 56 | WII_IPC_HLE, |
| 57 | WII_IPC_NET, | 57 | WII_IPC_NET, |
| 58 | WII_IPC_WC24, | 58 | NDMA, |
| 59 | WII_IPC_SSL, | 59 | HLE, |
| 60 | RENDER, | 60 | RENDER, |
| 61 | LCD, | 61 | LCD, |
| 62 | HW, | 62 | HW, |
diff --git a/src/common/log_manager.cpp b/src/common/log_manager.cpp index 245760d0d..8e56deb8f 100644 --- a/src/common/log_manager.cpp +++ b/src/common/log_manager.cpp | |||
| @@ -67,9 +67,9 @@ LogManager::LogManager() | |||
| 67 | m_Log[LogTypes::RENDER] = new LogContainer("RENDER", "RENDER"); | 67 | m_Log[LogTypes::RENDER] = new LogContainer("RENDER", "RENDER"); |
| 68 | m_Log[LogTypes::LCD] = new LogContainer("LCD", "LCD"); | 68 | m_Log[LogTypes::LCD] = new LogContainer("LCD", "LCD"); |
| 69 | m_Log[LogTypes::WII_IPC_NET] = new LogContainer("WII_IPC_NET", "WII IPC NET"); | 69 | m_Log[LogTypes::WII_IPC_NET] = new LogContainer("WII_IPC_NET", "WII IPC NET"); |
| 70 | m_Log[LogTypes::WII_IPC_WC24] = new LogContainer("WII_IPC_WC24", "WII IPC WC24"); | 70 | m_Log[LogTypes::NDMA] = new LogContainer("NDMA", "NDMA"); |
| 71 | m_Log[LogTypes::WII_IPC_SSL] = new LogContainer("WII_IPC_SSL", "WII IPC SSL"); | 71 | m_Log[LogTypes::HLE] = new LogContainer("HLE", "High Level Emulation"); |
| 72 | m_Log[LogTypes::HW] = new LogContainer("HARDWARE", "HARDWARE"); | 72 | m_Log[LogTypes::HW] = new LogContainer("HW", "Hardware"); |
| 73 | m_Log[LogTypes::ACTIONREPLAY] = new LogContainer("ActionReplay", "ActionReplay"); | 73 | m_Log[LogTypes::ACTIONREPLAY] = new LogContainer("ActionReplay", "ActionReplay"); |
| 74 | m_Log[LogTypes::MEMCARD_MANAGER] = new LogContainer("MemCard Manager", "MemCard Manager"); | 74 | m_Log[LogTypes::MEMCARD_MANAGER] = new LogContainer("MemCard Manager", "MemCard Manager"); |
| 75 | m_Log[LogTypes::NETPLAY] = new LogContainer("NETPLAY", "Netplay"); | 75 | m_Log[LogTypes::NETPLAY] = new LogContainer("NETPLAY", "Netplay"); |
diff --git a/src/common/string_util.cpp b/src/common/string_util.cpp index a99644f11..e5a9ba322 100644 --- a/src/common/string_util.cpp +++ b/src/common/string_util.cpp | |||
| @@ -17,6 +17,22 @@ | |||
| 17 | #include <errno.h> | 17 | #include <errno.h> |
| 18 | #endif | 18 | #endif |
| 19 | 19 | ||
| 20 | /// Make a string lowercase | ||
| 21 | void LowerStr(char* str) { | ||
| 22 | for (int i = 0; str[i]; i++) { | ||
| 23 | str[i] = tolower(str[ i ]); | ||
| 24 | } | ||
| 25 | } | ||
| 26 | |||
| 27 | /// Make a string uppercase | ||
| 28 | void UpperStr(char* str) { | ||
| 29 | for (int i=0; i < strlen(str); i++) { | ||
| 30 | if(str[i] >= 'a' && str[i] <= 'z') { | ||
| 31 | str[i] &= 0xDF; | ||
| 32 | } | ||
| 33 | } | ||
| 34 | } | ||
| 35 | |||
| 20 | // faster than sscanf | 36 | // faster than sscanf |
| 21 | bool AsciiToHex(const char* _szValue, u32& result) | 37 | bool AsciiToHex(const char* _szValue, u32& result) |
| 22 | { | 38 | { |
diff --git a/src/common/string_util.h b/src/common/string_util.h index 6b7e84797..b3c99a807 100644 --- a/src/common/string_util.h +++ b/src/common/string_util.h | |||
| @@ -14,6 +14,12 @@ | |||
| 14 | 14 | ||
| 15 | #include "common/common.h" | 15 | #include "common/common.h" |
| 16 | 16 | ||
| 17 | /// Make a string lowercase | ||
| 18 | void LowerStr(char* str); | ||
| 19 | |||
| 20 | /// Make a string uppercase | ||
| 21 | void UpperStr(char* str); | ||
| 22 | |||
| 17 | std::string StringFromFormat(const char* format, ...); | 23 | std::string StringFromFormat(const char* format, ...); |
| 18 | // Cheap! | 24 | // Cheap! |
| 19 | bool CharArrayFromFormatV(char* out, int outsize, const char* format, va_list args); | 25 | bool CharArrayFromFormatV(char* out, int outsize, const char* format, va_list args); |