File indexing completed on 2025-01-05 05:18:57
0001 // SPDX-FileCopyrightText: 2023-2024 Laurent Montel <montel.org> 0002 // 0003 // SPDX-License-Identifier: GPL-2.0-only OR GPL-3.0-only OR LicenseRef-KDE-Accepted-GPL 0004 // Code based on neochat code 0005 0006 #pragma once 0007 0008 #include <KStatusNotifierItem> 0009 0010 class SystemTray : public KStatusNotifierItem 0011 { 0012 Q_OBJECT 0013 public: 0014 explicit SystemTray(QObject *parent = nullptr); 0015 ~SystemTray() override; 0016 0017 /** 0018 * @brief Show the tray icon. 0019 */ 0020 void show(); 0021 0022 /** 0023 * @brief Hide the tray icon. 0024 */ 0025 void hide(); 0026 0027 Q_SIGNALS: 0028 /** 0029 * @brief Triggered when the system tray icon is clicked to request Alpaka be shown or hidden. 0030 */ 0031 void toggleWindow(); 0032 };