From 916c6b921246c3214b518886278990347fc00e21 Mon Sep 17 00:00:00 2001
From: Leena Miettinen <riitta-leena.miettinen@qt.io>
Date: Thu, 6 Oct 2016 17:22:04 +0200
Subject: [PATCH] Doc: Fix grouping Qt WebEngine modules
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Add a page for exposed Qt WebEngine module C++ classes.

Change-Id: I4fd15e9d5c5c1b8c51a836ad5a036083adaae328
Reviewed-by: Topi Reiniö <topi.reinio@theqtcompany.com>
---
 src/core/doc/src/qtwebenginecore-index.qdoc   |  1 -
 src/core/doc/src/qtwebenginecore-module.qdoc  |  1 +
 .../snippets/qtwebengine_build_snippet.qdoc   |  8 ++++
 src/webengine/doc/src/qtwebengine-index.qdoc  |  1 -
 src/webengine/doc/src/qtwebengine-module.qdoc | 44 +++++++++++++++++++
 ... => qtwebenginewidgets_build_snippet.qdoc} |  0
 .../doc/src/qtwebenginewidgets-index.qdoc     |  1 -
 .../doc/src/qtwebenginewidgets-module.qdoc    |  4 +-
 8 files changed, 55 insertions(+), 5 deletions(-)
 create mode 100644 src/webengine/doc/snippets/qtwebengine_build_snippet.qdoc
 create mode 100644 src/webengine/doc/src/qtwebengine-module.qdoc
 rename src/webenginewidgets/doc/snippets/{qtwebengine_build_snippet.qdoc => qtwebenginewidgets_build_snippet.qdoc} (100%)

diff --git a/src/core/doc/src/qtwebenginecore-index.qdoc b/src/core/doc/src/qtwebenginecore-index.qdoc
index 70af397ce..4d540e277 100644
--- a/src/core/doc/src/qtwebenginecore-index.qdoc
+++ b/src/core/doc/src/qtwebenginecore-index.qdoc
@@ -28,7 +28,6 @@
 /*!
     \page qtwebenginecore-index.html
     \title Qt WebEngine Core
-    \ingroup modules
 
     \brief Provides common API shared by Qt WebEngine and Qt WebEngine Widgets.
 
diff --git a/src/core/doc/src/qtwebenginecore-module.qdoc b/src/core/doc/src/qtwebenginecore-module.qdoc
index 6dc2478fc..0ac20a794 100644
--- a/src/core/doc/src/qtwebenginecore-module.qdoc
+++ b/src/core/doc/src/qtwebenginecore-module.qdoc
@@ -32,6 +32,7 @@
     \brief Provides public API shared by both QtWebEngine and QtWebEngineWidgets
     \since 5.6
     \ingroup qtwebengine-modules
+    \ingroup modules
 
     To include the definitions of the module's classes, use the
     following directive:
diff --git a/src/webengine/doc/snippets/qtwebengine_build_snippet.qdoc b/src/webengine/doc/snippets/qtwebengine_build_snippet.qdoc
new file mode 100644
index 000000000..248296588
--- /dev/null
+++ b/src/webengine/doc/snippets/qtwebengine_build_snippet.qdoc
@@ -0,0 +1,8 @@
+//! [0]
+QT += webengine
+//! [0]
+
+
+//! [1]
+#include <QtWebEngine>
+//! [1]
diff --git a/src/webengine/doc/src/qtwebengine-index.qdoc b/src/webengine/doc/src/qtwebengine-index.qdoc
index c4be591ff..bd6cc9a32 100644
--- a/src/webengine/doc/src/qtwebengine-index.qdoc
+++ b/src/webengine/doc/src/qtwebengine-index.qdoc
@@ -28,7 +28,6 @@
 /*!
     \page qtwebengine-index.html
     \title Qt WebEngine
-    \ingroup modules
 
     \brief Provides functionality for rendering regions of dynamic web content.
 
diff --git a/src/webengine/doc/src/qtwebengine-module.qdoc b/src/webengine/doc/src/qtwebengine-module.qdoc
new file mode 100644
index 000000000..97657f6a9
--- /dev/null
+++ b/src/webengine/doc/src/qtwebengine-module.qdoc
@@ -0,0 +1,44 @@
+/****************************************************************************
+**
+** Copyright (C) 2016 The Qt Company Ltd.
+** Contact: https://www.qt.io/licensing/
+**
+** This file is part of the documentation of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:FDL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see https://www.qt.io/terms-conditions. For further
+** information use the contact form at https://www.qt.io/contact-us.
+**
+** GNU Free Documentation License Usage
+** Alternatively, this file may be used under the terms of the GNU Free
+** Documentation License version 1.3 as published by the Free Software
+** Foundation and appearing in the file included in the packaging of
+** this file. Please review the following information to ensure
+** the GNU Free Documentation License version 1.3 requirements
+** will be met: https://www.gnu.org/licenses/fdl-1.3.html.
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+/*!
+    \module QtWebEngine
+    \title Qt WebEngine C++ Classes
+    \brief Exposes C++ functionality to Qt Quick.
+    \ingroup modules
+
+    The Qt WebEngine module exposes C++ functionality to Qt Quick.
+
+    To include the definitions of the module's classes, use the
+    following directive:
+
+    \snippet qtwebengine_build_snippet.qdoc 1
+
+    To link against the module, add the following to your qmake project file:
+
+    \snippet qtwebengine_build_snippet.qdoc 0
+*/
diff --git a/src/webenginewidgets/doc/snippets/qtwebengine_build_snippet.qdoc b/src/webenginewidgets/doc/snippets/qtwebenginewidgets_build_snippet.qdoc
similarity index 100%
rename from src/webenginewidgets/doc/snippets/qtwebengine_build_snippet.qdoc
rename to src/webenginewidgets/doc/snippets/qtwebenginewidgets_build_snippet.qdoc
diff --git a/src/webenginewidgets/doc/src/qtwebenginewidgets-index.qdoc b/src/webenginewidgets/doc/src/qtwebenginewidgets-index.qdoc
index 59d7bc5d1..abfd17ce3 100644
--- a/src/webenginewidgets/doc/src/qtwebenginewidgets-index.qdoc
+++ b/src/webenginewidgets/doc/src/qtwebenginewidgets-index.qdoc
@@ -28,7 +28,6 @@
 /*!
     \page qtwebenginewidgets-index.html
     \title Qt WebEngine Widgets
-    \ingroup modules
 
     \brief Provides a web browser engine as well as C++ classes to render  web content and interact
     with it.
diff --git a/src/webenginewidgets/doc/src/qtwebenginewidgets-module.qdoc b/src/webenginewidgets/doc/src/qtwebenginewidgets-module.qdoc
index d0f2fd930..959f96b10 100644
--- a/src/webenginewidgets/doc/src/qtwebenginewidgets-module.qdoc
+++ b/src/webenginewidgets/doc/src/qtwebenginewidgets-module.qdoc
@@ -40,9 +40,9 @@
     To include the definitions of the module's classes, use the
     following directive:
 
-    \snippet qtwebengine_build_snippet.qdoc 1
+    \snippet qtwebenginewidgets_build_snippet.qdoc 1
 
     To link against the module, add the following to your qmake project file:
 
-    \snippet qtwebengine_build_snippet.qdoc 0
+    \snippet qtwebenginewidgets_build_snippet.qdoc 0
 */
-- 
GitLab