Chromium Code Reviews| Index: base/i18n/rtl.h |
| diff --git a/base/i18n/rtl.h b/base/i18n/rtl.h |
| index a75ed4f967bcd20bd42048994bf5114d51825917..bca4d3bad4c625bf352b8c244410ac73ac71ca22 100644 |
| --- a/base/i18n/rtl.h |
| +++ b/base/i18n/rtl.h |
| @@ -31,6 +31,19 @@ enum TextDirection { |
| LEFT_TO_RIGHT, |
| }; |
| +// A string along with the text direction it should be displayed in. |
| +// Conceptually this is a struct; we just use 'class' to make it easier for |
| +// others to forward-declare us with 'class StringWithDirection'. |
| +class StringWithDirection { |
|
darin (slow to review)
2011/04/21 02:56:00
String16WithDirection maybe? see NullableString16
|
| +public: |
| + StringWithDirection() : direction(UNKNOWN_DIRECTION) { } |
| + StringWithDirection(const string16& str, TextDirection dir) |
| + : string(str), direction(dir) { } |
| + |
| + string16 string; |
|
darin (slow to review)
2011/04/21 02:56:00
do you need to mutate these later? how about just
|
| + TextDirection direction; |
| +}; |
| + |
| // Get the locale that the currently running process has been configured to use. |
| // The return value is of the form language[-country] (e.g., en-US) where the |
| // language is the 2 or 3 letter code from ISO-639. |