Skip to content
This repository was archived by the owner on Feb 22, 2023. It is now read-only.

[google_maps_flutter] Add TileOverlay support #2077

Closed
wants to merge 74 commits into from

Conversation

otopba
Copy link
Contributor

@otopba otopba commented Sep 21, 2019

Description

Add TileOverlay support.

Related Issues

flutter/flutter#25942

Checklist

  • I read the [Contributor Guide] and followed the process outlined there for submitting PRs.
  • My PR includes unit or integration tests for all changed/updated/fixed behaviors (See [Contributor Guide]).
  • All existing and new tests are passing.
  • I updated/added relevant documentation (doc comments with ///).
  • The analyzer (flutter analyze) does not report any problems on my PR.
  • I read and followed the [Flutter Style Guide].
  • The title of the PR starts with the name of the plugin surrounded by square brackets, e.g. [shared_preferences]
  • I updated pubspec.yaml with an appropriate new version according to the [pub versioning philosophy].
  • I updated CHANGELOG.md to add a description of the change.
  • I signed the [CLA].
  • I am willing to follow-up on review comments in a timely manner.

Breaking Change

  • Yes, this is a breaking change (please indicate a breaking change in CHANGELOG.md and increment major revision).
  • No, this is not a breaking change.

@otopba
Copy link
Contributor Author

otopba commented Sep 21, 2019

@iskakaushik Hi!
Could you add .codeStyle for this repo? Because now, I can't use autoformat for Kotlin code. Thank you
flutter/flutter#40618

UPD:
found https://github.com/google/google-java-format

# Conflicts:
#	packages/google_maps_flutter/CHANGELOG.md
#	packages/google_maps_flutter/pubspec.yaml
# Conflicts:
#	packages/google_maps_flutter/CHANGELOG.md
#	packages/google_maps_flutter/pubspec.yaml
# Conflicts:
#	packages/google_maps_flutter/CHANGELOG.md
#	packages/google_maps_flutter/pubspec.yaml
@otopba
Copy link
Contributor Author

otopba commented Nov 2, 2019

@iskakaushik Any updates?

@otopba otopba requested a review from cyanglaz as a code owner January 14, 2020 16:20
@queendevelopers
Copy link

How do I use this build? I am currently running flutter_google_maps 1.0.2 build.

@neokree
Copy link

neokree commented Oct 5, 2020

@queendevelopers This build has been initially developed on the 0.5.25 version of google_maps_flutter, but it was blocked by the release of the web support, which required a lot of the code developed by me and @otopba to be rewritten in order to support the "new" google_maps_flutter_interface.

The PR is blocked from that moment and I didn't had the time to fix it, but if you want to help it to conclude this development this is surely appreciated

@yamamotodin
Copy link

yamamotodin commented Oct 7, 2020

@otopba Thank you for implementation!

I found a mystery.

"Tile overlays" only works after _onMapCreated is called in ios.
In the Android, it works even before called _onMapCreated.

"example" is the tile overlay addition after _onMapCreated.

So I wrote this.

  void _onMapCreated(GoogleMapController controller) {
    this.controller = controller;
    setState(() {
      // mystery: 理屈はよくわからんがiosだとこの関数以降でなければタイルオーバレイが仕事しない
     _tileOverlay = ...;
    });
  }

Is that a matter of course?

neokree and others added 7 commits October 12, 2020 13:08
# Conflicts:
#	packages/google_maps_flutter/google_maps_flutter/CHANGELOG.md
#	packages/google_maps_flutter/google_maps_flutter/example/lib/main.dart
#	packages/google_maps_flutter/google_maps_flutter/lib/google_maps_flutter.dart
#	packages/google_maps_flutter/google_maps_flutter/lib/src/controller.dart
#	packages/google_maps_flutter/google_maps_flutter/lib/src/google_map.dart
#	packages/google_maps_flutter/google_maps_flutter/pubspec.yaml
# Conflicts:
#	packages/google_maps_flutter/google_maps_flutter/android/src/main/java/io/flutter/plugins/googlemaps/GoogleMapFactory.java
@otopba otopba requested a review from cyanglaz November 1, 2020 15:31
@otopba
Copy link
Contributor Author

otopba commented Nov 1, 2020

How do I use this build? I am currently running flutter_google_maps 1.0.2 build.

Just set this branch as source for Google Maps inside your pubspec file

@otopba
Copy link
Contributor Author

otopba commented Nov 1, 2020

@otopba Thank you for implementation!

I found a mystery.

"Tile overlays" only works after _onMapCreated is called in ios.
In the Android, it works even before called _onMapCreated.

"example" is the tile overlay addition after _onMapCreated.

So I wrote this.

  void _onMapCreated(GoogleMapController controller) {
    this.controller = controller;
    setState(() {
      // mystery: 理屈はよくわからんがiosだとこの関数以降でなければタイルオーバレイが仕事しない
     _tileOverlay = ...;
    });
  }

Is that a matter of course?

Could you check it in native app?

@otopba
Copy link
Contributor Author

otopba commented Nov 1, 2020

@cyanglaz friendly ping

@neokree
Copy link

neokree commented Nov 28, 2020

@cyanglaz Seems like the build cannot pass since we are doing changes on either google_maps_flutter and google_maps_flutter_platform_interface.

If I set the dependency of google_maps_flutter to google_maps_flutter_platform_interface: ^1.0.6, the build do not pass since google_maps_flutter_platform_interface: 1.0.6 is not published to pub.dev.

If I use a path dependency instead, the plugin can be tested, but the build can't be published since it would depend on the local google_maps_flutter_platform_interface.

Do we need to open a new MR with only the changes on google_maps_flutter_platform_interface?

@neokree
Copy link

neokree commented Nov 28, 2020

@jweidner-mbible Thank you for your tip, I added the fix now.

@yamamotodin The bug you found on iOS is now fixed on the latest commit.

@cyanglaz
Copy link
Contributor

cyanglaz commented Jan 8, 2021

@neokree let's fork a PR that only contains platform_interface changes. Then we can publish the platform interface changes first.

@cyanglaz
Copy link
Contributor

cyanglaz commented Feb 3, 2021

This is being worked on at #3434, I'm closing the PR :)

@cyanglaz cyanglaz closed this Feb 3, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.