summaryrefslogtreecommitdiffstats
path: root/src/core/browser_context_qt.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Update spellcheck api to support multiple languagesMichal Klocek2016-10-291-8/+17
| | | | | | Task-number: QTBUG-56074 Change-Id: I2a66e91dd4ed1026e5ab2539cfd3f9094263b48c Reviewed-by: Michael Brüning <michael.bruning@qt.io>
* Make BrowserContextQt a Chrome ProfileAllan Sandfeld Jensen2016-09-201-0/+10
| | | | | | | | Expose the preferences as a Profile class, this will make it possible to use more Chromium code unmodified. Change-Id: If49b5239c573391f8e25cfadc18240ed666974ae Reviewed-by: Michael Brüning <michael.bruning@qt.io>
* Adaptations to Chromium 52Allan Sandfeld Jensen2016-09-141-10/+6
| | | | | Change-Id: Idf8a511ba26d263fd9d014d87d5e1101d706da71 Reviewed-by: Michael Brüning <michael.bruning@qt.io>
* Make UserPrefs available without spell-checkingAllan Sandfeld Jensen2016-08-051-8/+3
| | | | | | | | Autofill and other components also need user preferences, so make it included by default. Change-Id: Id63241b2239451456ca8a8e1cd9771df4d48b8b8 Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* Basic porting to Chromium 51Allan Sandfeld Jensen2016-06-011-12/+16
| | | | | | | Trivial changes in methods, arguments and types. Change-Id: Ic707c376249f816268223e696ed5f6251df1f85f Reviewed-by: Michael Brüning <michael.bruning@theqtcompany.com>
* Use empty default values in spellcheck initMichal Klocek2016-05-041-6/+3
| | | | | | | | | Using default value in kSpellCheckDictionary ends up in migrating preferences from single-language to multi-language schema. Default values can be set on application start. Change-Id: I59e3667bcf57a859f1b18f389c1c44c81fc82651 Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* Remove availableDictionaries from spellcheck apiMichal Klocek2016-05-041-14/+6
| | | | | | | | | | | This method is broken, since SpellcheckerService is lazily initialized and dictionaries might be not loaded yet. Moreover there is a missing implementation on mac. Instead log warning when SpellcheckService can not load dictionary. Change-Id: Ifa2e769d83307543fa6cdf529475e9ab980022f0 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com>
* Merge remote-tracking branch 'origin/5.6' into 5.7Allan Sandfeld Jensen2016-04-251-3/+3
|\ | | | | | | Change-Id: I329397621f19ba3890be5daf44a6bb2d668ad2d8
| * Remove unused BrowserContextAdapter handlesKai Koehne2016-04-201-2/+2
| | | | | | | | | | Change-Id: Ic3504db1b55e1ff4375efacb450a96ce32a119ee Reviewed-by: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com>
| * Switch BrowserContextAdapter to QSharedPointerAllan Sandfeld Jensen2016-04-191-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | BrowserContextAdapter is not a form of shared data, and using QExplicitSharedDataPointer on it as always been a misuse of the class. Instead we should switch it to QSharedPointer, which also allows us to use QWeakPointer. Change-Id: I8eb489b4a12d3fdddcde55821be294814a156a9d Reviewed-by: Kai Koehne <kai.koehne@qt.io> Reviewed-by: Michal Klocek <michal.klocek@theqtcompany.com>
* | Use default language as default spell-checking languageAllan Sandfeld Jensen2016-04-011-1/+1
| | | | | | | | | | | | | | | | Instead of hard-coding en-US as the default, read the Qt default and use that. Change-Id: I118d2e7b9b4486dd32b2ccbd42c90bc1cee2257f Reviewed-by: Michal Klocek <michal.klocek@theqtcompany.com>
* | Merge remote-tracking branch 'origin/5.6' into 5.7Allan Sandfeld Jensen2016-03-081-1/+4
|\| | | | | | | Change-Id: Ieab3c4a6d16b1d7b7c0243ff8898f81807e7b1fc
| * Implement SSLHostStateDelegateAllan Sandfeld Jensen2016-02-231-1/+4
| | | | | | | | | | | | | | | | | | | | This class was introduced to track accepted certificate errors. Our lack of implementation caused a regression in certificate error handling. Task-number: QTBUG-51319 Change-Id: Idf3314fd17a5f9cb13a4513a3ccdb40954519c0d Reviewed-by: Michael Brüning <michael.bruning@theqtcompany.com>
* | Basic adaptation to Chromium 49Allan Sandfeld Jensen2016-03-071-2/+7
| | | | | | | | | | | | | | | | Converts types, callbacks and headers to match Chromium 49. Task-number: QTBUG-51173 Change-Id: I544ef46e187105e250fea1b48b72d2c81a906640 Reviewed-by: Michael Brüning <michael.bruning@theqtcompany.com>
* | Add spell checker supportMichal Klocek2016-02-011-0/+79
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Integrate chromium spell checker: * add spellchecker and dependencies to build * underline misspelled words in html text areas * right-click context menu shows up to 4 options to correct the misspelled word * toggle spell check from context menu * add new qml and widget api calls to qwebengineprofile to enable/disable spell check, select spell check language, get list of supported languages/dictionaries * register new qml spell check properties for QtWebEngine 1.3 * CONFIG+="no_spellcheck" to remove spellcheck support Change-Id: Ie61434ab9493597d7759a6f33794f6859c4e3a4c Reviewed-by: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com>
* | Unify license header usage.Jani Heikkinen2016-02-011-11/+14
|/ | | | | | | | | Update files using old header.LGPL3 to use header.LGPL Update files using old header.FLD to use new header.FDL Update files using old header.BSD to use new header.BSD Change-Id: I36a67aaa8c3ca6c7946308defc9c03c3571a7d23 Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
* Use default URLRequestInterceptors passed from ChromiumAleksey Yermakov2015-12-161-2/+2
| | | | | | | | | | | Default URLRequestInterceptors are required for App Cache and Service Workers support. They were previously ignored and dropped in BrowserContextQt::CreateRequestContext. Implementation in content shell was taken as a reference. Change-Id: I5a12e90febdb4c639f9ead9faf044df09431bdd0 Reviewed-by: Aleksey Yermakov <jp.kuraisu@gmail.com> Reviewed-by: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com>
* Update BrowserContext and WebContentsDelegate for Chromium 44Allan Sandfeld Jensen2015-07-011-0/+5
| | | | | | | Adds and changes interfaces to work with Chromium 44. Change-Id: Id7c02e7b1be255d591f7ac5449dde5823c261eb5 Reviewed-by: Andras Becsi <andras.becsi@theqtcompany.com>
* Permission Management for Chromium 44Allan Sandfeld Jensen2015-07-011-0/+8
| | | | | | | Implementing the new PermissionManager API. Change-Id: If0fdac24b8fec561a898aba009345576b5ce7fc6 Reviewed-by: Andras Becsi <andras.becsi@theqtcompany.com>
* Add public QtWebEngineCore C++ APIAndras Becsi2015-06-081-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | This patch introduces a new public C++ API layer in preparation to make it possible to integrate with lower level Chromium features related mostly to networking operations like accessing and blocking cookies, custom request headers, etc. This API layer can be used both by Qt Widgets and Qt Quick applications with a small C++ core. It should contatain API to access features that usually run on the IO thread to make it possible to perform heavy tasks that would otherwise require costly context switches to the UI thread. Furthermore for these features a QML API does either not make sense, since they are non-UI-related, or a QML API is simply not feasible, because the API is meant for advanced usecases like web browser development (i.e. custom protocol handlers, network traffic interception cookie syncing, etc.). In the long term this layer could also make it possible to reduce code duplication in the widgets and quick layers by moving common parts to the core layer. The new API is built entirely by qmake as a separate static library which is then linked into the QtWebEngineCore library built by gyp and ninja, to prevent the build options passed to Chromium to break the API layer. As a first step this only contains the global headers for core. Change-Id: Iccf8544587cde7c0d9c6abd462e4766bf9ec81ae Reviewed-by: Pierre Rossi <pierre.rossi@theqtcompany.com>
* Remove unneeded ResourceContextQt::set_url_request_context_getterAndras Becsi2015-05-121-2/+1
| | | | | | | This is an ancient relic that can be removed. Change-Id: Ia6926fff65d0e4d0769de940516866a2c51d9a0c Reviewed-by: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com>
* Add namespace to internal QtWebEngine APIAllan Sandfeld Jensen2015-03-021-0/+4
| | | | | | | | Adds the QtWebEngineCore namespace to all internal core API. This ensures we don't export any internal symbols in the global namespace. Change-Id: I26af888ea7c6c4c4d0f04c24a377c1a9d3c92751 Reviewed-by: Andras Becsi <andras.becsi@theqtcompany.com>
* Update copyright headersJani Heikkinen2015-02-161-7/+7
| | | | | | | | | Qt copyrights are now in The Qt Company, so we could update the source code headers accordingly. In the same go we should also fix the links to point to qt.io. Change-Id: Ieb6bac7a1be5c25eb7cb917495b58b6a870ca6d4 Reviewed-by: Pierre Rossi <pierre.rossi@theqtcompany.com>
* Update Chromium to version 40.0.2214.28 and ninja to 1.5.3.Zeno Albisser2015-01-201-1/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * scoped_refptr operator for implicit conversion to pointer has been disabled upstream: https://codereview.chromium.org/510323002 * Group permission API as done upstream: https://codereview.chromium.org/622793002 * content_worker gyp target has been removed upstream. * GetPageThumbnailData moved to DevToolsManagerDelegate. * ui/ui_resources has been renamed to ui/resources * WebPreferences and ResourceType have moved inside content. * Merge ResourceBundle's InitSharedInstanceLocaleOnly with InitSharedInstanceWithLocale(): https://codereview.chromium.org/457103003 * Remove obsolete accessibility events. * AX_EVENT_SELECTED_TEXT_CHANGED has been renamed to AX_EVENT_TEXT_SELECTION_CHANGED * AX_ROLE_MATH_ELEMENT was removed upstream. https://codereview.chromium.org/695133002 * Screen::IsDIPEnabled has been removed upstream. https://codereview.chromium.org/672823002 * Update DevToolsHttpHandlerDelegateQt according to ShellDevToolsManagerDelegate. * Various functionality from DevToolsHttpHandler was moved to DevToolsManagerDelegate https://codereview.chromium.org/560323005 * DevToolsHttpHandler::Start expects a scoped_ptr now. * Make sure event_factory_evdev.h is not included when USE_OZONE is not defined * ErrorPageParams was moved into namespace error_page. * Media Access is now handled by ContentBrowserClient::CheckMediaAccessPermission * SpecialStoragePolicy moved to namespace storage * Add implementation for new pure virtual function BrowserContext::GetSSLHostStateDelegate. * RenderPass::Id was renamed to RenderPass::RenderPassId * Include view_messages.h for ViewHostMsg_TextInputState_Param * CERT_UNABLE_TO_CHECK_REVOCATION has been deprecated by Chromium: https://codereview.chromium.org/449743002 * MailboxManager::ConsumeTexture only takes the mailbox as an argument * Replace RWHVQt::TextInputStateChanged with RWHVQt::TextInputTypeChanged. * RenderWidgetHostView::ScrollOffsetChanged has been removed. * SkBitmap::Config was removed upstream. * CopyFromCompositingSurfaceCallback has become an own type. * AcceleratedSurfaceInitialized only takes route_id as an argument. * ServerBoundCertService has been renamed to ChannelIDService. Related API has been renamed accordingly. * TextureImageTransportSurface was removed upstream. * Update MediaCaptureDispatcher::OnMediaRequestStateChanged signature. * AudioStream related functions are gone upstream. https://codereview.chromium.org/569713002 * Add implementation for RenderWidgetHostViewQt::GetLastScrollOffset. * Include generic touch_device implementation. * switches::kDisableDesktopNotifications was removed upstream. https://codereview.chromium.org/607843002 * PageTransition moved to ui. * Messages headers are not guarded. Including them multiple times does hurt. * ScaleGestureDetector does not create a standalone GestureDetector anymore. https://codereview.chromium.org/501503003 * MotionEvent::Cancel and Clone are not virtual anymore. https://codereview.chromium.org/502993004 * Exclude os_exchange_data_provider_mac from build. * Remove argument from ScopedClipboardWriter ctor. https://codereview.chromium.org/558913003 * Remove ShowPopupMenu override from WebContentsQt. The function is not pure virtual anymore, and we never implemented any specifics. * Do not use clang on desktop linux. * Request functions in ContentBrowserClient were merged into RequestPermission. * ninja: use configure.py --bootstrap instead of bootstrap.py Change-Id: I3575612826db7845461a949b4e737264bb4e8d88 Reviewed-by: Pierre Rossi <pierre.rossi@theqtcompany.com>
* Add QML download APIAndras Becsi2015-01-121-2/+2
| | | | | | | | | | | | | | | | This patch exposes downloadStarted and downloadFinished signals on the WebEngineProfile to notify about downloads. The WebEngineDownloadItem exposes a subset of Chromium's content::DownloadItem functionality. For now we expose minimal requirements to be able to control downloads in QML but this can be extended in the future. This patch also adds a DownloadView to quicktestbrowser to demonstrate the usage of the new API. [ChangeLog][QtWebEngineQML] Add QtQuick download API Change-Id: I8d8f0daf02c4e0151000427fc2a4b37d28b9db52 Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
* Do not use QDir::separator()Allan Sandfeld Jensen2015-01-071-2/+2
| | | | | | | | Build all paths Qt-style using / separators, and only convert it when converted to Chromium types. Change-Id: I181be6edb903f38e1772bcd324972d1d4e6672fc Reviewed-by: Pierre Rossi <pierre.rossi@theqtcompany.com>
* Introduce QWebEngineProfile APIAllan Sandfeld Jensen2014-12-121-3/+4
| | | | | | | | | | | | | | | Introduces initial widgets API for the Chromium BrowserContext. Adds API for controlling cookie jar policy, user-agent string and cache and persistent data paths. Similar QML API will follow in another patch. [ChangeLog][QtWebEngineWidgets][QWebEngineProfile] New API for profiles applying to groups of QWebEnginePages. Change-Id: I3c4ef4053fde7564af29178c91a0aca8a2b61a5f Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
* Use in-memory caches for off-the-record browsingAllan Sandfeld Jensen2014-12-031-1/+1
| | | | | | | | | Off the record should leave no record, which means we should not use disk storage for cookies and cache but instead trigger memory caching. Change-Id: I3e14ed0f91f925bc65675d2e7d9f07eb379a30b0 Reviewed-by: Andras Becsi <andras.becsi@theqtcompany.com> Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
* Merge remote-tracking branch 'origin/5.4' into devAllan Sandfeld Jensen2014-11-111-2/+7
|\ | | | | | | | | | | | | | | Conflicts: src/core/browser_context_qt.cpp src/webengine/api/qquickwebengineview_p.h Change-Id: I73bdec03b627b282851d7dda12006d4ab631072c
| * Cache to QStandardPaths::CacheLocationAllan Sandfeld Jensen2014-11-071-1/+13
| | | | | | | | | | | | | | | | | | We should save our cache in the configured CacheLocation, and ensure we are prepared for multiple BrowserContext by caching to a Default subdir. This matches how chromium caches on linux. Change-Id: Ibe914fca35435ea1658565be87747cfabc71e97b Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
* | Unglobalize browserContextAllan Sandfeld Jensen2014-11-061-15/+5
|/ | | | | | | | | | | | | | This patch makes it possible to have more than one BrowserContext, for instance for off-the-record browsering but also to enable any other configuration on browser context level. This will make it possible to add page-groups settings and API for settingsthat can only be done on BrowserContext level. This patch does not expose any new API. Change-Id: I0a0e194449cfb5a096a4ac6e2f2b3882b6b4cfa2 Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
* Disable Downloads for now.Michael Brüning2014-10-091-1/+0
| | | | | | | | | The current delegate just downloads files to the default download location. By not setting the delegate for downloads, we effectively disable them. Change-Id: I1b416f76ac9b4395ee0bcf9986134f4bf056d8ed Reviewed-by: Andras Becsi <andras.becsi@digia.com>
* Replace QStringLiteral with QLatin1String where appropriateKai Koehne2014-10-071-1/+1
| | | | | | | | | It's faster to use QLatin1String in places where we don't actually need a QString object (like for comparison, or when creating a string with QStringBuilder). Change-Id: I9b8e28040dc2b79a767e15015b85822d06141bbe Reviewed-by: Zeno Albisser <zeno.albisser@digia.com>
* Update License Headers for Qt WebEngine to LGPLv3.Zeno Albisser2014-08-211-14/+9
| | | | | | | Change-Id: Idbe0eafb51d77cc00e3a93179b81770724d5bfaa Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com> Reviewed-by: Tuukka Turunen <tuukka.turunen@digia.com> Reviewed-by: Pierre Rossi <pierre.rossi@gmail.com>
* Update the QtWebEngineCore library to run on top of Chromium 37Jocelyn Turcotte2014-08-141-12/+6
| | | | | | | | | | | | | | | Most of the patch is about upstream classes/methods that changed. Other important details: - icu data files are now used by default - cygwin is no longer required to build on Windows - RenderFrameHost has been replacing RenderViewHost in a few places, following the separate process iframes support in Chromium - The user agent is accessed through ContentClient::GetUserAgent instead of from the command line switches Change-Id: I86cc93aff7ce31176a80b0b4a5d54025674a451c Reviewed-by: Andras Becsi <andras.becsi@digia.com>
* Fix Google Maps not showing tiles when panning/zoomingJocelyn Turcotte2014-05-091-1/+1
| | | | | | | | | | | | The issue is that the web worker that fetches and pre-process the map tiles couldn't be started successfully from a Blob. We were missing the blob: scheme handler that was passed to us in the ignored protocol_handlers argument of BrowserContextQt::CreateRequestContext. Change-Id: I24b726a1577e7092d53b1821efd3e4aa2a66c7d9 Reviewed-by: Andras Becsi <andras.becsi@digia.com>
* Adapt to API changes in new stable branch 1750Andras Becsi2014-03-281-2/+6
| | | | | | Change-Id: If0cc263f36d396fd505c1d8b026e2493bfc29cc4 Reviewed-by: Pierre Rossi <pierre.rossi@gmail.com> Reviewed-by: Zeno Albisser <zeno.albisser@digia.com>
* Move the implementation of BrowserContextQt to its own cpp fileAndras Becsi2014-02-051-0/+147
Change-Id: Ie44a8733e3f9123c3d086f8df9ddcf2833bd235b Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>