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

Side by Side Diff: chrome/renderer/extensions/dispatcher.cc

Issue 11574006: Implement chrome.downloads.onDeterminingFilename() (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: @r185803 Created 7 years, 9 months 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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/renderer/extensions/dispatcher.h" 5 #include "chrome/renderer/extensions/dispatcher.h"
6 6
7 #include "base/callback.h" 7 #include "base/callback.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "base/string_piece.h" 10 #include "base/string_piece.h"
(...skipping 768 matching lines...) Expand 10 before | Expand all | Expand 10 after
779 source_map_.RegisterSource("browserAction", 779 source_map_.RegisterSource("browserAction",
780 IDR_BROWSER_ACTION_CUSTOM_BINDINGS_JS); 780 IDR_BROWSER_ACTION_CUSTOM_BINDINGS_JS);
781 source_map_.RegisterSource("contentSettings", 781 source_map_.RegisterSource("contentSettings",
782 IDR_CONTENT_SETTINGS_CUSTOM_BINDINGS_JS); 782 IDR_CONTENT_SETTINGS_CUSTOM_BINDINGS_JS);
783 source_map_.RegisterSource("contextMenus", 783 source_map_.RegisterSource("contextMenus",
784 IDR_CONTEXT_MENUS_CUSTOM_BINDINGS_JS); 784 IDR_CONTEXT_MENUS_CUSTOM_BINDINGS_JS);
785 source_map_.RegisterSource("declarativeContent", 785 source_map_.RegisterSource("declarativeContent",
786 IDR_DECLARATIVE_CONTENT_CUSTOM_BINDINGS_JS); 786 IDR_DECLARATIVE_CONTENT_CUSTOM_BINDINGS_JS);
787 source_map_.RegisterSource("declarativeWebRequest", 787 source_map_.RegisterSource("declarativeWebRequest",
788 IDR_DECLARATIVE_WEBREQUEST_CUSTOM_BINDINGS_JS); 788 IDR_DECLARATIVE_WEBREQUEST_CUSTOM_BINDINGS_JS);
789 source_map_.RegisterSource("downloads",
790 IDR_DOWNLOADS_CUSTOM_BINDINGS_JS);
789 source_map_.RegisterSource( 791 source_map_.RegisterSource(
790 "experimental.mediaGalleries", 792 "experimental.mediaGalleries",
791 IDR_EXPERIMENTAL_MEDIA_GALLERIES_CUSTOM_BINDINGS_JS); 793 IDR_EXPERIMENTAL_MEDIA_GALLERIES_CUSTOM_BINDINGS_JS);
792 source_map_.RegisterSource("experimental.offscreen", 794 source_map_.RegisterSource("experimental.offscreen",
793 IDR_EXPERIMENTAL_OFFSCREENTABS_CUSTOM_BINDINGS_JS); 795 IDR_EXPERIMENTAL_OFFSCREENTABS_CUSTOM_BINDINGS_JS);
794 source_map_.RegisterSource("experimental.notification", 796 source_map_.RegisterSource("experimental.notification",
795 IDR_NOTIFICATION_CUSTOM_BINDINGS_JS); 797 IDR_NOTIFICATION_CUSTOM_BINDINGS_JS);
796 source_map_.RegisterSource("extension", IDR_EXTENSION_CUSTOM_BINDINGS_JS); 798 source_map_.RegisterSource("extension", IDR_EXTENSION_CUSTOM_BINDINGS_JS);
797 source_map_.RegisterSource("fileBrowserHandler", 799 source_map_.RegisterSource("fileBrowserHandler",
798 IDR_FILE_BROWSER_HANDLER_CUSTOM_BINDINGS_JS); 800 IDR_FILE_BROWSER_HANDLER_CUSTOM_BINDINGS_JS);
(...skipping 500 matching lines...) Expand 10 before | Expand all | Expand 10 after
1299 std::string error_msg = base::StringPrintf(kMessage, function_name.c_str()); 1301 std::string error_msg = base::StringPrintf(kMessage, function_name.c_str());
1300 v8::ThrowException( 1302 v8::ThrowException(
1301 v8::Exception::Error(v8::String::New(error_msg.c_str()))); 1303 v8::Exception::Error(v8::String::New(error_msg.c_str())));
1302 return false; 1304 return false;
1303 } 1305 }
1304 1306
1305 return true; 1307 return true;
1306 } 1308 }
1307 1309
1308 } // namespace extensions 1310 } // namespace extensions
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698