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.
200 lines
5.6 KiB
200 lines
5.6 KiB
15 years ago
|
/* This file is part of the KDE project
|
||
|
*
|
||
|
* Copyright (C) 2000 Wynn Wilkes <wynnw@caldera.com>
|
||
|
* 2002 Till Krech <till@snafu.de>
|
||
|
*
|
||
|
* This library is free software; you can redistribute it and/or
|
||
|
* modify it under the terms of the GNU Library General Public
|
||
|
* License as published by the Free Software Foundation; either
|
||
|
* version 2 of the License, or (at your option) any later version.
|
||
|
*
|
||
|
* This library 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
|
||
|
* Library General Public License for more details.
|
||
|
*
|
||
|
* You should have received a copy of the GNU Library General Public License
|
||
|
* along with this library; see the file COPYING.LIB. If not, write to
|
||
|
* the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
|
||
|
* Boston, MA 02110-1301, USA.
|
||
|
*/
|
||
15 years ago
|
#include <tqevent.h>
|
||
15 years ago
|
#include "kqeventutil.h"
|
||
|
|
||
15 years ago
|
TQString KQEventUtil::getQtEventName( TQEvent* e )
|
||
15 years ago
|
{
|
||
15 years ago
|
TQString s;
|
||
15 years ago
|
|
||
|
switch( e->type() )
|
||
|
{
|
||
15 years ago
|
case TQEvent::None:
|
||
15 years ago
|
s = "None";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::Timer:
|
||
15 years ago
|
s = "Timer";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::MouseButtonPress:
|
||
15 years ago
|
s = "MouseButtonPress";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::MouseButtonRelease:
|
||
15 years ago
|
s = "MouseButtonRelease";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::MouseButtonDblClick:
|
||
15 years ago
|
s = "MouseButtonClick";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::MouseMove:
|
||
15 years ago
|
s = "MouseMove";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::KeyPress:
|
||
15 years ago
|
s = "KeyPress";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::KeyRelease:
|
||
15 years ago
|
s = "KeyRelease";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::FocusIn:
|
||
15 years ago
|
s = "FocusIn";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::FocusOut:
|
||
15 years ago
|
s = "FocusOut";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::Enter:
|
||
15 years ago
|
s = "Enter";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::Leave:
|
||
15 years ago
|
s = "Leave";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::Paint:
|
||
15 years ago
|
s = "Paint";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::Move:
|
||
15 years ago
|
s = "Move";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::Resize:
|
||
15 years ago
|
s = "Resize";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::Create:
|
||
15 years ago
|
s = "Create";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::Destroy:
|
||
15 years ago
|
s = "Destroy";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::Show:
|
||
15 years ago
|
s = "Show";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::Hide:
|
||
15 years ago
|
s = "Hide";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::Close:
|
||
15 years ago
|
s = "Close";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::Quit:
|
||
15 years ago
|
s = "Quit";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::Reparent:
|
||
15 years ago
|
s = "Reparent";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::ShowMinimized:
|
||
15 years ago
|
s = "ShowMinimized";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::ShowNormal:
|
||
15 years ago
|
s = "ShowNormal";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::WindowActivate:
|
||
15 years ago
|
s = "WindowActivate";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::WindowDeactivate:
|
||
15 years ago
|
s = "WindowDeactivate";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::ShowToParent:
|
||
15 years ago
|
s = "ShowToParent";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::HideToParent:
|
||
15 years ago
|
s = "HideToParent";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::ShowMaximized:
|
||
15 years ago
|
s = "ShowMaximized";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::Accel:
|
||
15 years ago
|
s = "Accel";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::Wheel:
|
||
15 years ago
|
s = "Wheel";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::AccelAvailable:
|
||
15 years ago
|
s = "AccelAvailable";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::CaptionChange:
|
||
15 years ago
|
s = "CaptionChange";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::IconChange:
|
||
15 years ago
|
s = "IconChange";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::ParentFontChange:
|
||
15 years ago
|
s = "ParentFontChange";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::ApplicationFontChange:
|
||
15 years ago
|
s = "ApplicationFontChange";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::ParentPaletteChange:
|
||
15 years ago
|
s = "ParentPaletteChange";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::ApplicationPaletteChange:
|
||
15 years ago
|
s = "ApplicationPaletteChange";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::Clipboard:
|
||
15 years ago
|
s = "Clipboard";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::Speech:
|
||
15 years ago
|
s = "Speech";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::SockAct:
|
||
15 years ago
|
s = "SockAct";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::AccelOverride:
|
||
15 years ago
|
s = "AccelOverride";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::DragEnter:
|
||
15 years ago
|
s = "DragEnter";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::DragMove:
|
||
15 years ago
|
s = "DragMove";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::DragLeave:
|
||
15 years ago
|
s = "DragLeave";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::Drop:
|
||
15 years ago
|
s = "Drop";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::DragResponse:
|
||
15 years ago
|
s = "DragResponse";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::ChildInserted:
|
||
15 years ago
|
s = "ChildInserted";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::ChildRemoved:
|
||
15 years ago
|
s = "ChildRemoved";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::LayoutHint:
|
||
15 years ago
|
s = "LayoutHint";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::ShowWindowRequest:
|
||
15 years ago
|
s = "ShowWindowRequest";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::ActivateControl:
|
||
15 years ago
|
s = "ActivateControl";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::DeactivateControl:
|
||
15 years ago
|
s = "DeactivateControl";
|
||
|
break;
|
||
15 years ago
|
case TQEvent::User:
|
||
15 years ago
|
s = "User Event";
|
||
|
break;
|
||
|
|
||
|
default:
|
||
15 years ago
|
s = "Undefined Event, value = " + TQString::number( e->type() );
|
||
15 years ago
|
break;
|
||
|
}
|
||
|
|
||
|
return s;
|
||
|
}
|