commit
ee980fe094
|
@ -131,16 +131,16 @@ struct Index {
|
|||
this.transformSquare1(this.url);
|
||||
|
||||
});
|
||||
Button('gif')
|
||||
.onClick(() => {
|
||||
this.transformSquare1(this.url);
|
||||
|
||||
});
|
||||
Button('webp')
|
||||
.onClick(() => {
|
||||
this.transformSquare1(this.url);
|
||||
|
||||
});
|
||||
// Button('gif')
|
||||
// .onClick(() => {
|
||||
// this.transformSquare1(this.url);
|
||||
//
|
||||
// });
|
||||
// Button('webp')
|
||||
// .onClick(() => {
|
||||
// this.transformSquare1(this.url);
|
||||
//
|
||||
// });
|
||||
}.margin({ top: 20, bottom: 20 })
|
||||
|
||||
Text("原图字节大小:" + this.originalBytesNumber)
|
||||
|
@ -199,26 +199,26 @@ struct Index {
|
|||
downsampling: new fitter()
|
||||
}
|
||||
});
|
||||
Button('gif')
|
||||
.onClick(() => {
|
||||
// this.transformSquare2(this.url);
|
||||
this.imageKnifeOption = {
|
||||
loadSrc: gifUrl,
|
||||
placeholderSrc: $r('app.media.icon_loading'),
|
||||
errorholderSrc: $r('app.media.icon_failed'),
|
||||
downsampling: new fitter()
|
||||
}
|
||||
});
|
||||
Button('webp')
|
||||
.onClick(() => {
|
||||
// this.transformSquare2(this.url);
|
||||
this.imageKnifeOption = {
|
||||
loadSrc: webpUrl,
|
||||
placeholderSrc: $r('app.media.icon_loading'),
|
||||
errorholderSrc: $r('app.media.icon_failed'),
|
||||
downsampling: new fitter()
|
||||
}
|
||||
});
|
||||
// Button('gif')
|
||||
// .onClick(() => {
|
||||
// // this.transformSquare2(this.url);
|
||||
// this.imageKnifeOption = {
|
||||
// loadSrc: gifUrl,
|
||||
// placeholderSrc: $r('app.media.icon_loading'),
|
||||
// errorholderSrc: $r('app.media.icon_failed'),
|
||||
// downsampling: new fitter()
|
||||
// }
|
||||
// });
|
||||
// Button('webp')
|
||||
// .onClick(() => {
|
||||
// // this.transformSquare2(this.url);
|
||||
// this.imageKnifeOption = {
|
||||
// loadSrc: webpUrl,
|
||||
// placeholderSrc: $r('app.media.icon_loading'),
|
||||
// errorholderSrc: $r('app.media.icon_failed'),
|
||||
// downsampling: new fitter()
|
||||
// }
|
||||
// });
|
||||
}.margin({ top: 20, bottom: 20 })
|
||||
|
||||
Text("降采样字节大小:" + this.bytesNumber)
|
||||
|
@ -259,16 +259,16 @@ struct Index {
|
|||
this.transformSquare1(jpgUrl);
|
||||
|
||||
});
|
||||
Button('gif')
|
||||
.onClick(() => {
|
||||
this.transformSquare1(gifUrl);
|
||||
|
||||
});
|
||||
Button('webp')
|
||||
.onClick(() => {
|
||||
this.transformSquare1(webpUrl);
|
||||
|
||||
});
|
||||
// Button('gif')
|
||||
// .onClick(() => {
|
||||
// this.transformSquare1(gifUrl);
|
||||
//
|
||||
// });
|
||||
// Button('webp')
|
||||
// .onClick(() => {
|
||||
// this.transformSquare1(webpUrl);
|
||||
//
|
||||
// });
|
||||
}.margin({ top: 20, bottom: 20 })
|
||||
|
||||
Text("原图字节大小:" + this.originalBytesNumber)
|
||||
|
@ -323,24 +323,24 @@ struct Index {
|
|||
errorholderSrc: $r('app.media.icon_failed'),
|
||||
}
|
||||
});
|
||||
Button('gif')
|
||||
.onClick(() => {
|
||||
// this.transformSquare2(gifUrl);
|
||||
this.imageKnifeOption = {
|
||||
loadSrc: gifUrl,
|
||||
placeholderSrc: $r('app.media.icon_loading'),
|
||||
errorholderSrc: $r('app.media.icon_failed'),
|
||||
}
|
||||
});
|
||||
Button('webp')
|
||||
.onClick(() => {
|
||||
// this.transformSquare2(webpUrl);
|
||||
this.imageKnifeOption = {
|
||||
loadSrc: webpUrl,
|
||||
placeholderSrc: $r('app.media.icon_loading'),
|
||||
errorholderSrc: $r('app.media.icon_failed'),
|
||||
}
|
||||
});
|
||||
// Button('gif')
|
||||
// .onClick(() => {
|
||||
// // this.transformSquare2(gifUrl);
|
||||
// this.imageKnifeOption = {
|
||||
// loadSrc: gifUrl,
|
||||
// placeholderSrc: $r('app.media.icon_loading'),
|
||||
// errorholderSrc: $r('app.media.icon_failed'),
|
||||
// }
|
||||
// });
|
||||
// Button('webp')
|
||||
// .onClick(() => {
|
||||
// // this.transformSquare2(webpUrl);
|
||||
// this.imageKnifeOption = {
|
||||
// loadSrc: webpUrl,
|
||||
// placeholderSrc: $r('app.media.icon_loading'),
|
||||
// errorholderSrc: $r('app.media.icon_failed'),
|
||||
// }
|
||||
// });
|
||||
}.margin({ top: 20, bottom: 20 })
|
||||
|
||||
Text("降采样字节大小:" + this.bytesNumber)
|
||||
|
|
Loading…
Reference in New Issue