|
23 | 23 | #include <QSettings> |
24 | 24 |
|
25 | 25 |
|
26 | | -/** |
27 | | -* @brief List of applications user has specified to open errors with |
| 26 | +/** |
| 27 | +* @brief List of applications user has specified to open errors with |
28 | 28 | * Each application has a name and a path. Name is displayed to the user |
29 | 29 | * and has no other meaning. It isn't used to start the application. |
30 | 30 | * Path contains the path to the application as well as the executable itself and |
|
39 | 39 | * |
40 | 40 | * Example opening a file with Kate and make Kate scroll to the corret line: |
41 | 41 | * kate -l(line) (file) |
42 | | -* |
| 42 | +* |
43 | 43 | */ |
44 | 44 | class ApplicationList : public QObject |
45 | 45 | { |
46 | 46 | public: |
47 | 47 |
|
48 | | - /** |
49 | | - * @brief Struct containing information of the application |
50 | | - * |
| 48 | + /** |
| 49 | + * @brief Struct containing information of the application |
| 50 | + * |
51 | 51 | */ |
52 | 52 | typedef struct |
53 | 53 | { |
54 | | - /** |
55 | | - * @brief Applicaton's name |
56 | | - * |
| 54 | + /** |
| 55 | + * @brief Applicaton's name |
| 56 | + * |
57 | 57 | */ |
58 | 58 | QString Name; |
59 | 59 |
|
60 | | - /** |
61 | | - * @brief Application's path and commandline arguments |
62 | | - * |
| 60 | + /** |
| 61 | + * @brief Application's path and commandline arguments |
| 62 | + * |
63 | 63 | */ |
64 | 64 | QString Path; |
65 | 65 | }ApplicationType; |
66 | 66 |
|
67 | 67 | ApplicationList(); |
68 | 68 | virtual ~ApplicationList(); |
69 | 69 |
|
70 | | - /** |
71 | | - * @brief Load all applications |
72 | | - * |
73 | | - * @param programSettings QSettings to load application list from |
| 70 | + /** |
| 71 | + * @brief Load all applications |
| 72 | + * |
| 73 | + * @param programSettings QSettings to load application list from |
74 | 74 | */ |
75 | 75 | void LoadSettings(QSettings &programSettings); |
76 | 76 |
|
77 | | - /** |
78 | | - * @brief Save all applications |
79 | | - * @param programSettings QSettings to save applications to |
| 77 | + /** |
| 78 | + * @brief Save all applications |
| 79 | + * @param programSettings QSettings to save applications to |
80 | 80 | */ |
81 | 81 | void SaveSettings(QSettings &programSettings); |
82 | 82 |
|
83 | | - /** |
84 | | - * @brief Get the amount of applications in the list |
85 | | - * @return The count of applications |
| 83 | + /** |
| 84 | + * @brief Get the amount of applications in the list |
| 85 | + * @return The count of applications |
86 | 86 | */ |
87 | 87 | int GetApplicationCount(); |
88 | 88 |
|
89 | | - /** |
90 | | - * @brief Get spesific application's name |
91 | | - * |
92 | | - * @param index Index of the application whose name to get |
93 | | - * @return Name of the application |
| 89 | + /** |
| 90 | + * @brief Get spesific application's name |
| 91 | + * |
| 92 | + * @param index Index of the application whose name to get |
| 93 | + * @return Name of the application |
94 | 94 | */ |
95 | 95 | QString GetApplicationName(const int index); |
96 | 96 |
|
97 | | - /** |
98 | | - * @brief Get Application's path |
99 | | - * |
100 | | - * @param index of the application whose path to get |
101 | | - * @return Application's path |
| 97 | + /** |
| 98 | + * @brief Get Application's path |
| 99 | + * |
| 100 | + * @param index of the application whose path to get |
| 101 | + * @return Application's path |
102 | 102 | */ |
103 | 103 | QString GetApplicationPath(const int index); |
104 | 104 |
|
105 | | - /** |
106 | | - * @brief Modify an application |
107 | | - * |
108 | | - * @param index Index of the application to modify |
| 105 | + /** |
| 106 | + * @brief Modify an application |
| 107 | + * |
| 108 | + * @param index Index of the application to modify |
109 | 109 | * @param name New name for the application |
110 | | - * @param path New path for the application |
| 110 | + * @param path New path for the application |
111 | 111 | */ |
112 | 112 | void SetApplicationType(const int index, |
113 | 113 | const QString &name, |
114 | 114 | const QString &path); |
115 | 115 |
|
116 | | - /** |
117 | | - * @brief Add a new application |
118 | | - * |
119 | | - * @param name Name of the application |
120 | | - * @param path Path to the application |
| 116 | + /** |
| 117 | + * @brief Add a new application |
| 118 | + * |
| 119 | + * @param name Name of the application |
| 120 | + * @param path Path to the application |
121 | 121 | */ |
122 | 122 | void AddApplicationType(const QString &name, const QString &path); |
123 | 123 |
|
124 | | - /** |
125 | | - * @brief Remove an application from the list |
126 | | - * |
127 | | - * @param index Index of the application to remove. |
| 124 | + /** |
| 125 | + * @brief Remove an application from the list |
| 126 | + * |
| 127 | + * @param index Index of the application to remove. |
128 | 128 | */ |
129 | 129 | void RemoveApplication(const int index); |
130 | 130 |
|
131 | | - /** |
| 131 | + /** |
132 | 132 | * @brief Move certain application as first. |
133 | 133 | * Position of the application is used by the application to determine |
134 | 134 | * which of the applications is the default application. First application |
135 | | - * (index 0) is the default application. |
136 | | - * |
137 | | - * @param index Index of the application to make the default one |
| 135 | + * (index 0) is the default application. |
| 136 | + * |
| 137 | + * @param index Index of the application to make the default one |
138 | 138 | */ |
139 | 139 | void MoveFirst(const int index); |
140 | 140 |
|
141 | | - /** |
142 | | - * @brief Remove all applications from this list and copy all applications from |
143 | | - * list given as a parameter. |
144 | | - * @param list Copying source |
| 141 | + /** |
| 142 | + * @brief Remove all applications from this list and copy all applications from |
| 143 | + * list given as a parameter. |
| 144 | + * @param list Copying source |
145 | 145 | */ |
146 | 146 | void Copy(ApplicationList &list); |
147 | 147 | protected: |
148 | 148 |
|
149 | | - /** |
150 | | - * @brief Clear the list |
151 | | - * |
| 149 | + /** |
| 150 | + * @brief Clear the list |
| 151 | + * |
152 | 152 | */ |
153 | 153 | void Clear(); |
154 | | - /** |
155 | | - * @brief List of applications |
156 | | - * |
| 154 | + /** |
| 155 | + * @brief List of applications |
| 156 | + * |
157 | 157 | */ |
158 | 158 | QList<ApplicationType> mApplications; |
159 | 159 | private: |
|
0 commit comments