{"action":"created","issue":{"url":"https://api.github.com/repos/Beep6581/RawTherapee/issues/4857","repository_url":"https://api.github.com/repos/Beep6581/RawTherapee","labels_url":"https://api.github.com/repos/Beep6581/RawTherapee/issues/4857/labels{/name}","comments_url":"https://api.github.com/repos/Beep6581/RawTherapee/issues/4857/comments","events_url":"https://api.github.com/repos/Beep6581/RawTherapee/issues/4857/events","html_url":"https://github.com/Beep6581/RawTherapee/pull/4857","id":368354301,"node_id":"MDExOlB1bGxSZXF1ZXN0MjIxNTUyMDk3","number":4857,"title":"Turn Listeners into abstract interfaces","user":{"login":"Floessie","id":10133457,"node_id":"MDQ6VXNlcjEwMTMzNDU3","avatar_url":"https://avatars3.githubusercontent.com/u/10133457?v=4","gravatar_id":"","url":"https://api.github.com/users/Floessie","html_url":"https://github.com/Floessie","followers_url":"https://api.github.com/users/Floessie/followers","following_url":"https://api.github.com/users/Floessie/following{/other_user}","gists_url":"https://api.github.com/users/Floessie/gists{/gist_id}","starred_url":"https://api.github.com/users/Floessie/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Floessie/subscriptions","organizations_url":"https://api.github.com/users/Floessie/orgs","repos_url":"https://api.github.com/users/Floessie/repos","events_url":"https://api.github.com/users/Floessie/events{/privacy}","received_events_url":"https://api.github.com/users/Floessie/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-10-09T19:08:28Z","updated_at":"2018-10-09T20:03:09Z","closed_at":null,"author_association":"COLLABORATOR","pull_request":{"url":"https://api.github.com/repos/Beep6581/RawTherapee/pulls/4857","html_url":"https://github.com/Beep6581/RawTherapee/pull/4857","diff_url":"https://github.com/Beep6581/RawTherapee/pull/4857.diff","patch_url":"https://github.com/Beep6581/RawTherapee/pull/4857.patch"},"body":"Hi,\r\n\r\nWhen working on #4446 I deliberately changed `SaveAsDialog::formatChanged(Glib::ustring)` to `SaveAsDialog::formatChanged(const Glib::ustring&)` unaware of the fact it was derived. It compiled without a warning and I had to find out for myself, why the dialog behaved strangely.\r\n\r\nThe problem was the fact, that the `FormatChangeListener` had a default implementation for `formatChanged()`. I then found out, that many of the Listeners are implemented in the same way, making it impossible to detect a signature miss.\r\n\r\nOne solution would be the marking of all derived methods with `override`, which can be automatically and globally done by `clang-tidy`. But this would only manifest the status quo and not reveal signature misses we have today or tomorrow.\r\n\r\nSo I went for a IMHO better solution: I made almost all Listeners abstract. This uncovered Listeners that weren't used anymore and will force future changes to comply with the base class. Fortunately, there were no signature misses in the code so far.\r\n\r\n\"Almost all\" means, there were two or three Listeners that are more than just callback classes. I'll have to think a bit more about them.\r\n\r\nDuring this code revision I also made the usual `const` and whitespace corrections. One outcome is that `LUT<T>::operator =()` is finally `const` correct. :tada:\r\n\r\nThere are still things to improve, and I'll probably add some commits here. Please feel free to do the same.\r\n\r\nI know this is a big one, but it's certainly worth it. :smile: \r\n\r\nBest,\r\nFlössie"},"comment":{"url":"https://api.github.com/repos/Beep6581/RawTherapee/issues/comments/428331327","html_url":"https://github.com/Beep6581/RawTherapee/pull/4857#issuecomment-428331327","issue_url":"https://api.github.com/repos/Beep6581/RawTherapee/issues/4857","id":428331327,"node_id":"MDEyOklzc3VlQ29tbWVudDQyODMzMTMyNw==","user":{"login":"Floessie","id":10133457,"node_id":"MDQ6VXNlcjEwMTMzNDU3","avatar_url":"https://avatars3.githubusercontent.com/u/10133457?v=4","gravatar_id":"","url":"https://api.github.com/users/Floessie","html_url":"https://github.com/Floessie","followers_url":"https://api.github.com/users/Floessie/followers","following_url":"https://api.github.com/users/Floessie/following{/other_user}","gists_url":"https://api.github.com/users/Floessie/gists{/gist_id}","starred_url":"https://api.github.com/users/Floessie/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Floessie/subscriptions","organizations_url":"https://api.github.com/users/Floessie/orgs","repos_url":"https://api.github.com/users/Floessie/repos","events_url":"https://api.github.com/users/Floessie/events{/privacy}","received_events_url":"https://api.github.com/users/Floessie/received_events","type":"User","site_admin":false},"created_at":"2018-10-09T20:03:09Z","updated_at":"2018-10-09T20:03:09Z","author_association":"COLLABORATOR","body":"@heckflosse Ingo, I think you're right, I found no reference to it at first glance."}}
{"actor":{"display_login":"Floessie"}}