summaryrefslogtreecommitdiffstats
path: root/src/extension/implementation/script.h
diff options
context:
space:
mode:
authorLiam P. White <inkscapebrony@gmail.com>2014-08-18 20:19:55 +0000
committerLiam P. White <inkscapebrony@gmail.com>2014-08-18 20:19:55 +0000
commitdce3466274e04364e25c47b0b71007a65c9cf9dd (patch)
tree37d21bcfbc010d83221de713fb83d6e15e1546cf /src/extension/implementation/script.h
parentFix accidental regression in previous commit (diff)
downloadinkscape-dce3466274e04364e25c47b0b71007a65c9cf9dd.tar.gz
inkscape-dce3466274e04364e25c47b0b71007a65c9cf9dd.zip
Code cleanup.
(bzr r13341.1.145)
Diffstat (limited to 'src/extension/implementation/script.h')
-rw-r--r--src/extension/implementation/script.h80
1 files changed, 11 insertions, 69 deletions
diff --git a/src/extension/implementation/script.h b/src/extension/implementation/script.h
index 270c361af..6a7d0c3b8 100644
--- a/src/extension/implementation/script.h
+++ b/src/extension/implementation/script.h
@@ -22,81 +22,30 @@
namespace Inkscape {
namespace XML {
class Node;
-}
-}
+} // namespace XML
-
-namespace Inkscape {
namespace Extension {
namespace Implementation {
-
/**
* Utility class used for loading and launching script extensions
*/
class Script : public Implementation {
-
public:
- /**
- *
- */
Script(void);
-
- /**
- *
- */
virtual ~Script();
-
-
- /**
- *
- */
virtual bool load(Inkscape::Extension::Extension *module);
-
- /**
- *
- */
virtual void unload(Inkscape::Extension::Extension *module);
-
- /**
- *
- */
virtual bool check(Inkscape::Extension::Extension *module);
ImplementationDocumentCache * newDocCache(Inkscape::Extension::Extension * ext, Inkscape::UI::View::View * view);
- /**
- *
- */
- virtual Gtk::Widget *prefs_input(Inkscape::Extension::Input *module,
- gchar const *filename);
-
- /**
- *
- */
- virtual SPDocument *open(Inkscape::Extension::Input *module,
- gchar const *filename);
-
- /**
- *
- */
+ virtual Gtk::Widget *prefs_input(Inkscape::Extension::Input *module, gchar const *filename);
+ virtual SPDocument *open(Inkscape::Extension::Input *module, gchar const *filename);
virtual Gtk::Widget *prefs_output(Inkscape::Extension::Output *module);
-
- /**
- *
- */
- virtual void save(Inkscape::Extension::Output *module,
- SPDocument *doc,
- gchar const *filename);
-
- /**
- *
- */
- virtual void effect(Inkscape::Extension::Effect *module,
- Inkscape::UI::View::View *doc,
- ImplementationDocumentCache * docCache);
-
+ virtual void save(Inkscape::Extension::Output *module, SPDocument *doc, gchar const *filename);
+ virtual void effect(Inkscape::Extension::Effect *module, Inkscape::UI::View::View *doc, ImplementationDocumentCache * docCache);
virtual bool cancelProcessing (void);
private:
@@ -105,7 +54,7 @@ private:
Glib::RefPtr<Glib::MainLoop> _main_loop;
/**
- * The command that has been dirived from
+ * The command that has been derived from
* the configuration file with appropriate directories
*/
std::list<std::string> command;
@@ -117,13 +66,10 @@ private:
*/
Glib::ustring helper_extension;
- std::string solve_reldir (Inkscape::XML::Node *reprin);
- bool check_existence (const std::string &command);
- void copy_doc (Inkscape::XML::Node * olddoc,
- Inkscape::XML::Node * newdoc);
- void checkStderr (const Glib::ustring &filename,
- Gtk::MessageType type,
- const Glib::ustring &message);
+ std::string solve_reldir(Inkscape::XML::Node *repr_in);
+ bool check_existence (std::string const& command);
+ void copy_doc(Inkscape::XML::Node * olddoc, Inkscape::XML::Node * newdoc);
+ void checkStderr (Glib::ustring const& filename, Gtk::MessageType type, Glib::ustring const& message);
class file_listener {
Glib::ustring _string;
@@ -140,6 +86,7 @@ private:
bool isDead () { return _dead; }
+ // TODO move these definitions into script.cpp
void init (int fd, Glib::RefPtr<Glib::MainLoop> main) {
_channel = Glib::IOChannel::create_from_fd(fd);
_channel->set_encoding();
@@ -202,11 +149,6 @@ private:
std::string resolveInterpreterExecutable(const Glib::ustring &interpNameArg);
}; // class Script
-
-
-
-
-
} // namespace Implementation
} // namespace Extension
} // namespace Inkscape