NativeScript / NativeScript/plugins
Unable to change transparency on TileOverlay on Android
还没有人认领这个 Issue。
- 主要语言
- TypeScript
- 星标
- 206
- 派生
- 123
- 平均合并
- 2 天 1 小时
- 30 天内合并 PR
- 1
描述
I'm migrating from the kefahB/nativescript-google-maps plugin to @nativescript/google-maps.
My app animates weather radar by composing an array of TileOverlays and then iteratively changing the TileOverlay's transparency to hide one overlay and display the next.
While transparency can be specified in the TileOverlayOptions when creating a TileOverlay, it can't be modified directly afterwards. Instead, you have to use native methods, such as on iOS:
tileOverlay.native.opacity = 1.0; // display tileOverlay
On Android, there's:
tileOverlay.native.setTransparency(0.0); // display tileOverlay
But this seems to have no effect. I can see in the debugger and via tileOverlay.native.getTransparency() that the native TileOverlay's transparency property has indeed been changed, but there is no change in the display.
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
调研方向
从通过 tileOverlay.native 暴露的 Android TileOverlay 实现开始,跟踪 TileOverlayOptions 中的 setTransparency 以及 transparency。复现 Android 上雷达叠加层的更新,并验证创建后更改 transparency 会改变渲染出的叠加层。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- android, typescript
- 领域
- mobile
- Issue 类型
- 缺陷
- 难度
- 3/5
- 预计耗时
- 1-2 天
- 活跃度
- 停滞
- 描述清晰度
- 基本清楚
- 新手友好度
- 42/100