diff options
author | Mark Tiefenbruck <mark@fluxbox.org> | 2008-01-11 07:41:22 (GMT) |
---|---|---|
committer | Mark Tiefenbruck <mark@fluxbox.org> | 2008-01-11 07:41:22 (GMT) |
commit | 9f2f65a698c4cc71373a7fe9d73a0889e0d3487b (patch) | |
tree | 4ad67db771d73ea3c48f80a1244037fc9754edd2 /src/FbTk/Command.hh | |
parent | 1f01d84c080d607a91eb417efcaf5e500b5f1d7e (diff) | |
download | fluxbox-9f2f65a698c4cc71373a7fe9d73a0889e0d3487b.zip fluxbox-9f2f65a698c4cc71373a7fe9d73a0889e0d3487b.tar.bz2 |
make FbTk::Command a template class, split parsing information out of ObjectRegistry
Diffstat (limited to 'src/FbTk/Command.hh')
-rw-r--r-- | src/FbTk/Command.hh | 11 |
1 files changed, 2 insertions, 9 deletions
diff --git a/src/FbTk/Command.hh b/src/FbTk/Command.hh index 5d38cb8..f1eb8f2 100644 --- a/src/FbTk/Command.hh +++ b/src/FbTk/Command.hh | |||
@@ -25,18 +25,11 @@ | |||
25 | namespace FbTk { | 25 | namespace FbTk { |
26 | 26 | ||
27 | /// Interface class for commands | 27 | /// Interface class for commands |
28 | template <typename Ret=void> | ||
28 | class Command { | 29 | class Command { |
29 | public: | 30 | public: |
30 | virtual ~Command() { } | 31 | virtual ~Command() { } |
31 | virtual void execute() = 0; | 32 | virtual Ret execute() = 0; |
32 | }; | ||
33 | |||
34 | /// Interface class for boolean commands | ||
35 | class BoolCommand: public Command { | ||
36 | public: | ||
37 | virtual ~BoolCommand() { } | ||
38 | virtual void execute() { bool_execute(); } | ||
39 | virtual bool bool_execute() = 0; | ||
40 | }; | 33 | }; |
41 | 34 | ||
42 | } // end namespace FbTk | 35 | } // end namespace FbTk |