PresentationApp/imgprovider.go

22 lines
348 B
Go
Raw Normal View History

2016-03-07 08:54:14 -08:00
// imgprovider.go
package main
import (
"fmt"
"image"
"strconv"
)
/*var imgproviderstr = `import QtQuick 2.4
Image {
source: "image://images/`*/
func imgProvider(id string, width, height int) image.Image {
var i int
fmt.Println("id: ", id)
i, _ = strconv.Atoi(id)
fmt.Println("haha: ", i)
return slides[i].getImage(width, height)
}