aboutsummaryrefslogtreecommitdiff
path: root/Minecraft.Client/Common/XUI/XUI_Ctrl_SliderWrapper.cpp
diff options
context:
space:
mode:
authorLoki Rautio <lokirautio@gmail.com>2026-03-07 21:12:22 -0600
committerLoki Rautio <lokirautio@gmail.com>2026-03-07 21:12:22 -0600
commit087b7e7abfe81dd7f0fdcdea36ac9f245950df1a (patch)
tree69454763e73ca764af4e682d3573080b13138a0e /Minecraft.Client/Common/XUI/XUI_Ctrl_SliderWrapper.cpp
parenta9be52c41a02d207233199e98898fe7483d7e817 (diff)
Revert "Project modernization (#630)"
This code was not tested and breaks in Release builds, reverting to restore functionality of the nightly. All in-game menus do not work and generating a world crashes. This reverts commit a9be52c41a02d207233199e98898fe7483d7e817.
Diffstat (limited to 'Minecraft.Client/Common/XUI/XUI_Ctrl_SliderWrapper.cpp')
-rw-r--r--Minecraft.Client/Common/XUI/XUI_Ctrl_SliderWrapper.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/Minecraft.Client/Common/XUI/XUI_Ctrl_SliderWrapper.cpp b/Minecraft.Client/Common/XUI/XUI_Ctrl_SliderWrapper.cpp
index 18995854..a4e9f6be 100644
--- a/Minecraft.Client/Common/XUI/XUI_Ctrl_SliderWrapper.cpp
+++ b/Minecraft.Client/Common/XUI/XUI_Ctrl_SliderWrapper.cpp
@@ -10,11 +10,11 @@ HRESULT CXuiCtrlSliderWrapper::OnInit( XUIMessageInit* pInitData, BOOL& bHandled
XuiElementGetChildById(m_hObj,L"FocusSink",&hObjChild);
XuiObjectFromHandle( hObjChild, &pObj );
- m_pFocusSink = static_cast<CXuiControl *>(pObj);
+ m_pFocusSink = (CXuiControl *)pObj;
XuiElementGetChildById(m_hObj,L"XuiSlider",&hObjChild);
XuiObjectFromHandle( hObjChild, &pObj );
- m_pSlider = static_cast<CXuiSlider *>(pObj);
+ m_pSlider = (CXuiSlider *)pObj;
m_sliderActive = false;
m_bDisplayVal=true;
@@ -119,7 +119,7 @@ HRESULT CXuiCtrlSliderWrapper::SetValueDisplay( BOOL bShow )
hr=XuiControlGetVisual(pThis->m_pSlider->m_hObj,&hVisual);
hr=XuiElementGetChildById(hVisual,L"Text_Value",&hText);
- if(hText!=nullptr)
+ if(hText!=NULL)
{
XuiElementSetShow(hText,bShow);
}
@@ -132,7 +132,7 @@ LPCWSTR CXuiCtrlSliderWrapper::GetText( )
CXuiCtrlSliderWrapper *pThis;
HRESULT hr = XuiObjectFromHandle(m_hObj, (void **) &pThis);
if (FAILED(hr))
- return nullptr;
+ return NULL;
return pThis->m_pSlider->GetText();
//return S_OK;
}
@@ -159,7 +159,7 @@ HXUIOBJ CXuiCtrlSliderWrapper::GetSlider()
CXuiCtrlSliderWrapper *pThis;
HRESULT hr = XuiObjectFromHandle(m_hObj, (void **) &pThis);
if (FAILED(hr))
- return nullptr;
+ return NULL;
return pThis->m_pSlider->m_hObj;
}