diff options
| author | 2015-05-21 10:48:10 +0200 | |
|---|---|---|
| committer | 2015-05-21 10:48:10 +0200 | |
| commit | 88e5130bd86992819a036ef982733b5ee344d656 (patch) | |
| tree | 99c2a247ae927952243afd60e22faac3ac9f1e55 /node | |
| parent | 2f24c7b8361d87b67e0a204b1f054d750f650d66 (diff) | |
| download | OneRoll-88e5130bd86992819a036ef982733b5ee344d656.tar.gz OneRoll-88e5130bd86992819a036ef982733b5ee344d656.zip | |
add API to set the link to documentation
Diffstat (limited to 'node')
| -rw-r--r-- | node/helpnode.cpp | 7 | ||||
| -rw-r--r-- | node/helpnode.h | 7 |
2 files changed, 13 insertions, 1 deletions
diff --git a/node/helpnode.cpp b/node/helpnode.cpp index d41464b..6108e4d 100644 --- a/node/helpnode.cpp +++ b/node/helpnode.cpp @@ -1,6 +1,7 @@ #include "helpnode.h" HelpNode::HelpNode() + : m_path("https://github.com/obiwankennedy/DiceParser/blob/master/HelpMe.md") { m_result = new StringResult(); } @@ -30,10 +31,14 @@ void HelpNode::run(ExecutionNode* previous) } QString HelpNode::toString() const { - return QObject::tr("Rolisteam Dice Parser:\nFull documentation at: https://github.com/obiwankennedy/DiceParser/blob/master/HelpMe.md \n"); + return QObject::tr("Rolisteam Dice Parser:\nFull documentation at: %1 \n").arg(m_path); } qint64 HelpNode::getPriority() const { return 0; } +void HelpNode::setHelpPath(QString path) +{ + m_path = path; +} diff --git a/node/helpnode.h b/node/helpnode.h index 3a949d9..88a0842 100644 --- a/node/helpnode.h +++ b/node/helpnode.h @@ -32,6 +32,13 @@ public: * @return */ virtual qint64 getPriority() const; + /** + * @brief setHelpPath + * @param path + */ + void setHelpPath(QString path); +private: + QString m_path; }; |