fw4spl
include/fwGui/dialog/InputDialog.hpp
1 /* ***** BEGIN LICENSE BLOCK *****
2  * FW4SPL - Copyright (C) IRCAD, 2009-2017.
3  * Distributed under the terms of the GNU Lesser General Public License (LGPL) as
4  * published by the Free Software Foundation.
5  * ****** END LICENSE BLOCK ****** */
6 
7 #ifndef __FWGUI_DIALOG_INPUTDIALOG_HPP__
8 #define __FWGUI_DIALOG_INPUTDIALOG_HPP__
9 
10 #include "fwGui/config.hpp"
11 #include "fwGui/dialog/IInputDialog.hpp"
12 #include "fwGui/GuiBaseObject.hpp"
13 
14 namespace fwGui
15 {
16 namespace dialog
17 {
31 class FWGUI_CLASS_API InputDialog : public ::fwGui::dialog::IInputDialog
32 {
33 
34 public:
35 
37 
38 
46  FWGUI_API static std::string showInputDialog(const std::string& title, const std::string& message,
47  const std::string& text = "");
48 
60  FWGUI_API InputDialog();
61 
69  FWGUI_API InputDialog(const std::string& title, const std::string& message, const std::string& text = "");
70 
72  FWGUI_API virtual ~InputDialog();
73 
75  FWGUI_API virtual void setTitle(const std::string& title) override;
76 
78  FWGUI_API virtual void setMessage(const std::string& msg) override;
79 
81  FWGUI_API virtual void setInput(const std::string& text) override;
82 
84  FWGUI_API virtual std::string getInput() override;
85 
86 protected:
87 
89  ::fwGui::dialog::IInputDialog::sptr m_implementation;
90 };
91 
92 } //namespace dialog
93 } // namespace fwGui
94 
95 #endif /*__FWGUI_DIALOG_INPUTDIALOG_HPP__*/
96 
The namespace fwGui contains the base interface for IHM services.
Definition: SJobBar.hpp:23
STL namespace.
#define fwCoreClassDefinitionsWithFactoryMacro(_classinfo_, _parameters_, _factory_)
Generate common construction methods for classes with one factory.
Defines the generic input dialog for IHM. Use the Delegate design pattern.
Defines the generic input dialog box for IHM.