diff --git a/examples/webenginewidgets/simplebrowser/browser.cpp b/examples/webenginewidgets/simplebrowser/browser.cpp
index f1420c2a30d435b14e24eaa21648de88ee647f9e..5eae4f3c111055d2816a082e28068173e49f7859 100644
--- a/examples/webenginewidgets/simplebrowser/browser.cpp
+++ b/examples/webenginewidgets/simplebrowser/browser.cpp
@@ -40,38 +40,26 @@
 
 #include "browser.h"
 #include "browserwindow.h"
-#include "webview.h"
-#include <QAuthenticator>
 
-Browser::Browser()
-{
-}
-
-Browser::~Browser()
-{
-    qDeleteAll(m_windows);
-    m_windows.clear();
-}
+#include <QWebEngineProfile>
 
-Browser &Browser::instance()
+Browser::Browser()
 {
-    static Browser browser;
-    return browser;
-}
+    // Quit application if the download manager window is the only remaining window
+    m_downloadManagerWidget.setAttribute(Qt::WA_QuitOnClose, false);
 
-QVector<BrowserWindow*> Browser::windows()
-{
-    return m_windows;
+    QObject::connect(
+        QWebEngineProfile::defaultProfile(), &QWebEngineProfile::downloadRequested,
+        &m_downloadManagerWidget, &DownloadManagerWidget::downloadRequested);
 }
 
-void Browser::addWindow(BrowserWindow *mainWindow)
+BrowserWindow *Browser::createWindow()
 {
-    if (m_windows.contains(mainWindow))
-        return;
-    m_windows.prepend(mainWindow);
+    auto mainWindow = new BrowserWindow(this);
+    m_windows.append(mainWindow);
     QObject::connect(mainWindow, &QObject::destroyed, [this, mainWindow]() {
         m_windows.removeOne(mainWindow);
     });
     mainWindow->show();
+    return mainWindow;
 }
-
diff --git a/examples/webenginewidgets/simplebrowser/browser.h b/examples/webenginewidgets/simplebrowser/browser.h
index 0fdbd46a74f7c6e247ef623ba0abbfad2ac97e23..27e2aaf4359722eb38af93ace21173ef4b2f85b4 100644
--- a/examples/webenginewidgets/simplebrowser/browser.h
+++ b/examples/webenginewidgets/simplebrowser/browser.h
@@ -41,6 +41,8 @@
 #ifndef BROWSER_H
 #define BROWSER_H
 
+#include "downloadmanagerwidget.h"
+
 #include <QVector>
 
 class BrowserWindow;
@@ -48,14 +50,16 @@ class BrowserWindow;
 class Browser
 {
 public:
-    ~Browser();
+    Browser();
+
+    QVector<BrowserWindow*> windows() { return m_windows; }
 
-    QVector<BrowserWindow*> windows();
-    void addWindow(BrowserWindow* window);
-    static Browser &instance();
+    BrowserWindow *createWindow();
+
+    DownloadManagerWidget &downloadManagerWidget() { return m_downloadManagerWidget; }
 
 private:
-    Browser();
     QVector<BrowserWindow*> m_windows;
+    DownloadManagerWidget m_downloadManagerWidget;
 };
 #endif // BROWSER_H
diff --git a/examples/webenginewidgets/simplebrowser/browserwindow.cpp b/examples/webenginewidgets/simplebrowser/browserwindow.cpp
index 0b85e2bb0b4a518dcffbcac5acf47503f9ff76ba..43c25e633f783876b32e58bd8175964df768f264 100644
--- a/examples/webenginewidgets/simplebrowser/browserwindow.cpp
+++ b/examples/webenginewidgets/simplebrowser/browserwindow.cpp
@@ -40,12 +40,13 @@
 
 #include "browser.h"
 #include "browserwindow.h"
+#include "downloadmanagerwidget.h"
 #include "tabwidget.h"
-#include "urllineedit.h"
 #include "webview.h"
 #include <QApplication>
 #include <QCloseEvent>
 #include <QDesktopWidget>
+#include <QEvent>
 #include <QFileDialog>
 #include <QInputDialog>
 #include <QMenuBar>
@@ -54,9 +55,10 @@
 #include <QStatusBar>
 #include <QToolBar>
 #include <QVBoxLayout>
+#include <QWebEngineProfile>
 
-BrowserWindow::BrowserWindow(QWidget *parent, Qt::WindowFlags flags)
-    : QMainWindow(parent, flags)
+BrowserWindow::BrowserWindow(Browser *browser)
+    : m_browser(browser)
     , m_tabWidget(new TabWidget(this))
     , m_progressBar(new QProgressBar(this))
     , m_historyBackAction(nullptr)
@@ -64,10 +66,11 @@ BrowserWindow::BrowserWindow(QWidget *parent, Qt::WindowFlags flags)
     , m_stopAction(nullptr)
     , m_reloadAction(nullptr)
     , m_stopReloadAction(nullptr)
-    , m_urlLineEdit(new UrlLineEdit(this))
+    , m_urlLineEdit(nullptr)
+    , m_favAction(nullptr)
 {
-    setToolButtonStyle(Qt::ToolButtonFollowStyle);
     setAttribute(Qt::WA_DeleteOnClose, true);
+    setFocusPolicy(Qt::ClickFocus);
 
     QToolBar *toolbar = createToolBar();
     addToolBar(toolbar);
@@ -85,7 +88,7 @@ BrowserWindow::BrowserWindow(QWidget *parent, Qt::WindowFlags flags)
 
     m_progressBar->setMaximumHeight(1);
     m_progressBar->setTextVisible(false);
-    m_progressBar->setStyleSheet(QStringLiteral("QProgressBar {border: 0px } QProgressBar::chunk { background-color: red; }"));
+    m_progressBar->setStyleSheet(QStringLiteral("QProgressBar {border: 0px} QProgressBar::chunk {background-color: #da4453}"));
 
     layout->addWidget(m_progressBar);
     layout->addWidget(m_tabWidget);
@@ -97,15 +100,14 @@ BrowserWindow::BrowserWindow(QWidget *parent, Qt::WindowFlags flags)
         statusBar()->showMessage(url);
     });
     connect(m_tabWidget, &TabWidget::loadProgress, this, &BrowserWindow::handleWebViewLoadProgress);
-    connect(m_tabWidget, &TabWidget::urlChanged, this, &BrowserWindow::handleWebViewUrlChanged);
-    connect(m_tabWidget, &TabWidget::iconChanged, this, &BrowserWindow::handleWebViewIconChanged);
     connect(m_tabWidget, &TabWidget::webActionEnabledChanged, this, &BrowserWindow::handleWebActionEnabledChanged);
-    connect(m_urlLineEdit, &QLineEdit::returnPressed, this, [this]() {
-        m_urlLineEdit->setFavIcon(QIcon(QStringLiteral(":defaulticon.png")));
-        loadPage(m_urlLineEdit->url());
+    connect(m_tabWidget, &TabWidget::urlChanged, [this](const QUrl &url) {
+        m_urlLineEdit->setText(url.toDisplayString());
+    });
+    connect(m_tabWidget, &TabWidget::favIconChanged, m_favAction, &QAction::setIcon);
+    connect(m_urlLineEdit, &QLineEdit::returnPressed, [this]() {
+        m_tabWidget->setUrl(QUrl::fromUserInput(m_urlLineEdit->text()));
     });
-
-    m_urlLineEdit->setFavIcon(QIcon(QStringLiteral(":defaulticon.png")));
 
     QAction *focusUrlLineEditAction = new QAction(this);
     addAction(focusUrlLineEditAction);
@@ -114,14 +116,10 @@ BrowserWindow::BrowserWindow(QWidget *parent, Qt::WindowFlags flags)
         m_urlLineEdit->setFocus(Qt::ShortcutFocusReason);
     });
 
-    handleWebViewTitleChanged(tr("Qt Simple Browser"));
+    handleWebViewTitleChanged(QString());
     m_tabWidget->createTab();
 }
 
-BrowserWindow::~BrowserWindow()
-{
-}
-
 QSize BrowserWindow::sizeHint() const
 {
     QRect desktopRect = QApplication::desktop()->screenGeometry();
@@ -134,18 +132,16 @@ QMenu *BrowserWindow::createFileMenu(TabWidget *tabWidget)
     QMenu *fileMenu = new QMenu(tr("&File"));
     fileMenu->addAction(tr("&New Window"), this, &BrowserWindow::handleNewWindowTriggered, QKeySequence::New);
 
-    QAction *newTabAction = new QAction(QIcon(QLatin1String(":addtab.png")), tr("New &Tab"), this);
+    QAction *newTabAction = new QAction(tr("New &Tab"), this);
     newTabAction->setShortcuts(QKeySequence::AddTab);
-    newTabAction->setIconVisibleInMenu(false);
     connect(newTabAction, &QAction::triggered, tabWidget, &TabWidget::createTab);
     fileMenu->addAction(newTabAction);
 
     fileMenu->addAction(tr("&Open File..."), this, &BrowserWindow::handleFileOpenTriggered, QKeySequence::Open);
     fileMenu->addSeparator();
 
-    QAction *closeTabAction = new QAction(QIcon(QLatin1String(":closetab.png")), tr("&Close Tab"), this);
+    QAction *closeTabAction = new QAction(tr("&Close Tab"), this);
     closeTabAction->setShortcuts(QKeySequence::Close);
-    closeTabAction->setIconVisibleInMenu(false);
     connect(closeTabAction, &QAction::triggered, [tabWidget]() {
         tabWidget->closeTab(tabWidget->currentIndex());
     });
@@ -156,8 +152,8 @@ QMenu *BrowserWindow::createFileMenu(TabWidget *tabWidget)
     connect(closeAction, &QAction::triggered, this, &QWidget::close);
     fileMenu->addAction(closeAction);
 
-    connect(fileMenu, &QMenu::aboutToShow, [closeAction]() {
-        if (Browser::instance().windows().count() == 1)
+    connect(fileMenu, &QMenu::aboutToShow, [this, closeAction]() {
+        if (m_browser->windows().count() == 1)
             closeAction->setText(tr("&Quit"));
         else
             closeAction->setText(tr("&Close Window"));
@@ -288,7 +284,7 @@ QMenu *BrowserWindow::createWindowMenu(TabWidget *tabWidget)
         menu->addAction(previousTabAction);
         menu->addSeparator();
 
-        QVector<BrowserWindow*> windows = Browser::instance().windows();
+        QVector<BrowserWindow*> windows = m_browser->windows();
         int index(-1);
         for (auto window : windows) {
             QAction *action = menu->addAction(window->windowTitle(), this, &BrowserWindow::handleShowWindowTriggered);
@@ -311,7 +307,7 @@ QMenu *BrowserWindow::createHelpMenu()
 QToolBar *BrowserWindow::createToolBar()
 {
     QToolBar *navigationBar = new QToolBar(tr("Navigation"));
-    navigationBar->setAllowedAreas(Qt::TopToolBarArea | Qt::BottomToolBarArea);
+    navigationBar->setMovable(false);
     navigationBar->toggleViewAction()->setEnabled(false);
 
     m_historyBackAction = new QAction(this);
@@ -328,6 +324,7 @@ QToolBar *BrowserWindow::createToolBar()
     m_historyBackAction->setShortcuts(backShortcuts);
     m_historyBackAction->setIconVisibleInMenu(false);
     m_historyBackAction->setIcon(QIcon(QStringLiteral(":go-previous.png")));
+    m_historyBackAction->setToolTip(tr("Go back in history"));
     connect(m_historyBackAction, &QAction::triggered, [this]() {
         m_tabWidget->triggerWebPageAction(QWebEnginePage::Back);
     });
@@ -345,6 +342,7 @@ QToolBar *BrowserWindow::createToolBar()
     m_historyForwardAction->setShortcuts(fwdShortcuts);
     m_historyForwardAction->setIconVisibleInMenu(false);
     m_historyForwardAction->setIcon(QIcon(QStringLiteral(":go-next.png")));
+    m_historyForwardAction->setToolTip(tr("Go forward in history"));
     connect(m_historyForwardAction, &QAction::triggered, [this]() {
         m_tabWidget->triggerWebPageAction(QWebEnginePage::Forward);
     });
@@ -355,22 +353,22 @@ QToolBar *BrowserWindow::createToolBar()
         m_tabWidget->triggerWebPageAction(QWebEnginePage::WebAction(m_stopReloadAction->data().toInt()));
     });
     navigationBar->addAction(m_stopReloadAction);
+
+    m_urlLineEdit = new QLineEdit(this);
+    m_favAction = new QAction(this);
+    m_urlLineEdit->addAction(m_favAction, QLineEdit::LeadingPosition);
+    m_urlLineEdit->setClearButtonEnabled(true);
     navigationBar->addWidget(m_urlLineEdit);
-    int size = m_urlLineEdit->sizeHint().height();
-    navigationBar->setIconSize(QSize(size, size));
-    return navigationBar;
-}
 
-void BrowserWindow::handleWebViewIconChanged(const QIcon &icon)
-{
-    m_urlLineEdit->setFavIcon(icon);
-}
+    auto downloadsAction = new QAction(this);
+    downloadsAction->setIcon(QIcon(QStringLiteral(":go-bottom.png")));
+    downloadsAction->setToolTip(tr("Show downloads"));
+    navigationBar->addAction(downloadsAction);
+    connect(downloadsAction, &QAction::triggered, [this]() {
+        m_browser->downloadManagerWidget().show();
+    });
 
-void BrowserWindow::handleWebViewUrlChanged(const QUrl &url)
-{
-    m_urlLineEdit->setUrl(url);
-    if (url.isEmpty())
-        m_urlLineEdit->setFocus();
+    return navigationBar;
 }
 
 void BrowserWindow::handleWebActionEnabledChanged(QWebEnginePage::WebAction action, bool enabled)
@@ -389,7 +387,7 @@ void BrowserWindow::handleWebActionEnabledChanged(QWebEnginePage::WebAction acti
         m_stopAction->setEnabled(enabled);
         break;
     default:
-        qWarning("Unhandled webActionChanged singal");
+        qWarning("Unhandled webActionChanged signal");
     }
 }
 
@@ -403,9 +401,7 @@ void BrowserWindow::handleWebViewTitleChanged(const QString &title)
 
 void BrowserWindow::handleNewWindowTriggered()
 {
-    BrowserWindow *window = new BrowserWindow();
-    Browser::instance().addWindow(window);
-    window->loadHomePage();
+    m_browser->createWindow();
 }
 
 void BrowserWindow::handleFileOpenTriggered()
@@ -414,7 +410,7 @@ void BrowserWindow::handleFileOpenTriggered()
                                                 tr("Web Resources (*.html *.htm *.svg *.png *.gif *.svgz);;All files (*.*)"));
     if (file.isEmpty())
         return;
-    loadPage(file);
+    currentTab()->setUrl(file);
 }
 
 void BrowserWindow::handleFindActionTriggered()
@@ -450,24 +446,6 @@ void BrowserWindow::closeEvent(QCloseEvent *event)
     deleteLater();
 }
 
-void BrowserWindow::loadHomePage()
-{
-    loadPage(QStringLiteral("http://www.qt.io"));
-}
-
-void BrowserWindow::loadPage(const QString &page)
-{
-    loadPage(QUrl::fromUserInput(page));
-}
-
-void BrowserWindow::loadPage(const QUrl &url)
-{
-    if (url.isValid()) {
-        m_urlLineEdit->setUrl(url);
-        m_tabWidget->setUrl(url);
-    }
-}
-
 TabWidget *BrowserWindow::tabWidget() const
 {
     return m_tabWidget;
@@ -483,23 +461,24 @@ void BrowserWindow::handleWebViewLoadProgress(int progress)
     static QIcon stopIcon(QStringLiteral(":process-stop.png"));
     static QIcon reloadIcon(QStringLiteral(":view-refresh.png"));
 
-    if (progress < 100 && progress > 0) {
+    if (0 < progress && progress < 100) {
         m_stopReloadAction->setData(QWebEnginePage::Stop);
         m_stopReloadAction->setIcon(stopIcon);
         m_stopReloadAction->setToolTip(tr("Stop loading the current page"));
+        m_progressBar->setValue(progress);
     } else {
         m_stopReloadAction->setData(QWebEnginePage::Reload);
         m_stopReloadAction->setIcon(reloadIcon);
         m_stopReloadAction->setToolTip(tr("Reload the current page"));
+        m_progressBar->setValue(0);
     }
-    m_progressBar->setValue(progress < 100 ? progress : 0);
 }
 
 void BrowserWindow::handleShowWindowTriggered()
 {
     if (QAction *action = qobject_cast<QAction*>(sender())) {
         int offset = action->data().toInt();
-        QVector<BrowserWindow*> windows = Browser::instance().windows();
+        QVector<BrowserWindow*> windows = m_browser->windows();
         windows.at(offset)->activateWindow();
         windows.at(offset)->currentTab()->setFocus();
     }
diff --git a/examples/webenginewidgets/simplebrowser/browserwindow.h b/examples/webenginewidgets/simplebrowser/browserwindow.h
index 03c8d385b23390def655589098603a4ead1d6d32..745061691e3cce5bec93a15037529d46fb2e4d57 100644
--- a/examples/webenginewidgets/simplebrowser/browserwindow.h
+++ b/examples/webenginewidgets/simplebrowser/browserwindow.h
@@ -42,14 +42,16 @@
 #define BROWSERWINDOW_H
 
 #include <QMainWindow>
+#include <QTime>
 #include <QWebEnginePage>
 
 QT_BEGIN_NAMESPACE
+class QLineEdit;
 class QProgressBar;
 QT_END_NAMESPACE
 
+class Browser;
 class TabWidget;
-class UrlLineEdit;
 class WebView;
 
 class BrowserWindow : public QMainWindow
@@ -57,15 +59,11 @@ class BrowserWindow : public QMainWindow
     Q_OBJECT
 
 public:
-    BrowserWindow(QWidget *parent = nullptr, Qt::WindowFlags flags = 0);
-    ~BrowserWindow();
+    BrowserWindow(Browser *browser);
     QSize sizeHint() const override;
     TabWidget *tabWidget() const;
     WebView *currentTab() const;
-
-    void loadPage(const QString &url);
-    void loadPage(const QUrl &url);
-    void loadHomePage();
+    Browser *browser() { return m_browser; }
 
 protected:
     void closeEvent(QCloseEvent *event) override;
@@ -77,8 +75,6 @@ private slots:
     void handleShowWindowTriggered();
     void handleWebViewLoadProgress(int);
     void handleWebViewTitleChanged(const QString &title);
-    void handleWebViewUrlChanged(const QUrl &url);
-    void handleWebViewIconChanged(const QIcon &icon);
     void handleWebActionEnabledChanged(QWebEnginePage::WebAction action, bool enabled);
 
 private:
@@ -90,6 +86,7 @@ private:
     QToolBar *createToolBar();
 
 private:
+    Browser *m_browser;
     TabWidget *m_tabWidget;
     QProgressBar *m_progressBar;
     QAction *m_historyBackAction;
@@ -97,7 +94,8 @@ private:
     QAction *m_stopAction;
     QAction *m_reloadAction;
     QAction *m_stopReloadAction;
-    UrlLineEdit *m_urlLineEdit;
+    QLineEdit *m_urlLineEdit;
+    QAction *m_favAction;
     QString m_lastSearch;
 };
 
diff --git a/examples/webenginewidgets/simplebrowser/data/AppLogoColor.png b/examples/webenginewidgets/simplebrowser/data/AppLogoColor.png
new file mode 100644
index 0000000000000000000000000000000000000000..2a49717828ba3977b2b49eb13a690ce1777ab6c0
Binary files /dev/null and b/examples/webenginewidgets/simplebrowser/data/AppLogoColor.png differ
diff --git a/examples/webenginewidgets/simplebrowser/data/addtab.png b/examples/webenginewidgets/simplebrowser/data/addtab.png
deleted file mode 100644
index 20928fb402aab20c838fca4dae2e9c1db2c54373..0000000000000000000000000000000000000000
Binary files a/examples/webenginewidgets/simplebrowser/data/addtab.png and /dev/null differ
diff --git a/examples/webenginewidgets/simplebrowser/data/closetab.png b/examples/webenginewidgets/simplebrowser/data/closetab.png
deleted file mode 100644
index ab9d669eeebed9718363bd06ba84fdfd9e7cd6b5..0000000000000000000000000000000000000000
Binary files a/examples/webenginewidgets/simplebrowser/data/closetab.png and /dev/null differ
diff --git a/examples/webenginewidgets/simplebrowser/data/defaulticon.png b/examples/webenginewidgets/simplebrowser/data/defaulticon.png
deleted file mode 100644
index 01a0920c93c67e94ee3c9b8317fd6dd1437e8e4d..0000000000000000000000000000000000000000
Binary files a/examples/webenginewidgets/simplebrowser/data/defaulticon.png and /dev/null differ
diff --git a/examples/webenginewidgets/simplebrowser/data/dialog-error.png b/examples/webenginewidgets/simplebrowser/data/dialog-error.png
new file mode 100644
index 0000000000000000000000000000000000000000..cdd95bade1d2fc496e067d2a78e4b1cf76624e03
Binary files /dev/null and b/examples/webenginewidgets/simplebrowser/data/dialog-error.png differ
diff --git a/examples/webenginewidgets/simplebrowser/data/edit-clear.png b/examples/webenginewidgets/simplebrowser/data/edit-clear.png
new file mode 100644
index 0000000000000000000000000000000000000000..5542948bca68a69ee870e7a52d03116319dde91d
Binary files /dev/null and b/examples/webenginewidgets/simplebrowser/data/edit-clear.png differ
diff --git a/examples/webenginewidgets/simplebrowser/data/go-bottom.png b/examples/webenginewidgets/simplebrowser/data/go-bottom.png
new file mode 100644
index 0000000000000000000000000000000000000000..bf973fedc2ceafa07c68be16aa3e9b20cfb71df6
Binary files /dev/null and b/examples/webenginewidgets/simplebrowser/data/go-bottom.png differ
diff --git a/examples/webenginewidgets/simplebrowser/data/go-next.png b/examples/webenginewidgets/simplebrowser/data/go-next.png
index 6f3f65d33d303315f0d8d9dd03c7e7e2427d4950..a68e2db77531cb15a2cddd62f567f030513b60fa 100644
Binary files a/examples/webenginewidgets/simplebrowser/data/go-next.png and b/examples/webenginewidgets/simplebrowser/data/go-next.png differ
diff --git a/examples/webenginewidgets/simplebrowser/data/go-previous.png b/examples/webenginewidgets/simplebrowser/data/go-previous.png
index 93be3d1ee6b90843d7df0f517733f63ce72f4611..c37bc0414c24b6e4f34096d0c0f20fbe0bf84045 100644
Binary files a/examples/webenginewidgets/simplebrowser/data/go-previous.png and b/examples/webenginewidgets/simplebrowser/data/go-previous.png differ
diff --git a/examples/webenginewidgets/simplebrowser/data/process-stop.png b/examples/webenginewidgets/simplebrowser/data/process-stop.png
index b68290bf1ebf568d8ab080a4e3ec7d75048ec461..e7a8d1722f328be5fa649f774e2fa6bcf049ebef 100644
Binary files a/examples/webenginewidgets/simplebrowser/data/process-stop.png and b/examples/webenginewidgets/simplebrowser/data/process-stop.png differ
diff --git a/examples/webenginewidgets/simplebrowser/data/simplebrowser.qrc b/examples/webenginewidgets/simplebrowser/data/simplebrowser.qrc
index 5795063ca9114c9848ef51edffb710aa90847164..ec8716721cc8d9d35a2297287cc21fd240e68e4c 100644
--- a/examples/webenginewidgets/simplebrowser/data/simplebrowser.qrc
+++ b/examples/webenginewidgets/simplebrowser/data/simplebrowser.qrc
@@ -1,12 +1,13 @@
 <RCC>
     <qresource prefix="/">
-        <file>addtab.png</file>
-        <file>defaulticon.png</file>
-        <file>closetab.png</file>
+        <file>AppLogoColor.png</file>
+        <file>dialog-error.png</file>
+        <file>edit-clear.png</file>
+        <file>go-bottom.png</file>
         <file>go-next.png</file>
         <file>go-previous.png</file>
         <file>process-stop.png</file>
-        <file>simplebrowser.svg</file>
+        <file>text-html.png</file>
         <file>view-refresh.png</file>
     </qresource>
 </RCC>
diff --git a/examples/webenginewidgets/simplebrowser/data/simplebrowser.svg b/examples/webenginewidgets/simplebrowser/data/simplebrowser.svg
deleted file mode 100644
index 9f39deb66dd6a2c97bd6e94eab55b1621082f60f..0000000000000000000000000000000000000000
--- a/examples/webenginewidgets/simplebrowser/data/simplebrowser.svg
+++ /dev/null
@@ -1,24 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Generator: Adobe Illustrator 19.2.0, SVG Export Plug-In . SVG Version: 6.00 Build 0)  -->
-<svg version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
-	 width="94px" height="94px" viewBox="0 0 94 94" enable-background="new 0 0 94 94" xml:space="preserve">
-<g>
-	<circle fill="none" cx="47" cy="47" r="47"/>
-	<g>
-		<path fill="#46A2DA" d="M47,92.979c-11.779,0-23.559-4.484-32.526-13.451C-3.461,61.591-3.461,32.409,14.472,14.474
-			C32.41-3.463,61.592-3.461,79.526,14.473c17.935,17.936,17.935,47.119,0.002,65.054l-0.002,0.001
-			C70.559,88.495,58.779,92.979,47,92.979z"/>
-	</g>
-	<path fill="#80C342" d="M93,47C93,21.595,72.405,1,47,1C34.297,1,22.797,6.149,14.473,14.473l65.054,65.054
-		C87.851,71.203,93,59.703,93,47z"/>
-	<g>
-		<path fill="#46A2DA" d="M47,65c-4.808,0-9.328-1.873-12.728-5.272c-7.018-7.019-7.018-18.438,0-25.456
-			C37.672,30.873,42.192,29,47,29s9.328,1.873,12.728,5.272c7.018,7.019,7.018,18.438,0,25.456C56.328,63.127,51.808,65,47,65z"/>
-		<path fill="#FFFFFF" d="M62.248,59.919c6.671-7.858,6.312-19.644-1.105-27.061C57.237,28.953,52.118,27,47,27
-			c-5.118,0-10.237,1.953-14.142,5.858c-7.81,7.81-7.81,20.474,0,28.284C36.763,65.047,41.882,67,47,67
-			c4.379,0,8.752-1.441,12.372-4.3L77.88,81.209c0.989-0.895,1.935-1.837,2.843-2.814L62.248,59.919z M35.686,58.314
-			c-6.238-6.238-6.238-16.389,0-22.627C38.708,32.664,42.726,31,47,31c4.274,0,8.292,1.664,11.314,4.686
-			c6.238,6.238,6.238,16.389,0,22.627C55.292,61.336,51.274,63,47,63C42.726,63,38.708,61.336,35.686,58.314z"/>
-	</g>
-</g>
-</svg>
diff --git a/examples/webenginewidgets/simplebrowser/data/text-html.png b/examples/webenginewidgets/simplebrowser/data/text-html.png
new file mode 100644
index 0000000000000000000000000000000000000000..a896697d78043cf2ed044a1a6cdcae86e736cca3
Binary files /dev/null and b/examples/webenginewidgets/simplebrowser/data/text-html.png differ
diff --git a/examples/webenginewidgets/simplebrowser/data/view-refresh.png b/examples/webenginewidgets/simplebrowser/data/view-refresh.png
index cab4d02c756502f922bbff34df34c0056406bd96..606ea9eba46b82eea04678e64369b97e595f9da5 100644
Binary files a/examples/webenginewidgets/simplebrowser/data/view-refresh.png and b/examples/webenginewidgets/simplebrowser/data/view-refresh.png differ
diff --git a/examples/webenginewidgets/simplebrowser/doc/images/simplebrowser.png b/examples/webenginewidgets/simplebrowser/doc/images/simplebrowser.png
index 7773090750279f739eb6309283eafcc20e1e9141..b09f7c853959ff0ec5900170bb77ca16c48b375c 100644
Binary files a/examples/webenginewidgets/simplebrowser/doc/images/simplebrowser.png and b/examples/webenginewidgets/simplebrowser/doc/images/simplebrowser.png differ
diff --git a/examples/webenginewidgets/simplebrowser/doc/src/simplebrowser.qdoc b/examples/webenginewidgets/simplebrowser/doc/src/simplebrowser.qdoc
index e57ec80ece8b9ba47597f2234d719547d54a738b..6736f85703929c62138d992feb4002a9af85201f 100644
--- a/examples/webenginewidgets/simplebrowser/doc/src/simplebrowser.qdoc
+++ b/examples/webenginewidgets/simplebrowser/doc/src/simplebrowser.qdoc
@@ -43,6 +43,7 @@
             forward in the web page browsing history.
         \li Multi-tab area for displaying web content within tabs.
         \li Status bar for displaying hovered links.
+        \li A simple download manager.
     \endlist
 
     The web content can be opened in new tabs or separate windows. HTTP and
@@ -52,13 +53,13 @@
 
     \section1 Class Hierarchy
 
-    We start with sketching a diagram of the classes that we are going to
+    We start with sketching a diagram of the main classes that we are going to
     implement:
 
     \image simplebrowser-model.png
 
     \list
-        \li \c{Browser} is a singleton class managing the application windows.
+        \li \c{Browser} is a class managing the application windows.
         \li \c{BrowserWindow} is a \l QMainWindow showing the menu, a navigation
             bar, \c {TabWidget}, and a status bar.
         \li \c{TabWidget} is a \l QTabWidget and contains one or multiple
@@ -68,11 +69,19 @@
         \li \c{WebPage} is a \l QWebEnginePage that represents website content.
     \endlist
 
+    Additionally, we will implement some auxiliary classes:
+
+    \list
+        \li \c{WebPopupWindow} is a \l QWidget for showing popup windows.
+        \li \c{DownloadManagerWidget} is a \l QWidget implementing the downloads
+        list.
+    \endlist
+
     \section1 Creating the Browser Main Window
 
-    This example supports multiple main windows that are owned by a
-    \c Browser singleton object. This class could also be used for further
-    functionality, such as downloading files, bookmarks, and history managers.
+    This example supports multiple main windows that are owned by a \c Browser
+    object. This class also owns the \c DownloadManagerWidget and could be used
+    for further functionality, such as bookmarks and history managers.
 
     In \c main.cpp, we create the first \c BrowserWindow instance and add it
     to the \c Browser object. If no arguments are passed on the command line,
@@ -104,6 +113,8 @@
     \quotefromfile webenginewidgets/simplebrowser/tabwidget.cpp
     \skipto TabWidget::createTab(
     \printuntil }
+    \skipto TabWidget::createBackgroundTab(
+    \printuntil }
 
     In \c TabWidget::setupView(), we make sure that the \c TabWidget always forwards
     the signals of the currently selected \c WebView:
@@ -225,20 +236,14 @@
 
     \section1 Opening a Web Page
 
-    This section describes the workflow for opening a new page.
-    When the user enters a URL in the navigation bar and presses \uicontrol Enter,
-    \c QLineEdit::returnPressed is emitted, which lets \c BrowserWindow
-    load the requested page:
+    This section describes the workflow for opening a new page. When the user
+    enters a URL in the navigation bar and presses \uicontrol Enter, the \c
+    QLineEdit::returnPressed signal is emitted and the new URL is then handed
+    over to \c TabWidget::setUrl:
 
     \quotefromfile webenginewidgets/simplebrowser/browserwindow.cpp
     \skipto connect(m_urlLineEdit
-    \printuntil });
-
-    The \c loadPage() method calls the \c setUrl() method of \c TabWidget:
-
-    \skipto void BrowserWindow::loadPage(const QUrl
-    \printuntil }
-    \printline }
+    \printline connect
 
     The call is forwarded to the currently selected tab:
 
@@ -249,4 +254,36 @@
 
     The \c setUrl() method of \c WebView just forwards the \c url to the associated \c WebPage,
     which in turn starts the downloading of the page's content in the background.
+
+    \section1 Managing Downloads
+
+    Downloads are associated with a \l QWebEngineProfile. Whenever a download is
+    triggered on a web page the \l QWebEngineProfile::defaultProfile signal is
+    emitted with a \l QWebEngineDownloadItem, which in this example is forwarded
+    to \c DownloadManagerWidget::downloadRequested:
+
+    \quotefromfile webenginewidgets/simplebrowser/browser.cpp
+    \skipto Browser::Browser
+    \printuntil /^\}/
+
+    This method prompts the user for a file name (with a pre-filled suggestion)
+    and starts the download (unless the user cancels the \uicontrol {Save As}
+    dialog):
+
+    \quotefromfile webenginewidgets/simplebrowser/downloadmanagerwidget.cpp
+    \skipto DownloadManagerWidget::downloadRequested
+    \printuntil /^\}/
+
+    The \l QWebEngineDownloadItem object will periodically emit the \l
+    {QWebEngineDownloadItem::}{downloadProgress} signal to notify potential
+    observers of the download progress and the \l
+    {QWebEngineDownloadItem::}{stateChanged} signal when the download is
+    finished or when an error occurs. See \c downloadmanagerwidget.cpp for an
+    example of how these signals can be handled.
+
+    \section1 Licensing
+
+    All icons used in the example, with the exception of \c{AppLogoColor.png},
+    originate from the public domain
+    \l{http://tango.freedesktop.org/Tango_Icon_Library}{Tango Icon Library}.
 */
diff --git a/examples/webenginewidgets/simplebrowser/downloadmanagerwidget.cpp b/examples/webenginewidgets/simplebrowser/downloadmanagerwidget.cpp
new file mode 100644
index 0000000000000000000000000000000000000000..5f32294e80d6a6127f2291d342b94b0cfe4af2ef
--- /dev/null
+++ b/examples/webenginewidgets/simplebrowser/downloadmanagerwidget.cpp
@@ -0,0 +1,86 @@
+/****************************************************************************
+**
+** Copyright (C) 2017 The Qt Company Ltd.
+** Contact: https://www.qt.io/licensing/
+**
+** This file is part of the examples of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+**   * Redistributions of source code must retain the above copyright
+**     notice, this list of conditions and the following disclaimer.
+**   * Redistributions in binary form must reproduce the above copyright
+**     notice, this list of conditions and the following disclaimer in
+**     the documentation and/or other materials provided with the
+**     distribution.
+**   * Neither the name of The Qt Company Ltd nor the names of its
+**     contributors may be used to endorse or promote products derived
+**     from this software without specific prior written permission.
+**
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "downloadmanagerwidget.h"
+
+#include "browser.h"
+#include "browserwindow.h"
+#include "downloadwidget.h"
+
+#include <QFileDialog>
+#include <QWebEngineDownloadItem>
+
+DownloadManagerWidget::DownloadManagerWidget(QWidget *parent)
+    : QWidget(parent)
+    , m_numDownloads(0)
+{
+    setupUi(this);
+}
+
+void DownloadManagerWidget::downloadRequested(QWebEngineDownloadItem *download)
+{
+    Q_ASSERT(download && download->state() == QWebEngineDownloadItem::DownloadRequested);
+
+    QString path = QFileDialog::getSaveFileName(this, tr("Save as"), download->path());
+    if (path.isEmpty())
+        return;
+
+    download->setPath(path);
+    download->accept();
+    add(new DownloadWidget(download));
+
+    show();
+}
+
+void DownloadManagerWidget::add(DownloadWidget *downloadWidget)
+{
+    connect(downloadWidget, &DownloadWidget::removeClicked, this, &DownloadManagerWidget::remove);
+    m_itemsLayout->insertWidget(0, downloadWidget, 0, Qt::AlignTop);
+    if (m_numDownloads++ == 0)
+        m_zeroItemsLabel->hide();
+}
+
+void DownloadManagerWidget::remove(DownloadWidget *downloadWidget)
+{
+    m_itemsLayout->removeWidget(downloadWidget);
+    downloadWidget->deleteLater();
+    if (--m_numDownloads == 0)
+        m_zeroItemsLabel->show();
+}
diff --git a/examples/webenginewidgets/simplebrowser/urllineedit.h b/examples/webenginewidgets/simplebrowser/downloadmanagerwidget.h
similarity index 69%
rename from examples/webenginewidgets/simplebrowser/urllineedit.h
rename to examples/webenginewidgets/simplebrowser/downloadmanagerwidget.h
index a01eb0e66f3ad37654477999dd759306d129bebd..597e6139a54771da82903c5469a0fffa86b25732 100644
--- a/examples/webenginewidgets/simplebrowser/urllineedit.h
+++ b/examples/webenginewidgets/simplebrowser/downloadmanagerwidget.h
@@ -1,7 +1,7 @@
 /****************************************************************************
 **
-** Copyright (C) 2016 The Qt Company Ltd.
-** Contact: http://www.qt.io/licensing/
+** Copyright (C) 2017 The Qt Company Ltd.
+** Contact: https://www.qt.io/licensing/
 **
 ** This file is part of the examples of the Qt Toolkit.
 **
@@ -38,33 +38,36 @@
 **
 ****************************************************************************/
 
-#ifndef URLLINEEDIT_H
-#define URLLINEEDIT_H
+#ifndef DOWNLOADMANAGERWIDGET_H
+#define DOWNLOADMANAGERWIDGET_H
 
-#include <QLineEdit>
+#include "ui_downloadmanagerwidget.h"
+
+#include <QWidget>
 
 QT_BEGIN_NAMESPACE
-class QToolButton;
+class QWebEngineDownloadItem;
 QT_END_NAMESPACE
 
-class UrlLineEdit : public QLineEdit
+class DownloadWidget;
+
+// Displays a list of downloads.
+class DownloadManagerWidget final : public QWidget, public Ui::DownloadManagerWidget
 {
     Q_OBJECT
-
 public:
-    UrlLineEdit(QWidget *parent = nullptr);
+    explicit DownloadManagerWidget(QWidget *parent = nullptr);
 
-public:
-    QUrl url() const;
-    void setUrl(const QUrl &url);
-    void setFavIcon(const QIcon &icon);
-
-protected:
-    void resizeEvent(QResizeEvent *event) override;
+    // Prompts user with a "Save As" dialog. If the user doesn't cancel it, then
+    // the QWebEngineDownloadItem will be accepted and the DownloadManagerWidget
+    // will be shown on the screen.
+    void downloadRequested(QWebEngineDownloadItem *webItem);
 
 private:
-    QToolButton *m_favButton;
-    QToolButton *m_clearButton;
+    void add(DownloadWidget *downloadWidget);
+    void remove(DownloadWidget *downloadWidget);
+
+    int m_numDownloads;
 };
 
-#endif // URLLINEEDIT_H
+#endif // DOWNLOADMANAGERWIDGET_H
diff --git a/examples/webenginewidgets/simplebrowser/downloadmanagerwidget.ui b/examples/webenginewidgets/simplebrowser/downloadmanagerwidget.ui
new file mode 100644
index 0000000000000000000000000000000000000000..b7544ac16ce20fe14fd9b1f124d01b86bee73ca6
--- /dev/null
+++ b/examples/webenginewidgets/simplebrowser/downloadmanagerwidget.ui
@@ -0,0 +1,104 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<ui version="4.0">
+ <class>DownloadManagerWidget</class>
+ <widget class="QWidget" name="DownloadManagerWidget">
+  <property name="geometry">
+   <rect>
+    <x>0</x>
+    <y>0</y>
+    <width>400</width>
+    <height>212</height>
+   </rect>
+  </property>
+  <property name="windowTitle">
+   <string>Downloads</string>
+  </property>
+  <property name="styleSheet">
+   <string notr="true">#DownloadManagerWidget {
+    background: palette(button)
+}</string>
+  </property>
+  <layout class="QVBoxLayout" name="m_topLevelLayout">
+   <property name="sizeConstraint">
+    <enum>QLayout::SetNoConstraint</enum>
+   </property>
+   <property name="leftMargin">
+    <number>0</number>
+   </property>
+   <property name="topMargin">
+    <number>0</number>
+   </property>
+   <property name="rightMargin">
+    <number>0</number>
+   </property>
+   <property name="bottomMargin">
+    <number>0</number>
+   </property>
+   <item>
+    <widget class="QScrollArea" name="m_scrollArea">
+     <property name="styleSheet">
+      <string notr="true">#m_scrollArea {
+  margin: 2px;
+  border: none;
+}</string>
+     </property>
+     <property name="verticalScrollBarPolicy">
+      <enum>Qt::ScrollBarAlwaysOn</enum>
+     </property>
+     <property name="horizontalScrollBarPolicy">
+      <enum>Qt::ScrollBarAlwaysOff</enum>
+     </property>
+     <property name="widgetResizable">
+      <bool>true</bool>
+     </property>
+     <property name="alignment">
+      <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set>
+     </property>
+     <widget class="QWidget" name="m_items">
+      <property name="styleSheet">
+       <string notr="true">#m_items {background: palette(mid)}</string>
+      </property>
+      <layout class="QVBoxLayout" name="m_itemsLayout">
+       <property name="spacing">
+        <number>2</number>
+       </property>
+       <property name="leftMargin">
+        <number>3</number>
+       </property>
+       <property name="topMargin">
+        <number>3</number>
+       </property>
+       <property name="rightMargin">
+        <number>3</number>
+       </property>
+       <property name="bottomMargin">
+        <number>3</number>
+       </property>
+       <item>
+        <widget class="QLabel" name="m_zeroItemsLabel">
+         <property name="sizePolicy">
+          <sizepolicy hsizetype="Expanding" vsizetype="Expanding">
+           <horstretch>0</horstretch>
+           <verstretch>0</verstretch>
+          </sizepolicy>
+         </property>
+         <property name="styleSheet">
+          <string notr="true">color: palette(shadow)</string>
+         </property>
+         <property name="text">
+          <string>No downloads</string>
+         </property>
+         <property name="alignment">
+          <set>Qt::AlignCenter</set>
+         </property>
+        </widget>
+       </item>
+      </layout>
+     </widget>
+    </widget>
+   </item>
+  </layout>
+ </widget>
+ <resources/>
+ <connections/>
+</ui>
diff --git a/examples/webenginewidgets/simplebrowser/downloadwidget.cpp b/examples/webenginewidgets/simplebrowser/downloadwidget.cpp
new file mode 100644
index 0000000000000000000000000000000000000000..a80366f77d887dcbca2111bcdf6579b5058f7552
--- /dev/null
+++ b/examples/webenginewidgets/simplebrowser/downloadwidget.cpp
@@ -0,0 +1,152 @@
+/****************************************************************************
+**
+** Copyright (C) 2017 The Qt Company Ltd.
+** Contact: https://www.qt.io/licensing/
+**
+** This file is part of the examples of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+**   * Redistributions of source code must retain the above copyright
+**     notice, this list of conditions and the following disclaimer.
+**   * Redistributions in binary form must reproduce the above copyright
+**     notice, this list of conditions and the following disclaimer in
+**     the documentation and/or other materials provided with the
+**     distribution.
+**   * Neither the name of The Qt Company Ltd nor the names of its
+**     contributors may be used to endorse or promote products derived
+**     from this software without specific prior written permission.
+**
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "downloadwidget.h"
+
+#include <QFileInfo>
+#include <QUrl>
+#include <QWebEngineDownloadItem>
+
+DownloadWidget::DownloadWidget(QWebEngineDownloadItem *download, QWidget *parent)
+    : QFrame(parent)
+    , m_download(download)
+    , m_timeAdded(QTime::currentTime())
+{
+    setupUi(this);
+    m_dstName->setText(QFileInfo(m_download->path()).fileName());
+    m_srcUrl->setText(m_download->url().toDisplayString());
+
+    connect(m_cancelButton, &QPushButton::clicked,
+            [this](bool) {
+        if (m_download->state() == QWebEngineDownloadItem::DownloadInProgress)
+            m_download->cancel();
+        else
+            emit removeClicked(this);
+    });
+
+    connect(m_download, &QWebEngineDownloadItem::downloadProgress,
+            [this](qint64, qint64) {
+        updateWidget();
+    });
+
+    connect(m_download, &QWebEngineDownloadItem::stateChanged,
+            [this](QWebEngineDownloadItem::DownloadState) {
+        updateWidget();
+    });
+
+    updateWidget();
+}
+
+inline QString DownloadWidget::withUnit(qreal bytes)
+{
+    if (bytes < (1 << 10))
+        return tr("%L1 B").arg(bytes);
+    else if (bytes < (1 << 20))
+        return tr("%L1 KiB").arg(bytes / (1 << 10), 0, 'f', 2);
+    else if (bytes < (1 << 30))
+        return tr("%L1 MiB").arg(bytes / (1 << 20), 0, 'f', 2);
+    else
+        return tr("%L1 GiB").arg(bytes / (1 << 30), 0, 'f', 2);
+}
+
+void DownloadWidget::updateWidget()
+{
+    qreal totalBytes = m_download->totalBytes();
+    qreal receivedBytes = m_download->receivedBytes();
+    qreal bytesPerSecond = receivedBytes / m_timeAdded.elapsed() * 1000;
+
+    auto state = m_download->state();
+    switch (state) {
+    case QWebEngineDownloadItem::DownloadRequested:
+        Q_UNREACHABLE();
+        break;
+    case QWebEngineDownloadItem::DownloadInProgress:
+        if (totalBytes >= 0) {
+            m_progressBar->setValue(qRound(100 * receivedBytes / totalBytes));
+            m_progressBar->setDisabled(false);
+            m_progressBar->setFormat(
+                tr("%p% - %1 of %2 downloaded - %3/s")
+                .arg(withUnit(receivedBytes))
+                .arg(withUnit(totalBytes))
+                .arg(withUnit(bytesPerSecond)));
+        } else {
+            m_progressBar->setValue(0);
+            m_progressBar->setDisabled(false);
+            m_progressBar->setFormat(
+                tr("unknown size - %1 downloaded - %2/s")
+                .arg(withUnit(receivedBytes))
+                .arg(withUnit(bytesPerSecond)));
+        }
+        break;
+    case QWebEngineDownloadItem::DownloadCompleted:
+        m_progressBar->setValue(100);
+        m_progressBar->setDisabled(true);
+        m_progressBar->setFormat(
+            tr("completed - %1 downloaded - %2/s")
+            .arg(withUnit(receivedBytes))
+            .arg(withUnit(bytesPerSecond)));
+        break;
+    case QWebEngineDownloadItem::DownloadCancelled:
+        m_progressBar->setValue(0);
+        m_progressBar->setDisabled(true);
+        m_progressBar->setFormat(
+            tr("cancelled - %1 downloaded - %2/s")
+            .arg(withUnit(receivedBytes))
+            .arg(withUnit(bytesPerSecond)));
+        break;
+    case QWebEngineDownloadItem::DownloadInterrupted:
+        m_progressBar->setValue(0);
+        m_progressBar->setDisabled(true);
+        m_progressBar->setFormat(
+            tr("interrupted: %1")
+            .arg(m_download->interruptReasonString()));
+        break;
+    }
+
+    if (state == QWebEngineDownloadItem::DownloadInProgress) {
+        static QIcon cancelIcon(QStringLiteral(":process-stop.png"));
+        m_cancelButton->setIcon(cancelIcon);
+        m_cancelButton->setToolTip(tr("Stop downloading"));
+    } else {
+        static QIcon removeIcon(QStringLiteral(":edit-clear.png"));
+        m_cancelButton->setIcon(removeIcon);
+        m_cancelButton->setToolTip(tr("Remove from list"));
+    }
+}
diff --git a/examples/webenginewidgets/simplebrowser/downloadwidget.h b/examples/webenginewidgets/simplebrowser/downloadwidget.h
new file mode 100644
index 0000000000000000000000000000000000000000..e8cf4282520af3798cb801f1c8e8c518e0c0fec3
--- /dev/null
+++ b/examples/webenginewidgets/simplebrowser/downloadwidget.h
@@ -0,0 +1,74 @@
+/****************************************************************************
+**
+** Copyright (C) 2017 The Qt Company Ltd.
+** Contact: https://www.qt.io/licensing/
+**
+** This file is part of the examples of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+**   * Redistributions of source code must retain the above copyright
+**     notice, this list of conditions and the following disclaimer.
+**   * Redistributions in binary form must reproduce the above copyright
+**     notice, this list of conditions and the following disclaimer in
+**     the documentation and/or other materials provided with the
+**     distribution.
+**   * Neither the name of The Qt Company Ltd nor the names of its
+**     contributors may be used to endorse or promote products derived
+**     from this software without specific prior written permission.
+**
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef DOWNLOADWIDGET_H
+#define DOWNLOADWIDGET_H
+
+#include "ui_downloadwidget.h"
+
+#include <QFrame>
+#include <QTime>
+
+QT_BEGIN_NAMESPACE
+class QWebEngineDownloadItem;
+QT_END_NAMESPACE
+
+// Displays one ongoing or finished download (QWebEngineDownloadItem).
+class DownloadWidget final : public QFrame, public Ui::DownloadWidget
+{
+    Q_OBJECT
+public:
+    // Precondition: The QWebEngineDownloadItem has been accepted.
+    explicit DownloadWidget(QWebEngineDownloadItem *download, QWidget *parent = nullptr);
+
+signals:
+    // This signal is emitted when the user indicates that they want to remove
+    // this download from the downloads list.
+    void removeClicked(DownloadWidget *self);
+
+private:
+    void updateWidget();
+    QString withUnit(qreal bytes);
+
+    QWebEngineDownloadItem *m_download;
+    QTime m_timeAdded;
+};
+
+#endif // DOWNLOADWIDGET_H
diff --git a/examples/webenginewidgets/simplebrowser/downloadwidget.ui b/examples/webenginewidgets/simplebrowser/downloadwidget.ui
new file mode 100644
index 0000000000000000000000000000000000000000..ee45e0b107690b6ef4be5dcbfa3d0d3667ea30c3
--- /dev/null
+++ b/examples/webenginewidgets/simplebrowser/downloadwidget.ui
@@ -0,0 +1,80 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<ui version="4.0">
+ <class>DownloadWidget</class>
+ <widget class="QFrame" name="DownloadWidget">
+  <property name="styleSheet">
+   <string notr="true">#DownloadWidget {
+  background: palette(button);
+  border: 1px solid palette(dark);
+  margin: 0px;
+}</string>
+  </property>
+  <layout class="QGridLayout" name="m_topLevelLayout">
+   <property name="sizeConstraint">
+    <enum>QLayout::SetMinAndMaxSize</enum>
+   </property>
+   <item row="0" column="0">
+    <widget class="QLabel" name="m_dstName">
+     <property name="styleSheet">
+      <string notr="true">font-weight: bold
+</string>
+     </property>
+     <property name="text">
+      <string>TextLabel</string>
+     </property>
+    </widget>
+   </item>
+   <item row="0" column="1">
+    <widget class="QPushButton" name="m_cancelButton">
+     <property name="sizePolicy">
+      <sizepolicy hsizetype="Fixed" vsizetype="Fixed"/>
+     </property>
+     <property name="styleSheet">
+      <string notr="true">QPushButton {
+  margin: 1px;
+  border: none;
+}
+QPushButton:pressed {
+  margin: none;
+  border: 1px solid palette(shadow);
+  background: palette(midlight);
+}</string>
+     </property>
+     <property name="flat">
+      <bool>false</bool>
+     </property>
+    </widget>
+   </item>
+   <item row="1" column="0" colspan="2">
+    <widget class="QLabel" name="m_srcUrl">
+     <property name="maximumSize">
+      <size>
+       <width>350</width>
+       <height>16777215</height>
+      </size>
+     </property>
+     <property name="styleSheet">
+      <string notr="true"/>
+     </property>
+     <property name="text">
+      <string>TextLabel</string>
+     </property>
+    </widget>
+   </item>
+   <item row="2" column="0" colspan="2">
+    <widget class="QProgressBar" name="m_progressBar">
+     <property name="styleSheet">
+      <string notr="true">font-size: 12px</string>
+     </property>
+     <property name="value">
+      <number>24</number>
+     </property>
+    </widget>
+   </item>
+  </layout>
+ </widget>
+ <resources>
+  <include location="data/simplebrowser.qrc"/>
+ </resources>
+ <connections/>
+</ui>
diff --git a/examples/webenginewidgets/simplebrowser/main.cpp b/examples/webenginewidgets/simplebrowser/main.cpp
index fa9f44c3494d64b11bff4c5bab5355af20a4e33d..93dfc8a8c48f75bdf15e8c4d542e484373714551 100644
--- a/examples/webenginewidgets/simplebrowser/main.cpp
+++ b/examples/webenginewidgets/simplebrowser/main.cpp
@@ -40,38 +40,35 @@
 
 #include "browser.h"
 #include "browserwindow.h"
+#include "webview.h"
 #include <QApplication>
 #include <QWebEngineSettings>
 
-QString getCommandLineUrlArgument()
+QUrl getCommandLineUrlArgument()
 {
     const QStringList args = QCoreApplication::arguments();
-    if (args.count() > 1) {
-        const QString lastArg = args.last();
-        const bool isValidUrl = QUrl::fromUserInput(lastArg).isValid();
-        if (isValidUrl)
-            return lastArg;
-    }
-    return QString();
+    if (args.count() > 1)
+        return QUrl::fromUserInput(args.last());
+    return QUrl();
 }
 
 int main(int argc, char **argv)
 {
     QCoreApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
+    QCoreApplication::setAttribute(Qt::AA_UseHighDpiPixmaps);
 
     QApplication app(argc, argv);
-    app.setWindowIcon(QIcon(QLatin1String(":simplebrowser.svg")));
+    app.setWindowIcon(QIcon(QStringLiteral(":AppLogoColor.png")));
 
     QWebEngineSettings::defaultSettings()->setAttribute(QWebEngineSettings::PluginsEnabled, true);
 
-    BrowserWindow *window = new BrowserWindow();
-    Browser::instance().addWindow(window);
+    QUrl url = getCommandLineUrlArgument();
+    if (!url.isValid())
+        url = QStringLiteral("https://www.qt.io");
 
-    const QString url = getCommandLineUrlArgument();
-    if (!url.isEmpty())
-        window->loadPage(url);
-    else
-        window->loadHomePage();
+    Browser browser;
+    BrowserWindow *window = browser.createWindow();
+    window->currentTab()->setUrl(url);
 
     return app.exec();
 }
diff --git a/examples/webenginewidgets/simplebrowser/simplebrowser.pro b/examples/webenginewidgets/simplebrowser/simplebrowser.pro
index 197d680916e1e35602b2e2531b297a2c725346d0..8120a28526968239dac241cfc606a9f232a37959 100644
--- a/examples/webenginewidgets/simplebrowser/simplebrowser.pro
+++ b/examples/webenginewidgets/simplebrowser/simplebrowser.pro
@@ -6,25 +6,29 @@ CONFIG += c++11
 HEADERS += \
     browser.h \
     browserwindow.h \
+    downloadmanagerwidget.h \
+    downloadwidget.h \
     tabwidget.h \
-    urllineedit.h \
-    webview.h \
     webpage.h \
-    webpopupwindow.h
+    webpopupwindow.h \
+    webview.h
 
 SOURCES += \
     browser.cpp \
     browserwindow.cpp \
+    downloadmanagerwidget.cpp \
+    downloadwidget.cpp \
     main.cpp \
     tabwidget.cpp \
-    urllineedit.cpp \
-    webview.cpp \
     webpage.cpp \
-    webpopupwindow.cpp
+    webpopupwindow.cpp \
+    webview.cpp
 
 FORMS += \
     certificateerrordialog.ui \
-    passworddialog.ui
+    passworddialog.ui \
+    downloadmanagerwidget.ui \
+    downloadwidget.ui
 
 RESOURCES += data/simplebrowser.qrc
 
diff --git a/examples/webenginewidgets/simplebrowser/tabwidget.cpp b/examples/webenginewidgets/simplebrowser/tabwidget.cpp
index a7f855c2ac38f1f015624d9e2446b2d2714b5d1c..c9fb32d833efb23785fe56d3a2de08d839b806fb 100644
--- a/examples/webenginewidgets/simplebrowser/tabwidget.cpp
+++ b/examples/webenginewidgets/simplebrowser/tabwidget.cpp
@@ -56,9 +56,8 @@ TabWidget::TabWidget(QWidget *parent)
     connect(tabBar, &QTabBar::customContextMenuRequested, this, &TabWidget::handleContextMenuRequested);
     connect(tabBar, &QTabBar::tabCloseRequested, this, &TabWidget::closeTab);
     connect(tabBar, &QTabBar::tabBarDoubleClicked, [this](int index) {
-        if (index != -1)
-            return;
-        createTab();
+        if (index == -1)
+            createTab();
     });
 
     setDocumentMode(true);
@@ -67,10 +66,6 @@ TabWidget::TabWidget(QWidget *parent)
     connect(this, &QTabWidget::currentChanged, this, &TabWidget::handleCurrentChanged);
 }
 
-TabWidget::~TabWidget()
-{
-}
-
 void TabWidget::handleCurrentChanged(int index)
 {
     if (index != -1) {
@@ -80,11 +75,7 @@ void TabWidget::handleCurrentChanged(int index)
         emit titleChanged(view->title());
         emit loadProgress(view->loadProgress());
         emit urlChanged(view->url());
-        QIcon pageIcon = view->page()->icon();
-        if (!pageIcon.isNull())
-            emit iconChanged(pageIcon);
-        else
-            emit iconChanged(QIcon(QStringLiteral(":defaulticon.png")));
+        emit favIconChanged(view->favIcon());
         emit webActionEnabledChanged(QWebEnginePage::Back, view->isWebActionEnabled(QWebEnginePage::Back));
         emit webActionEnabledChanged(QWebEnginePage::Forward, view->isWebActionEnabled(QWebEnginePage::Forward));
         emit webActionEnabledChanged(QWebEnginePage::Stop, view->isWebActionEnabled(QWebEnginePage::Stop));
@@ -93,7 +84,7 @@ void TabWidget::handleCurrentChanged(int index)
         emit titleChanged(QString());
         emit loadProgress(0);
         emit urlChanged(QUrl());
-        emit iconChanged(QIcon(QStringLiteral(":defaulticon.png")));
+        emit favIconChanged(QIcon());
         emit webActionEnabledChanged(QWebEnginePage::Back, false);
         emit webActionEnabledChanged(QWebEnginePage::Forward, false);
         emit webActionEnabledChanged(QWebEnginePage::Stop, false);
@@ -150,8 +141,10 @@ void TabWidget::setupView(WebView *webView)
 
     connect(webView, &QWebEngineView::titleChanged, [this, webView](const QString &title) {
         int index = indexOf(webView);
-        if (index != -1)
+        if (index != -1) {
             setTabText(index, title);
+            setTabToolTip(index, title);
+        }
         if (currentIndex() == index)
             emit titleChanged(title);
     });
@@ -170,26 +163,17 @@ void TabWidget::setupView(WebView *webView)
         if (currentIndex() == indexOf(webView))
             emit linkHovered(url);
     });
-    connect(webPage, &WebPage::iconChanged, [this, webView](const QIcon &icon) {
+    connect(webView, &WebView::favIconChanged, [this, webView](const QIcon &icon) {
         int index = indexOf(webView);
-        QIcon ico = icon.isNull() ? QIcon(QStringLiteral(":defaulticon.png")) : icon;
-
         if (index != -1)
-            setTabIcon(index, ico);
+            setTabIcon(index, icon);
         if (currentIndex() == index)
-            emit iconChanged(ico);
+            emit favIconChanged(icon);
     });
     connect(webView, &WebView::webActionEnabledChanged, [this, webView](QWebEnginePage::WebAction action, bool enabled) {
         if (currentIndex() ==  indexOf(webView))
             emit webActionEnabledChanged(action,enabled);
     });
-    connect(webView, &QWebEngineView::loadStarted, [this, webView]() {
-        int index = indexOf(webView);
-        if (index != -1) {
-            QIcon icon(QLatin1String(":view-refresh.png"));
-            setTabIcon(index, icon);
-        }
-    });
     connect(webPage, &QWebEnginePage::windowCloseRequested, [this, webView]() {
         int index = indexOf(webView);
         if (index >= 0)
@@ -197,15 +181,21 @@ void TabWidget::setupView(WebView *webView)
     });
 }
 
-WebView *TabWidget::createTab(bool makeCurrent)
+WebView *TabWidget::createTab()
+{
+    WebView *webView = createBackgroundTab();
+    setCurrentWidget(webView);
+    return webView;
+}
+
+WebView *TabWidget::createBackgroundTab()
 {
     WebView *webView = new WebView;
     WebPage *webPage = new WebPage(QWebEngineProfile::defaultProfile(), webView);
     webView->setPage(webPage);
     setupView(webView);
-    addTab(webView, tr("(Untitled)"));
-    if (makeCurrent)
-        setCurrentWidget(webView);
+    int index = addTab(webView, tr("(Untitled)"));
+    setTabIcon(index, webView->favIcon());
     return webView;
 }
 
@@ -239,7 +229,7 @@ void TabWidget::closeTab(int index)
 void TabWidget::cloneTab(int index)
 {
     if (WebView *view = webView(index)) {
-        WebView *tab = createTab(false);
+        WebView *tab = createTab();
         tab->setUrl(view->url());
     }
 }
diff --git a/examples/webenginewidgets/simplebrowser/tabwidget.h b/examples/webenginewidgets/simplebrowser/tabwidget.h
index 830effa4ea09215794bcc3be96c138b08031fb2f..e5a1671ae570cf44aa7692e35e51be02058d1251 100644
--- a/examples/webenginewidgets/simplebrowser/tabwidget.h
+++ b/examples/webenginewidgets/simplebrowser/tabwidget.h
@@ -56,7 +56,6 @@ class TabWidget : public QTabWidget
 
 public:
     TabWidget(QWidget *parent = nullptr);
-    ~TabWidget();
 
     WebView *currentWebView() const;
 
@@ -66,7 +65,7 @@ signals:
     void loadProgress(int progress);
     void titleChanged(const QString &title);
     void urlChanged(const QUrl &url);
-    void iconChanged(const QIcon &icon);
+    void favIconChanged(const QIcon &icon);
     void webActionEnabledChanged(QWebEnginePage::WebAction action, bool enabled);
 
 public slots:
@@ -74,7 +73,8 @@ public slots:
     void setUrl(const QUrl &url);
     void triggerWebPageAction(QWebEnginePage::WebAction action);
 
-    WebView *createTab(bool makeCurrent = true);
+    WebView *createTab();
+    WebView *createBackgroundTab();
     void closeTab(int index);
     void nextTab();
     void previousTab();
diff --git a/examples/webenginewidgets/simplebrowser/urllineedit.cpp b/examples/webenginewidgets/simplebrowser/urllineedit.cpp
deleted file mode 100644
index 7e67b635a91615eb36dc82edbb00150fa7a539ca..0000000000000000000000000000000000000000
--- a/examples/webenginewidgets/simplebrowser/urllineedit.cpp
+++ /dev/null
@@ -1,95 +0,0 @@
-/****************************************************************************
-**
-** Copyright (C) 2016 The Qt Company Ltd.
-** Contact: http://www.qt.io/licensing/
-**
-** This file is part of the examples of the Qt Toolkit.
-**
-** $QT_BEGIN_LICENSE:BSD$
-** You may use this file under the terms of the BSD license as follows:
-**
-** "Redistribution and use in source and binary forms, with or without
-** modification, are permitted provided that the following conditions are
-** met:
-**   * Redistributions of source code must retain the above copyright
-**     notice, this list of conditions and the following disclaimer.
-**   * Redistributions in binary form must reproduce the above copyright
-**     notice, this list of conditions and the following disclaimer in
-**     the documentation and/or other materials provided with the
-**     distribution.
-**   * Neither the name of The Qt Company Ltd nor the names of its
-**     contributors may be used to endorse or promote products derived
-**     from this software without specific prior written permission.
-**
-**
-** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
-** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
-** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
-** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
-** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
-** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
-** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
-** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
-** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
-** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
-**
-** $QT_END_LICENSE$
-**
-****************************************************************************/
-
-#include "urllineedit.h"
-#include <QToolButton>
-#include <QUrl>
-
-UrlLineEdit::UrlLineEdit(QWidget *parent)
-    : QLineEdit(parent)
-    , m_favButton(new QToolButton(this))
-    , m_clearButton(new QToolButton(this))
-{
-    m_clearButton->setIcon(QIcon(QStringLiteral(":closetab.png")));
-    m_clearButton->setVisible(false);
-    m_clearButton->setCursor(Qt::ArrowCursor);
-    QString style(QStringLiteral("QToolButton { border: none; padding: 1px; }"));
-    m_clearButton->setStyleSheet(style);
-    m_favButton->setStyleSheet(style);
-    setStyleSheet(QStringLiteral("QLineEdit { padding-left: %1px; padding-right: %2px;  } ")
-                  .arg(m_clearButton->sizeHint().width())
-                  .arg(m_favButton->sizeHint().width()));
-    int minIconHeight = qMax(m_favButton->sizeHint().height(), m_clearButton->sizeHint().height());
-    setMinimumSize(minimumSizeHint().width() +
-                   m_favButton->sizeHint().width() +
-                   m_clearButton->sizeHint().width(),
-                   qMax(minimumSizeHint().height(), minIconHeight));
-
-    connect(m_clearButton, &QToolButton::clicked, this, &QLineEdit::clear);
-    connect(this, &QLineEdit::textChanged, [this](const QString &text) {
-        m_clearButton->setVisible(!text.isEmpty() && !isReadOnly());
-    });
-}
-
-QUrl UrlLineEdit::url() const
-{
-    return QUrl::fromUserInput(text());
-}
-
-void UrlLineEdit::setUrl(const QUrl &url)
-{
-    setText(url.toString());
-    setCursorPosition(0);
-}
-
-void UrlLineEdit::setFavIcon(const QIcon &icon)
-{
-    QPixmap pixmap = icon.pixmap(16, 16);
-    m_favButton->setIcon(pixmap);
-}
-
-void UrlLineEdit::resizeEvent(QResizeEvent *event)
-{
-    QLineEdit::resizeEvent(event);
-    QSize clearButtonSize = m_clearButton->sizeHint();
-    m_clearButton->move(rect().right() - clearButtonSize.width(),
-                        (rect().bottom() - clearButtonSize.height()) / 2);
-    m_favButton->move(rect().left(), (rect().bottom() - m_favButton->sizeHint().height()) / 2);
-}
diff --git a/examples/webenginewidgets/simplebrowser/webpopupwindow.cpp b/examples/webenginewidgets/simplebrowser/webpopupwindow.cpp
index 8146dcfb7e2257bed3c95af1d737ecfe3600bec3..63246ac1d4a9bb30189296a54f4173644624c0f9 100644
--- a/examples/webenginewidgets/simplebrowser/webpopupwindow.cpp
+++ b/examples/webenginewidgets/simplebrowser/webpopupwindow.cpp
@@ -38,15 +38,17 @@
 **
 ****************************************************************************/
 
-#include "urllineedit.h"
 #include "webpage.h"
 #include "webpopupwindow.h"
 #include "webview.h"
+#include <QAction>
 #include <QIcon>
+#include <QLineEdit>
 #include <QVBoxLayout>
 
 WebPopupWindow::WebPopupWindow(QWebEngineProfile *profile)
-    : m_addressBar(new UrlLineEdit(this))
+    : m_urlLineEdit(new QLineEdit(this))
+    , m_favAction(new QAction(this))
     , m_view(new WebView(this))
 {
     setAttribute(Qt::WA_DeleteOnClose);
@@ -55,31 +57,29 @@ WebPopupWindow::WebPopupWindow(QWebEngineProfile *profile)
     QVBoxLayout *layout = new QVBoxLayout;
     layout->setMargin(0);
     setLayout(layout);
-    layout->addWidget(m_addressBar);
+    layout->addWidget(m_urlLineEdit);
     layout->addWidget(m_view);
 
     m_view->setPage(new WebPage(profile, m_view));
     m_view->setFocus();
-    m_addressBar->setReadOnly(true);
-    m_addressBar->setFavIcon(QIcon(QStringLiteral(":defaulticon.png")));
+
+    m_urlLineEdit->setReadOnly(true);
+    m_urlLineEdit->addAction(m_favAction, QLineEdit::LeadingPosition);
 
     connect(m_view, &WebView::titleChanged, this, &QWidget::setWindowTitle);
-    connect(m_view, &WebView::urlChanged, this, &WebPopupWindow::setUrl);
-    connect(m_view->page(), &WebPage::iconChanged, this, &WebPopupWindow::handleIconChanged);
+    connect(m_view, &WebView::urlChanged, [this](const QUrl &url) {
+        m_urlLineEdit->setText(url.toDisplayString());
+    });
+    connect(m_view, &WebView::favIconChanged, m_favAction, &QAction::setIcon);
     connect(m_view->page(), &WebPage::geometryChangeRequested, this, &WebPopupWindow::handleGeometryChangeRequested);
     connect(m_view->page(), &WebPage::windowCloseRequested, this, &QWidget::close);
 }
 
-QWebEngineView *WebPopupWindow::view() const
+WebView *WebPopupWindow::view() const
 {
     return m_view;
 }
 
-void WebPopupWindow::setUrl(const QUrl &url)
-{
-    m_addressBar->setUrl(url);
-}
-
 void WebPopupWindow::handleGeometryChangeRequested(const QRect &newGeometry)
 {
     m_view->setMinimumSize(newGeometry.width(), newGeometry.height());
@@ -87,12 +87,5 @@ void WebPopupWindow::handleGeometryChangeRequested(const QRect &newGeometry)
     // let the layout do the magic
     resize(0, 0);
     show();
-}
-
-void WebPopupWindow::handleIconChanged(const QIcon &icon)
-{
-    if (icon.isNull())
-        m_addressBar->setFavIcon(QIcon(QStringLiteral(":defaulticon.png")));
-    else
-        m_addressBar->setFavIcon(icon);
+    m_view->setFocus();
 }
diff --git a/examples/webenginewidgets/simplebrowser/webpopupwindow.h b/examples/webenginewidgets/simplebrowser/webpopupwindow.h
index af97ef7fc97cb70dfc70fe268d5a78893f76e69a..c737b4abc11a1e858c5c8e337273722e6a865dd0 100644
--- a/examples/webenginewidgets/simplebrowser/webpopupwindow.h
+++ b/examples/webenginewidgets/simplebrowser/webpopupwindow.h
@@ -44,12 +44,12 @@
 #include <QWidget>
 
 QT_BEGIN_NAMESPACE
+class QLineEdit;
 class QWebEngineProfile;
 class QWebEngineView;
 QT_END_NAMESPACE
 
 class WebView;
-class UrlLineEdit;
 
 class WebPopupWindow : public QWidget
 {
@@ -57,15 +57,14 @@ class WebPopupWindow : public QWidget
 
 public:
     WebPopupWindow(QWebEngineProfile *profile);
-    QWebEngineView *view() const;
-    void setUrl(const QUrl &url);
+    WebView *view() const;
 
 private slots:
     void handleGeometryChangeRequested(const QRect &newGeometry);
-    void handleIconChanged(const QIcon &icon);
 
 private:
-    UrlLineEdit *m_addressBar;
+    QLineEdit *m_urlLineEdit;
+    QAction *m_favAction;
     WebView *m_view;
 };
 #endif // WEBPOPUPWINDOW_H
diff --git a/examples/webenginewidgets/simplebrowser/webview.cpp b/examples/webenginewidgets/simplebrowser/webview.cpp
index e4e7f5efae1074e3d1eb836e9d666a471681d9ca..4bd5c84acb92ad6c9ff6995313b2ca6ca0044230 100644
--- a/examples/webenginewidgets/simplebrowser/webview.cpp
+++ b/examples/webenginewidgets/simplebrowser/webview.cpp
@@ -52,15 +52,21 @@
 
 WebView::WebView(QWidget *parent)
     : QWebEngineView(parent)
-    , m_loadProgress(0)
+    , m_loadProgress(100)
 {
+    connect(this, &QWebEngineView::loadStarted, [this]() {
+        m_loadProgress = 0;
+        emit favIconChanged(favIcon());
+    });
     connect(this, &QWebEngineView::loadProgress, [this](int progress) {
         m_loadProgress = progress;
     });
     connect(this, &QWebEngineView::loadFinished, [this](bool success) {
-        if (!success) {
-            m_loadProgress = 0;
-        }
+        m_loadProgress = success ? 100 : -1;
+        emit favIconChanged(favIcon());
+    });
+    connect(this, &QWebEngineView::iconChanged, [this](const QIcon &) {
+        emit favIconChanged(favIcon());
     });
 
     connect(this, &QWebEngineView::renderProcessTerminated,
@@ -115,21 +121,39 @@ bool WebView::isWebActionEnabled(QWebEnginePage::WebAction webAction) const
     return page()->action(webAction)->isEnabled();
 }
 
+QIcon WebView::favIcon() const
+{
+    QIcon favIcon = icon();
+    if (!favIcon.isNull())
+        return favIcon;
+
+    if (m_loadProgress < 0) {
+        static QIcon errorIcon(QStringLiteral(":dialog-error.png"));
+        return errorIcon;
+    } else if (m_loadProgress < 100) {
+        static QIcon loadingIcon(QStringLiteral(":view-refresh.png"));
+        return loadingIcon;
+    } else {
+        static QIcon defaultIcon(QStringLiteral(":text-html.png"));
+        return defaultIcon;
+    }
+}
+
 QWebEngineView *WebView::createWindow(QWebEnginePage::WebWindowType type)
 {
+    BrowserWindow *mainWindow = qobject_cast<BrowserWindow*>(window());
+    if (!mainWindow)
+        return nullptr;
+
     switch (type) {
     case QWebEnginePage::WebBrowserTab: {
-        BrowserWindow *mainWindow = qobject_cast<BrowserWindow*>(window());
         return mainWindow->tabWidget()->createTab();
     }
     case QWebEnginePage::WebBrowserBackgroundTab: {
-        BrowserWindow *mainWindow = qobject_cast<BrowserWindow*>(window());
-        return mainWindow->tabWidget()->createTab(false);
+        return mainWindow->tabWidget()->createBackgroundTab();
     }
     case QWebEnginePage::WebBrowserWindow: {
-        BrowserWindow *mainWindow = new BrowserWindow();
-        Browser::instance().addWindow(mainWindow);
-        return mainWindow->currentTab();
+        return mainWindow->browser()->createWindow()->currentTab();
     }
     case QWebEnginePage::WebDialog: {
         WebPopupWindow *popup = new WebPopupWindow(page()->profile());
diff --git a/examples/webenginewidgets/simplebrowser/webview.h b/examples/webenginewidgets/simplebrowser/webview.h
index f06162ea360af5dd73bbd82d2e207bf1e68139c6..23a9a29ee157b70ed412895eb777929b7464b883 100644
--- a/examples/webenginewidgets/simplebrowser/webview.h
+++ b/examples/webenginewidgets/simplebrowser/webview.h
@@ -56,6 +56,7 @@ public:
 
     int loadProgress() const;
     bool isWebActionEnabled(QWebEnginePage::WebAction webAction) const;
+    QIcon favIcon() const;
 
 protected:
     void contextMenuEvent(QContextMenuEvent *event) override;
@@ -63,6 +64,7 @@ protected:
 
 signals:
     void webActionEnabledChanged(QWebEnginePage::WebAction webAction, bool enabled);
+    void favIconChanged(const QIcon &icon);
 
 private:
     void createWebActionTrigger(QWebEnginePage *page, QWebEnginePage::WebAction);