ICF 3.1.1.10
Technical documentation of ICF Libraries
CProcessStartCommandComp.h
Go to the documentation of this file.
1/********************************************************************************
2** This file is part of the ICF Framework. Copyright (C) Witold Gantzke & Kirill Lepskiy
3** ICF Framework may be used under the terms of the LGPL License v. 2.1 by the Free Software Foundation.
4********************************************************************************/
5
6#ifndef iqtgui_CProcessStartCommanComp_included
7#define iqtgui_CProcessStartCommanComp_included
8
9
10// ICF includes
16
17
18namespace istdgui
19{
20
21
23 public QObject,
25 virtual public ibase::ICommandsProvider
26{
27 Q_OBJECT
28public:
30
32 {
34 };
35
36 I_BEGIN_COMPONENT(CProcessStartCommandComp);
37 I_REGISTER_INTERFACE(ibase::ICommandsProvider);
38 I_ASSIGN(m_applicationPathCompPtr, "ApplicationPath", "Path to the external executable used for opening the document file", true, "ApplicationPath");
39 I_ASSIGN(m_startProcessCommandNameAttrPtr, "CommandName", "Name/Text of the open document command shown in File menu", true, "Open In...");
40 I_ASSIGN_MULTI_0(m_processArgumentsAttrPtr, "ProcessArguments", "List of arguments for the external process", true);
41 I_END_COMPONENT;
42
44
45 // reimplemented (ibase::ICommandsProvider)
47
48protected:
49 virtual void CreateMenu();
50 virtual QStringList GetProcessArguments() const;
51 virtual bool StartProcess(const QStringList& arguments);
52
53 // reimplemented (icomp::CComponentBase)
54 void OnComponentCreated() override;
55
56private Q_SLOTS:
57 void OnStartProcessCommand();
58
59protected:
62
63 I_REF(ifile::IFileNameParam, m_applicationPathCompPtr);
64 I_ATTR(QString, m_startProcessCommandNameAttrPtr);
65 I_MULTIATTR(QString, m_processArgumentsAttrPtr);
66};
67
68
69} // namespace istdgui
70
71
72#endif // iqtgui_CProcessStartCommanComp_included
73
74
Interface for a provider of the heriarchical commands.
Common interface for any file system item name (e.g directory, file or URL path)
Wrapper provider of log-functionality for component based implementations.
Common interface to define the hierarchical graph structures.
Implementation of hierarchical command based on QAction from Qt.
virtual bool StartProcess(const QStringList &arguments)
virtual QStringList GetProcessArguments() const
const ibase::IHierarchicalCommand * GetCommands() const override
Get list of menu commands.
istdgui::CHierarchicalCommand m_startProcessCommand
istdgui::CHierarchicalCommand m_rootCommands
Standard GUI specific interfaces and components based on Qt.

© Witold Gantzke and Kirill Lepskiy