Commit Graph

199 Commits

Author SHA1 Message Date
Florian Bruhin
a1a5885367 Set parents for tab sub-objects 2018-06-12 14:09:06 +02:00
Florian Bruhin
8964845c18 Remove unused import 2018-06-11 15:30:01 +02:00
Florian Bruhin
6e23a6b958 Merge remote-tracking branch 'origin/pr/3654' 2018-06-11 14:56:32 +02:00
Florian Bruhin
a1fcdbcfd1 Move muted/audible API to own ".audio" object 2018-06-11 12:12:37 +02:00
Florian Bruhin
1c8d470bd7 Merge remote-tracking branch 'origin/pr/3908' 2018-06-11 12:06:09 +02:00
Florian Bruhin
cf8dbd8bfd Move pressing Enter into a method 2018-06-11 11:35:16 +02:00
Jay Kamat
315ed519ee
Use ctrl-enter in all cases 2018-06-10 16:27:56 -07:00
Jay Kamat
de127497a2
Press enter to follow links instead of using js
This codepath may trigger a crash which was fixed by
0e75f3272d.
However, this commit does not make it more likely to happen, and this
patch was backported into arch (at least).

In the future, we may be able to use <enter> on qtwebkit with js,
without triggering this crash
2018-06-09 15:42:44 -07:00
Jay Kamat
c33a887b2d
Add support for following tab selected elements to :follow-selected 2018-05-25 12:39:36 -07:00
Jay Kamat
ae04da7b78
Upgrade indicator to show recentlyAudible status 2018-05-09 18:57:53 -07:00
Jay Kamat
7a297e2e3f
Add support for muting tabs 2018-05-09 18:28:05 -07:00
Florian Bruhin
f5d7605ae0 Add a :scroll-to-anchor command
Fixes #2784
2018-03-19 19:18:33 +01:00
Florian Bruhin
e50068021d Use signals to update statusbar in caret mode
This means we don't use objreg anymore to get the status bar, and also makes the
bar more accurately reflect reality.

See #3583
2018-03-19 18:44:06 +01:00
Florian Bruhin
f7074b80d0 Fix lint 2018-03-16 09:07:25 +01:00
Florian Bruhin
6f8eb419ae Emit predicted_navigation when loading sessions
This avoids reloads (because of changed settings) after a session has been
loaded.

Related to #3718
2018-03-15 14:51:36 +01:00
Florian Bruhin
a22f973c99 Don't emit predicted_navigation for reloads at all
When we reload a page because of a config change, we won't get another
titleChanged signal (at least sometimes).

Also, the predicted_navigation signal is worthless when reloading anyways, as
we're going to load the same URL and not something different.

Fixes #3718
2018-03-14 18:19:11 +01:00
Markus Ongyerth
40364ce774 view-source pygments feedback pass 2018-03-13 12:40:51 +01:00
Florian Bruhin
1c9598d2c0 Don't emit predicted_navigation with invalid URLs
Fixes #3706
2018-03-13 09:46:09 +01:00
Florian Bruhin
87c6644751 Add predicted_navigation for reload()
This should avoid a double-reload for 'tsh' etc.
2018-03-07 23:54:58 +01:00
Florian Bruhin
9320214429 Only clear favicons on load with QtWebKit
QtWebEngine seems to automatically clear the favicon when loading e.g.
about:blank, and not clearing it there again fixes #3469.
Original issue: #187
2018-03-05 18:29:01 +01:00
Florian Bruhin
6fc560fc78 Rewrite comment 2018-03-02 06:31:23 +01:00
Jay Kamat
a2b5bf0b73
Clear old search results on webkit
Fixes an issue with #3626
2018-03-01 16:15:38 -05:00
Markus Ongyerth
f7bcdfc818 Add --pygment argument to view-source
The --pygment argument allows to use the pygment version of view-source
over the qtwebengine internal one.
This version is slightly different in what's processed before the site
is generated, so some javascript created texts can be available.
2018-02-28 16:53:28 +01:00
Florian Bruhin
de0aa32c11 Merge remote-tracking branch 'origin/pr/3626' 2018-02-26 07:20:34 +01:00
Jay Kamat
7a8fa5f46e
Implement deduplication of searches on webkit 2018-02-25 18:40:16 -05:00
Florian Bruhin
52b5492c6a Merge branch 'per-url' 2018-02-25 19:44:51 +01:00
Florian Bruhin
eade305965 Add a predicted_navigation signal
This is emitted when we know that we're going to visit some URL, but Qt doesn't
know yet. This way, we can change the settings early, and since we know which
settings have actually changed, prevent a change needing a reload in
_on_navigation_request.
2018-02-25 15:04:04 +01:00
Florian Bruhin
3956f81e73 Refactor websettings
This refactors the whole web(kit|engine|) settings mess a bit so there's a
Web(Kit|Engine)Settings object for (non-static) settings set on a
QWeb(Engine)Settings object in Qt. Everything else is set on module-level a bit
less declaratively.

The whole inheritance mess is gone, and we can now also construct a
Web(Kit|Engine)Settings object for a given tab.

Fixes #2701
2018-02-23 09:51:28 +01:00
Florian Bruhin
5fbd488fdf Only change settings for main-frame navigations 2018-02-20 22:45:29 +01:00
Florian Bruhin
f2bba2e4fa Fix navigation handling 2018-02-20 12:30:41 +01:00
Florian Bruhin
8b666d2d2e Try to update settings in acceptNavigationRequest
This still doesn't seem to update them early enough?
2018-02-19 22:08:42 +01:00
Florian Bruhin
7c1fb1d215 Refactor acceptNavigationRequest handling to use signals 2018-02-19 22:07:53 +01:00
Florian Bruhin
74a7676111 Fix issues with per-domain proof-of-concept 2018-02-19 22:07:53 +01:00
Florian Bruhin
5e50824042 Broken per-URL proof-of-concept 2018-02-19 22:07:53 +01:00
Jay Kamat
6eeacfe82b
Fix caret being cleared when leaving any mode 2018-02-13 09:27:15 -05:00
Florian Bruhin
772f0025f1 Clean up netrc support 2018-02-11 10:29:02 +01:00
Marc Jauvin
e8cc74f499
Merge branch 'master' into issue#2785 2018-02-10 08:17:47 -05:00
Marc Jauvin
d88a13598a syntax improvements and use real class attributes 2018-02-09 17:14:40 -05:00
Florian Bruhin
ce8d15d2b0 Simplify selection handling and remove QUTE_SELECTED_HTML
It was broken at least since caret support was introduced and it was only
available for QtWebKit anyways, so let's just drop it. This also makes the tab
API a bit simpler.
2018-02-06 22:48:00 +01:00
Florian Bruhin
16375f20d5 Always use JavaScript to get selection
It looks like getting the selection via the widget has issues even with Qt 5.10.

On Windows, we always get wrong results.

On Linux, it seems to be flaky. I first thought this was because of a race
between JavaScript setting the selection and Qt getting it, as now we don't use
JS to get the selection anymore, so it's possible that we get it before the
older JS code finished running. However, even calling selectedText() from a JS
callback didn't seem to help...

Since has_selection also is flawed and it taking a callback would make code more
complex as well, let's just assume there is a selection if the text is not
empty. In fact, that is exactly what QtWebEngine does for hasSelection anyways!

Fixes #3523
2018-02-06 21:58:31 +01:00
Florian Bruhin
6f028e9ad0 Update copyright years 2018-02-05 12:19:50 +01:00
Florian Bruhin
24cc54a574 Simplify initializing of AbstractTab subclasses
If we already pass the tab object, no need to pass the window ID separately.
2018-01-26 09:47:26 +01:00
Marc Jauvin
d2287b7a2e move backend specific code out of AbstractTab into respective backend
classes.
2018-01-25 22:38:25 -05:00
Marc Jauvin
88ff0c0425 url_str -> urlstr: urlstr used accross the codebase, more consistent 2018-01-25 18:01:43 -05:00
Marc Jauvin
bb8bc7ea3c fix test related to view-source
remove pygment title
remove view-source from history
2018-01-25 15:17:03 -05:00
Marc Jauvin
eb888cc8d7 fix latest change requests 2018-01-25 13:35:23 -05:00
Marc Jauvin
d7c51f7fc4 implement requested changes for PR #3521. 2018-01-24 18:04:05 -05:00
Marc Jauvin
2e912eeadf move backend dependent code to AbstractAction respective classes 2018-01-23 23:30:22 -05:00
Artur Shaik
5605d3cd8e
Merge branch 'master' into webengine_caret 2017-12-28 20:43:31 +06:00
Florian Bruhin
3f9ded3bed Add missing docstrings 2017-12-15 13:55:06 +01:00