summaryrefslogtreecommitdiff
path: root/amiga/download.c
diff options
context:
space:
mode:
authorChris Young <chris@unsatisfactorysoftware.co.uk>2009-05-19 07:23:56 +0000
committerChris Young <chris@unsatisfactorysoftware.co.uk>2009-05-19 07:23:56 +0000
commit6f120338edb03bbdf7224f1b4d5560caf61bb002 (patch)
tree90161e3be8f111dc224a0c1b0c98e61098abeee1 /amiga/download.c
parentefe2151c9a1d811b7b28d2f8c169688e7615ea11 (diff)
downloadnetsurf-6f120338edb03bbdf7224f1b4d5560caf61bb002.tar.gz
netsurf-6f120338edb03bbdf7224f1b4d5560caf61bb002.tar.bz2
Add ability to copy SVGs to the clipboard and save in IFF DR2D format.
svn path=/trunk/netsurf/; revision=7523
Diffstat (limited to 'amiga/download.c')
-rw-r--r--amiga/download.c16
1 files changed, 13 insertions, 3 deletions
diff --git a/amiga/download.c b/amiga/download.c
index fe9f370f5..5eeeccab1 100644
--- a/amiga/download.c
+++ b/amiga/download.c
@@ -31,6 +31,7 @@
#include "amiga/options.h"
#include "amiga/save_complete.h"
#include "amiga/bitmap.h"
+#include "amiga/iff_dr2d.h"
#include "content/fetch.h"
@@ -368,10 +369,19 @@ void ami_drag_save(struct Window *win)
case GUI_SAVE_OBJECT_NATIVE:
{
struct content *c = drag_save_data;
- c->bitmap->url = c->url;
- c->bitmap->title = c->title;
AddPart(path,c->title,1024);
- bitmap_save(c->bitmap,path,0);
+ if(c->bitmap)
+ {
+ c->bitmap->url = c->url;
+ c->bitmap->title = c->title;
+ bitmap_save(c->bitmap,path,0);
+ }
+#ifdef WITH_NS_SVG
+ else if(c->type == CONTENT_SVG)
+ {
+ ami_save_svg(c,path);
+ }
+#endif
}
break;
}