[SCM] WebKit Debian packaging branch, debian/unstable, updated. debian/1.1.18-1-697-g2f78b87
eric at webkit.org
eric at webkit.org
Wed Jan 20 22:27:51 UTC 2010
The following commit has been merged in the debian/unstable branch:
commit d0da8d1ac9623d0aac4c882a2edd33ed4b91a5aa
Author: eric at webkit.org <eric at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Mon Jan 18 14:37:01 2010 +0000
2010-01-18 Jonathan Dixon <joth at chromium.org>
Reviewed by Adam Barth.
Add support for enabling navigator.geolocation at runtime in the V8 bindings.
Adds the [EnabledAtRuntime] modifier to the navigator IDL.
https://bugs.webkit.org/show_bug.cgi?id=33467
* WebCore.gypi:
* bindings/v8/RuntimeEnabledFeatures.cpp:
* bindings/v8/RuntimeEnabledFeatures.h:
(WebCore::RuntimeEnabledFeatures::setGeolocationEnabled):
(WebCore::RuntimeEnabledFeatures::geolocationEnabled):
* bindings/v8/custom/V8NavigatorCustom.cpp: Added.
(WebCore::V8Navigator::GeolocationEnabled):
* page/Navigator.cpp:
(WebCore::Navigator::geolocation):
* page/Navigator.idl:
2010-01-18 Jonathan Dixon <joth at chromium.org>
Reviewed by Adam Barth.
Add support for enabling navigator.geolocation at runtime in the V8 bindings.
Adds the [EnabledAtRuntime] modifier to the navigator IDL.
https://bugs.webkit.org/show_bug.cgi?id=33467
* public/WebRuntimeFeatures.h:
* src/WebRuntimeFeatures.cpp:
(WebKit::WebRuntimeFeatures::enableGeolocation):
(WebKit::WebRuntimeFeatures::isGeolocationEnabled):
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@53406 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index 0a9c8c0..553c3f4 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,22 @@
+2010-01-18 Jonathan Dixon <joth at chromium.org>
+
+ Reviewed by Adam Barth.
+
+ Add support for enabling navigator.geolocation at runtime in the V8 bindings.
+ Adds the [EnabledAtRuntime] modifier to the navigator IDL.
+ https://bugs.webkit.org/show_bug.cgi?id=33467
+
+ * WebCore.gypi:
+ * bindings/v8/RuntimeEnabledFeatures.cpp:
+ * bindings/v8/RuntimeEnabledFeatures.h:
+ (WebCore::RuntimeEnabledFeatures::setGeolocationEnabled):
+ (WebCore::RuntimeEnabledFeatures::geolocationEnabled):
+ * bindings/v8/custom/V8NavigatorCustom.cpp: Added.
+ (WebCore::V8Navigator::GeolocationEnabled):
+ * page/Navigator.cpp:
+ (WebCore::Navigator::geolocation):
+ * page/Navigator.idl:
+
2010-01-18 Alexander Pavlov <apavlov at chromium.org>
Reviewed by Pavel Feldman.
diff --git a/WebCore/WebCore.gypi b/WebCore/WebCore.gypi
index 1a7a4df..d7af39f 100644
--- a/WebCore/WebCore.gypi
+++ b/WebCore/WebCore.gypi
@@ -720,6 +720,7 @@
'bindings/v8/custom/V8NamedNodeMapCustom.cpp',
'bindings/v8/custom/V8NamedNodesCollection.cpp',
'bindings/v8/custom/V8NamedNodesCollection.h',
+ 'bindings/v8/custom/V8NavigatorCustom.cpp',
'bindings/v8/custom/V8NodeCustom.cpp',
'bindings/v8/custom/V8NodeFilterCustom.cpp',
'bindings/v8/custom/V8NodeIteratorCustom.cpp',
diff --git a/WebCore/bindings/v8/RuntimeEnabledFeatures.cpp b/WebCore/bindings/v8/RuntimeEnabledFeatures.cpp
index cf97b5b..399379b 100644
--- a/WebCore/bindings/v8/RuntimeEnabledFeatures.cpp
+++ b/WebCore/bindings/v8/RuntimeEnabledFeatures.cpp
@@ -38,5 +38,6 @@ bool RuntimeEnabledFeatures::isLocalStorageEnabled = true;
bool RuntimeEnabledFeatures::isSessionStorageEnabled = true;
bool RuntimeEnabledFeatures::isNotificationsEnabled = false;
bool RuntimeEnabledFeatures::isApplicationCacheEnabled = false;
+bool RuntimeEnabledFeatures::isGeolocationEnabled = false;
} // namespace WebCore
diff --git a/WebCore/bindings/v8/RuntimeEnabledFeatures.h b/WebCore/bindings/v8/RuntimeEnabledFeatures.h
index d8078c5..e5a050a 100644
--- a/WebCore/bindings/v8/RuntimeEnabledFeatures.h
+++ b/WebCore/bindings/v8/RuntimeEnabledFeatures.h
@@ -51,6 +51,9 @@ public:
static void setApplicationCacheEnabled(bool isEnabled) { isApplicationCacheEnabled = isEnabled; }
static bool applicationCacheEnabled() { return isApplicationCacheEnabled; }
+ static void setGeolocationEnabled(bool isEnabled) { isGeolocationEnabled = isEnabled; }
+ static bool geolocationEnabled() { return isGeolocationEnabled; }
+
private:
// Never instantiate.
RuntimeEnabledFeatures() { }
@@ -60,6 +63,7 @@ private:
static bool isSessionStorageEnabled;
static bool isNotificationsEnabled;
static bool isApplicationCacheEnabled;
+ static bool isGeolocationEnabled;
};
} // namespace WebCore
diff --git a/WebCore/bindings/v8/custom/V8NavigatorCustom.cpp b/WebCore/bindings/v8/custom/V8NavigatorCustom.cpp
new file mode 100644
index 0000000..266745d
--- /dev/null
+++ b/WebCore/bindings/v8/custom/V8NavigatorCustom.cpp
@@ -0,0 +1,45 @@
+/*
+ * Copyright (C) 2010 Google Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are
+ * met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above
+ * copyright notice, this list of conditions and the following disclaimer
+ * in the documentation and/or other materials provided with the
+ * distribution.
+ * * Neither the name of Google Inc. nor the names of its
+ * contributors may be used to endorse or promote products derived from
+ * this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#include "config.h"
+#include "V8Navigator.h"
+
+#include "RuntimeEnabledFeatures.h"
+
+namespace WebCore {
+
+#if ENABLE(GEOLOCATION)
+bool V8Navigator::GeolocationEnabled()
+{
+ return RuntimeEnabledFeatures::geolocationEnabled();
+}
+#endif
+
+} // namespace WebCore
diff --git a/WebCore/page/Navigator.idl b/WebCore/page/Navigator.idl
index d5fcc1e..257ede1 100644
--- a/WebCore/page/Navigator.idl
+++ b/WebCore/page/Navigator.idl
@@ -41,7 +41,7 @@ module window {
readonly attribute boolean onLine;
#if defined(ENABLE_GEOLOCATION) && ENABLE_GEOLOCATION
- readonly attribute Geolocation geolocation;
+ readonly attribute [EnabledAtRuntime] Geolocation geolocation;
#endif
#if defined(ENABLE_DOM_STORAGE) && ENABLE_DOM_STORAGE
diff --git a/WebKit/chromium/ChangeLog b/WebKit/chromium/ChangeLog
index 61a6456..f6b9eb7 100644
--- a/WebKit/chromium/ChangeLog
+++ b/WebKit/chromium/ChangeLog
@@ -1,3 +1,16 @@
+2010-01-18 Jonathan Dixon <joth at chromium.org>
+
+ Reviewed by Adam Barth.
+
+ Add support for enabling navigator.geolocation at runtime in the V8 bindings.
+ Adds the [EnabledAtRuntime] modifier to the navigator IDL.
+ https://bugs.webkit.org/show_bug.cgi?id=33467
+
+ * public/WebRuntimeFeatures.h:
+ * src/WebRuntimeFeatures.cpp:
+ (WebKit::WebRuntimeFeatures::enableGeolocation):
+ (WebKit::WebRuntimeFeatures::isGeolocationEnabled):
+
2010-01-17 Kent Tamura <tkent at chromium.org>
Reviewed by Shinichiro Hamaji.
diff --git a/WebKit/chromium/public/WebRuntimeFeatures.h b/WebKit/chromium/public/WebRuntimeFeatures.h
index eb6b2da..da56b9a 100644
--- a/WebKit/chromium/public/WebRuntimeFeatures.h
+++ b/WebKit/chromium/public/WebRuntimeFeatures.h
@@ -62,6 +62,9 @@ public:
WEBKIT_API static void enableApplicationCache(bool);
WEBKIT_API static bool isApplicationCacheEnabled();
+ WEBKIT_API static void enableGeolocation(bool);
+ WEBKIT_API static bool isGeolocationEnabled();
+
private:
WebRuntimeFeatures();
};
diff --git a/WebKit/chromium/src/WebRuntimeFeatures.cpp b/WebKit/chromium/src/WebRuntimeFeatures.cpp
index b630a09..ca3d45c 100644
--- a/WebKit/chromium/src/WebRuntimeFeatures.cpp
+++ b/WebKit/chromium/src/WebRuntimeFeatures.cpp
@@ -151,4 +151,20 @@ bool WebRuntimeFeatures::isApplicationCacheEnabled()
#endif
}
+void WebRuntimeFeatures::enableGeolocation(bool enable)
+{
+#if ENABLE(GEOLOCATION)
+ RuntimeEnabledFeatures::setGeolocationEnabled(enable);
+#endif
+}
+
+bool WebRuntimeFeatures::isGeolocationEnabled()
+{
+#if ENABLE(GEOLOCATION)
+ return RuntimeEnabledFeatures::geolocationEnabled();
+#else
+ return false;
+#endif
+}
+
} // namespace WebKit
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list