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

Unified Diff: sky/viewer/platform/platform_impl.cc

Issue 776743002: Make v8 inspector not crash (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 6 years 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
« no previous file with comments | « sky/viewer/platform/platform_impl.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sky/viewer/platform/platform_impl.cc
diff --git a/sky/viewer/platform/platform_impl.cc b/sky/viewer/platform/platform_impl.cc
index 4248528b5c510838bf74ff0152f1b30a109187f4..8e0955cab8e49e22b4f7d0720adce02471822cf4 100644
--- a/sky/viewer/platform/platform_impl.cc
+++ b/sky/viewer/platform/platform_impl.cc
@@ -7,9 +7,6 @@
#include <cmath>
#include "base/debug/trace_event.h"
-#include "base/files/file_path.h"
-#include "base/files/file_util.h"
-#include "base/path_service.h"
#include "base/rand_util.h"
#include "base/stl_util.h"
#include "base/synchronization/waitable_event.h"
@@ -230,28 +227,4 @@ void PlatformImpl::updateTraceEventDuration(
category_group_enabled, name, traceEventHandle);
}
-// FIXME(sky): This is a horrible hack and makes sky only work when run
-// inside its source tree! crbug.com/434513
-blink::WebData PlatformImpl::loadResource(const char* name)
-{
- base::FilePath root_dir;
- PathService::Get(base::DIR_SOURCE_ROOT, &root_dir);
- base::FilePath engine_dir = root_dir.AppendASCII("sky").AppendASCII("engine");
- base::FilePath v8_dir = engine_dir.AppendASCII("bindings").AppendASCII("core").AppendASCII("v8");
- base::FilePath inspector_dir = engine_dir.AppendASCII("core").AppendASCII("inspector");
-
- base::FilePath path;
- if (std::string("InjectedScriptSource.js") == name)
- path = inspector_dir.AppendASCII(name);
- else if (std::string("DebuggerScript.js") == name)
- path = v8_dir.AppendASCII(name);
- else
- CHECK(false);
-
- std::string buffer;
- base::ReadFileToString(path, &buffer);
- CHECK(!buffer.empty());
- return blink::WebData(buffer.data(), buffer.size());
-}
-
} // namespace sky
« no previous file with comments | « sky/viewer/platform/platform_impl.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698