clickarea.h
00001 /* 00002 * Copyright (C) 2003 Hans Karlsson <karlsson.h@home.se> 00003 * Copyright (C) 2003-2004 Adam Geitgey <adam@rootnode.org> 00004 * Copyright (c) 2005 Ryan Nickell <p0z3r@earthlink.net> 00005 * 00006 * This file is part of SuperKaramba. 00007 * 00008 * SuperKaramba is free software; you can redistribute it and/or modify 00009 * it under the terms of the GNU General Public License as published by 00010 * the Free Software Foundation; either version 2 of the License, or 00011 * (at your option) any later version. 00012 * 00013 * SuperKaramba is distributed in the hope that it will be useful, 00014 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00015 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00016 * GNU General Public License for more details. 00017 * 00018 * You should have received a copy of the GNU General Public License 00019 * along with SuperKaramba; if not, write to the Free Software 00020 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA 00021 ****************************************************************************/ 00022 #ifndef CLICKAREA_H 00023 #define CLICKAREA_H 00024 00025 #include <tqstring.h> 00026 #include <tqrect.h> 00027 #include <tqevent.h> 00028 #include <tqregexp.h> 00029 00030 #include <kprocess.h> 00031 #include <kprocio.h> 00032 #include <krun.h> 00033 00034 #include <meter.h> 00035 #include "clickable.h" 00040 class ClickArea : public Meter 00041 { 00042 Q_OBJECT 00043 TQ_OBJECT 00044 public: 00045 ClickArea(karamba* k, int x, int y, int w, int h ); 00046 00047 ~ClickArea(); 00048 00049 virtual bool click( TQMouseEvent* ); 00050 void setOnClick( TQString ); 00051 void setServiceOnClick( TQString , TQString, TQString); 00052 void setOnMiddleClick( TQString ); 00053 00054 00055 TQRect getRectangle(); 00056 00057 void mUpdate( TQPainter* ); 00058 void setValue( long ); 00059 void setValue( TQString ); 00060 00061 TQRect rect; 00062 TQString onClick; 00063 TQString svc_onClick; 00064 TQString svc_name; 00065 TQString svc_icon; 00066 TQString onMiddleClick; 00067 TQString value; 00068 }; 00069 00070 #endif