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 | 5 * modification, are permitted provided that the following conditions |
6 * are met: | 6 * are met: |
7 * | 7 * |
8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. 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 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
72 OpenColorChooser(); | 72 OpenColorChooser(); |
73 } | 73 } |
74 | 74 |
75 void ColorChooserPopupUIController::EndChooser() { | 75 void ColorChooserPopupUIController::EndChooser() { |
76 if (chooser_) | 76 if (chooser_) |
77 chooser_->EndChooser(); | 77 chooser_->EndChooser(); |
78 | 78 |
79 ClosePopup(); | 79 ClosePopup(); |
80 } | 80 } |
81 | 81 |
82 AXObject* ColorChooserPopupUIController::RootAXObject() { | 82 AXObjectImpl* ColorChooserPopupUIController::RootAXObject() { |
83 return popup_ ? popup_->RootAXObject() : nullptr; | 83 return popup_ ? popup_->RootAXObject() : nullptr; |
84 } | 84 } |
85 | 85 |
86 void ColorChooserPopupUIController::WriteDocument(SharedBuffer* data) { | 86 void ColorChooserPopupUIController::WriteDocument(SharedBuffer* data) { |
87 Vector<ColorSuggestion> suggestions = client_->Suggestions(); | 87 Vector<ColorSuggestion> suggestions = client_->Suggestions(); |
88 Vector<String> suggestion_values; | 88 Vector<String> suggestion_values; |
89 for (unsigned i = 0; i < suggestions.size(); i++) | 89 for (unsigned i = 0; i < suggestions.size(); i++) |
90 suggestion_values.push_back(suggestions[i].color.Serialized()); | 90 suggestion_values.push_back(suggestions[i].color.Serialized()); |
91 IntRect anchor_rect_in_screen = chrome_client_->ViewportToScreen( | 91 IntRect anchor_rect_in_screen = chrome_client_->ViewportToScreen( |
92 client_->ElementRectRelativeToViewport(), frame_->View()); | 92 client_->ElementRectRelativeToViewport(), frame_->View()); |
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
151 popup_ = chrome_client_->OpenPagePopup(this); | 151 popup_ = chrome_client_->OpenPagePopup(this); |
152 } | 152 } |
153 | 153 |
154 void ColorChooserPopupUIController::ClosePopup() { | 154 void ColorChooserPopupUIController::ClosePopup() { |
155 if (!popup_) | 155 if (!popup_) |
156 return; | 156 return; |
157 chrome_client_->ClosePagePopup(popup_); | 157 chrome_client_->ClosePagePopup(popup_); |
158 } | 158 } |
159 | 159 |
160 } // namespace blink | 160 } // namespace blink |
OLD | NEW |