Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rotate pegman marker icon and google street view panorama accordingly #344

Open
wants to merge 6 commits into
base: dev
Choose a base branch
from

Conversation

Raruto
Copy link
Collaborator

@Raruto Raruto commented Feb 14, 2023

Summary

Improve end-user experience by rotating the marker arrow (on the map) in relation to what is currently displayed in the panorama container (streetview navigation).

Preview

ezgif-5-9821f4e63a

Notable changes

  • add new listener: google.maps.StreetViewPanorama#pov_changed
  • refactor listener google.maps.StreetviewPanorama#position_changed (just a little bit of code clean up)
  • increase color contrast of the marker icon from white to yellow (pegman marker)

Closes: #337
Supersedes: #338

- add new listener: `google.maps.StreetViewPanorama#pov_changed`
- refactor listener `google.maps.StreetviewPanorama#position_changed` (just a little bit of code clean up)
@Raruto Raruto added the ux Changes to a current behavior to improve user experience label Feb 14, 2023
@Raruto Raruto added this to the v3.9 milestone Feb 14, 2023
@Raruto Raruto marked this pull request as ready for review February 14, 2023 10:19
Comment on lines +158 to +166
* @TODO compute intial heading evaluating it between the "openlayers" and "streetview" coordinates
*/
// this._panorama.setPov({
// heading: google.maps.geometry.spherical.computeHeading(data.location.latLng, new google.maps.LatLng(this._clickLat, this._clickLng)),
// pitch: 0,
// zoom: 0
// });
}
};
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

take a look at it before merging

Comment on lines +203 to +206
/**
* @TODO really ugly, find out a simpler way to just update the `ol.style.Icon~rotation` value
*/
this.onPanoramaPositionChanged();
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

take a look at it before merging

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Raruto need to be close #338 before it

@Raruto
Copy link
Collaborator Author

Raruto commented Feb 14, 2023

@Raruto need to be close #338 before it

Sure, I've made these changes in a new pull request just so you can evaluate them separately.

Anyway, i set this other one on milestone v3.9 (just to not put too much things on v3.8...)

@Raruto Raruto modified the milestones: v3.9, v3.10 Oct 19, 2023
@Raruto Raruto removed this from the v3.10 milestone Apr 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ux Changes to a current behavior to improve user experience
Projects
None yet
2 participants