| 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 15 matching lines...) Expand all Loading... |
| 26 #include "web/ColorChooserPopupUIController.h" | 26 #include "web/ColorChooserPopupUIController.h" |
| 27 | 27 |
| 28 #include "core/frame/FrameView.h" | 28 #include "core/frame/FrameView.h" |
| 29 #include "core/frame/LocalFrame.h" | 29 #include "core/frame/LocalFrame.h" |
| 30 #include "core/html/forms/ColorChooserClient.h" | 30 #include "core/html/forms/ColorChooserClient.h" |
| 31 #include "core/page/PagePopup.h" | 31 #include "core/page/PagePopup.h" |
| 32 #include "platform/geometry/IntRect.h" | 32 #include "platform/geometry/IntRect.h" |
| 33 #include "public/platform/Platform.h" | 33 #include "public/platform/Platform.h" |
| 34 #include "public/web/WebColorChooser.h" | 34 #include "public/web/WebColorChooser.h" |
| 35 #include "web/ChromeClientImpl.h" | 35 #include "web/ChromeClientImpl.h" |
| 36 #include "web/WebViewImpl.h" | |
| 37 | 36 |
| 38 namespace blink { | 37 namespace blink { |
| 39 | 38 |
| 40 // Keep in sync with Actions in colorSuggestionPicker.js. | 39 // Keep in sync with Actions in colorSuggestionPicker.js. |
| 41 enum ColorPickerPopupAction { | 40 enum ColorPickerPopupAction { |
| 42 kColorPickerPopupActionChooseOtherColor = -2, | 41 kColorPickerPopupActionChooseOtherColor = -2, |
| 43 kColorPickerPopupActionCancel = -1, | 42 kColorPickerPopupActionCancel = -1, |
| 44 kColorPickerPopupActionSetValue = 0 | 43 kColorPickerPopupActionSetValue = 0 |
| 45 }; | 44 }; |
| 46 | 45 |
| (...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 152 popup_ = chrome_client_->OpenPagePopup(this); | 151 popup_ = chrome_client_->OpenPagePopup(this); |
| 153 } | 152 } |
| 154 | 153 |
| 155 void ColorChooserPopupUIController::ClosePopup() { | 154 void ColorChooserPopupUIController::ClosePopup() { |
| 156 if (!popup_) | 155 if (!popup_) |
| 157 return; | 156 return; |
| 158 chrome_client_->ClosePagePopup(popup_); | 157 chrome_client_->ClosePagePopup(popup_); |
| 159 } | 158 } |
| 160 | 159 |
| 161 } // namespace blink | 160 } // namespace blink |
| OLD | NEW |