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

tdeui

  • tdeui
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 <tdeglobal.h>
22 #include <tqlabel.h>
23 
24 class TDEActionCollection;
25 class TDEPopupMenu;
26 class KSystemTrayPrivate;
27 
63 class TDEUI_EXPORT KSystemTray : public TQLabel
64 {
65  TQ_OBJECT
66 public:
67 
81  KSystemTray( TQWidget* parent = 0, const char* name = 0 );
82 
83  /*
84  Destructor
85  */
86  ~KSystemTray();
87 
92  TDEPopupMenu* contextMenu() const;
93 
99  TDEActionCollection* 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, TDEInstance *instance=TDEGlobal::instance() );
121 
131  static TQPixmap loadSizedIcon( const TQString &icon, int iconWidth, TDEInstance *instance=TDEGlobal::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( TDEPopupMenu* 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  TDEPopupMenu* 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
KSystemTray
KDE System Tray Window class
Definition: ksystemtray.h:64
KSystemTray::quitSelected
void quitSelected()
Emitted when quit is selected in the menu.
TDEActionCollection
A managed set of TDEAction objects.
Definition: tdeactioncollection.h:79
TDEGlobal::instance
static TDEInstance * instance()
TDEInstance
TDEPopupMenu
A menu with title items.
Definition: tdepopupmenu.h:123

tdeui

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

tdeui

Skip menu "tdeui"
  • arts
  • dcop
  • dnssd
  • interfaces
  •   kspeech
  •     interface
  •     library
  •   tdetexteditor
  • kate
  • kded
  • kdoctools
  • kimgio
  • kjs
  • libtdemid
  • libtdescreensaver
  • tdeabc
  • tdecmshell
  • tdecore
  • tdefx
  • tdehtml
  • tdeinit
  • tdeio
  •   bookmarks
  •   httpfilter
  •   kpasswdserver
  •   kssl
  •   tdefile
  •   tdeio
  •   tdeioexec
  • tdeioslave
  •   http
  • tdemdi
  •   tdemdi
  • tdenewstuff
  • tdeparts
  • tdeprint
  • tderandr
  • tderesources
  • tdespell2
  • tdesu
  • tdeui
  • tdeunittest
  • tdeutils
  • tdewallet
Generated for tdeui by doxygen 1.9.1
This website is maintained by Timothy Pearson.