[Webkit-unassigned] [Bug 31597] locale for text breakiterator and string search is not set to the UI locale

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Nov 17 21:51:19 PST 2009


https://bugs.webkit.org/show_bug.cgi?id=31597





--- Comment #1 from Darin Adler <darin at apple.com>  2009-11-17 21:51:17 PST ---
(From update of attachment 43380)
>  const char* currentSearchLocaleID()
>  {
> -    // FIXME: Should use system locale.
> -    return "";
> +    // Chrome's UI language can be different from the OS UI language on Windows.
> +    // We want to return Chrome's UI language here.
> +    return defaultLanguage().ascii().data();
>  }

This will create a local CString, take a pointer to its contents, then destroy
the CString and return a pointer to the destroyed memory. So you definitely
can't land this as-is.

The concept is probably OK for Chromium.

For Mac OS X it would not be good to use defaultLanguage() for everything, so
it's good that you did not try to change all ports to work this way. Mac OS X
has a separate preference for "Order for sorted lists" that should be used for
searches but not text breaking.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list