1 // Windows/ResourceString.cpp
5 #include "Windows/ResourceString.h"
7 #include "Common/StringConvert.h"
10 extern HINSTANCE g_hInstance;
17 CSysString MyLoadString(HINSTANCE hInstance, UINT resourceID)
25 len = ::LoadString(hInstance, resourceID, s.GetBuffer(size - 1), size);
27 while (size - len <= 1);
32 CSysString MyLoadString(UINT resourceID)
34 return MyLoadString(g_hInstance, resourceID);
38 UString MyLoadStringW(HINSTANCE hInstance, UINT resourceID)
48 len = ::LoadStringW(hInstance, resourceID, s.GetBuffer(size - 1), size);
50 while (size - len <= 1);
54 return GetUnicodeString(MyLoadString(hInstance, resourceID));
57 UString MyLoadStringW(UINT resourceID)
59 return MyLoadStringW(g_hInstance, resourceID);