| OLD | NEW |
| 1 gShowBounds = false | 1 gShowBounds = false |
| 2 gUseBlurInTransitions = false | 2 gUseBlurInTransitions = false |
| 3 | 3 |
| 4 gPath = "/skia/trunk/resources/" | 4 gPath = "/puregit/resources/" |
| 5 | 5 |
| 6 function load_file(file) | 6 function load_file(file) |
| 7 local prev_path = package.path | 7 local prev_path = package.path |
| 8 package.path = package.path .. ";" .. gPath .. file .. ".lua" | 8 package.path = package.path .. ";" .. gPath .. file .. ".lua" |
| 9 require(file) | 9 require(file) |
| 10 package.path = prev_path | 10 package.path = prev_path |
| 11 end | 11 end |
| 12 | 12 |
| 13 load_file("slides_utils") | 13 load_file("slides_utils") |
| 14 | 14 |
| 15 gSlides = parse_file(io.open("/skia/trunk/resources/slides_content2.lua", "r")) | 15 gSlides = parse_file(io.open("/puregit/resources/slides_content2.lua", "r")) |
| 16 | 16 |
| 17 function make_rect(l, t, r, b) | 17 function make_rect(l, t, r, b) |
| 18 return { left = l, top = t, right = r, bottom = b } | 18 return { left = l, top = t, right = r, bottom = b } |
| 19 end | 19 end |
| 20 | 20 |
| 21 function make_paint(typefacename, stylebits, size, color) | 21 function make_paint(typefacename, stylebits, size, color) |
| 22 local paint = Sk.newPaint(); | 22 local paint = Sk.newPaint(); |
| 23 paint:setAntiAlias(true) | 23 paint:setAntiAlias(true) |
| 24 paint:setSubpixelText(true) | 24 paint:setSubpixelText(true) |
| 25 paint:setTypeface(Sk.newTypeface(typefacename, stylebits)) | 25 paint:setTypeface(Sk.newTypeface(typefacename, stylebits)) |
| (...skipping 319 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 345 } | 345 } |
| 346 | 346 |
| 347 function onCharHandler(uni) | 347 function onCharHandler(uni) |
| 348 local proc = keyProcs[uni] | 348 local proc = keyProcs[uni] |
| 349 if proc then | 349 if proc then |
| 350 proc() | 350 proc() |
| 351 return true | 351 return true |
| 352 end | 352 end |
| 353 return false | 353 return false |
| 354 end | 354 end |
| OLD | NEW |