@@ -88,12 +88,10 @@ Anvil::WindowUniquePtr Anvil::WindowWin3264::create(const std::string&
8888/* * Please see header for specification */
8989Anvil::WindowUniquePtr Anvil::WindowWin3264::create (HWND in_window_handle)
9090{
91- WindowUniquePtr result_ptr (nullptr ,
92- std::default_delete<Window>() );
93- RECT window_rect;
94- uint32_t window_size[2 ] = {0 };
95- std::vector<char > window_title;
96- uint32_t window_title_length = 0 ;
91+ WindowUniquePtr result_ptr (nullptr ,
92+ std::default_delete<Window>() );
93+ RECT window_rect;
94+ uint32_t window_size[2 ] = {0 };
9795
9896 /* The window has already been spawned by the user. Gather all the info we need in order to instantiate
9997 * the wrapper instance.
@@ -116,21 +114,10 @@ Anvil::WindowUniquePtr Anvil::WindowWin3264::create(HWND in_window_handle)
116114 window_size[0 ] = static_cast <uint32_t >(window_rect.right - window_rect.left );
117115 window_size[1 ] = static_cast <uint32_t >(window_rect.bottom - window_rect.top );
118116
119- window_title_length = static_cast <uint32_t >(::GetWindowTextLength (in_window_handle) );
120-
121- if (window_title_length != 0 )
122- {
123- window_title.resize (window_title_length);
124-
125- ::GetWindowText (in_window_handle,
126- static_cast <LPSTR>(&window_title.at(0 ) ),
127- static_cast<int> (window_title_length) );
128- }
129-
130117 /* Go ahead and create the window wrapper instance */
131118 result_ptr.reset (
132119 new Anvil::WindowWin3264 (in_window_handle,
133- std::string (&window_title. at ( 0 ) ) ,
120+ " HWND wrapper window instance " ,
134121 window_size[0 ],
135122 window_size[1 ],
136123 nullptr ) /* present_callback_func_ptr */
0 commit comments