Commit Graph

73 Commits

Author SHA1 Message Date
Vincent Sanders b182cc7617 remove box handling from browser window 2020-05-25 20:37:06 +01:00
Vincent Sanders 5c02f9bd97 rename browser window internal redraw request function
remove confusing reference to boxes
2020-05-25 11:28:35 +01:00
Vincent Sanders e8d0ba15ad split html box processing code
reduce the module size of the html box handling code by
 splitting into smaller sections.

No functional code change.
2020-04-29 20:37:42 +01:00
Vincent Sanders 4ae27a6592 remove scaling from internal browser get_dimensions calls 2019-08-02 12:26:19 +01:00
Vincent Sanders 2a03ea3049 move html and text content handlers where they belong 2018-05-10 13:37:02 +01:00
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
Vincent Sanders 0a8976156a split out browser window drag context into separate structure 2017-03-03 14:45:39 +00:00
Vincent Sanders 76a68d7dd0 Update content to split public and internal API 2016-06-06 09:01:38 +01:00
Vincent Sanders 69cea38f41 update scrollbar_create error handling to return nserror 2016-04-26 12:14:56 +01:00
Vincent Sanders 7ec49463da fix error reporting from frameset creation 2016-04-26 10:26:00 +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 df8c6c3ad7 Avoid calling calloc with 0 length data.
CERT MEM04-C suggests that zero length allocations behaviour might be
surprising so it should be avoided. This adds a check to ensure a zero
length allocation will be avoided. Additionally it returns errors to
the caller rather than warning directly (in some error paths)
2014-11-10 15:09:57 +00:00
Vincent Sanders 7c4c73f1b0 Desktop doxygen fixes 2014-11-09 21:49:33 +00:00
Michael Drake eed2a97eca Add bw function to get scrollbar type. 2014-10-25 12:04:11 +01:00
Michael Drake a38a63a37e Make history internal to browser_window module. 2014-02-15 18:44:50 +00:00
Michael Drake 49bed056dd Make browser_window_navigate (un)verifiable flag match browser_window_create. 2014-02-10 22:40:04 +00:00
Michael Drake af014bce99 Allow tab creation without history clone. Changes browser_window_create and browser_window_navigate flags. 2014-02-10 14:08:45 +00:00
Vincent Sanders db33103fa3 clean up desktop/gui.h include usage 2014-01-29 21:35:53 +00:00
Michael Drake 3f45e53539 s/history_core/local_history/ 2013-07-10 11:55:42 +01:00
Michael Drake c2a718075a A load of refactoring of how content selection and input work.
Keypresses now go via content interface.
Contents don't shove the selection object into browser windows any more.
Contents report selection existence by sending message.
HTML content keeps track of where selections in it exist.
Contents report whether they have input focus via caret setting msg.
Caret can be hidden (can still input/paste) or removed.
Consolidate textarea selection handling.
Make textarea report its selection status changes to client.
Various textarea fixes.
Changed how we decide when to clear selections, and give focus.
2013-02-22 12:19:35 +00:00
Vincent Sanders 529ca251fc rename flags for browser_window routines to be shorter 2013-02-18 11:51:42 +00:00
Vincent Sanders 3bfb5b96a7 browser_window_navigate refactor 2013-02-18 11:23:27 +00:00
Michael Drake 153c444454 Move browser_window struct to private header. Places that shouldn't include it do, such as front end code.
Frontends that have been updated to build:
  framebuffer
  gtk
  monkey
  riscos

TODO:
  amiga
  atari
  beos
  cocoa
  windows
2012-08-22 12:22:58 +01:00
Michael Drake 35fd2ad7f2 Don't use GUI_POINTERs in content handlers. 2012-08-16 22:21:08 +01:00
Michael Drake 6daf6c178d Frame drag start function can take child bw. Don't need to get root bw in html handler. Avoids bw dereferences. 2012-08-16 16:14:15 +01:00
Michael Drake 195a77a4cd Make new function for starting a frames resize and use it. 2012-08-16 15:55:20 +01:00
Michael Drake c1be4c9e77 Formatting changes. 2012-08-16 15:47:14 +01:00
Michael Drake 7277ce5dfc Remove redundant "action" param. 2012-08-16 15:43:14 +01:00
Michael Drake 83c8e940f8 Don't pass status to frames handler. 2012-08-16 15:38:06 +01:00
Michael Drake 4872bc30b8 Remove redundant scrollbar widget message. 2012-08-16 13:13:25 +01:00
Daniel Silverstone a195282bfb Include render/box.h
svn path=/trunk/netsurf/; revision=13639
2012-03-24 22:29:31 +00:00
Daniel Silverstone d1194be49f Migrate frame types so that desktop/browser.h does not include render/html.h
svn path=/trunk/netsurf/; revision=13605
2012-03-24 17:09:21 +00:00
Michael Drake c08ee82076 Allow drag handlers to inform browser window layer of any pointer range constraints.
svn path=/trunk/netsurf/; revision=13394
2012-01-10 22:02:19 +00:00
Michael Drake 767f40dc72 Simplify frameset distribution calcs.
svn path=/trunk/netsurf/; revision=13376
2012-01-06 14:44:01 +00:00
Michael Drake 41ef599293 Fix frame dimension calculations when required sizes don't fit the available space.
svn path=/trunk/netsurf/; revision=13271
2011-12-14 18:31:57 +00:00
John Mark Bell f2993e6ed0 content_get_url -> hlcache_handle_get_url, content__get_url -> content_get_url
svn path=/trunk/netsurf/; revision=13236
2011-12-04 14:55:23 +00:00
Michael Drake e2a7600e9a Big wodge of internal browser window scroll fixes, or "rationalisation of browser window scrollbar handling".
svn path=/trunk/netsurf/; revision=13221
2011-12-02 16:10:13 +00:00
Michael Drake 898b01e721 More conversion to nsurl. (box->href, object params, imagemaps, (i)frames)
svn path=/trunk/netsurf/; revision=12933
2011-10-03 20:28:29 +00:00
Michael Drake 36eff6da2b Port more internals to nsurl. Front ends may need updating.
svn path=/trunk/netsurf/; revision=12926
2011-10-03 15:56:47 +00:00
Michael Drake 7bf7d2d745 Improve resizing frames.
svn path=/trunk/netsurf/; revision=12771
2011-09-07 12:27:37 +00:00
Michael Drake 33ebea90d5 Finish moving frame resizing over to new frame dimensions.
svn path=/trunk/netsurf/; revision=12749
2011-09-06 10:44:00 +00:00
Michael Drake 0401d52f51 Remove gui_window_frame_resize_start() functions.
svn path=/trunk/netsurf/; revision=12738
2011-09-05 15:35:34 +00:00
Michael Drake 19317c76ba Implement frames in the core.
svn path=/trunk/netsurf/; revision=12709
2011-09-04 17:24:45 +00:00
Michael Drake 9c91893028 Fix selection for non-gui browser windows (iframes).
Selection no longer uses current_redraw_browser.
Fix long-standing selection bugs on platforms that use action on release behaviour.

svn path=/trunk/netsurf/; revision=12598
2011-07-13 13:20:26 +00:00
Michael Drake 9f2ea3be4c Iframe scrollbars.
svn path=/trunk/netsurf/; revision=12571
2011-07-05 20:13:28 +00:00
Michael Drake c587cfe9de Iframes inherit parent browser window's scale.
svn path=/trunk/netsurf/; revision=12505
2011-06-24 13:05:57 +00:00
Michael Drake 5a4c8916ef If iframes are reformatted due to containing document reflow, don't need to redraw them since they will be redrawn when the containing document is redrawn. Make iframe handling more robust.
svn path=/trunk/netsurf/; revision=12497
2011-06-24 09:30:33 +00:00
Michael Drake 53f4da3420 First pass at core iframes. Currently lacking scrollbars.
svn path=/trunk/netsurf/; revision=12474
2011-06-14 20:00:18 +00:00
Michael Drake a79ef8cffb Remove redundant code.
svn path=/trunk/netsurf/; revision=12458
2011-06-04 14:38:50 +00:00
Vincent Sanders c7e943c7d2 check for dereference of teh right value
svn path=/trunk/netsurf/; revision=12424
2011-05-17 07:28:15 +00:00