aboutsummaryrefslogtreecommitdiffstats
path: root/src/components/script/dom
diff options
context:
space:
mode:
authorMs2ger <ms2ger@gmail.com>2014-03-08 18:49:55 +0100
committerMs2ger <ms2ger@gmail.com>2014-03-08 18:49:55 +0100
commit9fbfb1909cde6225279730f123f312c270155d19 (patch)
tree808832ec3ca35be7aea6136e2fb019b2ba50dc26 /src/components/script/dom
parent4b061dc43d5a0d0f9850e0512eed28bfb8476e7b (diff)
downloadservo-9fbfb1909cde6225279730f123f312c270155d19.tar.gz
servo-9fbfb1909cde6225279730f123f312c270155d19.zip
Move JSVal into the jsval module.
Diffstat (limited to 'src/components/script/dom')
-rw-r--r--src/components/script/dom/bindings/callback.rs3
-rw-r--r--src/components/script/dom/bindings/codegen/CodegenRust.py6
-rw-r--r--src/components/script/dom/bindings/conversions.rs3
-rw-r--r--src/components/script/dom/bindings/utils.rs5
-rw-r--r--src/components/script/dom/htmlelement.rs3
-rw-r--r--src/components/script/dom/testbinding.rs3
-rw-r--r--src/components/script/dom/window.rs3
7 files changed, 17 insertions, 9 deletions
diff --git a/src/components/script/dom/bindings/callback.rs b/src/components/script/dom/bindings/callback.rs
index 10cb35c3af4..2263ea9d224 100644
--- a/src/components/script/dom/bindings/callback.rs
+++ b/src/components/script/dom/bindings/callback.rs
@@ -3,8 +3,9 @@
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
use dom::bindings::utils::Reflectable;
-use js::jsapi::{JSContext, JSObject, JS_WrapObject, JSVal, JS_ObjectIsCallable};
+use js::jsapi::{JSContext, JSObject, JS_WrapObject, JS_ObjectIsCallable};
use js::jsapi::{JS_GetProperty, JSTracer, JS_CallTracer};
+use js::jsval::JSVal;
use js::{JSVAL_IS_OBJECT, JSVAL_TO_OBJECT, JSTRACE_OBJECT};
use std::cast;
diff --git a/src/components/script/dom/bindings/codegen/CodegenRust.py b/src/components/script/dom/bindings/codegen/CodegenRust.py
index 47c91614d52..58260e6b800 100644
--- a/src/components/script/dom/bindings/codegen/CodegenRust.py
+++ b/src/components/script/dom/bindings/codegen/CodegenRust.py
@@ -5246,7 +5246,8 @@ class CGBindingRoot(CGThing):
'js::jsapi::{JSClass, JSFreeOp, JSFunctionSpec, JSHandleObject, jsid}',
'js::jsapi::{JSNativeWrapper, JSObject, JSPropertyDescriptor}',
'js::jsapi::{JSPropertyOpWrapper, JSPropertySpec}',
- 'js::jsapi::{JSStrictPropertyOpWrapper, JSString, JSTracer, JSVal}',
+ 'js::jsapi::{JSStrictPropertyOpWrapper, JSString, JSTracer}',
+ 'js::jsval::JSVal',
'js::glue::{CallJitMethodOp, CallJitPropertyOp, CreateProxyHandler}',
'js::glue::{GetProxyPrivate, NewProxyObject, ProxyTraps}',
'js::glue::{RUST_BOOLEAN_TO_JSVAL, RUST_FUNCTION_VALUE_TO_JITINFO}',
@@ -6443,7 +6444,8 @@ class GlobalGenRoots():
'js::jsapi::{JSClass, JSFreeOp, JSFunctionSpec, JSHandleObject, jsid}',
'js::jsapi::{JSNativeWrapper, JSObject, JSPropertyDescriptor}',
'js::jsapi::{JSPropertyOpWrapper, JSPropertySpec}',
- 'js::jsapi::{JSStrictPropertyOpWrapper, JSString, JSTracer, JSVal}',
+ 'js::jsapi::{JSStrictPropertyOpWrapper, JSString, JSTracer}',
+ 'js::jsval::JSVal',
'js::glue::{CallJitMethodOp, CallJitPropertyOp, CreateProxyHandler}',
'js::glue::{GetProxyPrivate, NewProxyObject, ProxyTraps}',
'js::glue::{RUST_BOOLEAN_TO_JSVAL, RUST_FUNCTION_VALUE_TO_JITINFO}',
diff --git a/src/components/script/dom/bindings/conversions.rs b/src/components/script/dom/bindings/conversions.rs
index 6b033225c85..266cfdc3eb0 100644
--- a/src/components/script/dom/bindings/conversions.rs
+++ b/src/components/script/dom/bindings/conversions.rs
@@ -2,10 +2,11 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
-use js::jsapi::{JSVal, JSBool, JSContext};
+use js::jsapi::{JSBool, JSContext};
use js::jsapi::{JS_ValueToUint64, JS_ValueToInt64};
use js::jsapi::{JS_ValueToECMAUint32, JS_ValueToECMAInt32};
use js::jsapi::{JS_ValueToUint16, JS_ValueToNumber, JS_ValueToBoolean};
+use js::jsval::JSVal;
use js::{JSVAL_FALSE, JSVAL_TRUE, JSVAL_NULL};
use js::glue::{RUST_INT_TO_JSVAL, RUST_UINT_TO_JSVAL, RUST_JS_NumberValue};
use js::glue::{RUST_JSVAL_IS_NULL, RUST_JSVAL_IS_VOID};
diff --git a/src/components/script/dom/bindings/utils.rs b/src/components/script/dom/bindings/utils.rs
index a749b26b42c..d510d13760f 100644
--- a/src/components/script/dom/bindings/utils.rs
+++ b/src/components/script/dom/bindings/utils.rs
@@ -30,11 +30,12 @@ use js::jsapi::{JS_HasPropertyById, JS_GetPrototype, JS_GetGlobalForObject};
use js::jsapi::{JS_NewUCStringCopyN, JS_DefineFunctions, JS_DefineProperty};
use js::jsapi::{JS_ValueToString, JS_GetReservedSlot, JS_SetReservedSlot};
use js::jsapi::{JSContext, JSObject, JSBool, jsid, JSClass, JSNative};
-use js::jsapi::{JSFunctionSpec, JSPropertySpec, JSVal, JSPropertyDescriptor};
+use js::jsapi::{JSFunctionSpec, JSPropertySpec, JSPropertyDescriptor};
use js::jsapi::{JS_NewGlobalObject, JS_InitStandardClasses};
use js::jsapi::{JSString};
use js::jsapi::{JS_AllowGC, JS_InhibitGC};
use js::jsfriendapi::bindgen::JS_NewObjectWithUniqueType;
+use js::jsval::JSVal;
use js::{JSPROP_ENUMERATE, JSVAL_NULL, JSCLASS_IS_GLOBAL, JSCLASS_IS_DOMJSCLASS};
use js::{JSPROP_PERMANENT, JSID_VOID, JSPROP_NATIVE_ACCESSORS, JSPROP_GETTER};
use js::{JSPROP_SETTER, JSVAL_VOID, JSVAL_TRUE, JSVAL_FALSE};
@@ -43,7 +44,7 @@ use js;
mod jsval {
use js::glue::{RUST_JSVAL_IS_NULL, RUST_JSVAL_IS_VOID};
- use js::jsapi::JSVal;
+ use js::jsval::JSVal;
pub fn is_null(v: JSVal) -> bool {
unsafe { RUST_JSVAL_IS_NULL(v) == 1 }
diff --git a/src/components/script/dom/htmlelement.rs b/src/components/script/dom/htmlelement.rs
index b27afdfff2e..84cf9ccfdba 100644
--- a/src/components/script/dom/htmlelement.rs
+++ b/src/components/script/dom/htmlelement.rs
@@ -10,7 +10,8 @@ use dom::document::Document;
use dom::element::{Element, ElementTypeId, HTMLElementTypeId};
use dom::eventtarget::{EventTarget, NodeTargetTypeId};
use dom::node::{Node, ElementNodeTypeId};
-use js::jsapi::{JSContext, JSVal};
+use js::jsapi::JSContext;
+use js::jsval::JSVal;
use js::JSVAL_NULL;
use servo_util::namespace;
use servo_util::str::DOMString;
diff --git a/src/components/script/dom/testbinding.rs b/src/components/script/dom/testbinding.rs
index 634e569791f..630e457fb87 100644
--- a/src/components/script/dom/testbinding.rs
+++ b/src/components/script/dom/testbinding.rs
@@ -9,7 +9,8 @@ use dom::window::Window;
use servo_util::str::DOMString;
use js::JSVAL_NULL;
-use js::jsapi::{JSVal, JSContext};
+use js::jsapi::JSContext;
+use js::jsval::JSVal;
#[deriving(Encodable)]
pub struct TestBinding {
diff --git a/src/components/script/dom/window.rs b/src/components/script/dom/window.rs
index d431745f018..0382e03b9fb 100644
--- a/src/components/script/dom/window.rs
+++ b/src/components/script/dom/window.rs
@@ -20,7 +20,8 @@ use servo_util::str::DOMString;
use servo_util::task::{spawn_named};
use js::glue::*;
-use js::jsapi::{JSObject, JSContext, JS_DefineProperty, JSVal};
+use js::jsapi::{JSObject, JSContext, JS_DefineProperty};
+use js::jsval::JSVal;
use js::{JSVAL_NULL, JSPROP_ENUMERATE};
use std::cast;