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

Unified Diff: sky/engine/bindings-dart/core/dart/DartScriptPromise.cpp

Issue 918273002: Remove bindings-dart (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 10 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 side-by-side diff with in-line comments
Download patch
Index: sky/engine/bindings-dart/core/dart/DartScriptPromise.cpp
diff --git a/sky/engine/bindings-dart/core/dart/DartScriptPromise.cpp b/sky/engine/bindings-dart/core/dart/DartScriptPromise.cpp
deleted file mode 100644
index b2cf7496fc759d3fdb163fae50eb50f121ab6136..0000000000000000000000000000000000000000
--- a/sky/engine/bindings-dart/core/dart/DartScriptPromise.cpp
+++ /dev/null
@@ -1,45 +0,0 @@
-// Copyright 2014 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "config.h"
-#include "bindings/core/dart/DartScriptPromise.h"
-
-#include "bindings/common/ExceptionMessages.h"
-#include "bindings/common/ExceptionState.h"
-#include "bindings/core/dart/DartUtilities.h"
-#include "bindings/core/v8/V8Binding.h"
-#include "bindings/core/v8/V8ThrowException.h"
-#include "core/dom/DOMException.h"
-#include <v8.h>
-
-namespace blink {
-
-DartScriptPromise::DartScriptPromise(DartScriptState* scriptState, Dart_Handle future)
- : m_scriptState(scriptState)
- , m_value(future)
-{
- if (!future)
- return;
-
- if (!Dart_IsFuture(future)) {
- m_value.clear();
- // FIXMEDART: How do we do a sticky error?
- Dart_Handle coreLib = Dart_LookupLibrary(Dart_NewStringFromCString("dart:core"));
- Dart_Handle errorClass = Dart_GetType(coreLib, DartUtilities::stringToDart((String)"ArgumentError"), 0, 0);
- Dart_Handle dartMessage = DartUtilities::stringToDart((String)"the given value is not a Future");
- Dart_Handle error = Dart_New(errorClass, Dart_NewStringFromCString(""), 1, &dartMessage);
- Dart_ThrowException(error);
- ASSERT_NOT_REACHED();
- return;
- }
-}
-
-PassRefPtr<AbstractScriptPromise> DartScriptPromise::then(PassOwnPtr<ScriptFunction> onFulfilled, PassOwnPtr<ScriptFunction> onRejected)
-{
- // FIXMEDART: Implement.
- RELEASE_ASSERT_NOT_REACHED();
- return nullptr;
-}
-
-} // namespace blink
« no previous file with comments | « sky/engine/bindings-dart/core/dart/DartScriptPromise.h ('k') | sky/engine/bindings-dart/core/dart/DartScriptPromiseResolver.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698