aboutsummaryrefslogtreecommitdiffhomepage
path: root/samplecode
diff options
context:
space:
mode:
authorGravatar Ben Wagner <bungeman@google.com>2018-05-22 11:24:21 -0400
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2018-05-22 15:51:25 +0000
commitd6de89bebdee9185b18c2da77c27371ad8318b4b (patch)
treefda3ff1ef119465611bfd2af5c5369a07601baf7 /samplecode
parent7325942b4966ce9435aa0e7e4cf676c7e5d8ac8d (diff)
Update SampleLua and lua files.
The lua files were moved at one point without the internal path references being updated. This updates them so that the SampleLua slides can be seen in their full glory. Change-Id: I4dd09c847be48d80fa61d3b9864d34a4aa9bb2f5 Reviewed-on: https://skia-review.googlesource.com/129515 Reviewed-by: Herb Derby <herb@google.com> Commit-Queue: Ben Wagner <bungeman@google.com>
Diffstat (limited to 'samplecode')
-rw-r--r--samplecode/SampleLua.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/samplecode/SampleLua.cpp b/samplecode/SampleLua.cpp
index 2c94e81f76..7b04fd073b 100644
--- a/samplecode/SampleLua.cpp
+++ b/samplecode/SampleLua.cpp
@@ -57,8 +57,7 @@ public:
if (nullptr == fLua) {
fLua = new SkLua;
- SkString str = GetResourcePath(LUA_FILENAME);
- sk_sp<SkData> data(SkData::MakeFromFileName(str.c_str()));
+ sk_sp<SkData> data = GetResourceAsData(LUA_FILENAME);
if (data) {
fLua->runCode(data->data(), data->size());
this->setImageFilename(fLua->get());