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 16 matching lines...) Expand all Loading... |
27 #include "web/ColorChooserPopupUIController.h" | 27 #include "web/ColorChooserPopupUIController.h" |
28 | 28 |
29 #include "core/frame/FrameView.h" | 29 #include "core/frame/FrameView.h" |
30 #include "platform/ColorChooserClient.h" | 30 #include "platform/ColorChooserClient.h" |
31 #include "platform/geometry/IntRect.h" | 31 #include "platform/geometry/IntRect.h" |
32 #include "public/platform/Platform.h" | 32 #include "public/platform/Platform.h" |
33 #include "public/web/WebColorChooser.h" | 33 #include "public/web/WebColorChooser.h" |
34 #include "web/ChromeClientImpl.h" | 34 #include "web/ChromeClientImpl.h" |
35 #include "web/WebViewImpl.h" | 35 #include "web/WebViewImpl.h" |
36 | 36 |
37 using namespace WebCore; | 37 using namespace blink; |
38 | 38 |
39 namespace blink { | 39 namespace blink { |
40 | 40 |
41 // Keep in sync with Actions in colorSuggestionPicker.js. | 41 // Keep in sync with Actions in colorSuggestionPicker.js. |
42 enum ColorPickerPopupAction { | 42 enum ColorPickerPopupAction { |
43 ColorPickerPopupActionChooseOtherColor = -2, | 43 ColorPickerPopupActionChooseOtherColor = -2, |
44 ColorPickerPopupActionCancel = -1, | 44 ColorPickerPopupActionCancel = -1, |
45 ColorPickerPopupActionSetValue = 0 | 45 ColorPickerPopupActionSetValue = 0 |
46 }; | 46 }; |
47 | 47 |
48 ColorChooserPopupUIController::ColorChooserPopupUIController(WebCore::LocalFrame
* frame, ChromeClientImpl* chromeClient, ColorChooserClient* client) | 48 ColorChooserPopupUIController::ColorChooserPopupUIController(blink::LocalFrame*
frame, ChromeClientImpl* chromeClient, ColorChooserClient* client) |
49 : ColorChooserUIController(frame, client) | 49 : ColorChooserUIController(frame, client) |
50 , m_chromeClient(chromeClient) | 50 , m_chromeClient(chromeClient) |
51 , m_client(client) | 51 , m_client(client) |
52 , m_popup(0) | 52 , m_popup(0) |
53 , m_locale(Locale::defaultLocale()) | 53 , m_locale(Locale::defaultLocale()) |
54 { | 54 { |
55 } | 55 } |
56 | 56 |
57 ColorChooserPopupUIController::~ColorChooserPopupUIController() | 57 ColorChooserPopupUIController::~ColorChooserPopupUIController() |
58 { | 58 { |
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
142 } | 142 } |
143 | 143 |
144 void ColorChooserPopupUIController::closePopup() | 144 void ColorChooserPopupUIController::closePopup() |
145 { | 145 { |
146 if (!m_popup) | 146 if (!m_popup) |
147 return; | 147 return; |
148 m_chromeClient->closePagePopup(m_popup); | 148 m_chromeClient->closePagePopup(m_popup); |
149 } | 149 } |
150 | 150 |
151 } | 151 } |
OLD | NEW |