diff options
Diffstat (limited to 'webkit')
-rw-r--r-- | webkit/glue/event_conversion.h | 5 | ||||
-rw-r--r-- | webkit/glue/plugins/test/plugin_npobject_proxy_test.cc | 7 | ||||
-rw-r--r-- | webkit/glue/webframe_impl.h | 5 | ||||
-rw-r--r-- | webkit/glue/webframeloaderclient_impl.h | 6 | ||||
-rw-r--r-- | webkit/glue/webkit_glue.cc | 5 | ||||
-rw-r--r-- | webkit/glue/weburlrequest_impl.h | 7 | ||||
-rw-r--r-- | webkit/glue/webview_impl.h | 5 | ||||
-rw-r--r-- | webkit/port/bindings/scripts/CodeGeneratorV8.pm | 31 | ||||
-rw-r--r-- | webkit/port/bindings/v8/v8_binding.h | 7 | ||||
-rw-r--r-- | webkit/port/platform/TemporaryLinkStubs.cpp | 5 |
10 files changed, 53 insertions, 30 deletions
diff --git a/webkit/glue/event_conversion.h b/webkit/glue/event_conversion.h index 8c75070..8f37267 100644 --- a/webkit/glue/event_conversion.h +++ b/webkit/glue/event_conversion.h @@ -6,12 +6,13 @@ #define WEBKIT_GLUE_EVENT_CONVERSION_H__ #include "base/basictypes.h" +#include "base/compiler_specific.h" -#pragma warning(push, 0) +MSVC_PUSH_WARNING_LEVEL(0); #include "PlatformKeyboardEvent.h" #include "PlatformMouseEvent.h" #include "PlatformWheelEvent.h" -#pragma warning(pop) +MSVC_POP_WARNING(); namespace WebCore { class Widget; diff --git a/webkit/glue/plugins/test/plugin_npobject_proxy_test.cc b/webkit/glue/plugins/test/plugin_npobject_proxy_test.cc index c0ac83d..bc191be 100644 --- a/webkit/glue/plugins/test/plugin_npobject_proxy_test.cc +++ b/webkit/glue/plugins/test/plugin_npobject_proxy_test.cc @@ -2,8 +2,13 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. +#include "base/basictypes.h" +#include "base/compiler_specific.h" + +#if defined(OS_WIN) #define STRSAFE_NO_DEPRECATE #include <strsafe.h> +#endif #include "webkit/glue/plugins/test/plugin_npobject_proxy_test.h" namespace NPAPIClient { @@ -25,7 +30,7 @@ NPError NPObjectProxyTest::SetWindow(NPWindow* pNPWindow) { NPObject *doc = NPVARIANT_TO_OBJECT(docv); NPVariant strv; -#pragma warning(suppress: 4267) + MSVC_SUPPRESS_WARNING(4267); STRINGZ_TO_NPVARIANT("div", strv); NPVariant textv; diff --git a/webkit/glue/webframe_impl.h b/webkit/glue/webframe_impl.h index 53cea39..a9d1fc4 100644 --- a/webkit/glue/webframe_impl.h +++ b/webkit/glue/webframe_impl.h @@ -29,6 +29,7 @@ #include <string> #include "base/basictypes.h" +#include "base/compiler_specific.h" #include "base/gfx/platform_canvas.h" #include "base/scoped_ptr.h" #include "base/task.h" @@ -38,11 +39,11 @@ #include "webkit/glue/webplugin_delegate.h" #include "webkit/glue/webview_delegate.h" -#pragma warning(push, 0) +MSVC_PUSH_WARNING_LEVEL(0); #include "ResourceHandleClient.h" #include "Frame.h" #include "PlatformString.h" -#pragma warning(pop) +MSVC_POP_WARNING(); class AltErrorPageResourceFetcher; class WebErrorImpl; diff --git a/webkit/glue/webframeloaderclient_impl.h b/webkit/glue/webframeloaderclient_impl.h index bb0e35d..7612d88 100644 --- a/webkit/glue/webframeloaderclient_impl.h +++ b/webkit/glue/webframeloaderclient_impl.h @@ -5,9 +5,11 @@ #ifndef WEBKIT_GLUE_WEBFRAMELOADERCLIENT_IMPL_H__ #define WEBKIT_GLUE_WEBFRAMELOADERCLIENT_IMPL_H__ -#pragma warning(push, 0) +#include "base/compiler_specific.h" + +MSVC_PUSH_WARNING_LEVEL(0); #include "FrameLoaderClient.h" -#pragma warning(pop) +MSVC_POP_WARNING(); #include "build/build_config.h" #include "googleurl/src/gurl.h" diff --git a/webkit/glue/webkit_glue.cc b/webkit/glue/webkit_glue.cc index 1699f6f..d477645 100644 --- a/webkit/glue/webkit_glue.cc +++ b/webkit/glue/webkit_glue.cc @@ -2,6 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. +#include "base/compiler_specific.h" #include "build/build_config.h" #if defined(OS_WIN) @@ -11,7 +12,7 @@ #include "config.h" #include "webkit_version.h" -#pragma warning(push, 0) +MSVC_PUSH_WARNING_LEVEL(0); #include "BackForwardList.h" #include "Document.h" #include "FrameTree.h" @@ -27,7 +28,7 @@ #include "PlatformString.h" #include "RenderTreeAsText.h" #include "SharedBuffer.h" -#pragma warning(pop) +MSVC_POP_WARNING(); #if USE(V8_BINDING) || USE(JAVASCRIPTCORE_BINDINGS) #include "JSBridge.h" // for set flags diff --git a/webkit/glue/weburlrequest_impl.h b/webkit/glue/weburlrequest_impl.h index 8628806..8b33385 100644 --- a/webkit/glue/weburlrequest_impl.h +++ b/webkit/glue/weburlrequest_impl.h @@ -5,13 +5,14 @@ #ifndef WEBKIT_GLUE_WEBURLREQUEST_IMPL_H__ #define WEBKIT_GLUE_WEBURLREQUEST_IMPL_H__ -#include "webkit/glue/weburlrequest.h" #include "base/basictypes.h" +#include "base/compiler_specific.h" +#include "webkit/glue/weburlrequest.h" -#pragma warning(push, 0) +MSVC_PUSH_WARNING_LEVEL(0); #include "FrameLoadRequest.h" #include "HistoryItem.h" -#pragma warning(pop) +MSVC_POP_WARNING(); class WebRequestImpl : public WebRequest { public: diff --git a/webkit/glue/webview_impl.h b/webkit/glue/webview_impl.h index 31be2ff..1fb2ebb 100644 --- a/webkit/glue/webview_impl.h +++ b/webkit/glue/webview_impl.h @@ -8,6 +8,7 @@ #include <set> #include "base/basictypes.h" +#include "base/compiler_specific.h" #include "base/gfx/platform_canvas.h" #include "base/gfx/point.h" #include "base/gfx/size.h" @@ -16,10 +17,10 @@ #include "webkit/glue/webpreferences.h" #include "webkit/glue/webview.h" -#pragma warning(push, 0) +MSVC_PUSH_WARNING_LEVEL(0); #include "webkit/port/history/BackForwardList.h" #include "webkit/port/platform/WidgetClientWin.h" -#pragma warning(pop) +MSVC_POP_WARNING(); namespace WebCore { class Frame; diff --git a/webkit/port/bindings/scripts/CodeGeneratorV8.pm b/webkit/port/bindings/scripts/CodeGeneratorV8.pm index e617d6e..009b87e 100644 --- a/webkit/port/bindings/scripts/CodeGeneratorV8.pm +++ b/webkit/port/bindings/scripts/CodeGeneratorV8.pm @@ -425,6 +425,8 @@ sub GenerateNormalAttrGetter } } + my $getterStringUsesImp = $implClassName ne "double"; + # Getter push(@implContentDecls, <<END); static v8::Handle<v8::Value> ${attrName}AttrGetter(v8::Local<v8::String> name, const v8::AccessorInfo& info) { @@ -435,8 +437,12 @@ END push(@implContentDecls, <<END); V8SVGPODTypeWrapper<$implClassName>* imp_wrapper = V8Proxy::FastToNativeObject<V8SVGPODTypeWrapper<$implClassName> >(V8ClassIndex::$classIndex, info.Holder()); $implClassName imp_instance = *imp_wrapper; +END + if ($getterStringUsesImp) { + push(@implContentDecls, <<END); $implClassName* imp = &imp_instance; END + } } elsif ($attrExt->{"v8OnProto"}) { # perform lookup first @@ -473,17 +479,20 @@ END my $returnType = $codeGenerator->StripModule($attribute->signature->type); - my $getterString = "imp->$getterFunc("; - $getterString .= "ec" if $useExceptions; - $getterString .= ")"; - if (IsRefPtrType($returnType)) { - $implIncludes{"wtf/GetPtr.h"} = 1; - $getterString = "WTF::getPtr(" . $getterString . ")"; - } - if ($nativeType eq "int" and $attribute->signature->extendedAttributes->{"ConvertFromString"}) { - $getterString .= ".toInt()"; - } - if ($implClassName eq "double") { + my $getterString; + if ($getterStringUsesImp) { + $getterString = "imp->$getterFunc("; + $getterString .= "ec" if $useExceptions; + $getterString .= ")"; + if (IsRefPtrType($returnType)) { + $implIncludes{"wtf/GetPtr.h"} = 1; + $getterString = "WTF::getPtr(" . $getterString . ")"; + } + if ($nativeType eq "int" and + $attribute->signature->extendedAttributes->{"ConvertFromString"}) { + $getterString .= ".toInt()"; + } + } else { $getterString = "imp_instance"; } diff --git a/webkit/port/bindings/v8/v8_binding.h b/webkit/port/bindings/v8/v8_binding.h index f5edfc4..81d7dde 100644 --- a/webkit/port/bindings/v8/v8_binding.h +++ b/webkit/port/bindings/v8/v8_binding.h @@ -5,6 +5,7 @@ #ifndef V8_BINDING_H__ #define V8_BINDING_H__ +#include "base/compiler_specific.h" #include "build/build_config.h" #include <v8.h> @@ -14,9 +15,9 @@ // Suppress warnings in CString of converting size_t to unsigned int. // TODO(fqian): fix CString.h. -#pragma warning(push, 0) +MSVC_PUSH_WARNING_LEVEL(0); #include "CString.h" -#pragma warning(pop) +MSVC_POP_WARNING(); #if defined(OS_LINUX) // Use the platform.h for linux. @@ -133,7 +134,7 @@ inline int ToInt32(v8::Handle<v8::Value> value) { // If a WebCore string length is greater than the threshold, // v8String creates an external string to avoid allocating // the string in the large object space (which has a high memory overhead). -static const int kV8ExternalStringThreshold = 2048; +static const unsigned int kV8ExternalStringThreshold = 2048; // Convert a string to a V8 string. inline v8::Handle<v8::String> v8String(const String& str) { diff --git a/webkit/port/platform/TemporaryLinkStubs.cpp b/webkit/port/platform/TemporaryLinkStubs.cpp index 341b043..34fb5f3 100644 --- a/webkit/port/platform/TemporaryLinkStubs.cpp +++ b/webkit/port/platform/TemporaryLinkStubs.cpp @@ -24,16 +24,17 @@ */ #include "config.h" +#include "base/compiler_specific.h" #define WIN32_COMPILE_HACK -#pragma warning(push, 0) +MSVC_PUSH_WARNING_LEVEL(0); #include "Color.h" #include "SSLKeyGenerator.h" #include "KURL.h" #include "NotImplemented.h" #include "SharedBuffer.h" -#pragma warning(pop) +MSVC_POP_WARNING(); using namespace WebCore; |