summaryrefslogtreecommitdiff
path: root/render
Commit message (Collapse)AuthorAgeFilesLines
...
* Spaces to tabs.Michael Drake2016-01-291-1/+1
|
* Add comment on on-demand JS context creation safetyMichael Drake2016-01-211-0/+3
| | | | Checking for enable_scripting isn't needed here.
* Ensure we do on-demand JS context creation only when JS is enabled.Michael Drake2016-01-211-13/+16
| | | | | | | | | | | An alternative approach which may be better would be to create the JavaScript context when the html_content is created, rather than on demand. This code checks for the JS context and creates one every time we add a node to the DOM. So when JS is on, every doc with a single node in it has a JS context. This seems to make on-demand creation a redundant overhead.
* Fix place where we're calling a js_* fn without checking for context.Michael Drake2016-01-211-1/+3
|
* Ensure constant javascript_enabled for HTML contents.Michael Drake2016-01-213-4/+8
| | | | | | | | | | | | | | | | Now we take the value of the javascript_enabled option when the content is created. We then use the content's script_enabled boolean everywhere else. This prevents us getting inconsistent values for javascript_enabled if a user toggles the setting while a page is loading. It was read frequently during box construction, and also the parser's script enabled setting could change where we handled a change of encoding. Now we only care about the setting of the javascript_enabled option at time of html_content creation.
* Pass html_content to box_extract_link.Michael Drake2016-01-213-15/+18
|
* Simplify place_float_below loop condition.Michael Drake2016-01-211-1/+1
|
* Make use of cached place float below value earlier.Michael Drake2016-01-201-1/+5
|
* Cache place below level, to avoid pointless calls to find_sides.Michael Drake2016-01-203-1/+12
|
* Optimise white hot find_sides to take advantage of sorted float_children.Michael Drake2016-01-201-1/+7
| | | | | Now we have an early exit when we get to the floats above the area we're interested in.
* Sort float_children of containers by their bottom edge.Michael Drake2016-01-201-2/+27
|
* Split adding float to a container out into separate function.Michael Drake2016-01-201-10/+14
|
* Remove redundant condition in white hot path.Michael Drake2016-01-201-1/+1
|
* Remove erroneous redeclaration of variable in new scope.Michael Drake2015-12-201-1/+0
|
* Make it clearer why we're asserting.Michael Drake2015-11-111-1/+2
|
* Only fire click event on button 1 press.Michael Drake2015-11-061-2/+1
|
* Assert that we have a node.Michael Drake2015-11-061-0/+1
|
* Always consider the root element's box.Michael Drake2015-11-061-5/+2
| | | | Previously we didn't consider it at all.
* Fix overflow-{x|y} handling.Michael Drake2015-11-011-3/+4
|
* Fix descendant bounding box calcs to work with overflow-{x|y}.Michael Drake2015-10-311-16/+16
|
* Don't call up if the parent's jscontext has gone NULL in the meantimeDaniel Silverstone2015-10-311-1/+1
|
* Change click handling to fire_dom_eventDaniel Silverstone2015-10-311-1/+1
|
* Add fire_dom_event, it's in a bad place but we can move it laterDaniel Silverstone2015-10-312-0/+42
|
* Shunt the handling of new elementsDaniel Silverstone2015-10-311-3/+4
|
* Initial work toward JS event supportDaniel Silverstone2015-10-311-0/+14
|
* Fix dom document leak for framesets.Michael Drake2015-10-311-0/+5
|
* Make nsurl utf8 string conversion function consistent with nsurl API.Michael Drake2015-10-251-1/+1
|
* Rework IDN URL retrieval to return an nserrorChris Young2015-10-241-6/+11
|
* Modify the status bar link text so it shows either the ASCII encoded or IDN ↵Chris Young2015-10-241-4/+15
| | | | | | | host, depending on the set option. Default is to display the encoded version as this provides some security making phishing domains more obvious, and a lot of our frontends are unable to display the full range of UTF-8 characters on the status bar. Displaying the decoded address in the URL bar requires frontends to be updated (GTK and Amiga done already), and the same caveats apply.
* ensure completion of async js scripts completes the fetchVincent Sanders2015-10-021-0/+7
| | | | | | When the fetch of asynchronous javascript scripts completed the completion of html rendering was not processed leaving the state machine waiting forever.
* fix gadget resource leak (coverity #1109875)Vincent Sanders2015-09-071-0/+1
|
* Rename context_menu.c and strip out all the context menu code, so this file ↵Chris Young2015-09-051-0/+1
| | | | and popupmenu.class is only used (optionally) for HTML form selection.
* Reorder percentage calculation.Michael Drake2015-08-241-2/+2
| | | | | | | | | Fixed point representation couldn't store 0.65 exactly, so avoid doing the divide by 100 first. I will look at moving this into libcss's fixed point header and doing it in a way that avoids arithmetic overflow, but for now this fixes el reg layout.
* It's not a hubbub errorDaniel Silverstone2015-08-121-1/+2
|
* Store the HTML content as userdata on the DOM's HTMLDocumentDaniel Silverstone2015-08-091-0/+53
|
* Only iterate the form when freeing a control if there is one.Daniel Silverstone2015-06-031-14/+16
| | | | This fixes Bug#2322
* fixup all the remaining logging macro callsitesVincent Sanders2015-05-281-1/+1
| | | | | The semantic patch tool appears to have missed some difficult to reason about callsites which have now been manually cleaned up
* Change LOG() macro to be varadicVincent Sanders2015-05-2815-242/+187
| | | | | | | | | | | | 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.
* put assert back to protect against bad logic in frontend drag implementationsVincent Sanders2015-05-081-0/+4
|
* remove assert if drag message contains an unknown type.Vincent Sanders2015-05-031-8/+12
| | | | | Instead of asserting if a message contains an unsupported drag type the message is now logged and ignored.
* Silence incorrect warning from gcc 4.9Vincent Sanders2015-05-031-9/+19
| | | | | | | This makes the box_move_xy function return a value on all code paths. This was not really necessary as there is an assert in the path that could have returned without a value. The gcc optimiser seems unable to reason about this in this case causing a warning.
* Ensure result of ftell is checked for errorsVincent Sanders2015-04-261-0/+6
| | | | | | | | The ftell call in the html renderer handling of drag and drop was not checking its return value for errors which could have resulted in attempting to read -1 bytes. coverity 1251038
* Remove duplicate branch in relative position handling.Michael Drake2015-04-231-5/+5
|
* Ensure we delink form controls when freeing themDaniel Silverstone2015-04-221-0/+19
|
* add some debug to form gadget freeingVincent Sanders2015-03-271-3/+10
| | | | | Serveral reports of form freeing segfaulting on RISC OS so this adds some debug in this area to see if we can tell why.
* To avoid namespace conflicts with ncurses add NetSurf key prefix.Witold Filipczyk2015-03-273-12/+12
| | | | Adds a NetSurf key code prefix of NS_ to all key codes.
* Forms: consider submit buttons successful. Fixes #2284.John-Mark Bell2015-03-101-2/+47
|
* Add invalidate API to html content script handling and use it.Vincent Sanders2015-03-093-25/+66
| | | | | | | | | | The html content script handling needs to invalidate its JavaScript context when the browsing context (browser_window) containing it is either closed or the content fetch is aborted (stopped) Previously the invalidation was only done on browser_window close which resulted in use after free crashes because of the now invalid JavaScript context.
* clear the html content reference to javascript context.Vincent Sanders2015-03-061-0/+8
| | | | | | | | | | | | When the browser window is about to be destroyed html_close gets called indicating the browser_window previously associated with the html content is about to become invalid. This makes the javascript context invalid within the html content (it is held by the browser window) when that context is about to be destroyed. Previously the javascript children would continue to attempt to use the context after it had been destroyed causing all sorts of strange errors and failures.
* Remove nsurl include.Michael Drake2015-02-261-3/+2
|