From 01724cfaad1a98860db7ad145f015437d4fa1aae Mon Sep 17 00:00:00 2001 From: Marvin D <41352111+IcePixelx@users.noreply.github.com> Date: Wed, 21 Dec 2022 15:55:52 +0100 Subject: [PATCH] vtable.cpp clean up --- r5dev/public/utility/vtable.cpp | 6 +++--- r5dev/public/utility/vtable.h | 8 ++++---- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/r5dev/public/utility/vtable.cpp b/r5dev/public/utility/vtable.cpp index d5817092..278b7e78 100644 --- a/r5dev/public/utility/vtable.cpp +++ b/r5dev/public/utility/vtable.cpp @@ -14,7 +14,7 @@ // const std::string& - // uint32_t //----------------------------------------------------------------------------- -CVTableHelper::CVTableHelper(CModule* module, const std::string& tableName, uint32_t refIndex) : m_svVirtualTableName(tableName) +CVTableHelper::CVTableHelper(CModule* module, const string& tableName, uint32_t refIndex) : m_svVirtualTableName(tableName) { m_pVirtualTable = module->GetVirtualMethodTable(tableName, refIndex); m_nVirtualFunctionCount = GetVTableLength(); @@ -27,7 +27,7 @@ CVTableHelper::CVTableHelper(CModule* module, const std::string& tableName, uint // Input : uintptr_t - // const std::string& - //----------------------------------------------------------------------------- -CVTableHelper::CVTableHelper(uintptr_t virtualTable, const std::string& tableName) : m_pVirtualTable(virtualTable), m_svVirtualTableName(tableName) +CVTableHelper::CVTableHelper(uintptr_t virtualTable, const string& tableName) : m_pVirtualTable(virtualTable), m_svVirtualTableName(tableName) { m_nVirtualFunctionCount = GetVTableLength(); GetAllVTableFunctions(); @@ -39,7 +39,7 @@ CVTableHelper::CVTableHelper(uintptr_t virtualTable, const std::string& tableNam // Input : void* - // const std::string& - //----------------------------------------------------------------------------- -CVTableHelper::CVTableHelper(void* virtualTable, const std::string& tableName) : m_pVirtualTable(uintptr_t(virtualTable)), m_svVirtualTableName(tableName) +CVTableHelper::CVTableHelper(void* virtualTable, const string& tableName) : m_pVirtualTable(uintptr_t(virtualTable)), m_svVirtualTableName(tableName) { m_nVirtualFunctionCount = GetVTableLength(); GetAllVTableFunctions(); diff --git a/r5dev/public/utility/vtable.h b/r5dev/public/utility/vtable.h index 247255fd..f2240554 100644 --- a/r5dev/public/utility/vtable.h +++ b/r5dev/public/utility/vtable.h @@ -5,9 +5,9 @@ class CVTableHelper public: CVTableHelper(void) = default; - CVTableHelper(CModule* module, const std::string& tableName = "", uint32_t refIndex = 0); - CVTableHelper(uintptr_t virtualTable, const std::string& tableName = ""); - CVTableHelper(void* virtualTable, const std::string& tableName = ""); + CVTableHelper(CModule* module, const string& tableName = "", uint32_t refIndex = 0); + CVTableHelper(uintptr_t virtualTable, const string& tableName = ""); + CVTableHelper(void* virtualTable, const string& tableName = ""); inline operator uintptr_t(void) const { @@ -34,7 +34,7 @@ public: return m_nVirtualFunctionCount; } - const std::string& GetVTableName() + const string& GetVTableName() { return m_svVirtualTableName; }