public JBCefClient addDialogHandler(@NotNull CefDialogHandler handler, @NotNull CefBrowser browser) {
    return myDialogHandler.add(handler, browser, () -> {
      myCefClient.addDialogHandler(new CefDialogHandler() {
        @Override
        public boolean onFileDialog(CefBrowser browser,
                                    FileDialogMode mode,
                                    String title,
                                    String defaultFilePath,
                                    Vector<String> acceptFilters,
                                    CefFileDialogCallback callback) {
          return myDialogHandler.handleBooleanFirst(browser, handler -> {
            return handler.onFileDialog(browser, mode, title, defaultFilePath, acceptFilters, callback);
          });
        }
      });
    });
  }
public JBCefClient addDialogHandler(@NotNull CefDialogHandler handler, @NotNull CefBrowser browser)