diff options
author | James Bursa <james@netsurf-browser.org> | 2005-04-13 21:58:28 +0000 |
---|---|---|
committer | James Bursa <james@netsurf-browser.org> | 2005-04-13 21:58:28 +0000 |
commit | 11bc5345c5faf42a5b99623ee24b1a91ca181fd6 (patch) | |
tree | b3dc1c7e1691ddf335a87643c35b8ad9f4ba1a84 /render/box.h | |
parent | 4ebe390f8d02013035fd884836dcb8a75ac5efbd (diff) | |
download | netsurf-11bc5345c5faf42a5b99623ee24b1a91ca181fd6.tar.gz netsurf-11bc5345c5faf42a5b99623ee24b1a91ca181fd6.tar.bz2 |
[project @ 2005-04-13 21:58:28 by bursa]
Add fallback field to struct box for object fallback content. Add some checks for tree consistency to box_dump(). Rename struct plugin_params to object_param. Clean up box_object(), box_embed(), box_iframe(), and box_image(). Implement object fallback to contents if the fetch or conversion fails.
svn path=/import/netsurf/; revision=1627
Diffstat (limited to 'render/box.h')
-rw-r--r-- | render/box.h | 43 |
1 files changed, 22 insertions, 21 deletions
diff --git a/render/box.h b/render/box.h index 8f55459ac..fe67e8fb3 100644 --- a/render/box.h +++ b/render/box.h @@ -81,6 +81,8 @@ struct box; struct column; struct css_style; +struct object_params; +struct object_param; /** Type of a struct box. */ @@ -92,27 +94,6 @@ typedef enum { BOX_INLINE_BLOCK, BOX_BR, BOX_TEXT } box_type; -/* parameters for <object> and related elements */ -struct object_params { - char* data; - char* type; - char* codetype; - char* codebase; - char* classid; - struct plugin_params* params; - /* not a parameter but stored here for convenience */ - char* basehref; - -}; - -struct plugin_params { - char* name; - char* value; - char* type; - char* valuetype; - struct plugin_params* next; -}; - /** Node in box tree. All dimensions are in pixels. */ struct box { /** Type of box. */ @@ -181,6 +162,7 @@ struct box { struct box *children; /**< First child box, or 0. */ struct box *last; /**< Last child box, or 0. */ struct box *parent; /**< Parent box, or 0. */ + struct box *fallback; /**< Fallback children for object, or 0. */ /** First float child box, or 0. Float boxes are in the tree twice, in * this list for the block box which defines the area for floats, and @@ -221,6 +203,25 @@ struct column { int max; }; +/** Parameters for <object> and similar elements. */ +struct object_params { + char *data; + char *type; + char *codetype; + char *codebase; + char *classid; + struct object_param *params; +}; + +/** Linked list of <object> parameters. */ +struct object_param { + char *name; + char *value; + char *type; + char *valuetype; + struct object_param *next; +}; + #define UNKNOWN_WIDTH INT_MAX #define UNKNOWN_MAX_WIDTH INT_MAX |