Chromium Code Reviews| Index: content/renderer/context_menu_params_builder.cc |
| diff --git a/content/renderer/context_menu_params_builder.cc b/content/renderer/context_menu_params_builder.cc |
| index 63dcd4d1e7b6b3c5b903b9dac8906f4e88882da2..3d1397449b4e82d7fbf6d1dc85c7183443dd376a 100644 |
| --- a/content/renderer/context_menu_params_builder.cc |
| +++ b/content/renderer/context_menu_params_builder.cc |
| @@ -5,8 +5,11 @@ |
| #include "content/renderer/context_menu_params_builder.h" |
| #include "base/logging.h" |
| +#include "content/child/weburlresponse_extradata_impl.h" |
| #include "content/common/ssl_status_serialization.h" |
| +#include "content/public/common/content_client.h" |
|
jam
2015/05/15 06:52:19
nit: by convention we don't include content_client
megjablon
2015/05/15 20:31:08
Done.
|
| #include "content/public/common/context_menu_params.h" |
| +#include "content/public/renderer/content_renderer_client.h" |
| #include "content/renderer/dom_utils.h" |
| #include "content/renderer/history_serialization.h" |
| #include "content/renderer/menu_item_builder.h" |
| @@ -43,6 +46,11 @@ ContextMenuParams ContextMenuParamsBuilder::Build( |
| params.referrer_policy = data.referrerPolicy; |
| params.suggested_filename = data.suggestedFilename; |
| + if (!data.imageResponse.isNull()) { |
| + GetContentClient()->renderer()->AddContextMenuProperties( |
| + data.imageResponse, ¶ms.properties); |
| + } |
| + |
| for (size_t i = 0; i < data.dictionarySuggestions.size(); ++i) |
| params.dictionary_suggestions.push_back(data.dictionarySuggestions[i]); |