Commit Graph

2082 Commits

Author SHA1 Message Date
Michael Drake
c8efbbc206 Page info: We need a non-const browser window.
Due to where we pass it back out to browser window.
2020-02-24 19:17:27 +00:00
Vincent Sanders
1a25234f20 implement browser_window_show_certificates 2020-02-24 18:56:15 +00:00
Daniel Silverstone
40cb70b845
netsurf_init: Use disc_cache_path if specified, otherwise platform path
Signed-off-by: Daniel Silverstone <dsilvers@digital-scurf.org>
2020-02-24 15:37:11 +00:00
Daniel Silverstone
a8ffa12cdf
options: Add disc_cache_path option
Signed-off-by: Daniel Silverstone <dsilvers@digital-scurf.org>
2020-02-24 15:37:11 +00:00
Daniel Silverstone
50ff8433da
browser_window: Use messages for unknown errors
Signed-off-by: Daniel Silverstone <dsilvers@digital-scurf.org>
2020-02-24 09:47:23 +00:00
Michael Drake
21bbda23fa Browser window: Set the search string on show cookies.
We still need to tell the front end to open the cookies
window.
2020-02-24 08:55:26 +00:00
Michael Drake
214f436b07 Cookie manager: Add API to set the search string. 2020-02-24 08:49:50 +00:00
Michael Drake
34e61df8eb Treeview: Add API for setting the search string. 2020-02-24 08:44:52 +00:00
Daniel Silverstone
f3a0e9f0a1
browser_window: Various little SSL fixes
Signed-off-by: Daniel Silverstone <dsilvers@digital-scurf.org>
2020-02-23 22:32:58 +00:00
Michael Drake
494db4cd51 Page info: Fix typo. 2020-02-23 21:04:38 +00:00
Michael Drake
be659af7e5 Page info: Avoid anonymous union for AmigaOS3 and OpenBSD. 2020-02-23 20:23:00 +00:00
Michael Drake
66c069816a NetSurf: Init/fini the page-info module on browser startup/quit. 2020-02-23 17:38:14 +00:00
Michael Drake
0e4f09db0f Buildsystem: Build the page-info module. 2020-02-23 17:38:14 +00:00
Michael Drake
7a3f864940 Page info: Add core window size getter, and stub for keypresses. 2020-02-23 17:38:14 +00:00
Michael Drake
1149a1304d Page info: Implement mouse action handling. 2020-02-23 17:38:14 +00:00
Michael Drake
4b2697c989 Page info: Implement redraw. 2020-02-23 17:38:14 +00:00
Michael Drake
c32e1bb340 Page info: Implement page info window creation and destruction. 2020-02-23 17:38:14 +00:00
Michael Drake
3940918b68 Page info: Add data structures and module init/fini. 2020-02-23 17:38:14 +00:00
Michael Drake
9198c9958a Desktop: Add page-info API.
This will be a core window intended to show information about the
page currently shown in the associated browser window.
2020-02-23 17:38:14 +00:00
Michael Drake
a39b651620 Browser window: Add stubs for new interfaces for page-info dialogue. 2020-02-23 17:38:14 +00:00
Michael Drake
d23a7b4c8f Browser window: Constify bw through page_info_state getter. 2020-02-23 17:38:14 +00:00
Vincent Sanders
0c34d06494 Keep the complete certificate chain from a fetch
Instead of extracting information from the X509 certificate chain in
the fetcher the entire chain is propagated in Distinguished Encoding
Rules (DER) format.

This allows all the information contained in a certificate chain to be
retained which can subsequently be presented to the user
2020-02-23 16:23:50 +00:00
Daniel Silverstone
bc94555d9e
hotlist: Report if infallible destruction fails
Signed-off-by: Daniel Silverstone <dsilvers@digital-scurf.org>
2020-02-23 09:37:42 +00:00
Daniel Silverstone
1ecc36384d
browser_window: Propagate error code when handling errors
Signed-off-by: Daniel Silverstone <dsilvers@digital-scurf.org>
2020-02-23 09:20:05 +00:00
Michael Drake
727ff38647 Treeview: Constify clip rectangle. 2020-02-22 20:04:56 +00:00
Michael Drake
f39ce1a262 Browser window: Constify the bw in the URL access function. 2020-02-22 16:37:37 +00:00
Daniel Silverstone
277c1550f5
browser_window: Inform GUI about redirects and final URL
To correctly have the GUI know about all url bar updates, we
should inform it during the processing of redirects and we should
ensure that when we're in the ready-but-not-done phase we do not
use the fetch parameters but instead the content's known URL

Signed-off-by: Daniel Silverstone <dsilvers@digital-scurf.org>
2020-02-22 16:24:36 +00:00
Daniel Silverstone
0fa5f81a52
Browser: Support requesting location focus
In the creation of a browser window it may be valuable to request
that the GUI focus the location input box.  This can be used when
the user requests a new tab/window to allow the entry box to be
focussed properly immediately.

Signed-off-by: Daniel Silverstone <dsilvers@digital-scurf.org>
2020-02-22 15:10:51 +00:00
Daniel Silverstone
f3bdee255d
Browser: Add FOREGROUND flag to window creation
To better support new-tab / new-window operations as well as
GUIs which want to allow tabs to open in the background by default,
add a flag to request a new browser window be foregrounded.  This
will allow us to simplify at least the GTK frontend a little.

Signed-off-by: Daniel Silverstone <dsilvers@digital-scurf.org>
2020-02-22 11:41:15 +00:00
Michael Drake
9a98f19611 Core: Remove unused minimum GIF delay option. 2020-02-21 11:45:20 +00:00
Vincent Sanders
55ba27c68f re-order config include so strcasecmp is correctly detected on RISC OS/win32 2019-12-22 11:11:04 +00:00
Vincent Sanders
bacd8d229c make RISC OS specific window_screen_ options limited to that frontend 2019-12-20 12:59:28 +00:00
Daniel Silverstone
b9cb2cab0b
browser_window: Don't use the fetch parameters for page info
In order to cope with redirects properly, use the content's URL
not the fetch parameters.

Signed-off-by: Daniel Silverstone <dsilvers@digital-scurf.org>
2019-12-01 21:56:41 +00:00
Daniel Silverstone
c4919105ba
browser_window: Remove spurious stopping of throbber
Signed-off-by: Daniel Silverstone <dsilvers@digital-scurf.org>
2019-12-01 21:21:50 +00:00
Daniel Silverstone
b2f98e7092
browser_window: Dispatch page info notification on root browser
Signed-off-by: Daniel Silverstone <dsilvers@digital-scurf.org>
2019-12-01 18:38:51 +00:00
Daniel Silverstone
92caa16cfc
Add missing unrefs
Signed-off-by: Daniel Silverstone <dsilvers@digital-scurf.org>
2019-12-01 17:25:49 +00:00
Daniel Silverstone
7f628f7ee8
browser_window: Add an event for page info state change
Signed-off-by: Daniel Silverstone <dsilvers@digital-scurf.org>
2019-12-01 16:06:56 +00:00
Daniel Silverstone
6fc2666d07
Allow contents to indicate if they believe they may not be secure.
HTML contents reference many other objects.  The browser window
needs to know if any of them may not be secure, in which case it
needs to report that in its page state.  If other content types
might refer to sub-contents, they will need to define the callback
too.

Signed-off-by: Daniel Silverstone <dsilvers@digital-scurf.org>
2019-12-01 15:49:08 +00:00
Daniel Silverstone
9741df214d
browser_window: Add basic page info state and SSL accessors
In order to begin work on the page info dialog, we need access
to the current page's state and SSL chain if available.

Signed-off-by: Daniel Silverstone <dsilvers@digital-scurf.org>
2019-12-01 15:01:24 +00:00
Daniel Silverstone
0840613ac2
browser_window: Set referer and flags in ssl error pathway
To make the SSL error pathway consistent with the other error
pathways, set the referer and the fetch parameter flags the same
as the others.

Signed-off-by: Daniel Silverstone <dsilvers@digital-scurf.org>
2019-11-30 14:46:16 +00:00
Vincent Sanders
dae0ff3d26 remove warning callback from miscelaneous function table 2019-11-11 16:59:28 +00:00
Vincent Sanders
92fff918cc fix "may be used uninitialised" warning 2019-11-06 08:23:27 +00:00
Vincent Sanders
cbb0c05258 remove unecessary user warning calls and improve error propogation in html box 2019-11-05 23:05:42 +00:00
Vincent Sanders
78aa34e5d7 remove user warnings from hotlist load and curl poll 2019-11-05 00:07:06 +00:00
Vincent Sanders
7c63f5f66b improve error returns throughout complete save and remove user warnings 2019-11-04 23:39:13 +00:00
Vincent Sanders
4b0c3f0efe add internal query handler for fetch errors
Any errors from the fetch which are not already handled are
  reported with an internal query page instead of a modal
  dialog.

This is much less invasive for the user and much more in
  keeping with how this is handled by other browsers.

The handler is similar to the timeout handler but the
  functionality is kept separate as it is intended timeout
  handling be extended in future.
2019-10-30 18:56:38 +00:00
Vincent Sanders
76eac19227 add internal query page for request timeouts 2019-10-29 22:29:22 +00:00
Michael Drake
5aeca580f4 save complete: Change de-duplication to compare URLs, rather than contents.
We seem to have more than one content for the same resource.

For example:

* save `<img src="about:logo"><img src="about:logo">` as img-test.html
* run `rm -rf test-save && make && ./nsgtk img-test.html`
* ctrl+s
* save as "test-save" in the current netsurf dir.
* run `md5sum test-save/*`

before and after this commit.  The de-duplication works with URLs,
where it wasn't working with hlcache_handles or contents.
2019-10-26 12:51:17 +01:00
Michael Drake
044ddd5d43 save complete: ctx_find_content: compare contents, not hlcache_handles
There can be multiple hlcache_handles per sharable content.
2019-10-26 12:42:38 +01:00
Vincent Sanders
6e7f98787a ensure all error messages have text if not provided by caller 2019-10-25 21:43:19 +01:00