| 1848 | |
| 1849 | |
| 1850 | ResultType GuiType::ControlGetEdit(ResultToken &aResultToken, GuiControlType &aControl) |
| 1851 | // Only called by Edit.Value, so aTranslateEOL == true is implied. |
| 1852 | { |
| 1853 | if (!ControlGetWindowText(aResultToken, aControl)) |
| 1854 | return FAIL; |
| 1855 | if (GetWindowLong(aControl.hwnd, GWL_STYLE) & ES_MULTILINE) // For consistency with ControlSetEdit(). |
| 1856 | { |
| 1857 | // Auto-translate CRLF to LF for better compatibility with other script commands. |
| 1858 | // Since edit controls tend to have many hard returns in them, use SCS_SENSITIVE to |
| 1859 | // enhance performance. This performance gain is extreme when the control contains |
| 1860 | // thousands of CRLFs: |
| 1861 | StrReplace(aResultToken.marker, _T("\r\n"), _T("\n"), SCS_SENSITIVE |
| 1862 | , -1, -1, NULL, &aResultToken.marker_length); // Pass &marker_length to improve performance and (more importantly) update it. |
| 1863 | } |
| 1864 | return OK; |
| 1865 | } |
| 1866 | |
| 1867 | |
| 1868 | ResultType GuiType::ControlSetDateTime(GuiControlType &aControl, LPTSTR aContents, ResultToken &aResultToken) |
nothing calls this directly
no test coverage detected