| OLD | NEW |
| 1 /** | 1 /** |
| 2 * This file is part of the theme implementation for form controls in WebCore. | 2 * This file is part of the theme implementation for form controls in WebCore. |
| 3 * | 3 * |
| 4 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2012 Apple Computer, Inc. | 4 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2012 Apple Computer, Inc. |
| 5 * | 5 * |
| 6 * This library is free software; you can redistribute it and/or | 6 * This library is free software; you can redistribute it and/or |
| 7 * modify it under the terms of the GNU Library General Public | 7 * modify it under the terms of the GNU Library General Public |
| 8 * License as published by the Free Software Foundation; either | 8 * License as published by the Free Software Foundation; either |
| 9 * version 2 of the License, or (at your option) any later version. | 9 * version 2 of the License, or (at your option) any later version. |
| 10 * | 10 * |
| (...skipping 816 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 827 { | 827 { |
| 828 if (width <= 0) | 828 if (width <= 0) |
| 829 return String(); | 829 return String(); |
| 830 | 830 |
| 831 String string; | 831 String string; |
| 832 if (fileList->isEmpty()) { | 832 if (fileList->isEmpty()) { |
| 833 string = locale.queryString(WebLocalizedString::FileButtonNoFileSelected
Label); | 833 string = locale.queryString(WebLocalizedString::FileButtonNoFileSelected
Label); |
| 834 } else if (fileList->length() == 1) { | 834 } else if (fileList->length() == 1) { |
| 835 string = fileList->item(0)->name(); | 835 string = fileList->item(0)->name(); |
| 836 } else { | 836 } else { |
| 837 // FIXME: Localization of fileList->length(). | 837 return StringTruncator::rightTruncate(locale.queryString(WebLocalizedStr
ing::MultipleFileUploadText, locale.convertToLocalizedNumber(String::number(file
List->length()))), width, font); |
| 838 return StringTruncator::rightTruncate(locale.queryString(WebLocalizedStr
ing::MultipleFileUploadText, String::number(fileList->length())), width, font); | |
| 839 } | 838 } |
| 840 | 839 |
| 841 return StringTruncator::centerTruncate(string, width, font); | 840 return StringTruncator::centerTruncate(string, width, font); |
| 842 } | 841 } |
| 843 | 842 |
| 844 bool LayoutTheme::shouldOpenPickerWithF4Key() const | 843 bool LayoutTheme::shouldOpenPickerWithF4Key() const |
| 845 { | 844 { |
| 846 return false; | 845 return false; |
| 847 } | 846 } |
| 848 | 847 |
| (...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 917 | 916 |
| 918 // padding - not honored by WinIE, needs to be removed. | 917 // padding - not honored by WinIE, needs to be removed. |
| 919 style.resetPadding(); | 918 style.resetPadding(); |
| 920 | 919 |
| 921 // border - honored by WinIE, but looks terrible (just paints in the control
box and turns off the Windows XP theme) | 920 // border - honored by WinIE, but looks terrible (just paints in the control
box and turns off the Windows XP theme) |
| 922 // for now, we will not honor it. | 921 // for now, we will not honor it. |
| 923 style.resetBorder(); | 922 style.resetBorder(); |
| 924 } | 923 } |
| 925 | 924 |
| 926 } // namespace blink | 925 } // namespace blink |
| OLD | NEW |