Chromium Code Reviews| Index: content/shell/renderer/test_runner/event_sender.cc |
| diff --git a/content/shell/renderer/test_runner/event_sender.cc b/content/shell/renderer/test_runner/event_sender.cc |
| index 79071bfddfba42e27a0859165e2bf16ab63bdac8..f35cc260cad9630d6d021c80d8c1121f414d2752 100644 |
| --- a/content/shell/renderer/test_runner/event_sender.cc |
| +++ b/content/shell/renderer/test_runner/event_sender.cc |
| @@ -124,6 +124,7 @@ const double kMultipleClickTimeSec = 1; |
| const int kMultipleClickRadiusPixels = 5; |
| const char kSubMenuDepthIdentifier[] = "_"; |
| const char kSubMenuIdentifier[] = " >"; |
| +const char kSeparatorIdentifier[] = "Separator"; |
|
tkent
2014/08/25 20:20:53
I prefer that the string look special, rather than
|
| bool OutsideMultiClickRadius(const WebPoint& a, const WebPoint& b) { |
| return ((a.x - b.x) * (a.x - b.x) + (a.y - b.y) * (a.y - b.y)) > |
| @@ -133,7 +134,9 @@ bool OutsideMultiClickRadius(const WebPoint& a, const WebPoint& b) { |
| void PopulateCustomItems(const WebVector<WebMenuItemInfo>& customItems, |
| const std::string& prefix, std::vector<std::string>* strings) { |
| for (size_t i = 0; i < customItems.size(); ++i) { |
| - if (customItems[i].type == blink::WebMenuItemInfo::SubMenu) { |
| + if (customItems[i].type == blink::WebMenuItemInfo::Separator) { |
| + strings->push_back(prefix + kSeparatorIdentifier); |
| + } else if (customItems[i].type == blink::WebMenuItemInfo::SubMenu) { |
| strings->push_back(prefix + customItems[i].label.utf8() + |
| kSubMenuIdentifier); |
| PopulateCustomItems(customItems[i].subMenuItems, prefix + |