diff options
-rw-r--r-- | .gitignore | 4 | ||||
-rw-r--r-- | examples/examples.pro | 2 | ||||
-rw-r--r-- | examples/webenginewidgets/contentmanipulation/contentmanipulation.pro (renamed from examples/webenginewidgets/fancybrowser/fancybrowser.pro) | 4 | ||||
-rw-r--r-- | examples/webenginewidgets/contentmanipulation/doc/images/contentmanipulation-example.png (renamed from examples/webenginewidgets/fancybrowser/doc/images/fancybrowser-example.png) | bin | 98031 -> 98031 bytes | |||
-rw-r--r-- | examples/webenginewidgets/contentmanipulation/doc/src/contentmanipulation.qdoc (renamed from examples/webenginewidgets/fancybrowser/doc/src/fancybrowser.qdoc) | 28 | ||||
-rw-r--r-- | examples/webenginewidgets/contentmanipulation/jquery.min.js (renamed from examples/webenginewidgets/fancybrowser/jquery.min.js) | 0 | ||||
-rw-r--r-- | examples/webenginewidgets/contentmanipulation/jquery.qrc (renamed from examples/webenginewidgets/fancybrowser/jquery.qrc) | 0 | ||||
-rw-r--r-- | examples/webenginewidgets/contentmanipulation/main.cpp (renamed from examples/webenginewidgets/fancybrowser/main.cpp) | 0 | ||||
-rw-r--r-- | examples/webenginewidgets/contentmanipulation/mainwindow.cpp (renamed from examples/webenginewidgets/fancybrowser/mainwindow.cpp) | 0 | ||||
-rw-r--r-- | examples/webenginewidgets/contentmanipulation/mainwindow.h (renamed from examples/webenginewidgets/fancybrowser/mainwindow.h) | 0 |
10 files changed, 19 insertions, 19 deletions
diff --git a/.gitignore b/.gitignore index 9f362ff0f..ab40b145a 100644 --- a/.gitignore +++ b/.gitignore @@ -13,8 +13,8 @@ examples/webengine/quicknanobrowser/quicknanobrowser examples/webengine/quicknanobrowser/quicknanobrowser.app examples/webenginewidgets/browser/browser examples/webenginewidgets/browser/browser.app -examples/webenginewidgets/fancybrowser/fancybrowser -examples/webenginewidgets/fancybrowser/fancybrowser.app +examples/webenginewidgets/contentmanipulation/contentmanipulation +examples/webenginewidgets/contentmanipulation/contentmanipulation.app tests/quicktestbrowser/quicktestbrowser tests/**/tst_* diff --git a/examples/examples.pro b/examples/examples.pro index 8345fded6..d6960e017 100644 --- a/examples/examples.pro +++ b/examples/examples.pro @@ -7,5 +7,5 @@ qtHaveModule(webengine) { qtHaveModule(webenginewidgets) { SUBDIRS += \ webenginewidgets/demobrowser \ - webenginewidgets/fancybrowser + webenginewidgets/contentmanipulation } diff --git a/examples/webenginewidgets/fancybrowser/fancybrowser.pro b/examples/webenginewidgets/contentmanipulation/contentmanipulation.pro index e5dcd9678..2ac97d487 100644 --- a/examples/webenginewidgets/fancybrowser/fancybrowser.pro +++ b/examples/webenginewidgets/contentmanipulation/contentmanipulation.pro @@ -6,5 +6,5 @@ SOURCES = main.cpp \ RESOURCES = jquery.qrc # install -target.path = $$[QT_INSTALL_EXAMPLES]/webenginewidgets/fancybrowser -INSTALLS += target
\ No newline at end of file +target.path = $$[QT_INSTALL_EXAMPLES]/webenginewidgets/contentmanipulation +INSTALLS += target diff --git a/examples/webenginewidgets/fancybrowser/doc/images/fancybrowser-example.png b/examples/webenginewidgets/contentmanipulation/doc/images/contentmanipulation-example.png Binary files differindex 717ac9ddc..717ac9ddc 100644 --- a/examples/webenginewidgets/fancybrowser/doc/images/fancybrowser-example.png +++ b/examples/webenginewidgets/contentmanipulation/doc/images/contentmanipulation-example.png diff --git a/examples/webenginewidgets/fancybrowser/doc/src/fancybrowser.qdoc b/examples/webenginewidgets/contentmanipulation/doc/src/contentmanipulation.qdoc index b798e4832..676173755 100644 --- a/examples/webenginewidgets/fancybrowser/doc/src/fancybrowser.qdoc +++ b/examples/webenginewidgets/contentmanipulation/doc/src/contentmanipulation.qdoc @@ -26,16 +26,16 @@ ****************************************************************************/ /*! - \example webenginewidgets/fancybrowser - \title WebEngine Fancy Browser Example + \example webenginewidgets/contentmanipulation + \title WebEngine Content Manipulation Example \ingroup webengine-widgetexamples \brief Demonstrates how to use browse web and manipulate content - \brief The Fancy Browser example shows how to use JQuery with QtWebEngine to + \brief The Content Manipulation example shows how to use JQuery with QtWebEngine to create a web browser with special effects and content manipulation. - \image fancybrowser-example.png + \image contentmanipulation-example.png The application makes use of QWebEnginePage::evaluateJavaScript to evaluate the jQuery JavaScript code. A QMainWindow with a QWebEngineView @@ -48,7 +48,7 @@ The \c MainWindow class inherits QMainWindow. It implements a number of slots to perform actions on both the application and on the web content. - \snippet webenginewidgets/fancybrowser/mainwindow.h 1 + \snippet webenginewidgets/contentmanipulation/mainwindow.h 1 We also declare a QString that contains the jQuery, a QWebView that displays the web content, and a QLineEdit that acts as the @@ -58,7 +58,7 @@ We start by implementing the constructor. - \snippet webenginewidgets/fancybrowser/mainwindow.cpp 1 + \snippet webenginewidgets/contentmanipulation/mainwindow.cpp 1 The first part of the constructor sets the value of \c progress to 0. This value will be used later in the code to visualize the @@ -68,7 +68,7 @@ content. The jQuery library is a JavaScript library that provides different functions for manipulating HTML. - \snippet webenginewidgets/fancybrowser/mainwindow.cpp 2 + \snippet webenginewidgets/contentmanipulation/mainwindow.cpp 2 The second part of the constructor creates a QWebView and connects slots to the views signals. Furthermore, we create a QLineEdit as @@ -77,13 +77,13 @@ QLineEdit to a QToolbar together with a set of navigation actions from QWebView::pageAction. - \snippet webenginewidgets/fancybrowser/mainwindow.cpp 3 + \snippet webenginewidgets/contentmanipulation/mainwindow.cpp 3 The third and last part of the constructor implements two QMenus and assigns a set of actions to them. The last line sets the QWebView as the central widget in the QMainWindow. - \snippet webenginewidgets/fancybrowser/mainwindow.cpp 4 + \snippet webenginewidgets/contentmanipulation/mainwindow.cpp 4 When the page is loaded, \c adjustLocation() updates the address bar; \c adjustLocation() is triggered by the \c loadFinished() @@ -92,13 +92,13 @@ the new web page has finished loading, \c adjustLocation() will be run once more to update the address bar. - \snippet webenginewidgets/fancybrowser/mainwindow.cpp 5 + \snippet webenginewidgets/contentmanipulation/mainwindow.cpp 5 \c adjustTitle() sets the window title and displays the loading progress. This slot is triggered by the \c titleChanged() signal in QWebView. - \snippet webenginewidgets/fancybrowser/mainwindow.cpp 6 + \snippet webenginewidgets/contentmanipulation/mainwindow.cpp 6 When a web page has loaded, \c finishLoading() is triggered by the \c loadFinished() signal in QWebView. \c finishLoading() then updates the @@ -113,7 +113,7 @@ that the images of the newly loaded page respect the state of the toggle action. - \snippet webenginewidgets/fancybrowser/mainwindow.cpp 7 + \snippet webenginewidgets/contentmanipulation/mainwindow.cpp 7 The first jQuery-based function, \c highlightAllLinks(), is designed to highlight all links in the current webpage. The JavaScript code looks @@ -121,14 +121,14 @@ For each such element, the background color is set to be yellow by using CSS. - \snippet webenginewidgets/fancybrowser/mainwindow.cpp 8 + \snippet webenginewidgets/contentmanipulation/mainwindow.cpp 8 The \c rotateImages() function rotates the images on the current web page. This JavaScript code relies on CSS transforms and looks up all \e {img} elements and rotates the images 180 degrees and then back again. - \snippet webenginewidgets/fancybrowser/mainwindow.cpp 9 + \snippet webenginewidgets/contentmanipulation/mainwindow.cpp 9 The remaining four methods remove different elements from the current web page. \c removeGifImages() removes all GIF images on the page by looking up diff --git a/examples/webenginewidgets/fancybrowser/jquery.min.js b/examples/webenginewidgets/contentmanipulation/jquery.min.js index b1ae21d8b..b1ae21d8b 100644 --- a/examples/webenginewidgets/fancybrowser/jquery.min.js +++ b/examples/webenginewidgets/contentmanipulation/jquery.min.js diff --git a/examples/webenginewidgets/fancybrowser/jquery.qrc b/examples/webenginewidgets/contentmanipulation/jquery.qrc index 1022d682f..1022d682f 100644 --- a/examples/webenginewidgets/fancybrowser/jquery.qrc +++ b/examples/webenginewidgets/contentmanipulation/jquery.qrc diff --git a/examples/webenginewidgets/fancybrowser/main.cpp b/examples/webenginewidgets/contentmanipulation/main.cpp index a21d881f4..a21d881f4 100644 --- a/examples/webenginewidgets/fancybrowser/main.cpp +++ b/examples/webenginewidgets/contentmanipulation/main.cpp diff --git a/examples/webenginewidgets/fancybrowser/mainwindow.cpp b/examples/webenginewidgets/contentmanipulation/mainwindow.cpp index 3dca497a3..3dca497a3 100644 --- a/examples/webenginewidgets/fancybrowser/mainwindow.cpp +++ b/examples/webenginewidgets/contentmanipulation/mainwindow.cpp diff --git a/examples/webenginewidgets/fancybrowser/mainwindow.h b/examples/webenginewidgets/contentmanipulation/mainwindow.h index 8e9b12538..8e9b12538 100644 --- a/examples/webenginewidgets/fancybrowser/mainwindow.h +++ b/examples/webenginewidgets/contentmanipulation/mainwindow.h |