问题描述
我需要能够在Flutter插件中指定图片并在本机插件(例如iOS)中访问该图片。但是,我不确定支持大多数源类型的最佳方法是什么。
实施应类似于:
<div class="power-switch">
<input type="checkBox" />
<div class="button">
<svg class="power-off">
<use xlink:href="#line" class="line" />
<use xlink:href="#circle" class="circle" />
</svg>
<svg class="power-on">
<use xlink:href="#line" class="line" />
<use xlink:href="#circle" class="circle" />
</svg>
</div>
</div>
<!-- SVG -->
<svg xmlns="http://www.w3.org/2000/svg" style="display: none;">
<symbol xmlns="http://www.w3.org/2000/svg" viewBox="0 0 150 150" id="line">
<line x1="75" y1="34" x2="75" y2="58"/>
</symbol>
<symbol xmlns="http://www.w3.org/2000/svg" viewBox="0 0 150 150" id="circle">
<circle cx="75" cy="80" r="35"/>
</symbol>
</svg>
我现在想从本地插件中访问该图像(例如,从Web URL,文件路径等)。
static void openImage(image) async {
await _channel.invokeMethod('open',image);
}
参数需要哪个参数?
无需将映像复制到temp目录中的最佳方法是什么?
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)