Mercurial > MadButterfly
annotate inkscape/firefox/inkscape-mb-patch.diff @ 1206:1d476b35dc79
Merge and move code of tracking max frame number to MBScene_dom_monitor
author | Thinker K.F. Li <thinker@codemud.net> |
---|---|
date | Tue, 04 Jan 2011 10:08:02 +0800 |
parents | 63aaf96209cd |
children |
rev | line source |
---|---|
339
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
1 diff -cr inkscape-0.46/share/ui/menus-bars.xml inkscape-0.46-mb/share/ui/menus-bars.xml |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
2 *** inkscape-0.46/share/ui/menus-bars.xml 2008-03-11 12:21:15.000000000 +0800 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
3 --- inkscape-0.46-mb/share/ui/menus-bars.xml 2009-01-18 12:09:57.000000000 +0800 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
4 *************** |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
5 *** 22,27 **** |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
6 --- 22,28 ---- |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
7 <menuitem action='InkscapePreferences'/> |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
8 <separator/> |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
9 <menuitem action='Close'/> |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
10 + <menuitem action='EffectMadButterfly'/> |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
11 <menuitem action='Quit'/> |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
12 </menu> |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
13 <menu action='MenuEdit'> |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
14 diff -cr inkscape-0.46/src/dom/io/uristream.cpp inkscape-0.46-mb/src/dom/io/uristream.cpp |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
15 *** inkscape-0.46/src/dom/io/uristream.cpp 2008-03-11 12:19:31.000000000 +0800 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
16 --- inkscape-0.46-mb/src/dom/io/uristream.cpp 2008-11-04 23:08:25.000000000 +0800 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
17 *************** |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
18 *** 39,45 **** |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
19 * Released under GNU GPL, read the file 'COPYING' for more information |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
20 */ |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
21 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
22 ! |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
23 #include "uristream.h" |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
24 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
25 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
26 --- 39,45 ---- |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
27 * Released under GNU GPL, read the file 'COPYING' for more information |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
28 */ |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
29 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
30 ! #include <string.h> |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
31 #include "uristream.h" |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
32 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
33 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
34 diff -cr inkscape-0.46/src/extension/effect.cpp inkscape-0.46-mb/src/extension/effect.cpp |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
35 *** inkscape-0.46/src/extension/effect.cpp 2008-03-11 12:20:24.000000000 +0800 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
36 --- inkscape-0.46-mb/src/extension/effect.cpp 2009-01-18 10:54:48.000000000 +0800 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
37 *************** |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
38 *** 27,32 **** |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
39 --- 27,35 ---- |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
40 namespace Extension { |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
41 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
42 Effect * Effect::_last_effect = NULL; |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
43 + #ifdef CONF_MADBUTTERFLY |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
44 + Effect * Effect::MadButterflyEffect = NULL; |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
45 + #endif |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
46 Inkscape::XML::Node * Effect::_effects_list = NULL; |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
47 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
48 Effect::Effect (Inkscape::XML::Node * in_repr, Implementation::Implementation * in_imp) |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
49 *************** |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
50 *** 44,49 **** |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
51 --- 47,58 ---- |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
52 if (!strcmp(this->get_id(), "org.inkscape.filter.dropshadow")) |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
53 return; |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
54 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
55 + #ifdef CONF_MADBUTTERFLY |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
56 + if (!strcmp(this->get_id(),"net.sourceforge.madbutterfly.filter.update")) { |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
57 + MadButterflyEffect = this; |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
58 + } |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
59 + #endif |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
60 + |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
61 bool hidden = false; |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
62 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
63 no_doc = false; |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
64 diff -cr inkscape-0.46/src/extension/effect.h inkscape-0.46-mb/src/extension/effect.h |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
65 *** inkscape-0.46/src/extension/effect.h 2008-03-11 12:20:18.000000000 +0800 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
66 --- inkscape-0.46-mb/src/extension/effect.h 2009-01-18 09:51:23.000000000 +0800 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
67 *************** |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
68 *** 40,45 **** |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
69 --- 40,48 ---- |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
70 /** \brief This is the last effect that was used. This is used in |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
71 a menu item to rapidly recall the same effect. */ |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
72 static Effect * _last_effect; |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
73 + #ifdef CONF_MADBUTTERFLY |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
74 + static Effect * MadButterflyEffect; |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
75 + #endif |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
76 /** \brief The location of the effects menu on the menu structure |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
77 XML file. This is saved so it only has to be discovered |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
78 once. */ |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
79 *************** |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
80 *** 120,125 **** |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
81 --- 123,131 ---- |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
82 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
83 /** \brief Static function to get the last effect used */ |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
84 static Effect * get_last_effect (void) { return _last_effect; }; |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
85 + #ifdef CONF_MADBUTTERFLY |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
86 + static Effect * get_madbutterfly_effect (void) { return MadButterflyEffect; }; |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
87 + #endif |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
88 static void set_last_effect (Effect * in_effect); |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
89 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
90 static void place_menus (void); |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
91 diff -cr inkscape-0.46/src/extension/init.cpp inkscape-0.46-mb/src/extension/init.cpp |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
92 *** inkscape-0.46/src/extension/init.cpp 2008-03-11 12:20:24.000000000 +0800 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
93 --- inkscape-0.46-mb/src/extension/init.cpp 2009-01-18 10:16:51.000000000 +0800 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
94 *************** |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
95 *** 97,103 **** |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
96 #include "internal/bitmap/unsharpmask.h" |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
97 #include "internal/bitmap/wave.h" |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
98 #endif /* WITH_IMAGE_MAGICK */ |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
99 ! |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
100 extern gboolean inkscape_app_use_gui( Inkscape::Application const *app ); |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
101 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
102 namespace Inkscape { |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
103 --- 97,103 ---- |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
104 #include "internal/bitmap/unsharpmask.h" |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
105 #include "internal/bitmap/wave.h" |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
106 #endif /* WITH_IMAGE_MAGICK */ |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
107 ! #include "effect.h" |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
108 extern gboolean inkscape_app_use_gui( Inkscape::Application const *app ); |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
109 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
110 namespace Inkscape { |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
111 diff -cr inkscape-0.46/src/inkscape.cpp inkscape-0.46-mb/src/inkscape.cpp |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
112 *** inkscape-0.46/src/inkscape.cpp 2008-03-11 12:20:05.000000000 +0800 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
113 --- inkscape-0.46-mb/src/inkscape.cpp 2009-01-21 23:48:17.000000000 +0800 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
114 *************** |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
115 *** 61,66 **** |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
116 --- 61,68 ---- |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
117 #include "prefs-utils.h" |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
118 #include "xml/repr.h" |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
119 #include "io/sys.h" |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
120 + #include "verbs.h" |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
121 + #include "helper/action.h" |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
122 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
123 #include "extension/init.h" |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
124 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
125 *************** |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
126 *** 577,582 **** |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
127 --- 579,596 ---- |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
128 } |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
129 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
130 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
131 + #ifdef CONF_MADBUTTERFLY |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
132 + void |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
133 + inkscape_int_handler(int signo) |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
134 + { |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
135 + SPDesktop *desk = inkscape_active_desktop(); |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
136 + Inkscape::Verb *v = Inkscape::Verb::get(SP_VERB_EFFECT_MADBUTTERFLY); |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
137 + SPAction *act = v->get_action(desk); |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
138 + if (act) |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
139 + sp_action_perform(act,NULL); |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
140 + signal(SIGINT, inkscape_int_handler); |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
141 + } |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
142 + #endif |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
143 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
144 void |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
145 inkscape_application_init (const gchar *argv0, gboolean use_gui) |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
146 *************** |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
147 *** 591,596 **** |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
148 --- 605,613 ---- |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
149 #ifndef WIN32 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
150 bus_handler = signal (SIGBUS, inkscape_crash_handler); |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
151 #endif |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
152 + //#ifdef CONF_MADBUTTERFLY |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
153 + signal(SIGUSR2, inkscape_int_handler); |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
154 + //#endif |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
155 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
156 inkscape->use_gui = use_gui; |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
157 inkscape->argv0 = g_strdup(argv0); |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
158 diff -cr inkscape-0.46/src/verbs.cpp inkscape-0.46-mb/src/verbs.cpp |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
159 *** inkscape-0.46/src/verbs.cpp 2008-03-11 12:20:07.000000000 +0800 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
160 --- inkscape-0.46-mb/src/verbs.cpp 2009-01-18 12:04:40.000000000 +0800 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
161 *************** |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
162 *** 1903,1908 **** |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
163 --- 1903,1974 ---- |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
164 SPActionEventVector TextVerb::vector = |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
165 {{NULL},TextVerb::perform, NULL, NULL, NULL, NULL}; |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
166 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
167 + #ifdef CONF_MADBUTTERFLY |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
168 + /* *********** Effect MadButterfly ********** */ |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
169 + |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
170 + /** \brief A class to represent the last effect issued */ |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
171 + class EffectMadButterflyVerb : public Verb { |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
172 + private: |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
173 + static void perform(SPAction *action, void *mydata, void *otherdata); |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
174 + static SPActionEventVector vector; |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
175 + protected: |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
176 + virtual SPAction *make_action(Inkscape::UI::View::View *view); |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
177 + public: |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
178 + /** \brief Use the Verb initializer with the same parameters. */ |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
179 + EffectMadButterflyVerb(unsigned int const code, |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
180 + gchar const *id, |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
181 + gchar const *name, |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
182 + gchar const *tip, |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
183 + gchar const *image) : |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
184 + Verb(code, id, name, tip, image) |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
185 + { |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
186 + set_default_sensitive(false); |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
187 + } |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
188 + }; /* EffectMadButterflyVerb class */ |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
189 + |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
190 + /** |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
191 + * The vector to attach in the last effect verb. |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
192 + */ |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
193 + SPActionEventVector EffectMadButterflyVerb::vector = |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
194 + {{NULL},EffectMadButterflyVerb::perform, NULL, NULL, NULL, NULL}; |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
195 + |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
196 + /** \brief Create an action for a \c EffectLastVerb |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
197 + \param view Which view the action should be created for |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
198 + \return The built action. |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
199 + |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
200 + Calls \c make_action_helper with the \c vector. |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
201 + */ |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
202 + SPAction * |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
203 + EffectMadButterflyVerb::make_action(Inkscape::UI::View::View *view) |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
204 + { |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
205 + return make_action_helper(view, &vector); |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
206 + } |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
207 + |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
208 + /** \brief Decode the verb code and take appropriate action */ |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
209 + void |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
210 + EffectMadButterflyVerb::perform(SPAction *action, void *data, void */*pdata*/) |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
211 + { |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
212 + /* These aren't used, but are here to remind people not to use |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
213 + the CURRENT_DOCUMENT macros unless they really have to. */ |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
214 + Inkscape::UI::View::View *current_view = sp_action_get_view(action); |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
215 + // SPDocument *current_document = SP_VIEW_DOCUMENT(current_view); |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
216 + Inkscape::Extension::Effect *effect = Inkscape::Extension::Effect::get_madbutterfly_effect(); |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
217 + |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
218 + if (effect == NULL) return; |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
219 + if (current_view == NULL) return; |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
220 + |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
221 + switch ((long) data) { |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
222 + case SP_VERB_EFFECT_MADBUTTERFLY: |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
223 + effect->effect(current_view); |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
224 + break; |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
225 + default: |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
226 + return; |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
227 + } |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
228 + |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
229 + return; |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
230 + } |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
231 + /* *********** End Effect MadButterfly ********** */ |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
232 + #endif |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
233 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
234 /* *********** Effect Last ********** */ |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
235 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
236 *************** |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
237 *** 2570,2575 **** |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
238 --- 2636,2645 ---- |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
239 N_("Repeat the last effect with the same settings"), NULL), |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
240 new EffectLastVerb(SP_VERB_EFFECT_LAST_PREF, "EffectLastPref", N_("Previous Effect Settings..."), |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
241 N_("Repeat the last effect with new settings"), NULL), |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
242 + //#ifdef CONF_MADBUTTERFLY |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
243 + new EffectMadButterflyVerb(SP_VERB_EFFECT_MADBUTTERFLY, "EffectMadButterfly", N_("Effect for MadButterfly"), |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
244 + N_("For MadButterfly integration"), NULL), |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
245 + //#endif |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
246 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
247 /* Fit Page */ |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
248 new FitCanvasVerb(SP_VERB_FIT_CANVAS_TO_SELECTION, "FitCanvasToSelection", N_("Fit Page to Selection"), |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
249 diff -cr inkscape-0.46/src/verbs.h inkscape-0.46-mb/src/verbs.h |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
250 *** inkscape-0.46/src/verbs.h 2008-03-11 12:20:28.000000000 +0800 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
251 --- inkscape-0.46-mb/src/verbs.h 2009-01-18 00:37:43.000000000 +0800 |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
252 *************** |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
253 *** 23,29 **** |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
254 #include "helper/helper-forward.h" |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
255 #include "forward.h" |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
256 #include <glibmm/ustring.h> |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
257 ! |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
258 /** \brief This anonymous enum is used to provide a list of the Verbs |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
259 which are defined staticly in the verb files. There may be |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
260 other verbs which are defined dynamically also. */ |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
261 --- 23,29 ---- |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
262 #include "helper/helper-forward.h" |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
263 #include "forward.h" |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
264 #include <glibmm/ustring.h> |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
265 ! #define CONF_MADBUTTERFLY |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
266 /** \brief This anonymous enum is used to provide a list of the Verbs |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
267 which are defined staticly in the verb files. There may be |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
268 other verbs which are defined dynamically also. */ |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
269 *************** |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
270 *** 246,251 **** |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
271 --- 246,252 ---- |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
272 /* Effects */ |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
273 SP_VERB_EFFECT_LAST, |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
274 SP_VERB_EFFECT_LAST_PREF, |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
275 + SP_VERB_EFFECT_MADBUTTERFLY, |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
276 /* Fit Canvas */ |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
277 SP_VERB_FIT_CANVAS_TO_SELECTION, |
63aaf96209cd
* Move location of files so that we can produce XPI file from them.
wycc
parents:
diff
changeset
|
278 SP_VERB_FIT_CANVAS_TO_DRAWING, |