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

Side by Side Diff: chrome/renderer/extensions/logging_native_handler.h

Issue 234413005: Move most of ChromeV8Context to a base ScriptContext (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: factor feature_channel out of module_system Created 6 years, 8 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 #ifndef CHROME_RENDERER_EXTENSIONS_LOGGING_NATIVE_HANDLER_H_ 5 #ifndef CHROME_RENDERER_EXTENSIONS_LOGGING_NATIVE_HANDLER_H_
6 #define CHROME_RENDERER_EXTENSIONS_LOGGING_NATIVE_HANDLER_H_ 6 #define CHROME_RENDERER_EXTENSIONS_LOGGING_NATIVE_HANDLER_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "chrome/renderer/extensions/object_backed_native_handler.h" 10 #include "extensions/renderer/object_backed_native_handler.h"
11 11
12 namespace extensions { 12 namespace extensions {
13 class ScriptContext;
13 14
14 // Exposes logging.h macros to JavaScript bindings. 15 // Exposes logging.h macros to JavaScript bindings.
15 class LoggingNativeHandler : public ObjectBackedNativeHandler { 16 class LoggingNativeHandler : public ObjectBackedNativeHandler {
16 public: 17 public:
17 explicit LoggingNativeHandler(ChromeV8Context* context); 18 explicit LoggingNativeHandler(ScriptContext* context);
18 virtual ~LoggingNativeHandler(); 19 virtual ~LoggingNativeHandler();
19 20
20 // Equivalent to CHECK(predicate) << message. 21 // Equivalent to CHECK(predicate) << message.
21 // 22 //
22 // void(predicate, message?) 23 // void(predicate, message?)
23 void Check(const v8::FunctionCallbackInfo<v8::Value>& args); 24 void Check(const v8::FunctionCallbackInfo<v8::Value>& args);
24 25
25 // Equivalent to DCHECK(predicate) << message. 26 // Equivalent to DCHECK(predicate) << message.
26 // 27 //
27 // void(predicate, message?) 28 // void(predicate, message?)
(...skipping 18 matching lines...) Expand all
46 bool* check_value, 47 bool* check_value,
47 std::string* error_message); 48 std::string* error_message);
48 49
49 std::string ToStringOrDefault(const v8::Handle<v8::String>& v8_string, 50 std::string ToStringOrDefault(const v8::Handle<v8::String>& v8_string,
50 const std::string& dflt); 51 const std::string& dflt);
51 }; 52 };
52 53
53 } // namespace extensions 54 } // namespace extensions
54 55
55 #endif // CHROME_RENDERER_EXTENSIONS_LOGGING_NATIVE_HANDLER_H_ 56 #endif // CHROME_RENDERER_EXTENSIONS_LOGGING_NATIVE_HANDLER_H_
OLDNEW
« no previous file with comments | « chrome/renderer/extensions/file_system_natives.cc ('k') | chrome/renderer/extensions/logging_native_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698