Call back directly from DialogModelHost to fields
Replaces methods like DialogModel::OnButtonPressed() with DialogModelButton::OnPressed(), so that those calls from DialogModelHost don't have to go through DialogModel. This also makes the callback for DialogModelButton mandatory and removes it from Params. The dialog buttons OK and Cancel are the exceptions that don't need one and use a NOTREACHED() lambda. The change also adds util::PassKey<DialogModelHost> to additional DialogModelField methods to narrow the public API from methods that are unnecessary for public consumption. Bug: 1106422 Change-Id: I8f50e1ce48b2862fce3be5054d6c788c41846f53 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2354637 Commit-Queue: Peter Boström <pbos@chromium.org> Reviewed-by:Scott Violet <sky@chromium.org> Cr-Commit-Position: refs/heads/master@{#798356}
Showing
Please register or sign in to comment