OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2006, 2007, 2012 Apple Inc. All rights reserved. | 2 * Copyright (C) 2006, 2007, 2012 Apple Inc. All rights reserved. |
3 * | 3 * |
4 * This library is free software; you can redistribute it and/or | 4 * This library is free software; you can redistribute it and/or |
5 * modify it under the terms of the GNU Library General Public | 5 * modify it under the terms of the GNU Library General Public |
6 * License as published by the Free Software Foundation; either | 6 * License as published by the Free Software Foundation; either |
7 * version 2 of the License, or (at your option) any later version. | 7 * version 2 of the License, or (at your option) any later version. |
8 * | 8 * |
9 * This library is distributed in the hope that it will be useful, | 9 * This library is distributed in the hope that it will be useful, |
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
(...skipping 15 matching lines...) Expand all Loading... |
26 #include "core/dom/shadow/ElementShadow.h" | 26 #include "core/dom/shadow/ElementShadow.h" |
27 #include "core/dom/shadow/ShadowRoot.h" | 27 #include "core/dom/shadow/ShadowRoot.h" |
28 #include "core/editing/PositionWithAffinity.h" | 28 #include "core/editing/PositionWithAffinity.h" |
29 #include "core/fileapi/FileList.h" | 29 #include "core/fileapi/FileList.h" |
30 #include "core/html/HTMLInputElement.h" | 30 #include "core/html/HTMLInputElement.h" |
31 #include "core/layout/LayoutButton.h" | 31 #include "core/layout/LayoutButton.h" |
32 #include "core/layout/LayoutTheme.h" | 32 #include "core/layout/LayoutTheme.h" |
33 #include "core/layout/TextRunConstructor.h" | 33 #include "core/layout/TextRunConstructor.h" |
34 #include "core/paint/FileUploadControlPainter.h" | 34 #include "core/paint/FileUploadControlPainter.h" |
35 #include "platform/fonts/Font.h" | 35 #include "platform/fonts/Font.h" |
36 #include "platform/graphics/GraphicsContextStateSaver.h" | |
37 #include "platform/text/PlatformLocale.h" | 36 #include "platform/text/PlatformLocale.h" |
38 #include "platform/text/TextRun.h" | 37 #include "platform/text/TextRun.h" |
39 #include <math.h> | 38 #include <math.h> |
40 | 39 |
41 namespace blink { | 40 namespace blink { |
42 | 41 |
43 using namespace HTMLNames; | 42 using namespace HTMLNames; |
44 | 43 |
45 const int defaultWidthNumChars = 34; | 44 const int defaultWidthNumChars = 34; |
46 | 45 |
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
161 } | 160 } |
162 | 161 |
163 String LayoutFileUploadControl::fileTextValue() const | 162 String LayoutFileUploadControl::fileTextValue() const |
164 { | 163 { |
165 HTMLInputElement* input = toHTMLInputElement(node()); | 164 HTMLInputElement* input = toHTMLInputElement(node()); |
166 ASSERT(input->files()); | 165 ASSERT(input->files()); |
167 return LayoutTheme::theme().fileListNameForWidth(input->locale(), input->fil
es(), style()->font(), maxFilenameWidth()); | 166 return LayoutTheme::theme().fileListNameForWidth(input->locale(), input->fil
es(), style()->font(), maxFilenameWidth()); |
168 } | 167 } |
169 | 168 |
170 } // namespace blink | 169 } // namespace blink |
OLD | NEW |