Tentative implementation of wxStaticText::DoGetLabel().
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@45278 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
a8988cb339
commit
115de22f78
@ -283,7 +283,10 @@ void wxStaticText::DoSetLabel(const wxString& str)
|
||||
|
||||
wxString wxStaticText::DoGetLabel() const
|
||||
{
|
||||
// FIXME: how to retrieve the text?
|
||||
//return wxGetWindowText(GetHWND());
|
||||
HWND hwnd = GetHwnd();
|
||||
LONG textLen = ::WinQueryWindowTextLength(hwnd);
|
||||
wxCharBuffer buffer(textLen+1);
|
||||
::WinQueryWindowText(hwnd, textLen+1, buffer.data());
|
||||
return buffer;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user