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

Side by Side Diff: src/utils/SkLua.cpp

Issue 100313005: Add cast to fix Win* compile complaint/failure (Closed) Base URL: http://skia.googlecode.com/svn/trunk/
Patch Set: Switch from push a scalar to pushing a U32 Created 7 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2013 Google Inc. 2 * Copyright 2013 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #include "SkLua.h" 8 #include "SkLua.h"
9 #include "SkCanvas.h" 9 #include "SkCanvas.h"
10 #include "SkData.h" 10 #include "SkData.h"
(...skipping 627 matching lines...) Expand 10 before | Expand all | Expand 10 after
638 SkLua(L).pushU32(get_obj<SkPaint>(L, 1)->getStrokeCap()); 638 SkLua(L).pushU32(get_obj<SkPaint>(L, 1)->getStrokeCap());
639 return 1; 639 return 1;
640 } 640 }
641 641
642 static int lpaint_getStrokeJoin(lua_State* L) { 642 static int lpaint_getStrokeJoin(lua_State* L) {
643 SkLua(L).pushU32(get_obj<SkPaint>(L, 1)->getStrokeJoin()); 643 SkLua(L).pushU32(get_obj<SkPaint>(L, 1)->getStrokeJoin());
644 return 1; 644 return 1;
645 } 645 }
646 646
647 static int lpaint_getTextEncoding(lua_State* L) { 647 static int lpaint_getTextEncoding(lua_State* L) {
648 SkLua(L).pushScalar(static_cast<SkScalar>(get_obj<SkPaint>(L, 1)->getTextEnc oding())); 648 SkLua(L).pushU32(get_obj<SkPaint>(L, 1)->getTextEncoding());
649 return 1; 649 return 1;
650 } 650 }
651 651
652 static int lpaint_getStrokeWidth(lua_State* L) { 652 static int lpaint_getStrokeWidth(lua_State* L) {
653 SkLua(L).pushScalar(get_obj<SkPaint>(L, 1)->getStrokeWidth()); 653 SkLua(L).pushScalar(get_obj<SkPaint>(L, 1)->getStrokeWidth());
654 return 1; 654 return 1;
655 } 655 }
656 656
657 static int lpaint_setStrokeWidth(lua_State* L) { 657 static int lpaint_setStrokeWidth(lua_State* L) {
658 get_obj<SkPaint>(L, 1)->setStrokeWidth(lua2scalar(L, 2)); 658 get_obj<SkPaint>(L, 1)->setStrokeWidth(lua2scalar(L, 2));
(...skipping 569 matching lines...) Expand 10 before | Expand all | Expand 10 after
1228 REG_CLASS(L, SkShader); 1228 REG_CLASS(L, SkShader);
1229 REG_CLASS(L, SkTypeface); 1229 REG_CLASS(L, SkTypeface);
1230 REG_CLASS(L, SkMatrix); 1230 REG_CLASS(L, SkMatrix);
1231 } 1231 }
1232 1232
1233 extern "C" int luaopen_skia(lua_State* L); 1233 extern "C" int luaopen_skia(lua_State* L);
1234 extern "C" int luaopen_skia(lua_State* L) { 1234 extern "C" int luaopen_skia(lua_State* L) {
1235 SkLua::Load(L); 1235 SkLua::Load(L);
1236 return 0; 1236 return 0;
1237 } 1237 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698