• Skip to content
  • Skip to link menu
Trinity API Reference
  • Trinity API Reference
  • kdeui
 

kdeui

  • kdeui
ksystemtray.h
1 /* This file is part of the KDE libraries
2  Copyright (C) 1999 Matthias Ettrich <ettrich@kde.org>
3 
4  This library is free software; you can redistribute it and/or
5  modify it under the terms of the GNU Library General Public
6  License version 2 as published by the Free Software Foundation.
7 
8  This library is distributed in the hope that it will be useful,
9  but WITHOUT ANY WARRANTY; without even the implied warranty of
10  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11  Library General Public License for more details.
12 
13  You should have received a copy of the GNU Library General Public License
14  along with this library; see the file COPYING.LIB. If not, write to
15  the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
16  Boston, MA 02110-1301, USA.
17 */
18 #ifndef KSYSTEMTRAY_H
19 #define KSYSTEMTRAY_H
20 
21 #include <kglobal.h>
22 #include <tqlabel.h>
23 
24 class KActionCollection;
25 class KPopupMenu;
26 class KSystemTrayPrivate;
27 
63 class KDEUI_EXPORT KSystemTray : public TQLabel
64 {
65  Q_OBJECT
66 public:
67 
81  KSystemTray( TQWidget* parent = 0, const char* name = 0 );
82 
83  /*
84  Destructor
85  */
86  ~KSystemTray();
87 
92  KPopupMenu* contextMenu() const;
93 
99  KActionCollection* actionCollection();
100 
104  virtual void setPixmap( const TQPixmap& icon );
105 
110  virtual void setCaption( const TQString& title );
111 
120  static TQPixmap loadIcon( const TQString &icon, KInstance *instance=KGlobal::instance() );
121 
131  static TQPixmap loadSizedIcon( const TQString &icon, int iconWidth, KInstance *instance=KGlobal::instance() );
132 
133 signals:
139  void quitSelected();
140 
141 public slots:
142 
150  void toggleActive();
155  void setActive();
160  void setInactive();
161 
162 protected:
163 
170  void mousePressEvent( TQMouseEvent * );
171 
178  void mouseReleaseEvent( TQMouseEvent * );
179 
180 
181 
186  virtual void contextMenuAboutToShow( KPopupMenu* menu );
187 
191  void showEvent( TQShowEvent * );
192 
196  void enterEvent( TQEvent* );
197 
198 private slots:
199  void minimizeRestoreAction();
200  void maybeQuit();
201 
202 private:
203  void activateOrHide();
204  void minimizeRestore( bool restore );
205  KPopupMenu* menu;
206  // minimizeRestoreId is no longer needed. remove in KDE 4.0
207  int minimizeRestoreId;
208  uint hasQuit :1;
209 protected:
210  virtual void virtual_hook( int id, void* data );
211 private:
212  KSystemTrayPrivate* d;
213 };
214 
215 
216 #endif
KActionCollection
A managed set of KAction objects.
Definition: kactioncollection.h:78
KPopupMenu
A menu with title items.
Definition: kpopupmenu.h:123
KSystemTray
KDE System Tray Window class
Definition: ksystemtray.h:63
KInstance
KGlobal::instance
static KInstance * instance()

kdeui

Skip menu "kdeui"
  • Main Page
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Namespace Members
  • Class Members
  • Related Pages

kdeui

Skip menu "kdeui"
  • arts
  • dcop
  • dnssd
  • interfaces
  •     interface
  •     library
  •   kspeech
  •   ktexteditor
  • kabc
  • kate
  • kcmshell
  • kdecore
  • kded
  • kdefx
  • kdeprint
  • kdesu
  • kdeui
  • kdoctools
  • khtml
  • kimgio
  • kinit
  • kio
  •   bookmarks
  •   httpfilter
  •   kfile
  •   kio
  •   kioexec
  •   kpasswdserver
  •   kssl
  • kioslave
  •   http
  • kjs
  • kmdi
  •   kmdi
  • knewstuff
  • kparts
  • krandr
  • kresources
  • kspell2
  • kunittest
  • kutils
  • kwallet
  • libkmid
  • libkscreensaver
Generated for kdeui by doxygen 1.8.8
This website is maintained by Timothy Pearson.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. |