comparison inkscape/firefox/content/madswatter.js @ 389:45e04408fc19

Implement stub functions for the MadSwatter integration.
author wycc
date Sun, 12 Apr 2009 11:58:53 +0800
parents
children ebf83a50e1e1
comparison
equal deleted inserted replaced
388:f3e6ac47752c 389:45e04408fc19
1 asdasd=1;
2 function MadSwatter(inkscape)
3 {
4 this.inkscape = inkscape;
5 }
6
7
8 function MadSwatter_callback(mbsvg,self)
9 {
10
11 $(self.inkscape.mbsvg.doc).find("channels").replaceWith(mbsvg.find("channels"));
12 $('#display').tabs('select',0);
13 //self.inkscape.updateDocument();
14 }
15
16 MadSwatter.prototype.edit=function()
17 {
18 // Generate a new document with the current scene
19 // FIXME: Do we need to do animation filter here?
20 // FIXME: Do we need to support hiearchical animation?
21 $('#display').tabs('select',2);
22 var kk = this.inkscape.mbsvg.generateCurrentSVG();
23 //MadSwatter_invoke(kk,MadSwatter_callback,this);
24 // Simulate the MadSwatter
25 kk.find("metadata").append("<channels></channels>");
26 setTimeout(function () { MadSwatter_callback(kk,this);}, 3000);
27 }