You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
59 lines
1.9 KiB
59 lines
1.9 KiB
15 years ago
|
/*
|
||
|
KSysGuard, the KDE System Guard
|
||
|
|
||
|
Copyright (c) 1999, 2000, 2001 Chris Schlaeger <cs@kde.org>
|
||
|
|
||
|
This program is free software; you can redistribute it and/or
|
||
|
modify it under the terms of version 2 of the GNU General Public
|
||
|
License as published by the Free Software Foundation.
|
||
|
|
||
|
This program is distributed in the hope that it will be useful,
|
||
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||
|
GNU General Public License for more details.
|
||
|
|
||
|
You should have received a copy of the GNU General Public License
|
||
|
along with this program; if not, write to the Free Software
|
||
|
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||
|
|
||
|
KSysGuard is currently maintained by Chris Schlaeger <cs@kde.org>.
|
||
|
Please do not commit any changes without consulting me first. Thanks!
|
||
|
|
||
|
*/
|
||
|
|
||
12 years ago
|
#include <tdelocale.h>
|
||
15 years ago
|
#include <ksgrd/SensorManager.h>
|
||
|
|
||
14 years ago
|
#include <tqwhatsthis.h>
|
||
15 years ago
|
|
||
|
#include "DummyDisplay.h"
|
||
|
|
||
14 years ago
|
DummyDisplay::DummyDisplay( TQWidget* parent, const char* name,
|
||
|
const TQString&, double, double )
|
||
15 years ago
|
: KSGRD::SensorDisplay( parent, name, i18n( "Drop Sensor Here" ) )
|
||
|
{
|
||
|
setMinimumSize( 16, 16 );
|
||
|
|
||
14 years ago
|
TQWhatsThis::add( this, i18n(
|
||
15 years ago
|
"This is an empty space in a worksheet. Drag a sensor from "
|
||
|
"the Sensor Browser and drop it here. A sensor display will "
|
||
|
"appear that allows you to monitor the values of the sensor "
|
||
|
"over time." ) );
|
||
|
}
|
||
|
|
||
14 years ago
|
void DummyDisplay::resizeEvent( TQResizeEvent* )
|
||
15 years ago
|
{
|
||
|
frame()->setGeometry( 0, 0, width(), height() );
|
||
|
}
|
||
|
|
||
14 years ago
|
bool DummyDisplay::eventFilter( TQObject* object, TQEvent* event )
|
||
15 years ago
|
{
|
||
14 years ago
|
if ( event->type() == TQEvent::MouseButtonRelease &&
|
||
14 years ago
|
( (TQMouseEvent*)event)->button() == Qt::LeftButton )
|
||
15 years ago
|
setFocus();
|
||
|
|
||
14 years ago
|
return TQWidget::eventFilter( object, event );
|
||
15 years ago
|
}
|
||
|
|
||
|
#include "DummyDisplay.moc"
|