Commit Graph

608 Commits

Author SHA1 Message Date
Vincent Sanders
75018632a9 Use coccinelle to change logging macro calls in c files
for F in $(git ls-files '*.c');do spatch --sp-file foo.cocci --in-place ${F};done

@@ expression E; @@
-LOG(E);
+NSLOG(netsurf, INFO, E);
@@ expression E, E1; @@
-LOG(E, E1);
+NSLOG(netsurf, INFO, E, E1);
@@ expression E, E1, E2; @@
-LOG(E, E1, E2);
+NSLOG(netsurf, INFO, E, E1, E2);
@@ expression E, E1, E2, E3; @@
-LOG(E, E1, E2, E3);
+NSLOG(netsurf, INFO, E, E1, E2, E3);
@@ expression E, E1, E2, E3, E4; @@
-LOG(E, E1, E2, E3, E4);
+NSLOG(netsurf, INFO, E, E1, E2, E3, E4);
@@ expression E, E1, E2, E3, E4, E5; @@
-LOG(E, E1, E2, E3, E4, E5);
+NSLOG(netsurf, INFO, E, E1, E2, E3, E4, E5);
@@ expression E, E1, E2, E3, E4, E5, E6; @@
-LOG(E, E1, E2, E3, E4, E5, E6);
+NSLOG(netsurf, INFO, E, E1, E2, E3, E4, E5, E6);
@@ expression E, E1, E2, E3, E4, E5, E6, E7; @@
-LOG(E, E1, E2, E3, E4, E5, E6, E7);
+NSLOG(netsurf, INFO, E, E1, E2, E3, E4, E5, E6, E7);
2017-09-06 18:45:27 +01:00
Michael Drake
7385f74141 Browser favicon: Handle errorcode in the hlcache callback. 2017-08-28 11:04:42 +01:00
Vincent Sanders
703427a486 Update documentation removing junk and moving to markdown for most text files 2017-06-09 17:30:00 +01:00
Vincent Sanders
87066f9f8d simplify the browser window operations by removing scroll API
The browser window scrollingAPI was duplicated in window operation
table, this simplifies it to a single set_scroll API.
2017-04-26 20:48:54 +01:00
Vincent Sanders
bd932d958b remove reformat from browser window operation table
the reformat callback was completely unecessary and implementations
appeared potentialy buggy. This rationalises the API and reduces the
number of operations a frontend must provide.
2017-04-26 09:43:18 +01:00
Vincent Sanders
14bff8d023 replace redraw and update methods with invalidate in window table API 2017-04-19 16:23:08 +01:00
Vincent Sanders
0a8976156a split out browser window drag context into separate structure 2017-03-03 14:45:39 +00:00
Vincent Sanders
6083de4ee1 split out browser windoe favicon context to separate structure 2017-03-03 14:45:39 +00:00
Vincent Sanders
855721282c split out status bar text cache into separate struct 2017-03-03 14:45:39 +00:00
Vincent Sanders
44c5aef1c8 make scrollbar redraw signal errors correctly
allow scrollbar redraw to return error codes and update documentation
commenst appropriately.
2017-03-01 23:30:29 +00:00
Vincent Sanders
7d660561cc Update knockout plotter to use new API 2017-02-11 13:57:06 +00:00
Vincent Sanders
3722ff8d86 Update all core use of plotters to new API 2017-02-11 13:55:41 +00:00
Vincent Sanders
012b797713 remove unecessary textinput header use from global history header 2016-06-30 15:40:10 +01:00
Vincent Sanders
c313524998 reduce curl usage to fetcher, url unescaping and time parsing 2016-06-29 23:06:53 +01:00
Vincent Sanders
8861923455 Allow include directories to be added by sub makefiles 2016-06-06 14:47:27 +01:00
Vincent Sanders
76a68d7dd0 Update content to split public and internal API 2016-06-06 09:01:38 +01:00
Vincent Sanders
667605869f move plotters header into public API 2016-05-30 21:05:57 +01:00
Vincent Sanders
7fc0a4c481 move desktop window header into public API 2016-05-30 17:32:57 +01:00
Vincent Sanders
fe7eb85614 move misc header into public API 2016-05-30 11:23:32 +01:00
Vincent Sanders
1eb86d9df2 move window header into public API 2016-05-30 11:01:40 +01:00
Vincent Sanders
6722943b81 move the CSS content handler 2016-05-26 11:18:41 +01:00
Vincent Sanders
6a36d4ec2b remove all core usage of warn_user API 2016-04-26 12:50:16 +01:00
Vincent Sanders
7ec49463da fix error reporting from frameset creation 2016-04-26 10:26:00 +01:00
Vincent Sanders
16dde3c704 make framebuffer use nsutils library monotonic times 2016-04-21 13:50:16 +01:00
Vincent Sanders
77a1b4b5e0 replace wallclock API usage with nsutils monitonic time 2016-04-21 13:12:56 +01:00
Vincent Sanders
392307bb1f reduce content header interdependancy 2016-04-18 23:04:16 +01:00
Vincent Sanders
33c7df0c40 complete the rename of the gui browser table
When the operations tables were created the browser table was renamed
to miscellaneous except the actual rename patch was never applied,
this fixes that situation.
2016-04-16 23:50:21 +01:00
Vincent Sanders
9faef114ec Update font interface documentation to include parameter direction 2016-03-22 17:52:24 +00:00
Michael Drake
0a3519fdac Remove torrent of logging during browser window resize. 2016-02-06 12:41:51 +00:00
Michael Drake
519775a65c Don't leak frame scrollbars. 2015-10-31 16:14:40 +00:00
Vincent Sanders
eb17f4ab37 Implement basic browsing context name property 2015-10-18 10:53:49 +01:00
Michael Drake
16fd36eb9d Proper error handling for JS context creation. 2015-08-13 12:23:59 +01:00
Michael Drake
c7a3229494 Can't tell if failure to create a JS context is an error or not.
It won't create one when built jsoff.
2015-08-13 11:59:43 +01:00
Michael Drake
379d97123a Handle failure to create new context. 2015-08-13 11:49:09 +01:00
Michael Drake
99765cf2d0 Remove TODO. 2015-08-13 09:48:09 +01:00
Michael Drake
2d53524635 Fix crash when JS context is required from a frame. 2015-08-13 09:39:04 +01:00
Vincent Sanders
c105738fa3 Change LOG() macro to be varadic
This changes the LOG macro to be varadic removing the need for all
callsites to have double bracketing and allows for future improvement
on how we use the logging macros.

The callsites were changed with coccinelle and the changes checked by
hand. Compile tested for several frontends but not all.

A formatting annotation has also been added which allows the compiler
to check the parameters and types passed to the logging.
2015-05-28 16:08:46 +01:00
Vincent Sanders
75d3fdc42e Convert RISC OS to use bitmap render operation 2015-04-24 23:49:49 +01:00
Vincent Sanders
cc11912da1 Convert framebuffer frontend to bitmap operations table. 2015-04-14 23:08:02 +01:00
Vincent Sanders
3ff4846c1a Remove usage of browser private interfaces
The cocoa frontend was directly acessing browser internals instead of
using the API. In the case of gui.m there was a check for the browser
window not being root (browser->parent != NULL) . As gui windows can
only ever be associated with the root brower window (i.e. its parent
will always be NULL) this was completely redundant.
2014-11-21 11:48:43 +00:00
Vincent Sanders
79e501075a make the form select menu API smaller.
By hiding all but the form selection menu option structure from code
outside of render this reduces the API to the absolute minimum to
support this feature.
2014-11-13 21:52:08 +00:00
Vincent Sanders
3405803280 Improve content encoding information API
Extend the content_get_encoding() API to retrieve the source of
the encoding as well as the actual encoding.
2014-11-07 12:33:34 +00:00
Vincent Sanders
8c2cfecfb5 Allow content handlers to have debug values set through API
Previously content handler debugging features were accessed by global
variables. This allows the setting of debugging parameters via a
content API giving per content control over debugging features.
Currently only used by the html content handler to toggle global
redraw debugging.
2014-11-06 22:51:46 +00:00
Vincent Sanders
46f369ca9e move themse install to its own header 2014-11-06 14:19:15 +00:00
Vincent Sanders
8ec7ad053a Make the fetching of a contents encoding generic.
The frontends previously had to use an html renderer API to get the
encoding of a content. This also required the explicit checking of the
contents type rather than using the existing content API to abstract
this knowledge.
2014-11-05 23:44:31 +00:00
Vincent Sanders
c14ddad660 change url setting api to take an nsurl instead of a text string 2014-11-02 22:30:45 +00:00
Vincent Sanders
c31c4babe1 Change contextual content retrieval to browser features.
Update the API which allows frontends to acquire the page features
(images, link urls or form elements) present at the given coordinates
within a browser window.

By making this an explicit browser_window API and using the browser.h
header for the associated data structure with a more appropriate API
naming the usage is much more obvious and contained.

Additionally the link url is now passed around as a nsurl stopping it
being converted from nsurl to text and back again several times.
2014-11-02 15:46:42 +00:00
Vincent Sanders
b1ee46cfb3 make adding a history entry return an error code.
This returns the error code to the caller instead of (sometimes)
warning the user directly.
2014-10-29 22:47:25 +00:00
Vincent Sanders
a221fa7213 Ensure browser window creation returns errors from common initialisation.
The browser window common initialisation code returns error codes which
were being ignored. The errors were additionally being reported via
warn_user in inappropriate places within browser history construction.
2014-10-29 22:29:06 +00:00
Vincent Sanders
7ace528729 Update url setting API to return nserror code instead of calling warn_user 2014-10-29 00:18:12 +00:00