1 /* This file is part of the KDE project
3 Copyright (C) 2002 by Patrick Charbonnier <pch@freeshell.org>
4 Based On Caitoo v.0.7.3 (c) 1998 - 2000, Matej Koss
6 This program is free software; you can redistribute it and/or
7 modify it under the terms of the GNU General Public
8 License as published by the Free Software Foundation; either
9 version 2 of the License, or (at your option) any later version.
15 #include <ksystemtrayicon.h>
17 #include "core/observer.h"
25 * This class implements the main tray icon for kget. It has a popup
26 * from which the user can open a new transfer, configure kget,
27 * minimize/restore or quit the app (default behavior).
29 * @short KGet's system tray icon.
32 class Tray
: public KSystemTrayIcon
, public ModelObserver
36 Tray( MainWindow
* parent
);
39 void setDownloading(bool running
);
43 * Repaints trayIcon showing progress (and overlay if present)
45 void paintIcon( int mergePixels
= -1, bool force
= false );
47 * Blend an overlay icon over 'sourcePixmap' and repaint trayIcon
49 void blendOverlay( QPixmap
* sourcePixmap
);
52 QPixmap
*baseIcon
, *grayedIcon
, *alternateIcon
;
53 QPixmap
*playOverlay
, *stopOverlay
;
54 QPixmap
*overlay
; //!< The current overlay (may be NULL)
59 void slotActivated( QSystemTrayIcon::ActivationReason reason
);