ORE Studio 0.0.4
Loading...
Searching...
No Matches
plugin_context.hpp
1/* -*- mode: c++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-
2 *
3 * Copyright (C) 2026 Marco Craveiro <marco.craveiro@gmail.com>
4 *
5 * This program is free software; you can redistribute it and/or modify it under
6 * the terms of the GNU General Public License as published by the Free Software
7 * Foundation; either version 3 of the License, or (at your option) any later
8 * version.
9 *
10 * This program is distributed in the hope that it will be useful, but WITHOUT
11 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
12 * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License along with
15 * this program; if not, write to the Free Software Foundation, Inc., 51 Franklin
16 * Street, Fifth Floor, Boston, MA 02110-1301, USA.
17 *
18 */
19#ifndef ORES_QT_PLUGIN_CONTEXT_HPP
20#define ORES_QT_PLUGIN_CONTEXT_HPP
21
22#include <memory>
23#include <string>
24#include <QString>
25#include "ores.qt/export.hpp"
26
27class QMainWindow;
28class QMdiArea;
29class QStatusBar;
30
31namespace ores::eventing::service { class event_bus; }
32
33namespace ores::qt {
34
35class ClientManager;
36class ImageCache;
37class ChangeReasonCache;
38class BadgeCache;
39
47struct ORES_QT_API plugin_context {
48 QMainWindow* main_window = nullptr;
49 QMdiArea* mdi_area = nullptr;
50 QStatusBar* status_bar = nullptr;
51 ClientManager* client_manager = nullptr;
52 ImageCache* image_cache = nullptr;
53 ChangeReasonCache* change_reason_cache = nullptr;
54 BadgeCache* badge_cache = nullptr;
55 std::shared_ptr<eventing::service::event_bus> event_bus;
56 QString username;
57 std::string http_base_url;
58};
59
60}
61
62#endif
Event bus and related services.
Definition event_bus.hpp:33
Qt-based graphical user interface for ORE Studio.
Definition AccountController.hpp:32
Client-side cache of badge definitions and mappings.
Definition BadgeCache.hpp:47
Shared cache for change reasons used across all entity dialogs.
Definition ChangeReasonCache.hpp:48
Manages the lifecycle of the NATS client and login state.
Definition ClientManager.hpp:123
Cache for dynamically loaded images (flags, icons) from the server.
Definition ImageCache.hpp:54
Context passed to each plugin at login time.
Definition plugin_context.hpp:47