更新说明:
- 补充单个图片测试demo Signed-off-by: 明月清风 <qiufeihu1@h-partners.com>
This commit is contained in:
parent
7030f5f55a
commit
dc96ec43b4
|
@ -29,8 +29,9 @@ struct SingleImage {
|
|||
fs.writeSync(file.fd, icon.buffer);
|
||||
fs.fsyncSync(file.fd);
|
||||
fs.closeSync(file);
|
||||
getContext().resourceManager.getMediaContentSync( $r("app.media.aaa"))
|
||||
.buffer as ArrayBuffer;
|
||||
this.changePic(getContext().resourceManager.getMediaContentSync( $r("app.media.aaa"))
|
||||
.buffer as ArrayBuffer);
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
@ -84,12 +85,12 @@ struct SingleImage {
|
|||
transformation: new BlurTransformation(10)
|
||||
}
|
||||
}).width(100).height(100)
|
||||
Text("自定义下载")
|
||||
Text("pixelMap加载图片")
|
||||
.fontSize(30)
|
||||
.fontWeight(FontWeight.Bold)
|
||||
ImageKnifeComponent({
|
||||
imageKnifeOption: {
|
||||
loadSrc: this.pixelMap,
|
||||
loadSrc: this.pixelMap!,
|
||||
placeholderSrc: $r("app.media.loading"),
|
||||
errorholderSrc: $r("app.media.app_icon"),
|
||||
objectFit: ImageFit.Contain,
|
||||
|
|
Loading…
Reference in New Issue