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

Reversegeocode #5976

Merged
merged 16 commits into from
Nov 29, 2017
Merged

Reversegeocode #5976

merged 16 commits into from
Nov 29, 2017

Conversation

marhab21
Copy link
Contributor

I added a Reverse Geocoder to the Custom Geocoder.html Sandcastle demo, and I also added a new demo, which is another Reverse Geocoder, using BingMaps, and giving the address every time the user clicks on a location on the map.
This will demonstrate various features of Cesium, including comparing the information retrieved from OpenStreetMap to the one retrieved from Bing Maps.
Let me know what documentation or what else I need to add, or what I might be doing wrong : )
I had to edit .gitignore in order to add a gallery item.

@cesium-concierge
Copy link

Please sign the CLA before we review this PR.

Welcome to the Cesium community @marhab21!

Can you please send in a Contributor License Agreement (CLA) so that we can review and merge this pull request?

⚠️ I noticed that CHANGES.md has not been updated. If this change updates the public API in any way, fixes a bug, or makes any non-trivial update, please add a bullet point to CHANGES.md and comment on this pull request so we know it was updated. For more info, see the Pull Request Guidelines.


I am a bot who helps you make Cesium awesome! Contributions to my configuration are welcome.

🌍 🌎 🌏

@marhab21
Copy link
Contributor Author

I have already sent a CLA. I failed eslint, but corrected the errors.

@marhab21
Copy link
Contributor Author

What do I do to get the code reviewed?

@marhab21
Copy link
Contributor Author

Still says CLA Required...hmmm...I sent it to [email protected]...should I do something else?

@hpinkos
Copy link
Contributor

hpinkos commented Nov 14, 2017

Hi @marhab21, we're a bit busy this week, but someone should have time to review your pull request soon. Thanks!

@marhab21
Copy link
Contributor Author

marhab21 commented Nov 14, 2017 via email

@pjcozzi
Copy link
Contributor

pjcozzi commented Nov 14, 2017

We now have a CLA from @marhab21, thanks again!

.gitignore Outdated
@@ -10,7 +10,7 @@ Thumbs.db
/Apps/CesiumViewer/Gallery/gallery-index.js

/Apps/Sandcastle/jsHintOptions.js
/Apps/Sandcastle/gallery/gallery-index.js
#/Apps/Sandcastle/gallery/gallery-index.js
Copy link
Contributor

Choose a reason for hiding this comment

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

Can you revert this change?

Copy link
Contributor

Choose a reason for hiding this comment

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

We don't want to commit gallery-index.js. It is generated automatically when you run npm run build

* @alias OpenStreetMapNominatimGeocoder
* @constructor
*/
* This class is an example of a custom geocoder, and reverse geocoder. It provides both * * through the OpenStreetMap Nominatim service. Press the "Reverse Geocoder" button to go * * to OpenStreet Map headquarters. OpenStreetMap has more information in the UK than in the * US.
Copy link
Contributor

Choose a reason for hiding this comment

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

Was the * * intentional?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

No, I think it is a result of formatting when I got rid of the tabs...will fix : )

/**
* Find the camera position after search, and put a point there.
*/
function setPointForSearchLocation() {
Copy link
Contributor

Choose a reason for hiding this comment

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

Something in this function is causing an error to be thrown when you use the geocoder search

@hpinkos
Copy link
Contributor

hpinkos commented Nov 28, 2017

Thanks for the pull request @marhab21! I think these demos will be helpful for people.
Those are all of the comments I have for now. Be sure to add a comment to CHANGES.md about your change

@marhab21
Copy link
Contributor Author

marhab21 commented Nov 28, 2017 via email

@marhab21
Copy link
Contributor Author

OK, I hope I have fixed everything. Do I need to close the pull request, or do I wait 'til it's merged?
Thank you so much Hannah for the review...

@hpinkos
Copy link
Contributor

hpinkos commented Nov 28, 2017

You can just leave this PR open. I'll take another look at it tomorrow.

Does anyone else want to look at these sandcastle examples? @pjcozzi?

@pjcozzi
Copy link
Contributor

pjcozzi commented Nov 28, 2017

Sounds like a great example, but I have to pass due to time constraints.

@mramato
Copy link
Contributor

mramato commented Nov 29, 2017

While I'm fine with having a reverse geocoding example (though I haven't run it yet), I'm not sure updating the custom geocoder example to add reverse geocoding is a good idea, I think it confuses what is otherwise a solid simple example. Since this is all just example code (no Cesium to changes at all) I think just adding the new example would be preferred.

@marhab21
Copy link
Contributor Author

marhab21 commented Nov 29, 2017 via email

@ggetz
Copy link
Contributor

ggetz commented Nov 29, 2017

@marhab21 Revert the changes in the Custom Geocoder example, and add the code to a new Sandcastle example. You should make a new file like Custom Geocoder.html and put the code there. Also create a thumbnail image like the other examples.

@mramato
Copy link
Contributor

mramato commented Nov 29, 2017

@ggetz there is already a new Sandcastle example, we just need to revert the custom geocoder example and that's it. There's no reason to have two reverse geocoding examples.

If you could reset this branch to clean up the history, that would be great too; but if you're not sure how to do that, don't worry about it.

@marhab21
Copy link
Contributor Author

Thank you! I will revert the Custom Geocoder...I am not sure about how to reset the branch. I will look into it, but might leave it alone...I will confirm one way or the other.

@marhab21
Copy link
Contributor Author

Well, I have tried everything, but my builds keep failing, and I can't figure out why. I did catch 1 lint error, which I fixed. But the build keeps failing mainly in KML files, and things that don't seem to have anything to do with my changes. What am I missing? Here is the raw log...
Errors.txt

@hpinkos
Copy link
Contributor

hpinkos commented Nov 29, 2017

No worries @marhab21. We've had some problems with CI randomly failing lately. I'll take a closer look when I have a minute to do another review here, but It doesn't seem related to your changes.

@marhab21
Copy link
Contributor Author

Thank you Hannah!! : )

@hpinkos
Copy link
Contributor

hpinkos commented Nov 29, 2017

This is a super cool demo, thanks for the contribution @marhab21! I just pushed a commit with some code cleanup so your example follows the same coding guidelines as our other demos. I also removed the code to put a point at the location when you enter an address into the geocoder search bar because it wasn't as relevant to this example.

Congratulations on your first contribution!

@hpinkos hpinkos merged commit ad7636e into CesiumGS:master Nov 29, 2017
@hpinkos
Copy link
Contributor

hpinkos commented Nov 29, 2017

Just noticed that the formatting for CHANGES.md got a little messed up. I fixed it in master: 2a21744

@marhab21 marhab21 deleted the reversegeocode branch November 29, 2017 23:55
@marhab21
Copy link
Contributor Author

marhab21 commented Nov 29, 2017

Thank you everyone! I am so happy to have a contribution in Cesium!! And thanks for making the last minute fixes...
: )
When will the demo be up in Official Sandcastle?

@marhab21
Copy link
Contributor Author

I found it in "Showcases", but it doesn't seem to load, and redirects to HelloWorld :(

@mramato
Copy link
Contributor

mramato commented Nov 30, 2017

When will the demo be up in Official Sandcastle?

It will go out on Friday with the next Cesium release (Cesium releases on the first business day of every month).

@marhab21
Copy link
Contributor Author

marhab21 commented Nov 30, 2017 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants