This is a stub issue to hold discussion and ideas while #1879120: Use core dialogs rather than CKEditor dialogs is getting finished up.
Right now we have the ability to insert an image into a WYSIWYG editor through a modal dialog that is provided by Drupal. However this modal right now only provides the basics: URL, height/width, and alt attributes. There is very little point in making a dialog that does a server-side request unless we make use of the the server-side abilities that Drupal provides us. In this case, I'm referring to allowing a user to upload an image in the image modal dialog.
Because the modal dialog is server-side, it means that we can use a #type = 'managed_file' element in the modal to handle file uploads. After the initial problem of uploading a file is handled, we may extend this element (similar to the way FileField Sources does) to provide other ways to select a file, such as using Views to select recent uploads, or to actually *transfer* images from remote URLs, or to paste from the clipboard, or other ways of managing files.