[google_maps_flutter] Replace use of zIndex in examples and tests#11572
[google_maps_flutter] Replace use of zIndex in examples and tests#11572stuartmorgan-g wants to merge 1 commit intoflutter:mainfrom
Conversation
Replaces uses of the deprecated `zIndex` in examples and tests with the preferred `zIndexInt`. This doesn't change the production use of `zIndex` in google_maps_flutter_web, as that could change behavior, so should stay for now.
There was a problem hiding this comment.
Code Review
This pull request replaces the deprecated double-based zIndex property with the integer-based zIndexInt across the Google Maps Flutter Android and iOS packages, including their respective examples and tests. The changes update marker creation, z-index modification logic, and test assertions to use the new integer property. Reviewer feedback suggests further consistency by updating parameter names and test expectation properties to fully utilize the zIndexInt API.
| rotation: marker.rotation, | ||
| visible: marker.visible, | ||
| zIndex: marker.zIndex.toInt(), | ||
| zIndex: marker.zIndexInt, |
| expect(firstChanged.rotation, object2new.rotation); | ||
| expect(firstChanged.visible, object2new.visible); | ||
| expect(firstChanged.zIndex, object2new.zIndex); | ||
| expect(firstChanged.zIndex, object2new.zIndexInt); |
There was a problem hiding this comment.
| expect(firstAdded.rotation, object3.rotation); | ||
| expect(firstAdded.visible, object3.visible); | ||
| expect(firstAdded.zIndex, object3.zIndex); | ||
| expect(firstAdded.zIndex, object3.zIndexInt); |
There was a problem hiding this comment.
| rotation: marker.rotation, | ||
| visible: marker.visible, | ||
| zIndex: marker.zIndex.toInt(), | ||
| zIndex: marker.zIndexInt, |
| expect(firstChanged.rotation, object2new.rotation); | ||
| expect(firstChanged.visible, object2new.visible); | ||
| expect(firstChanged.zIndex, object2new.zIndex); | ||
| expect(firstChanged.zIndex, object2new.zIndexInt); |
There was a problem hiding this comment.
| expect(firstChanged.rotation, object2new.rotation); | ||
| expect(firstChanged.visible, object2new.visible); | ||
| expect(firstChanged.zIndex, object2new.zIndex); | ||
| expect(firstChanged.zIndex, object2new.zIndexInt); |
There was a problem hiding this comment.
| expect(firstAdded.rotation, object3.rotation); | ||
| expect(firstAdded.visible, object3.visible); | ||
| expect(firstAdded.zIndex, object3.zIndex); | ||
| expect(firstAdded.zIndex, object3.zIndexInt); |
There was a problem hiding this comment.
| rotation: marker.rotation, | ||
| visible: marker.visible, | ||
| zIndex: marker.zIndex.toInt(), | ||
| zIndex: marker.zIndexInt, |
| expect(firstChanged.rotation, object2new.rotation); | ||
| expect(firstChanged.visible, object2new.visible); | ||
| expect(firstChanged.zIndex, object2new.zIndex); | ||
| expect(firstChanged.zIndex, object2new.zIndexInt); |
There was a problem hiding this comment.
| expect(firstAdded.rotation, object3.rotation); | ||
| expect(firstAdded.visible, object3.visible); | ||
| expect(firstAdded.zIndex, object3.zIndex); | ||
| expect(firstAdded.zIndex, object3.zIndexInt); |
There was a problem hiding this comment.
Replaces uses of the deprecated
zIndexin examples and tests with the preferredzIndexInt.This doesn't change the production use of
zIndexin google_maps_flutter_web, as that could change behavior, so should stay for now.