OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2012 Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
6 * met: | 6 * met: |
7 * | 7 * |
8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
63 } | 63 } |
64 | 64 |
65 void PagePopupController::closePopup() | 65 void PagePopupController::closePopup() |
66 { | 66 { |
67 if (m_popupClient) | 67 if (m_popupClient) |
68 m_popupClient->closePopup(); | 68 m_popupClient->closePopup(); |
69 } | 69 } |
70 | 70 |
71 void PagePopupController::selectFontsFromOwnerDocument(Document* targetDocument) | 71 void PagePopupController::selectFontsFromOwnerDocument(Document* targetDocument) |
72 { | 72 { |
73 if (!targetDocument || !m_popupClient) | 73 ASSERT(targetDocument); |
74 return; | 74 if (m_popupClient) |
75 m_popupClient->selectFontsFromOwnerDocument(*targetDocument); | 75 m_popupClient->selectFontsFromOwnerDocument(*targetDocument); |
76 } | 76 } |
77 | 77 |
78 String PagePopupController::localizeNumberString(const String& numberString) | 78 String PagePopupController::localizeNumberString(const String& numberString) |
79 { | 79 { |
80 if (m_popupClient) | 80 if (m_popupClient) |
81 return m_popupClient->locale().convertToLocalizedNumber(numberString); | 81 return m_popupClient->locale().convertToLocalizedNumber(numberString); |
82 return numberString; | 82 return numberString; |
83 } | 83 } |
84 | 84 |
85 String PagePopupController::formatMonth(int year, int zeroBaseMonth) | 85 String PagePopupController::formatMonth(int year, int zeroBaseMonth) |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
120 { | 120 { |
121 Platform::current()->histogramEnumeration(name.utf8().data(), sample, bounda
ryValue); | 121 Platform::current()->histogramEnumeration(name.utf8().data(), sample, bounda
ryValue); |
122 } | 122 } |
123 | 123 |
124 void PagePopupController::setWindowRect(int x, int y, int width, int height) | 124 void PagePopupController::setWindowRect(int x, int y, int width, int height) |
125 { | 125 { |
126 m_popup.setWindowRect(IntRect(x, y, width, height)); | 126 m_popup.setWindowRect(IntRect(x, y, width, height)); |
127 } | 127 } |
128 | 128 |
129 } // namespace blink | 129 } // namespace blink |
OLD | NEW |