{"action":"created","issue":{"url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/issues/14443","labels_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/issues/14443/labels{/name}","comments_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/issues/14443/comments","events_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/issues/14443/events","html_url":"https://github.com/CleverRaven/Cataclysm-DDA/issues/14443","id":122431530,"number":14443,"title":"Map notes disappear when examined and escaped","user":{"login":"aeoo","id":16316104,"avatar_url":"https://avatars.githubusercontent.com/u/16316104?v=3","gravatar_id":"","url":"https://api.github.com/users/aeoo","html_url":"https://github.com/aeoo","followers_url":"https://api.github.com/users/aeoo/followers","following_url":"https://api.github.com/users/aeoo/following{/other_user}","gists_url":"https://api.github.com/users/aeoo/gists{/gist_id}","starred_url":"https://api.github.com/users/aeoo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aeoo/subscriptions","organizations_url":"https://api.github.com/users/aeoo/orgs","repos_url":"https://api.github.com/users/aeoo/repos","events_url":"https://api.github.com/users/aeoo/events{/privacy}","received_events_url":"https://api.github.com/users/aeoo/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":11,"created_at":"2015-12-16T05:27:58Z","updated_at":"2015-12-17T02:07:15Z","closed_at":null,"body":"Build 0.C-8241 or 4043 on jenkins.\r\n\r\nIf I examine a Map note and hit escape it seems like the note just gets deleted.  This isn't desirable.  If I hit the escape button I want whatever was there to be preserved (no action taken, I just want to get out of the screen).\r\n\r\nSo to reproduce, hit \"m\" inside the running game to get to the map screen.  Then hit \"N\" to make a note.  Make some note and hit enter.  Then hit \"N\" again on the same square to examine the note.  Then hit escape.  The note appears to have been deleted.  Ideally it should be left intact."},"comment":{"url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/issues/comments/165314776","html_url":"https://github.com/CleverRaven/Cataclysm-DDA/issues/14443#issuecomment-165314776","issue_url":"https://api.github.com/repos/CleverRaven/Cataclysm-DDA/issues/14443","id":165314776,"user":{"login":"aeoo","id":16316104,"avatar_url":"https://avatars.githubusercontent.com/u/16316104?v=3","gravatar_id":"","url":"https://api.github.com/users/aeoo","html_url":"https://github.com/aeoo","followers_url":"https://api.github.com/users/aeoo/followers","following_url":"https://api.github.com/users/aeoo/following{/other_user}","gists_url":"https://api.github.com/users/aeoo/gists{/gist_id}","starred_url":"https://api.github.com/users/aeoo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aeoo/subscriptions","organizations_url":"https://api.github.com/users/aeoo/orgs","repos_url":"https://api.github.com/users/aeoo/repos","events_url":"https://api.github.com/users/aeoo/events{/privacy}","received_events_url":"https://api.github.com/users/aeoo/received_events","type":"User","site_admin":false},"created_at":"2015-12-17T02:07:15Z","updated_at":"2015-12-17T02:07:15Z","body":">Because \"user pressed escape\" should retain the old note text, and \"user explicitly entered an empty string\" should delete the old text.\r\n\r\nI agree that what you describe is ideal, but in practical terms is it possible to ask people if they use the edit function to delete notes often?  It seems like a corner case.  Ideally it's good to handle corner cases in a manner consistent with the \"least surprise\" principle.  But assuming we have a genuine corner case there, it's rare.  So the easiest thing to do is to code an 80% solution.  Handle all the common cases and leave the rare ones alone.  The common way to delete a note is, I assume, with a \"D\" button.  Backspacing through an edited note is a strange way to delete a note.  But I agree that ideally if someone really went through the trouble of backspacing everything via edit, they should be rewarded with a deleted note, lol.  Ideally.  But that wouldn't be a part of my 80% solution tho.   This is how I think about it.  I might say something else if we had polled the users and we knew for a fact that perhaps backspacing through notes is a very common occurrence."}}