Fixed #110 can not compile under /permissive mode
This commit is contained in:
parent
0ccc90ac94
commit
45c5104ce0
@ -27,7 +27,7 @@ public:
|
|||||||
template<typename InheritType>
|
template<typename InheritType>
|
||||||
UINT ui::ButtonTemplate<InheritType>::GetControlFlags() const
|
UINT ui::ButtonTemplate<InheritType>::GetControlFlags() const
|
||||||
{
|
{
|
||||||
return IsKeyboardEnabled() && IsEnabled() ? UIFLAG_TABSTOP : UIFLAG_DEFAULT;
|
return this->IsKeyboardEnabled() && this->IsEnabled() ? UIFLAG_TABSTOP : UIFLAG_DEFAULT;
|
||||||
}
|
}
|
||||||
|
|
||||||
template<typename InheritType>
|
template<typename InheritType>
|
||||||
|
@ -301,7 +301,9 @@ CTxtWinHost::~CTxtWinHost()
|
|||||||
|
|
||||||
BOOL CTxtWinHost::Init(RichEdit *re, const CREATESTRUCT *pcs)
|
BOOL CTxtWinHost::Init(RichEdit *re, const CREATESTRUCT *pcs)
|
||||||
{
|
{
|
||||||
|
PCreateTextServices TextServicesProc = nullptr;
|
||||||
IUnknown *pUnk = nullptr;
|
IUnknown *pUnk = nullptr;
|
||||||
|
HMODULE hmod = NULL;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
std::wstring edit_dll(L"msftedit.dll");
|
std::wstring edit_dll(L"msftedit.dll");
|
||||||
m_re = re;
|
m_re = re;
|
||||||
@ -349,7 +351,6 @@ BOOL CTxtWinHost::Init(RichEdit *re, const CREATESTRUCT *pcs)
|
|||||||
//if(FAILED(CreateTextServices(NULL, this, &pUnk)))
|
//if(FAILED(CreateTextServices(NULL, this, &pUnk)))
|
||||||
// goto err;
|
// goto err;
|
||||||
|
|
||||||
PCreateTextServices TextServicesProc = nullptr;
|
|
||||||
//解决32位系统下跨窗口间拖拽文字在win7及win7以下系统上会出现重复的问题(64位暂不修复) lty 20170714
|
//解决32位系统下跨窗口间拖拽文字在win7及win7以下系统上会出现重复的问题(64位暂不修复) lty 20170714
|
||||||
#if defined(_M_X64) || defined(__x86_64__)
|
#if defined(_M_X64) || defined(__x86_64__)
|
||||||
edit_dll = L"msftedit.dll";
|
edit_dll = L"msftedit.dll";
|
||||||
@ -358,7 +359,7 @@ BOOL CTxtWinHost::Init(RichEdit *re, const CREATESTRUCT *pcs)
|
|||||||
if (!(::GetFileAttributesW(edit_dll.c_str()) != INVALID_FILE_ATTRIBUTES))
|
if (!(::GetFileAttributesW(edit_dll.c_str()) != INVALID_FILE_ATTRIBUTES))
|
||||||
edit_dll = L"msftedit.dll";
|
edit_dll = L"msftedit.dll";
|
||||||
#endif
|
#endif
|
||||||
HMODULE hmod = LoadLibraryW(edit_dll.c_str()); //msftedit.dll
|
hmod = LoadLibraryW(edit_dll.c_str()); //msftedit.dll
|
||||||
if (hmod)
|
if (hmod)
|
||||||
{
|
{
|
||||||
TextServicesProc = (PCreateTextServices)GetProcAddress(hmod,"CreateTextServices");
|
TextServicesProc = (PCreateTextServices)GetProcAddress(hmod,"CreateTextServices");
|
||||||
|
Loading…
Reference in New Issue
Block a user