From 9969d6f3099bd0fc19668754a5d54c740c5e7fd8 Mon Sep 17 00:00:00 2001 From: Lars Knoll Date: Mon, 10 Jun 2013 15:10:02 +0200 Subject: Remove two more places where we used v8 Change Value::isInt32() to convert to an integer if possible. Use this to avoid casting doubles to ints twice. usage of v8::Value::IsInt32() in two places. Change-Id: I5b9d8be7d90b461c11440bf54660ceef7e8f0f1b Reviewed-by: Simon Hausmann --- src/quick/items/qquickdroparea.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/quick/items/qquickdroparea.cpp') diff --git a/src/quick/items/qquickdroparea.cpp b/src/quick/items/qquickdroparea.cpp index 3b8f02db8c..f930835bee 100644 --- a/src/quick/items/qquickdroparea.cpp +++ b/src/quick/items/qquickdroparea.cpp @@ -421,9 +421,9 @@ void QQuickDropEvent::accept(QQmlV4Function *args) Qt::DropAction action = event->dropAction(); if (args->length() >= 1) { - v8::Handle v = (*args)[0]; - if (v->IsInt32()) - action = Qt::DropAction(v->Int32Value()); + QV4::Value v = (*args)[0]; + if (v.isInt32()) + action = Qt::DropAction(v.integerValue()); } // get action from arguments. event->setDropAction(action); -- cgit v1.2.3