Florian Bruhin
a48ea597d0
Set websettings on each profile's setting object
...
Turns out QWebEngineSettings.globalSettings() only sets things on the default
profile. We now get everything from the default profile settings, but set it on
both the default and the private profile.
Fixes #2638
(cherry picked from commit b11a4388cd10b6ff2fd917fca689ebdc50d581ae)
2017-05-17 06:31:51 +02:00
Florian Bruhin
766a1ebb6d
Remove wrong private browsing assertion
...
This tried to assert that we never create a DiskCache object when private
browsing is turned on. However, when initializing, we still create a global
DiskCache, so this will hit when qutebrowser is started with private browsing
turned on via the config.
We could just not create the DiskCache at all when started in private browsing
mode, however we might still need it later when opening a non-private window.
2017-05-16 11:33:52 +02:00
Florian Bruhin
27aa40428e
Also make DownloadManager NAM private if private browsing is on
...
There's only one global DownloadManager with its own NAM (for downloads not
associated with a page). We can't really decide whether that should be private
or not, so as a best-effort approximation we simply make it private if private
browsing was turned on when starting qutebrowser.
2017-05-16 11:32:35 +02:00
Florian Bruhin
89dc8185b9
Fix lint
2017-05-16 09:08:59 +02:00
Florian Bruhin
1fcce6d87c
Change how error page retries work
...
A simple reload won't work when e.g. the renderer process crashed, so let's try
this instead.
Also, searchFor seemed to be unused.
2017-05-16 07:51:37 +02:00
Florian Bruhin
a4021e8e7a
Show error page for renderer process crashes on 5.9
...
Fixes #2291
2017-05-16 07:50:26 +02:00
Florian Bruhin
bdf56e63dd
Fix long line
2017-05-16 07:31:02 +02:00
Florian Bruhin
d0dd1644af
Set user agent correctly on QtWebEngine
2017-05-16 06:46:45 +02:00
Florian Bruhin
086139110d
Merge branch 'new-private-browsing'
2017-05-16 06:32:15 +02:00
Florian Bruhin
adb924a758
Use -p for :save-session --with-private
2017-05-16 06:28:21 +02:00
Florian Bruhin
658abf7b2b
Fix coverage on old Qt versions
2017-05-15 13:39:49 +02:00
Florian Bruhin
e13a5c0f17
Use a list for stylesheet flags
...
If we simply use sorted() on a dict, we define insert before private-command,
which means the statusbar isn't going to be green when in insert mode while
private browsing.
2017-05-15 11:07:43 +02:00
Florian Bruhin
3cdcc34d1d
Update private-browsing option description
2017-05-15 11:07:43 +02:00
Florian Bruhin
c4307c9f03
Fix lint
2017-05-15 11:07:43 +02:00
Florian Bruhin
f6fc2666ce
Generate stylesheet for statusbar
2017-05-15 11:07:43 +02:00
Florian Bruhin
73ca884d24
Add a setting for private command mode color
...
This also refactors how color properties are handled in StatusBar.
2017-05-15 11:07:43 +02:00
Florian Bruhin
3c3f695af4
Fix things pointed out in reviews
2017-05-15 11:07:43 +02:00
Florian Bruhin
6ee382ef30
Sort windows when saving sessions
...
This should help with flaky tests when the window order changes
2017-05-15 11:02:29 +02:00
Florian Bruhin
8993667479
Remove unused imports
2017-05-15 11:02:29 +02:00
Florian Bruhin
eda95d7926
Simplify window/private distinction in commands.py
2017-05-15 11:02:29 +02:00
Florian Bruhin
cde36f34b0
Remove QtWebKit-NG warnings
...
The next release will support private browsing, and we can't easily check the
version somehow.
2017-05-15 11:02:29 +02:00
Florian Bruhin
9805b43c85
Handle private browsing in sessions
2017-05-15 11:02:29 +02:00
Florian Bruhin
f907b6b6b0
Have an isolated command history for private windows
2017-05-15 11:02:26 +02:00
Florian Bruhin
dd675c4e8d
Set title for :view-source pages
2017-05-15 09:16:24 +02:00
Florian Bruhin
5b1d35bef9
Don't add data: URLs to history
2017-05-15 09:04:16 +02:00
Florian Bruhin
920dde4a68
Don't set an URL for :view-source tabs
...
Otherwise the page URL gets added to the history again with QtWebKit.
2017-05-15 09:03:45 +02:00
Anton Grensjö
47f391d38b
Set explicit=False for :navigate --tab
...
Related to #2624
2017-05-13 04:16:49 +02:00
Florian Bruhin
273749cce8
Don't set explicit=True for :tab-clone/:view-source
...
Fixes #2624
2017-05-12 22:27:24 +02:00
Florian Bruhin
17fdda6a5e
Check for href attribute in WebElement.is_link
...
Fixes #2619
2017-05-12 12:59:25 +02:00
Florian Bruhin
9e2aa65c02
Remove webelem.Group.prevnext
...
Apart from checking for buttons with an href attribute (which made no sense at
all and should never return any element) this was identical to
webelem.Group.links.
2017-05-12 09:41:12 +02:00
Florian Bruhin
203a5dff74
Get rid of webelem.FILTERS
...
There's actually no good reason to filter javascript links as we might want to
click them (or copy their URL) just like any other link - this fixes #2404 .
With that being gone, we don't need FILTERS at all anymore, as we can check for
existence of the href attribute in the CSS selector instead.
2017-05-12 09:41:12 +02:00
Florian Bruhin
c6e31391de
Fix most tests/lint
2017-05-10 09:19:24 +02:00
Florian Bruhin
f4d3f97cb7
Implement private browsing for QtWebEngine
2017-05-10 09:17:54 +02:00
Florian Bruhin
1c50377c0a
Initial work on new private browsing
2017-05-10 07:00:21 +02:00
Florian Bruhin
b91d4ee9c2
Clean up :debug-webaction
2017-05-09 22:02:30 +02:00
Florian Bruhin
822623f2ed
Finally update copyrights...
2017-05-09 21:37:03 +02:00
Florian Bruhin
905032924a
Remove search_displayed initialization in subclasses
...
We set this in BrowserTab anyways, and the value in WebKitTab was wrong.
2017-05-09 17:58:28 +02:00
Florian Bruhin
4b5e528d05
Add AbstractTab.key_press
2017-05-09 17:56:07 +02:00
Florian Bruhin
76fa126133
Simplify debug string
2017-05-09 17:55:51 +02:00
Florian Bruhin
e3eda28d88
Update docstrings
2017-05-09 17:52:13 +02:00
Jay Kamat
e10d636ca0
Fix a few small issues
...
- Remove an unused warnings
- Reverse if statement arguments to simplify logic
2017-05-09 08:08:05 -07:00
Jay Kamat
a3d41c0467
Refactor search method of AbstractBrowserTab into a field
2017-05-09 00:24:13 -07:00
Jay Kamat
d1aac9e9e9
Add docstrings to key_press methods
2017-05-08 23:43:21 -07:00
Jay Kamat
5bdd291d28
Refactor key_press into _repeated_key_press
...
Also split off generic key pressing ability from WebKitScroller to WebKitTab
2017-05-08 23:11:50 -07:00
Jay Kamat
63cffaf558
Refactor _key_press from WebEngineScroller to WebEngineTab
2017-05-08 22:49:14 -07:00
Jay Kamat
c9953b9f0d
Add support for follow_selected via fake-clicks
2017-05-08 22:31:29 -07:00
Jay Kamat
e07a1045a8
Add is_link method to webelem
2017-05-08 22:00:11 -07:00
Florian Bruhin
9db92de2d5
Add a no cover pragma for certificate error hashing
2017-05-09 06:15:21 +02:00
Florian Bruhin
90b0af97ce
Improve serialization crash check
...
It now works correctly with view-source URLs and is disabled on Qt 5.9.
Fixes #2289
See #2458
2017-05-03 23:15:17 +02:00
Florian Bruhin
ea2d5e97e2
Disable serialization crash check on Qt 5.9
2017-05-03 21:31:09 +02:00