summaryrefslogtreecommitdiff
path: root/embed
Commit message (Collapse)AuthorAgeFilesLines
* Revert "embed-prefs: Disable automatic window open via javascript"Michael Catanzaro2021-03-121-0/+1
| | | | | | | | | | This reverts commit b37ef802ce0eaf556916ae292bd76afa0b1fc73e. Looks like we were too aggressive here. WebKit's default behavior may not actually be suitable for browsers. It broke the VMWare vSphere web console. Fixes #1467
* Fix potential loss of session state when web process is unresponsiveMichael Catanzaro2021-03-121-0/+38
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If any web process is unresponsive when the window is closed using the close button in the header bar -- not Ctrl+Q -- then the entire session state is lost. Disaster! This happens to me three or four times per year, and it is sad because it inevitably results in me forgetting important things I had to do. Anyway, the problem is our code to handle an unresponsive web process. We'd like to cancel the JavaScript execution using g_cancellable_cancel(), but it doesn't work because the underlying WebKit operation is not actually cancellable, so instead we use a big hammer and gtk_widget_destroy() the EphyWebView. Then when we wind up closing the session later, there are no tabs open and nothing to save. It was tricky to figure out how to fix this, because the only way to truly cancel the operation is to destroy the web view, and if we do that then we have to close the session first to avoid losing tabs, but the user could legitimately choose to reject a modified forms close confirmation warning, in which case they would wind up using Epiphany after the session is closed, meaning all subsequent changes to open tabs would be lost since they won't be saved after the session is closed. Eventually I realized that we can just move the timeout from EphyWindow -- where it's handled in two separate places, once for closing a single tab, and once for closing an entire window -- down into EphyWebView itself. This solves all our problems because now EphyWindow can assume the JS execution always completes in a reasonable time. I tested this by changing the call to webkit_web_view_run_javascript_in_world() in ephy_web_view_has_modified_forms() to execute a while(true) loop. Without the other changes, the session state is lost if closing the window using the close button in the header bar. With this patch, the session state is no longer lost. Fixes #1445
* view: avoid adding ephy-pdf URIs to history databaseMichael Catanzaro2021-03-111-0/+6
| | | | | ephy-pdf: is an internal URI scheme and it shouldn't be showing up in the address bar dropdown or the history dialog.
* Fix regression preventing clicking links beneath the floating barMichael Catanzaro2021-03-111-1/+1
| | | | | | | | | When the floating bar covers a link at the bottom of the page, I should be able to click the floating bar to click the link. This broke in !850. There is some visual glitchiness where the bar briefly appears on the left before being moved out of the way to the right, but I'm not sure how to fix that
* Update code style with new rule setJan-Michael Brummer2021-02-211-2/+3
|
* Never register internal APIs in the default script worldMichael Catanzaro2021-02-111-1/+21
| | | | Fixes #1443
* Port to HdyTabView/HdyTabBarAlexander Mikhaylenko2021-02-042-6/+11
| | | | Replace the aging GtkNotebook-based tabs with a new implementation.
* Remove ephy_web_process_extension_deinitializeMichael Catanzaro2021-02-042-11/+3
| | | | dispose works fine.
* Revert "Fix setup of webextensions"Michael Catanzaro2021-02-031-2/+5
| | | This reverts commit 7d73117519c792cccceb757c50bc7a8dd98f0ac9
* Rename webextension uri to ephy-webextensionJan-Michael Brummer2021-02-032-2/+2
| | | | Make it clear that this is an own epiphany internal uri scheme.
* Fix setup of webextensionsJan-Michael Brummer2021-02-021-5/+2
| | | | Fixes: https://gitlab.gnome.org/GNOME/epiphany/-/issues/1435
* Set floating bar alignment based on enter-notify-eventJan-Michael Brummer2021-02-011-1/+21
| | | | | | In case the pointer hovers the floating bar move it to the other direction. Fixes: https://gitlab.gnome.org/GNOME/epiphany/-/issues/1368
* Enable eslint prefer-const ruleSonny Piers2021-01-213-83/+83
|
* Add eslint file for JavaScript codeSonny Piers2021-01-213-20/+25
|
* Always enable smooth scrollingMichael Catanzaro2021-01-191-0/+1
| | | | | This was rejected from WebKit in https://bugs.webkit.org/show_bug.cgi?id=220512.
* Remove smooth scrolling optionJan-Michael Brummer2021-01-191-4/+0
| | | | Fixes: https://gitlab.gnome.org/GNOME/epiphany/-/issues/802
* Add initial WebExtension supportJan-Michael Brummer2021-01-1710-2/+401
|
* ephy: make getWebAppTitle return nullSonny Piers2021-01-161-5/+10
| | | | set_default_application_title will fallback to a better formatted hostname
* find-toolbar: Select pre-filled text in search fieldBenjamin Berg2021-01-151-2/+4
| | | | | | | | | | | With commit 809d76e6cfc7 (Pre-fill search field with current selected text) focused text from the website will be pre-filled into the search entry. This is great, but even though the entry is focused, one cannot simply start typing to update the search text. Improve this user interaction by selecting the pre-filled text. Related: #809
* Enable media-stream supportJan-Michael Brummer2021-01-101-0/+1
|
* Skip addresses with a space in is_host_with_port()Jan-Michael Brummer2021-01-091-1/+5
| | | | | | | Addresses with a space shouldn't be treated as a valid host with port. Just exit early. Fixes: https://gitlab.gnome.org/GNOME/epiphany/-/issues/1418
* Avoid weak equality operators in JS codemcatanzaro/js-safetyMichael Catanzaro2020-12-082-42/+42
| | | | We don't want type coercions anywhere in our comparisons.
* Fix HiDPI faviconsAlexander Mikhaylenko2020-11-161-5/+14
| | | | | | | | | | | Currently the icon is handled in a weird way involving manually managing a cairo surface instead of just using GIcon. Getting scale factor from the window doesn't work when the widget isn't realized yet and doesn't have a window to begin with, which gtk_widget_get_scale_factor() does handle. Additionally, the icon isn't reloaded on scale factor changes. Fixes https://gitlab.gnome.org/GNOME/epiphany/-/issues/1298
* embed-shell: stop setting TLS errors policyMichael Catanzaro2020-10-281-3/+0
| | | | | This API is deprecated in 2.32, and it hasn't been needed since 2.6.something since FAIL is now default, so we can drop it.
* web-view: reduce size of ITP permission request messagemcatanzaro/#1358Michael Catanzaro2020-10-111-1/+1
| | | | Fixes #1358
* web-view: avoid crash destroying ITP permission request info barmcatanzaro/#1357Michael Catanzaro2020-10-101-1/+1
| | | | | | We need to own the WebKitPolicyDecision. Probably fixes #1357
* Move gsb data to meson_options.txtJan-Michael Brummer2020-09-291-3/+1
| | | | | | Move gsb_api_key to meson_options.txt so we can provide the necessary support within flatpak, but can disable it for the rest. Fixes: https://gitlab.gnome.org/GNOME/epiphany/-/issues/682
* ephy-reader-handler: Only fetch existing source data for user triggered actionsJan-Michael Brummer2020-09-262-46/+49
| | | | | | | Store user reader mode toggle request as EphyWebView property. Based on this information load the existing source data or trigger a new load. Fixes: https://gitlab.gnome.org/GNOME/epiphany/-/issues/1339
* overview.js: add missing semicolonMichael Catanzaro2020-09-251-1/+1
|
* overview: Ensure there are always 9 items on overviewJan-Michael Brummer2020-09-252-8/+30
| | | | Fixes: https://gitlab.gnome.org/GNOME/epiphany/-/issues/1326
* Skip system web apps for about:applicationsAlexander Mikhaylenko2020-09-251-0/+3
| | | | | They cannot be deleted as we don't control their desktop file. Don't show them at all.
* Remove ad-hoc query parameter strippingmcatanzaro/send-requestMichael Catanzaro2020-09-111-22/+0
| | | | | | | This old, manual, and very non-comprehensive method of tracking prevention doesn't make much sense to do now that we have far more sophisticated anti-tracking measures in WebKit and enabled by default that don't require listing ad-hoc query parameters to remove from URLs.
* embed: Remove unused GtkPanedwip/exalm/panedAlexander Mikhaylenko2020-09-112-11/+3
| | | | Looks like it's a leftover from inspector from very long ago.
* Revert "ephy.js: Improve multi login experience"Michael Catanzaro2020-09-041-108/+121
| | | | This reverts commit 87f1033b0fbb785d5a0219e492ebd88b8d380410.
* Revert "ephy: Close password completion dialog also on Tab and Escape"Michael Catanzaro2020-09-041-5/+0
| | | | This reverts commit 7050df3e2d64c6f37dd13716c28ee7718f7203f6.
* Revert "ephy: Hook menu also for one user"Michael Catanzaro2020-09-041-2/+2
| | | | This reverts commit 1e45efe7d788fc2e8ba673420a3563b11bb9560d.
* Revert "web-view: Remove handling of plugin errors"Michael Catanzaro2020-09-031-2/+11
| | | This reverts commit 868de06fca4018bb5eaf61bed8dd8c952e813ec2
* web-view: Remove handling of plugin errorsMichael Catanzaro2020-09-021-11/+2
| | | | | | | | | | | | | | | | | | | | | | | WebKitGTK trunk no longer supports plugins, and our use of the plugin error types is causing a deprecation warning: [103/281] Compiling C object embed/libephyembed.a.p/ephy-web-view.c.o ../../../../Projects/epiphany/embed/ephy-web-view.c: In function ‘load_failed_cb’: ../../../../Projects/epiphany/embed/ephy-web-view.c:2286:7: warning: ‘webkit_plugin_error_quark’ is deprecated [-Wdeprecated-declarations] 2286 | error->domain != WEBKIT_PLUGIN_ERROR) { | ^~~~~ In file included from /home/mcatanzaro/Projects/GNOME/install/include/webkitgtk-4.0/webkit2/webkit2.h:46, from ../../../../Projects/epiphany/embed/ephy-web-view.h:24, from ../../../../Projects/epiphany/embed/ephy-web-view.c:23: /home/mcatanzaro/Projects/GNOME/install/include/webkitgtk-4.0/webkit2/WebKitError.h:164:1: note: declared here 164 | webkit_plugin_error_quark (void); | ^~~~~~~~~~~~~~~~~~~~~~~~~ Since we already disable plugins, there's no need to check for plugin errors anymore. Note this also adjusts the position of a break statement to improve readability (no functional change).
* ephy: Hook menu also for one userJan-Michael Brummer2020-09-011-2/+2
| | | | | In case user accidently deletes his user name, there is not way back to restore the entry. Hook up the menu if users list is not empty to help user in this case.
* ephy: Close password completion dialog also on Tab and EscapeJan-Michael Brummer2020-09-011-0/+5
|
* ephy.js: Improve multi login experienceJan-Michael Brummer2020-08-311-121/+108
| | | | | | | | | | | | Reimplement password fill user menu function, which fixes: - multi user selection - keyboard highlight selection - mouse hovering - user selection with return - closing of password menu after leaving content Fixes: https://gitlab.gnome.org/GNOME/epiphany/-/issues/1143
* embed-prefs: don't customize allow-top-navigation-to-data-urlsMichael Catanzaro2020-08-251-3/+0
| | | | | | | | This was added in https://gitlab.gnome.org/GNOME/epiphany/-/commit/cba76bc107e26de853571fde16b240f88dd3d8b6. It's no longer needed with the version of WebKitGTK we already require (2.29.3) so we can remove it.
* embed-prefs: Disable automatic window open via javascriptJan-Michael Brummer2020-08-251-1/+0
|
* filter-manager: Disable filter manager functionality in test modeJan-Michael Brummer2020-08-251-0/+4
| | | | | | | | | | As filter manager is automatically started during ephy embed shell bringup it causes network access (filter download). This breaks during offline tests for every UI test. Disable filter manager functionally in this case. Fixes: https://gitlab.gnome.org/GNOME/epiphany/-/issues/1314
* ephy-web-view: fix closing curly quotes useRafael Fontenelle2020-08-071-2/+2
|
* Stop using HANDY_USE_UNSTABLE_APIAdrien Plazas2020-08-071-1/+0
| | | | It isn't needed anymore since libhandy 0.90.0.
* Removed unused variablesJan-Michael Brummer2020-07-293-3/+0
| | | | | | Fix compiler warnings shown with clang about unused variables Fixes: https://gitlab.gnome.org/GNOME/epiphany/-/issues/1280
* Support permission requests for webcam and micJan-Michael Brummer2020-07-271-16/+73
| | | | | | Currently we are only asking for either webcam or mic permission, but for video chats it is requesting permission for both. Take care of those cases.
* Add flatpak open directory download actions using libportalJan-Michael Brummer2020-07-251-5/+3
| | | | | | libportal is now a fixed dependency for Epiphany. Fixes: https://gitlab.gnome.org/GNOME/epiphany/-/issues/948
* Add setting to disable website data storageMichael Catanzaro2020-07-211-0/+24
| | | | | | | | | This will block access to cookies, localStorage, and IndexedDB. That is, it will finally do what users who previously disabled cookies *actually* wanted to do. This is our replacement for the previous tri-state cookie policy, which no longer makes sense now that we have ITP.