burningmantech / ranger-ims-mac

Ranger Incident Management System—Mac OS Client
Apache License 2.0
4 stars 2 forks source link

Summary field clears if edited w/o action then state is changed #56

Closed wsanchez closed 9 years ago

wsanchez commented 9 years ago

Steps to reproduce:

Notice the summary field clears out.

wsanchez commented 9 years ago

OK what's going on here is that when you do anything that modifies the incident (like change priority), that causes all of the views to get updated, because they may have changed and so we want to see the changes.

But if you are in the middle of editing some text, no change has been made to the incident, and when it gets updated, the original value gets put in there for you.

wsanchez commented 9 years ago

So what I want is a way to cause whatever text field is in the middle of an edit to tell the app to update the incident, which normally happens when you hit return or exit the text field.

An answer to this question on StackOverflow suggests that changing the first responder will cause the current first responder to send its action, and the a text field in mid-edit is going to be the first responder, so… yeah that seems to work.

Fix: 0dadcdbe7e67ba3bfaca0863dceaf13e482b0ed4