Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(234)

Side by Side Diff: chrome/browser/extensions/extension_menu_manager.cc

Issue 5712003: webkit: use string16 in ContextMenuParams (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: works Created 10 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/extensions/extension_menu_manager.h" 5 #include "chrome/browser/extensions/extension_menu_manager.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "app/l10n_util.h" 9 #include "app/l10n_util.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 392 matching lines...) Expand 10 before | Expand all | Expand 10 after
403 break; 403 break;
404 default: {} // Do nothing. 404 default: {} // Do nothing.
405 } 405 }
406 406
407 AddURLProperty(properties, "linkUrl", params.unfiltered_link_url); 407 AddURLProperty(properties, "linkUrl", params.unfiltered_link_url);
408 AddURLProperty(properties, "srcUrl", params.src_url); 408 AddURLProperty(properties, "srcUrl", params.src_url);
409 AddURLProperty(properties, "pageUrl", params.page_url); 409 AddURLProperty(properties, "pageUrl", params.page_url);
410 AddURLProperty(properties, "frameUrl", params.frame_url); 410 AddURLProperty(properties, "frameUrl", params.frame_url);
411 411
412 if (params.selection_text.length() > 0) 412 if (params.selection_text.length() > 0)
413 properties->SetString("selectionText", 413 properties->SetString("selectionText", params.selection_text);
414 WideToUTF16Hack(params.selection_text));
415 414
416 properties->SetBoolean("editable", params.is_editable); 415 properties->SetBoolean("editable", params.is_editable);
417 416
418 args.Append(properties); 417 args.Append(properties);
419 418
420 // Add the tab info to the argument list. 419 // Add the tab info to the argument list.
421 if (tab_contents) { 420 if (tab_contents) {
422 args.Append(ExtensionTabUtil::CreateTabValue(tab_contents)); 421 args.Append(ExtensionTabUtil::CreateTabValue(tab_contents));
423 } else { 422 } else {
424 args.Append(new DictionaryValue()); 423 args.Append(new DictionaryValue());
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
495 if (profile < other.profile) 494 if (profile < other.profile)
496 return true; 495 return true;
497 if (profile == other.profile) { 496 if (profile == other.profile) {
498 if (extension_id < other.extension_id) 497 if (extension_id < other.extension_id)
499 return true; 498 return true;
500 if (extension_id == other.extension_id) 499 if (extension_id == other.extension_id)
501 return uid < other.uid; 500 return uid < other.uid;
502 } 501 }
503 return false; 502 return false;
504 } 503 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698