summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichele Calgaro <michele.calgaro@yahoo.it>2023-11-30 20:43:20 +0900
committerMichele Calgaro <michele.calgaro@yahoo.it>2023-11-30 21:03:28 +0900
commitd7ae9fb514226c126e04cfe4f34800beb9f4ea19 (patch)
tree4d12f786f3541b9ff0225f0ceb2bec0b9268a163
parentb727f4b3b1957bec28a350575237b93f8f278cdb (diff)
downloadkoffice-d7ae9fb514226c126e04cfe4f34800beb9f4ea19.tar.gz
koffice-d7ae9fb514226c126e04cfe4f34800beb9f4ea19.zip
Replace 'Event' #define strings
Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
-rw-r--r--chalk/ui/kis_view.cpp2
-rw-r--r--chalk/ui/kobirdeyepanel.cpp4
-rw-r--r--karbon/dockers/vdocumentdocker.cpp2
-rw-r--r--karbon/vtool.cpp4
-rw-r--r--karbon/widgets/vstrokefillpreview.cpp2
-rw-r--r--kexi/formeditor/container.cpp14
-rw-r--r--kexi/formeditor/widgetfactory.cpp2
-rw-r--r--kexi/formeditor/widgetpropertyset.cpp4
-rw-r--r--kexi/kexiutils/utils.cpp8
-rw-r--r--kexi/main/keximainwindowimpl.cpp14
-rw-r--r--kexi/main/printing/kexisimpleprintpreviewwindow.cpp4
-rw-r--r--kexi/main/startup/KexiStartupDialog.cpp2
-rw-r--r--kexi/main/startup/KexiStartupFileDialog.cpp6
-rw-r--r--kexi/plugins/forms/widgets/kexidbcombobox.cpp10
-rw-r--r--kexi/plugins/forms/widgets/kexidbform.cpp8
-rw-r--r--kexi/plugins/forms/widgets/kexidblineedit.cpp2
-rw-r--r--kexi/plugins/importexport/csv/kexicsvimportdialog.cpp2
-rw-r--r--kexi/widget/kexibrowser.cpp4
-rw-r--r--kexi/widget/relations/kexirelationviewtable.cpp10
-rw-r--r--kexi/widget/tableview/kexiblobtableedit.cpp2
-rw-r--r--kexi/widget/tableview/kexicomboboxpopup.cpp2
-rw-r--r--kexi/widget/tableview/kexicomboboxtableedit.cpp2
-rw-r--r--kexi/widget/tableview/kexitableedit.cpp2
-rw-r--r--kexi/widget/tableview/kexitableview.cpp2
-rw-r--r--kexi/widget/tableview/kexitableviewheader.cpp2
-rw-r--r--kexi/widget/utils/kexirecordnavigator.cpp8
-rw-r--r--kivio/kiviopart/addstenciltool.cpp6
-rw-r--r--kivio/kiviopart/ui/kivio_birdeye_panel.cpp4
-rw-r--r--kivio/plugins/kivioconnectortool/tool_connector.cpp6
-rw-r--r--kivio/plugins/kivioselecttool/tool_select.cpp6
-rw-r--r--kivio/plugins/kiviotargettool/kiviotargettool.cpp4
-rw-r--r--kivio/plugins/kiviozoomtool/tool_zoom.cpp12
-rw-r--r--kpresenter/KPrCanvas.cpp4
-rw-r--r--kspread/kspread_canvas.cpp2
-rw-r--r--kword/KWCanvas.cpp6
-rw-r--r--lib/kofficecore/KoContainerHandler.cpp4
-rw-r--r--lib/kofficeui/KoTooluButton.cpp4
-rw-r--r--lib/koproperty/editor.cpp2
-rw-r--r--lib/koproperty/editoritem.cpp4
-rw-r--r--lib/koproperty/editors/booledit.cpp2
-rw-r--r--lib/koproperty/editors/fontedit.cpp2
-rw-r--r--lib/koproperty/editors/pixmapedit.cpp4
-rw-r--r--lib/koproperty/editors/spinbox.cpp4
-rw-r--r--lib/koproperty/widget.cpp2
44 files changed, 101 insertions, 101 deletions
diff --git a/chalk/ui/kis_view.cpp b/chalk/ui/kis_view.cpp
index 2e123f5d4..3a8105388 100644
--- a/chalk/ui/kis_view.cpp
+++ b/chalk/ui/kis_view.cpp
@@ -3449,7 +3449,7 @@ bool KisView::eventFilter(TQObject *o, TQEvent *e)
case TQEvent::TabletPress:
case TQEvent::TabletRelease:
{
- TQTabletEvent *te = TQT_TQTABLETEVENT(e);
+ TQTabletEvent *te = static_cast<TQTabletEvent*>(e);
KisInputDevice device;
switch (te->device()) {
diff --git a/chalk/ui/kobirdeyepanel.cpp b/chalk/ui/kobirdeyepanel.cpp
index 5cc9799e9..b096725e7 100644
--- a/chalk/ui/kobirdeyepanel.cpp
+++ b/chalk/ui/kobirdeyepanel.cpp
@@ -308,11 +308,11 @@ void KoBirdEyePanel::updateVisibleArea()
bool KoBirdEyePanel::eventFilter(TQObject* o, TQEvent* ev)
{
if (o == m_page->view && ev->type() == TQEvent::Resize) {
- resizeViewEvent(TQT_TQRESIZEEVENT(ev)->size());
+ resizeViewEvent(static_cast<TQResizeEvent*>(ev)->size());
}
if (o == m_page->view && ev->type() == TQEvent::Paint) {
- paintViewEvent(TQT_TQPAINTEVENT(ev));
+ paintViewEvent(static_cast<TQPaintEvent*>(ev));
}
if (o == m_page->view && ev->type() == TQEvent::MouseMove) {
diff --git a/karbon/dockers/vdocumentdocker.cpp b/karbon/dockers/vdocumentdocker.cpp
index dc676a85c..cf02d2cd7 100644
--- a/karbon/dockers/vdocumentdocker.cpp
+++ b/karbon/dockers/vdocumentdocker.cpp
@@ -102,7 +102,7 @@ VDocumentPreview::eventFilter( TQObject* object, TQEvent* event )
}
KoRect rect = m_view->canvasWidget()->boundingBox();
- TQMouseEvent* mouseEvent = TQT_TQMOUSEEVENT( event );
+ TQMouseEvent* mouseEvent = static_cast<TQMouseEvent*>( event );
if( event->type() == TQEvent::MouseButtonPress )
{
m_firstPoint.setX( mouseEvent->pos().x() );
diff --git a/karbon/vtool.cpp b/karbon/vtool.cpp
index a9b29ac8e..906f53c93 100644
--- a/karbon/vtool.cpp
+++ b/karbon/vtool.cpp
@@ -150,7 +150,7 @@ VTool::keyEvent( TQEvent* event )
// Key press events.
if( event->type() == TQEvent::KeyPress )
{
- TQKeyEvent* keyEvent = TQT_TQKEYEVENT( event );
+ TQKeyEvent* keyEvent = static_cast<TQKeyEvent*>( event );
// Terminate the current drawing with the Enter-key:
if(
@@ -211,7 +211,7 @@ VTool::keyEvent( TQEvent* event )
// Key release events:
if( event->type() == TQEvent::KeyRelease )
{
- TQKeyEvent* keyEvent = TQT_TQKEYEVENT( event );
+ TQKeyEvent* keyEvent = static_cast<TQKeyEvent*>( event );
TQt::Key key = (TQt::Key)keyEvent->key();
if( key == TQt::Key_Shift )
diff --git a/karbon/widgets/vstrokefillpreview.cpp b/karbon/widgets/vstrokefillpreview.cpp
index 5e05eecd2..c7b165f44 100644
--- a/karbon/widgets/vstrokefillpreview.cpp
+++ b/karbon/widgets/vstrokefillpreview.cpp
@@ -84,7 +84,7 @@ VStrokeFillPreview::paintEvent( TQPaintEvent* event )
bool
VStrokeFillPreview::eventFilter( TQObject *, TQEvent *event )
{
- TQMouseEvent* e = TQT_TQMOUSEEVENT( event );
+ TQMouseEvent* e = static_cast<TQMouseEvent*>( event );
int ex = e->x() - int( ( width() - PANEL_SIZEX ) / 2 );
int ey = e->y() - int( ( height() - PANEL_SIZEY ) / 2 );
diff --git a/kexi/formeditor/container.cpp b/kexi/formeditor/container.cpp
index 17f1ced84..ae75caa2c 100644
--- a/kexi/formeditor/container.cpp
+++ b/kexi/formeditor/container.cpp
@@ -63,7 +63,7 @@ EventEater::eventFilter(TQObject *, TQEvent *ev)
// we need to simulate the Press event
if(ev->type() == TQEvent::MouseButtonRelease && m_widget->inherits("TQTabWidget"))
{
- TQMouseEvent *mev = TQT_TQMOUSEEVENT(ev);
+ TQMouseEvent *mev = static_cast<TQMouseEvent*>(ev);
if(mev->button() == TQt::LeftButton)
{
TQMouseEvent *myev = new TQMouseEvent(TQEvent::MouseButtonPress, mev->pos(), mev->button(), mev->state());
@@ -162,7 +162,7 @@ Container::eventFilter(TQObject *s, TQEvent *e)
kdDebug() << "TQEvent::MouseButtonPress this = " << name() << endl;
m_moving = TQT_TQWIDGET(s);
- TQMouseEvent *mev = TQT_TQMOUSEEVENT(e);
+ TQMouseEvent *mev = static_cast<TQMouseEvent*>(e);
m_grab = TQPoint(mev->x(), mev->y());
// we are drawing a connection
@@ -239,7 +239,7 @@ Container::eventFilter(TQObject *s, TQEvent *e)
case TQEvent::MouseButtonRelease:
{
- TQMouseEvent *mev = TQT_TQMOUSEEVENT(e);
+ TQMouseEvent *mev = static_cast<TQMouseEvent*>(e);
if (!m_mousePressEventReceived) {
m_mouseReleaseEvent = *mev;
m_objectForMouseReleaseEvent = s;
@@ -252,7 +252,7 @@ Container::eventFilter(TQObject *s, TQEvent *e)
case TQEvent::MouseMove:
{
- TQMouseEvent *mev = TQT_TQMOUSEEVENT(e);
+ TQMouseEvent *mev = static_cast<TQMouseEvent*>(e);
if(m_insertBegin!=TQPoint(-1,-1) && FormManager::self()->isInserting() && ((mev->state() == TQt::LeftButton) || (mev->state() == (TQt::LeftButton|TQt::ControlButton)) ||
(mev->state() == (TQt::LeftButton|TQt::ControlButton|TQt::AltButton)) || (mev->state() == (TQt::LeftButton|TQt::ShiftButton)) ) )
// draw the insert rect
@@ -343,7 +343,7 @@ Container::eventFilter(TQObject *s, TQEvent *e)
//case TQEvent::AccelOverride:
case TQEvent::KeyPress:
{
- TQKeyEvent *kev = TQT_TQKEYEVENT(e);
+ TQKeyEvent *kev = static_cast<TQKeyEvent*>(e);
if(kev->key() == Key_F2) // pressing F2 == double-clicking
{
@@ -374,7 +374,7 @@ Container::eventFilter(TQObject *s, TQEvent *e)
// we simulate a mouse move event to update screen
TQMouseEvent *mev = new TQMouseEvent(TQEvent::MouseMove, m_moving->mapFromGlobal(TQCursor::pos()), TQt::NoButton,
TQt::LeftButton|TQt::ControlButton );
- eventFilter(TQT_TQOBJECT(m_moving), TQT_TQEVENT(mev));
+ eventFilter(m_moving, mev);
delete mev;
}
else if(kev->key() == FormManager::self()->contextMenuKey())
@@ -435,7 +435,7 @@ Container::eventFilter(TQObject *s, TQEvent *e)
case TQEvent::KeyRelease:
{
- TQKeyEvent *kev = TQT_TQKEYEVENT(e);
+ TQKeyEvent *kev = static_cast<TQKeyEvent*>(e);
if((kev->key() == Key_Control) && (m_state == CopyingWidget)) {
// cancel copying
//m_copyRect = TQRect();
diff --git a/kexi/formeditor/widgetfactory.cpp b/kexi/formeditor/widgetfactory.cpp
index 14fd26654..6611be2f8 100644
--- a/kexi/formeditor/widgetfactory.cpp
+++ b/kexi/formeditor/widgetfactory.cpp
@@ -388,7 +388,7 @@ WidgetFactory::eventFilter(TQObject *obj, TQEvent *ev)
if(obj != (TQObject *)w)
return false;
- TQKeyEvent *e = TQT_TQKEYEVENT(ev);
+ TQKeyEvent *e = static_cast<TQKeyEvent*>(ev);
if(((e->key() == TQt::Key_Return) || (e->key() == TQt::Key_Enter)) && (e->state() != AltButton))
resetEditor();
if(e->key() == TQt::Key_Escape)
diff --git a/kexi/formeditor/widgetpropertyset.cpp b/kexi/formeditor/widgetpropertyset.cpp
index 99e6f511d..5beed16b2 100644
--- a/kexi/formeditor/widgetpropertyset.cpp
+++ b/kexi/formeditor/widgetpropertyset.cpp
@@ -749,13 +749,13 @@ WidgetPropertySet::eventFilter(TQObject *o, TQEvent *ev)
return false;
if(d->lastGeoCommand)
- d->lastGeoCommand->setPos(TQT_TQMOVEEVENT(ev)->pos());
+ d->lastGeoCommand->setPos(static_cast<TQMoveEvent*>(ev)->pos());
else {
TQStringList list;
foreach(TQGuardedWidgetList::ConstIterator, it, d->widgets)
list.append((*it)->name());
- d->lastGeoCommand = new GeometryPropertyCommand(this, list, TQT_TQMOVEEVENT(ev)->oldPos());
+ d->lastGeoCommand = new GeometryPropertyCommand(this, list, static_cast<TQMoveEvent*>(ev)->oldPos());
if (KFormDesigner::FormManager::self()->activeForm())
KFormDesigner::FormManager::self()->activeForm()->addCommand(d->lastGeoCommand, false);
}
diff --git a/kexi/kexiutils/utils.cpp b/kexi/kexiutils/utils.cpp
index ed62c07cb..4a0d54896 100644
--- a/kexi/kexiutils/utils.cpp
+++ b/kexi/kexiutils/utils.cpp
@@ -375,17 +375,17 @@ void* KexiUtils::stringToPtrInternal(const TQString& str, uint size)
void KexiUtils::setFocusWithReason(TQWidget* widget, TQFocusEvent::Reason reason)
{
TQEvent fe( TQEvent::FocusIn );
- TQT_TQFOCUSEVENT(&fe)->setReason(reason);
+ static_cast<TQFocusEvent*>(&fe)->setReason(reason);
TQApplication::sendEvent( widget, &fe );
- TQT_TQFOCUSEVENT(&fe)->resetReason();
+ static_cast<TQFocusEvent*>(&fe)->resetReason();
}
void KexiUtils::unsetFocusWithReason(TQWidget* widget, TQFocusEvent::Reason reason)
{
TQEvent fe( TQEvent::FocusOut );
- TQT_TQFOCUSEVENT(&fe)->setReason(reason);
+ static_cast<TQFocusEvent*>(&fe)->setReason(reason);
TQApplication::sendEvent( widget, &fe );
- TQT_TQFOCUSEVENT(&fe)->resetReason();
+ static_cast<TQFocusEvent*>(&fe)->resetReason();
}
CopyFileResult KexiUtils::copyFile(const TQString& src, const TQString& dest)
diff --git a/kexi/main/keximainwindowimpl.cpp b/kexi/main/keximainwindowimpl.cpp
index 1c313ba29..0920928bd 100644
--- a/kexi/main/keximainwindowimpl.cpp
+++ b/kexi/main/keximainwindowimpl.cpp
@@ -3408,18 +3408,18 @@ bool KexiMainWindowImpl::eventFilter( TQObject *obj, TQEvent * e )
{
//KexiVDebug << "eventFilter: " <<e->type() << " " <<obj->name()<<endl;
if (e->type()==TQEvent::KeyPress) {
- KexiVDebug << "KEY EVENT " << TQString::number(TQT_TQKEYEVENT(e)->key(), 16) << endl;
+ KexiVDebug << "KEY EVENT " << TQString::number(static_cast<TQKeyEvent*>(e)->key(), 16) << endl;
KexiVDebug << endl;
}
if (e->type()==TQEvent::AccelOverride) {
- //KexiVDebug << "AccelOverride EVENT " << TQT_TQKEYEVENT(e)->key() << " " << TQT_TQKEYEVENT(e)->state() == ControlButton << endl;
+ //KexiVDebug << "AccelOverride EVENT " << static_cast<TQKeyEvent*>(e)->key() << " " << static_cast<TQKeyEvent*>(e)->state() == ControlButton << endl;
//avoid sending CTRL+Tab key twice for tabbed/ideal mode, epecially for win32
- if (TQT_TQKEYEVENT(e)->key()==TQt::Key_Tab && TQT_TQKEYEVENT(e)->state() == ControlButton) {
+ if (static_cast<TQKeyEvent*>(e)->key()==TQt::Key_Tab && static_cast<TQKeyEvent*>(e)->state() == ControlButton) {
if (d->action_window_next->shortcut().keyCodeQt()==TQt::Key_Tab+TQt::CTRL && d->action_window_next->shortcut().count()==1
&& (mdiMode()==KMdi::TabPageMode || mdiMode()==KMdi::IDEAlMode))
{
- TQT_TQKEYEVENT(e)->accept();
+ static_cast<TQKeyEvent*>(e)->accept();
}
}
}
@@ -3536,7 +3536,7 @@ bool KexiMainWindowImpl::eventFilter( TQObject *obj, TQEvent * e )
//remember currently focued window invalidate act.
if (e->type()==TQEvent::FocusOut) {
- if (TQT_TQFOCUSEVENT(e)->reason()==TQFocusEvent::Popup) {
+ if (static_cast<TQFocusEvent*>(e)->reason()==TQFocusEvent::Popup) {
if (KexiUtils::hasParent(TQT_TQOBJECT(d->curDialog), TQT_TQOBJECT(focus_w))) {
invalidateSharedActions(TQT_TQOBJECT(d->curDialog));
d->focus_before_popup=d->curDialog;
@@ -3558,14 +3558,14 @@ bool KexiMainWindowImpl::eventFilter( TQObject *obj, TQEvent * e )
d->focus_before_popup=0;
return true;
} else if (e->type()==TQEvent::FocusOut) {
- if (TQT_TQFOCUSEVENT(e)->reason()==TQFocusEvent::Tab) {
+ if (static_cast<TQFocusEvent*>(e)->reason()==TQFocusEvent::Tab) {
//activate current child:
if (d->curDialog) {
d->curDialog->activate();
return true;
}
}
- else if (TQT_TQFOCUSEVENT(e)->reason()==TQFocusEvent::Popup) {
+ else if (static_cast<TQFocusEvent*>(e)->reason()==TQFocusEvent::Popup) {
d->focus_before_popup=w;
}
//invalidateSharedActions();
diff --git a/kexi/main/printing/kexisimpleprintpreviewwindow.cpp b/kexi/main/printing/kexisimpleprintpreviewwindow.cpp
index 3870f09e4..b6cb9f44d 100644
--- a/kexi/main/printing/kexisimpleprintpreviewwindow.cpp
+++ b/kexi/main/printing/kexisimpleprintpreviewwindow.cpp
@@ -338,7 +338,7 @@ bool KexiSimplePrintPreviewWindow::event( TQEvent * e )
{
TQEvent::Type t = e->type();
if (t==TQEvent::KeyPress) {
- TQKeyEvent *ke = TQT_TQKEYEVENT(e);
+ TQKeyEvent *ke = static_cast<TQKeyEvent*>(e);
const int k = ke->key();
bool ok = true;
if (k==TQt::Key_Equal || k==TQt::Key_Plus)
@@ -358,7 +358,7 @@ bool KexiSimplePrintPreviewWindow::event( TQEvent * e )
}
}
else if (t==TQEvent::AccelOverride) {
- TQKeyEvent *ke = TQT_TQKEYEVENT(e);
+ TQKeyEvent *ke = static_cast<TQKeyEvent*>(e);
const int k = ke->key();
bool ok = true;
if (k==TQt::Key_PageUp)
diff --git a/kexi/main/startup/KexiStartupDialog.cpp b/kexi/main/startup/KexiStartupDialog.cpp
index 9f3e5de74..c738d1923 100644
--- a/kexi/main/startup/KexiStartupDialog.cpp
+++ b/kexi/main/startup/KexiStartupDialog.cpp
@@ -658,7 +658,7 @@ bool KexiStartupDialog::eventFilter( TQObject *o, TQEvent *e )
{
if (o==d->templatesWidget_IconListBox && d->templatesWidget_IconListBox) {
if (e->type()==TQEvent::KeyPress
- && (TQT_TQKEYEVENT(e)->key()==Key_Enter || TQT_TQKEYEVENT(e)->key()==Key_Return)
+ && (static_cast<TQKeyEvent*>(e)->key()==Key_Enter || static_cast<TQKeyEvent*>(e)->key()==Key_Return)
|| e->type()==TQEvent::MouseButtonDblClick)
{
const int t_id = d->templatesWidget->activePageIndex();
diff --git a/kexi/main/startup/KexiStartupFileDialog.cpp b/kexi/main/startup/KexiStartupFileDialog.cpp
index 7b0aa5c84..61aa07353 100644
--- a/kexi/main/startup/KexiStartupFileDialog.cpp
+++ b/kexi/main/startup/KexiStartupFileDialog.cpp
@@ -409,9 +409,9 @@ void KexiStartupFileDialog::setFocus()
bool KexiStartupFileDialog::eventFilter ( TQObject * watched, TQEvent * e )
{
//filter-out ESC key
- if (e->type()==TQEvent::KeyPress && TQT_TQKEYEVENT(e)->key()==TQt::Key_Escape
- && TQT_TQKEYEVENT(e)->state()==TQt::NoButton) {
- TQT_TQKEYEVENT(e)->accept();
+ if (e->type()==TQEvent::KeyPress && static_cast<TQKeyEvent*>(e)->key()==TQt::Key_Escape
+ && static_cast<TQKeyEvent*>(e)->state()==TQt::NoButton) {
+ static_cast<TQKeyEvent*>(e)->accept();
emit rejected();
return true;
}
diff --git a/kexi/plugins/forms/widgets/kexidbcombobox.cpp b/kexi/plugins/forms/widgets/kexidbcombobox.cpp
index 088d0a48a..5fb89443a 100644
--- a/kexi/plugins/forms/widgets/kexidbcombobox.cpp
+++ b/kexi/plugins/forms/widgets/kexidbcombobox.cpp
@@ -338,7 +338,7 @@ bool KexiDBComboBox::eventFilter( TQObject *o, TQEvent *e )
}
else if (e->type()==TQEvent::Enter) {
if (!d->isEditable
- || /*over button if editable combo*/buttonGeometry().contains( TQT_TQMOUSEEVENT(e)->pos() ))
+ || /*over button if editable combo*/buttonGeometry().contains( static_cast<TQMouseEvent*>(e)->pos() ))
{
d->mouseOver = true;
update();
@@ -346,7 +346,7 @@ bool KexiDBComboBox::eventFilter( TQObject *o, TQEvent *e )
}
else if (e->type()==TQEvent::MouseMove) {
if (d->isEditable) {
- const bool overButton = buttonGeometry().contains( TQT_TQMOUSEEVENT(e)->pos() );
+ const bool overButton = buttonGeometry().contains( static_cast<TQMouseEvent*>(e)->pos() );
if (overButton != d->mouseOver) {
d->mouseOver = overButton;
update();
@@ -359,7 +359,7 @@ bool KexiDBComboBox::eventFilter( TQObject *o, TQEvent *e )
}
else if (e->type()==TQEvent::KeyPress) {
// handle F2/F4
- if (handleKeyPressEvent(TQT_TQKEYEVENT(e)))
+ if (handleKeyPressEvent(static_cast<TQKeyEvent*>(e)))
return true;
}
else if (e->type()==TQEvent::FocusOut) {
@@ -372,11 +372,11 @@ bool KexiDBComboBox::eventFilter( TQObject *o, TQEvent *e )
else if (!d->isEditable && d->subWidgetsWithDisabledEvents && d->subWidgetsWithDisabledEvents->find(o)) {
if (e->type()==TQEvent::MouseButtonPress) {
// clicking the subwidget should mean the same as clicking the combo box (i.e. show the popup)
- if (handleMousePressEvent(TQT_TQMOUSEEVENT(e)))
+ if (handleMousePressEvent(static_cast<TQMouseEvent*>(e)))
return true;
}
else if (e->type()==TQEvent::KeyPress) {
- if (handleKeyPressEvent(TQT_TQKEYEVENT(e)))
+ if (handleKeyPressEvent(static_cast<TQKeyEvent*>(e)))
return true;
}
return e->type()!=TQEvent::Paint;
diff --git a/kexi/plugins/forms/widgets/kexidbform.cpp b/kexi/plugins/forms/widgets/kexidbform.cpp
index 0fb4519e2..81ce66848 100644
--- a/kexi/plugins/forms/widgets/kexidbform.cpp
+++ b/kexi/plugins/forms/widgets/kexidbform.cpp
@@ -394,7 +394,7 @@ bool KexiDBForm::eventFilter( TQObject * watched, TQEvent * e )
kexipluginsdbg << "RESIZE" << endl;
if (e->type()==TQEvent::KeyPress) {
if (preview()) {
- TQKeyEvent *ke = TQT_TQKEYEVENT(e);
+ TQKeyEvent *ke = static_cast<TQKeyEvent*>(e);
const int key = ke->key();
bool tab = ke->state() == TQt::NoButton && key == TQt::Key_Tab;
bool backtab = ((ke->state() == TQt::NoButton || ke->state() == TQt::ShiftButton) && key == TQt::Key_Backtab)
@@ -569,7 +569,7 @@ bool KexiDBForm::eventFilter( TQObject * watched, TQEvent * e )
}
else if (e->type()==TQEvent::FocusIn) {
bool focusDataWidget = preview();
- if (TQT_TQFOCUSEVENT(e)->reason()==TQFocusEvent::Popup) {
+ if (static_cast<TQFocusEvent*>(e)->reason()==TQFocusEvent::Popup) {
kdDebug() << "->>> focus IN, popup" <<endl;
focusDataWidget = !d->popupFocused;
d->popupFocused = false;
@@ -608,7 +608,7 @@ bool KexiDBForm::eventFilter( TQObject * watched, TQEvent * e )
}
}
else if (e->type()==TQEvent::FocusOut) {
- if (TQT_TQFOCUSEVENT(e)->reason()==TQFocusEvent::Popup) {
+ if (static_cast<TQFocusEvent*>(e)->reason()==TQFocusEvent::Popup) {
//d->widgetFocusedBeforePopup = (TQWidget*)watched;
d->popupFocused = true;
}
@@ -616,7 +616,7 @@ bool KexiDBForm::eventFilter( TQObject * watched, TQEvent * e )
d->popupFocused = false;
// d->widgetFocusedBeforePopup = 0;
// kdDebug() << "e->type()==TQEvent::FocusOut " << watched->className() << " " <<watched->name() << endl;
-// UNSET_FOCUS_USING_REASON(watched, TQT_TQFOCUSEVENT(e)->reason());
+// UNSET_FOCUS_USING_REASON(watched, static_cast<TQFocusEvent*>(e)->reason());
}
return KexiDBFormBase::eventFilter(watched, e);
}
diff --git a/kexi/plugins/forms/widgets/kexidblineedit.cpp b/kexi/plugins/forms/widgets/kexidblineedit.cpp
index 5d1fadf61..5e2ac08ab 100644
--- a/kexi/plugins/forms/widgets/kexidblineedit.cpp
+++ b/kexi/plugins/forms/widgets/kexidblineedit.cpp
@@ -346,7 +346,7 @@ bool KexiDBLineEdit::event( TQEvent * e )
const bool ret = KLineEdit::event( e );
KexiDBTextWidgetInterface::event(e, this, text().isEmpty());
if (e->type()==TQEvent::FocusOut) {
- TQFocusEvent *fe = TQT_TQFOCUSEVENT(e);
+ TQFocusEvent *fe = static_cast<TQFocusEvent*>(e);
// if (fe->reason()!=TQFocusEvent::ActiveWindow && fe->reason()!=TQFocusEvent::Popup) {
if (fe->reason()==TQFocusEvent::Tab || fe->reason()==TQFocusEvent::Backtab) {
//display aligned to left after loosing the focus (only if this is tab/backtab event)
diff --git a/kexi/plugins/importexport/csv/kexicsvimportdialog.cpp b/kexi/plugins/importexport/csv/kexicsvimportdialog.cpp
index daf536c59..9c9c5f222 100644
--- a/kexi/plugins/importexport/csv/kexicsvimportdialog.cpp
+++ b/kexi/plugins/importexport/csv/kexicsvimportdialog.cpp
@@ -1630,7 +1630,7 @@ bool KexiCSVImportDialog::eventFilter ( TQObject * watched, TQEvent * e )
return true;
if (watched == m_startAtLineSpinBox && t==TQEvent::KeyPress) {
- TQKeyEvent *ke = TQT_TQKEYEVENT(e);
+ TQKeyEvent *ke = static_cast<TQKeyEvent*>(e);
if (ke->key()==TQt::Key_Enter || ke->key()==TQt::Key_Return) {
m_table->setFocus();
return true;
diff --git a/kexi/widget/kexibrowser.cpp b/kexi/widget/kexibrowser.cpp
index 1d59dae04..dd0b16a15 100644
--- a/kexi/widget/kexibrowser.cpp
+++ b/kexi/widget/kexibrowser.cpp
@@ -567,7 +567,7 @@ bool KexiBrowser::eventFilter ( TQObject *o, TQEvent * e )
itemRenameDone();
}
else if (e->type()==TQEvent::KeyPress) {
- TQKeyEvent *ke = TQT_TQKEYEVENT(e);
+ TQKeyEvent *ke = static_cast<TQKeyEvent*>(e);
if (ke->key()==TQt::Key_Enter || ke->key()==TQt::Key_Return) {
if (0==(ke->state() & (TQt::ShiftButton|TQt::ControlButton|TQt::AltButton))) {
TQListViewItem *it = m_list->selectedItem();
@@ -580,7 +580,7 @@ bool KexiBrowser::eventFilter ( TQObject *o, TQEvent * e )
}
}
else if (e->type()==TQEvent::AccelOverride) {
- TQKeyEvent *ke = TQT_TQKEYEVENT(e);
+ TQKeyEvent *ke = static_cast<TQKeyEvent*>(e);
//override delete action
if (ke->key()==TQt::Key_Delete && ke->state()==TQt::NoButton) {
slotRemove();
diff --git a/kexi/widget/relations/kexirelationviewtable.cpp b/kexi/widget/relations/kexirelationviewtable.cpp
index 347805be8..7053c7781 100644
--- a/kexi/widget/relations/kexirelationviewtable.cpp
+++ b/kexi/widget/relations/kexirelationviewtable.cpp
@@ -208,10 +208,10 @@ bool KexiRelationViewTableContainerHeader::eventFilter(TQObject *, TQEvent *ev)
{
if (ev->type()==TQEvent::MouseMove)
{
- if (m_dragging && TQT_TQMOUSEEVENT(ev)->state()==TQt::LeftButton) {
+ if (m_dragging && static_cast<TQMouseEvent*>(ev)->state()==TQt::LeftButton) {
int diffX,diffY;
- diffX=TQT_TQMOUSEEVENT(ev)->globalPos().x()-m_grabX;
- diffY=TQT_TQMOUSEEVENT(ev)->globalPos().y()-m_grabY;
+ diffX=static_cast<TQMouseEvent*>(ev)->globalPos().x()-m_grabX;
+ diffY=static_cast<TQMouseEvent*>(ev)->globalPos().y()-m_grabY;
if ((abs(diffX)>2) || (abs(diffY)>2))
{
TQPoint newPos=parentWidget()->pos()+TQPoint(diffX,diffY);
@@ -245,8 +245,8 @@ bool KexiRelationViewTableContainerHeader::eventFilter(TQObject *, TQEvent *ev)
//move and update helpers
parentWidget()->move(newPos);
- m_grabX=TQT_TQMOUSEEVENT(ev)->globalPos().x();
- m_grabY=TQT_TQMOUSEEVENT(ev)->globalPos().y();
+ m_grabX=static_cast<TQMouseEvent*>(ev)->globalPos().x();
+ m_grabY=static_cast<TQMouseEvent*>(ev)->globalPos().y();
// kdDebug()<<"HEADER:emitting moved"<<endl;
emit moved();
}
diff --git a/kexi/widget/tableview/kexiblobtableedit.cpp b/kexi/widget/tableview/kexiblobtableedit.cpp
index 75f516111..b3de34193 100644
--- a/kexi/widget/tableview/kexiblobtableedit.cpp
+++ b/kexi/widget/tableview/kexiblobtableedit.cpp
@@ -456,7 +456,7 @@ void KexiBlobTableEdit::handleAction(const TQString& actionName)
bool KexiBlobTableEdit::eventFilter( TQObject *o, TQEvent *e )
{
if (o == d->popup && e->type()==TQEvent::KeyPress) {
- TQKeyEvent* ke = TQT_TQKEYEVENT(e);
+ TQKeyEvent* ke = static_cast<TQKeyEvent*>(e);
const int state = ke->state();
const int k = ke->key();
if ( (state==TQt::NoButton && (k==TQt::Key_Tab || k==TQt::Key_Left || k==TQt::Key_Right))
diff --git a/kexi/widget/tableview/kexicomboboxpopup.cpp b/kexi/widget/tableview/kexicomboboxpopup.cpp
index dfd6edb45..6877bd780 100644
--- a/kexi/widget/tableview/kexicomboboxpopup.cpp
+++ b/kexi/widget/tableview/kexicomboboxpopup.cpp
@@ -351,7 +351,7 @@ bool KexiComboBoxPopup::eventFilter( TQObject *o, TQEvent *e )
}
else if (o==d->tv) {
if (e->type()==TQEvent::KeyPress) {
- TQKeyEvent *ke = TQT_TQKEYEVENT(e);
+ TQKeyEvent *ke = static_cast<TQKeyEvent*>(e);
const int k = ke->key();
if ((ke->state()==TQt::NoButton && (k==Key_Escape || k==Key_F4))
|| (ke->state()==AltButton && k==Key_Up))
diff --git a/kexi/widget/tableview/kexicomboboxtableedit.cpp b/kexi/widget/tableview/kexicomboboxtableedit.cpp
index a818e40b9..0ac9923e6 100644
--- a/kexi/widget/tableview/kexicomboboxtableedit.cpp
+++ b/kexi/widget/tableview/kexicomboboxtableedit.cpp
@@ -348,7 +348,7 @@ int KexiComboBoxTableEdit::widthForValue( TQVariant &val, const TQFontMetrics &f
bool KexiComboBoxTableEdit::eventFilter( TQObject *o, TQEvent *e )
{
if (!column()->isReadOnly() && e->type()==TQEvent::MouseButtonPress && m_scrollView) {
- TQPoint gp = TQT_TQMOUSEEVENT(e)->globalPos()
+ TQPoint gp = static_cast<TQMouseEvent*>(e)->globalPos()
+ TQPoint(m_scrollView->childX(d->button), m_scrollView->childY(d->button));
TQRect r(d->button->mapToGlobal(d->button->geometry().topLeft()),
d->button->mapToGlobal(d->button->geometry().bottomRight()));
diff --git a/kexi/widget/tableview/kexitableedit.cpp b/kexi/widget/tableview/kexitableedit.cpp
index 943ec1e89..a4b70aaba 100644
--- a/kexi/widget/tableview/kexitableedit.cpp
+++ b/kexi/widget/tableview/kexitableedit.cpp
@@ -124,7 +124,7 @@ KexiTableEdit::eventFilter(TQObject* watched, TQEvent* e)
{
if(e->type() == TQEvent::KeyPress)
{
- TQKeyEvent* ev = TQT_TQKEYEVENT(e);
+ TQKeyEvent* ev = static_cast<TQKeyEvent*>(e);
if(ev->key() == Key_Escape)
{
diff --git a/kexi/widget/tableview/kexitableview.cpp b/kexi/widget/tableview/kexitableview.cpp
index 284cbd1da..dbb89f5db 100644
--- a/kexi/widget/tableview/kexitableview.cpp
+++ b/kexi/widget/tableview/kexitableview.cpp
@@ -2412,7 +2412,7 @@ bool KexiTableView::eventFilter( TQObject *o, TQEvent *e )
if (e->type()==TQEvent::KeyPress) {
if (e->spontaneous() /*|| e->type()==TQEvent::AccelOverride*/) {
- TQKeyEvent *ke = TQT_TQKEYEVENT(e);
+ TQKeyEvent *ke = static_cast<TQKeyEvent*>(e);
const int k = ke->key();
int s = ke->state();
//cell editor's events:
diff --git a/kexi/widget/tableview/kexitableviewheader.cpp b/kexi/widget/tableview/kexitableviewheader.cpp
index 0ee90f5a9..305222ca2 100644
--- a/kexi/widget/tableview/kexitableviewheader.cpp
+++ b/kexi/widget/tableview/kexitableviewheader.cpp
@@ -120,7 +120,7 @@ void KexiTableViewHeader::setToolTip( int section, const TQString & toolTip )
bool KexiTableViewHeader::eventFilter(TQObject * watched, TQEvent * e)
{
if (e->type()==TQEvent::MouseMove) {
- const int section = sectionAt( TQT_TQMOUSEEVENT(e)->x() );
+ const int section = sectionAt( static_cast<TQMouseEvent*>(e)->x() );
if (section != m_lastToolTipSection && section >= 0 && section < (int)m_toolTips.count()) {
TQToolTip::remove(this, m_toolTipRect);
TQString tip = m_toolTips[ section ];
diff --git a/kexi/widget/utils/kexirecordnavigator.cpp b/kexi/widget/utils/kexirecordnavigator.cpp
index d61c7dc89..334c605ab 100644
--- a/kexi/widget/utils/kexirecordnavigator.cpp
+++ b/kexi/widget/utils/kexirecordnavigator.cpp
@@ -196,7 +196,7 @@ bool KexiRecordNavigator::eventFilter( TQObject *o, TQEvent *e )
bool recordEntered = false;
bool ret;
if (e->type()==TQEvent::KeyPress) {
- TQKeyEvent *ke = TQT_TQKEYEVENT(e);
+ TQKeyEvent *ke = static_cast<TQKeyEvent*>(e);
switch (ke->key()) {
case TQt::Key_Escape: {
ke->accept();
@@ -218,9 +218,9 @@ bool KexiRecordNavigator::eventFilter( TQObject *o, TQEvent *e )
}
}
else if (e->type()==TQEvent::FocusOut) {
- if (TQT_TQFOCUSEVENT(e)->reason()!=TQFocusEvent::Tab
- && TQT_TQFOCUSEVENT(e)->reason()!=TQFocusEvent::Backtab
- && TQT_TQFOCUSEVENT(e)->reason()!=TQFocusEvent::Other)
+ if (static_cast<TQFocusEvent*>(e)->reason()!=TQFocusEvent::Tab
+ && static_cast<TQFocusEvent*>(e)->reason()!=TQFocusEvent::Backtab
+ && static_cast<TQFocusEvent*>(e)->reason()!=TQFocusEvent::Other)
recordEntered=true;
ret = false;
}
diff --git a/kivio/kiviopart/addstenciltool.cpp b/kivio/kiviopart/addstenciltool.cpp
index ddbe38c55..4e3f14ecc 100644
--- a/kivio/kiviopart/addstenciltool.cpp
+++ b/kivio/kiviopart/addstenciltool.cpp
@@ -51,7 +51,7 @@ bool AddStencilTool::processEvent(TQEvent* e)
switch(e->type()) {
case TQEvent::MouseButtonPress:
{
- TQMouseEvent* me = TQT_TQMOUSEEVENT(e);
+ TQMouseEvent* me = static_cast<TQMouseEvent*>(e);
if(me->button() == TQt::LeftButton) {
m_leftMouseButtonPressed = true;
@@ -63,7 +63,7 @@ bool AddStencilTool::processEvent(TQEvent* e)
}
case TQEvent::MouseButtonRelease:
{
- TQMouseEvent* me = TQT_TQMOUSEEVENT(e);
+ TQMouseEvent* me = static_cast<TQMouseEvent*>(e);
if(m_leftMouseButtonPressed && (me->button() == TQt::LeftButton)) {
m_leftMouseButtonPressed = false;
@@ -75,7 +75,7 @@ bool AddStencilTool::processEvent(TQEvent* e)
}
case TQEvent::MouseMove:
{
- TQMouseEvent* me = TQT_TQMOUSEEVENT(e);
+ TQMouseEvent* me = static_cast<TQMouseEvent*>(e);
if(m_leftMouseButtonPressed) {
resize(me->pos());
diff --git a/kivio/kiviopart/ui/kivio_birdeye_panel.cpp b/kivio/kiviopart/ui/kivio_birdeye_panel.cpp
index 8cb189768..ed92bff8b 100644
--- a/kivio/kiviopart/ui/kivio_birdeye_panel.cpp
+++ b/kivio/kiviopart/ui/kivio_birdeye_panel.cpp
@@ -99,7 +99,7 @@ bool KivioBirdEyePanel::eventFilter(TQObject* o, TQEvent* ev)
}
if (o == canvas && ev->type() == TQEvent::MouseMove) {
- TQMouseEvent* me = TQT_TQMOUSEEVENT(ev);
+ TQMouseEvent* me = static_cast<TQMouseEvent*>(ev);
if (me->state() == TQt::LeftButton)
handleMouseMoveAction(me->pos());
else
@@ -110,7 +110,7 @@ bool KivioBirdEyePanel::eventFilter(TQObject* o, TQEvent* ev)
}
if (o == canvas && ev->type() == TQEvent::MouseButtonPress) {
- TQMouseEvent* me = TQT_TQMOUSEEVENT(ev);
+ TQMouseEvent* me = static_cast<TQMouseEvent*>(ev);
if (me->button() == TQt::LeftButton)
handleMousePress(me->pos());
diff --git a/kivio/plugins/kivioconnectortool/tool_connector.cpp b/kivio/plugins/kivioconnectortool/tool_connector.cpp
index 5e45cc369..5ca46ebbc 100644
--- a/kivio/plugins/kivioconnectortool/tool_connector.cpp
+++ b/kivio/plugins/kivioconnectortool/tool_connector.cpp
@@ -93,17 +93,17 @@ bool ConnectorTool::processEvent(TQEvent* e)
switch (e->type())
{
case TQEvent::MouseButtonPress:
- mousePress( TQT_TQMOUSEEVENT(e) );
+ mousePress( static_cast<TQMouseEvent*>(e) );
return true;
break;
case TQEvent::MouseButtonRelease:
- mouseRelease( TQT_TQMOUSEEVENT(e) );
+ mouseRelease( static_cast<TQMouseEvent*>(e) );
return true;
break;
case TQEvent::MouseMove:
- mouseMove( TQT_TQMOUSEEVENT(e) );
+ mouseMove( static_cast<TQMouseEvent*>(e) );
return true;
break;
diff --git a/kivio/plugins/kivioselecttool/tool_select.cpp b/kivio/plugins/kivioselecttool/tool_select.cpp
index 86a05245f..50cdecc73 100644
--- a/kivio/plugins/kivioselecttool/tool_select.cpp
+++ b/kivio/plugins/kivioselecttool/tool_select.cpp
@@ -128,13 +128,13 @@ bool SelectTool::processEvent(TQEvent* e)
break;
case TQEvent::MouseMove:
- mouseMove( TQT_TQMOUSEEVENT(e));
+ mouseMove( static_cast<TQMouseEvent*>(e));
return true;
break;
case TQEvent::KeyPress:
- if((TQT_TQKEYEVENT(e)->key() >= Key_Left) && (TQT_TQKEYEVENT(e)->key() <= Key_Down)) {
- keyPress(TQT_TQKEYEVENT(e));
+ if((static_cast<TQKeyEvent*>(e)->key() >= Key_Left) && (static_cast<TQKeyEvent*>(e)->key() <= Key_Down)) {
+ keyPress(static_cast<TQKeyEvent*>(e));
return true;
}
break;
diff --git a/kivio/plugins/kiviotargettool/kiviotargettool.cpp b/kivio/plugins/kiviotargettool/kiviotargettool.cpp
index be6f60d8d..46f6b5c59 100644
--- a/kivio/plugins/kiviotargettool/kiviotargettool.cpp
+++ b/kivio/plugins/kiviotargettool/kiviotargettool.cpp
@@ -49,10 +49,10 @@ namespace Kivio {
bool TargetTool::processEvent(TQEvent* e)
{
if(e->type() == TQEvent::MouseButtonPress) {
- mousePress(TQT_TQMOUSEEVENT(e));
+ mousePress(static_cast<TQMouseEvent*>(e));
return true;
} else if(e->type() == TQEvent::MouseMove) {
- mouseMove(TQT_TQMOUSEEVENT(e));
+ mouseMove(static_cast<TQMouseEvent*>(e));
return true;
}
diff --git a/kivio/plugins/kiviozoomtool/tool_zoom.cpp b/kivio/plugins/kiviozoomtool/tool_zoom.cpp
index d2a10db87..2ae6cfea9 100644
--- a/kivio/plugins/kiviozoomtool/tool_zoom.cpp
+++ b/kivio/plugins/kiviozoomtool/tool_zoom.cpp
@@ -110,14 +110,14 @@ bool ZoomTool::processEvent(TQEvent* e)
if(!m_bHandMode) {
switch(e->type()) {
case TQEvent::KeyPress:
- if (!m_bLockKeyboard && (TQT_TQKEYEVENT(e)->key() == Key_Shift)) {
+ if (!m_bLockKeyboard && (static_cast<TQKeyEvent*>(e)->key() == Key_Shift)) {
m_pCurrent = m_pMinus;
canvas->setCursor(*m_pMinusCursor);
return true;
}
break;
case TQEvent::KeyRelease:
- if (!m_bLockKeyboard && (TQT_TQKEYEVENT(e)->key() == Key_Shift)) {
+ if (!m_bLockKeyboard && (static_cast<TQKeyEvent*>(e)->key() == Key_Shift)) {
m_pCurrent = m_pPlus;
canvas->setCursor(*m_pPlusCursor);
return true;
@@ -125,7 +125,7 @@ bool ZoomTool::processEvent(TQEvent* e)
break;
case TQEvent::MouseButtonPress:
{
- TQMouseEvent* me = TQT_TQMOUSEEVENT(e);
+ TQMouseEvent* me = static_cast<TQMouseEvent*>(e);
if(me->button() == TQt::LeftButton) {
if(m_pCurrent == m_pMinus) {
@@ -153,7 +153,7 @@ bool ZoomTool::processEvent(TQEvent* e)
break;
case TQEvent::MouseMove:
if (m_bDrawRubber) {
- canvas->continueRectDraw(TQT_TQMOUSEEVENT(e)->pos(), KivioCanvas::Rubber);
+ canvas->continueRectDraw(static_cast<TQMouseEvent*>(e)->pos(), KivioCanvas::Rubber);
return true;
}
break;
@@ -164,7 +164,7 @@ bool ZoomTool::processEvent(TQEvent* e)
switch(e->type()) {
case TQEvent::MouseButtonPress:
isHandMousePressed = true;
- mousePos = TQT_TQMOUSEEVENT(e)->pos();
+ mousePos = static_cast<TQMouseEvent*>(e)->pos();
return true;
break;
case TQEvent::MouseButtonRelease:
@@ -174,7 +174,7 @@ bool ZoomTool::processEvent(TQEvent* e)
case TQEvent::MouseMove:
if (isHandMousePressed) {
canvas->setUpdatesEnabled(false);
- TQPoint newPos = TQT_TQMOUSEEVENT(e)->pos();
+ TQPoint newPos = static_cast<TQMouseEvent*>(e)->pos();
mousePos -= newPos;
canvas->scrollDx(-mousePos.x());
canvas->scrollDy(-mousePos.y());
diff --git a/kpresenter/KPrCanvas.cpp b/kpresenter/KPrCanvas.cpp
index 04a81ae32..245d83f26 100644
--- a/kpresenter/KPrCanvas.cpp
+++ b/kpresenter/KPrCanvas.cpp
@@ -226,7 +226,7 @@ bool KPrCanvas::eventFilter( TQObject *o, TQEvent *e )
return TRUE;
case TQEvent::KeyPress:
{
- TQKeyEvent * keyev = TQT_TQKEYEVENT(e);
+ TQKeyEvent * keyev = static_cast<TQKeyEvent*>(e);
if ( keyev->key() == TDEGlobalSettings::contextMenuKey() ) {
popupContextMenu();
return true;
@@ -249,7 +249,7 @@ bool KPrCanvas::eventFilter( TQObject *o, TQEvent *e )
case TQEvent::AccelOverride:
{
#ifndef NDEBUG
- TQKeyEvent * keyev = TQT_TQKEYEVENT(e);
+ TQKeyEvent * keyev = static_cast<TQKeyEvent*>(e);
// Debug keys
if ( ( keyev->state() & ControlButton ) && ( keyev->state() & ShiftButton ) )
{
diff --git a/kspread/kspread_canvas.cpp b/kspread/kspread_canvas.cpp
index 1154f650b..837f6e98a 100644
--- a/kspread/kspread_canvas.cpp
+++ b/kspread/kspread_canvas.cpp
@@ -357,7 +357,7 @@ bool Canvas::eventFilter( TQObject *o, TQEvent *e )
{
case TQEvent::KeyPress:
{
- TQKeyEvent * keyev = TQT_TQKEYEVENT(e);
+ TQKeyEvent * keyev = static_cast<TQKeyEvent*>(e);
if ((keyev->key()==Key_Tab) || (keyev->key()==Key_Backtab))
{
keyPressEvent ( keyev );
diff --git a/kword/KWCanvas.cpp b/kword/KWCanvas.cpp
index fb0889f69..3412b029a 100644
--- a/kword/KWCanvas.cpp
+++ b/kword/KWCanvas.cpp
@@ -1725,7 +1725,7 @@ bool KWCanvas::eventFilter( TQObject *o, TQEvent *e )
{
// kdDebug() << " KeyPress m_currentFrameSetEdit=" << m_currentFrameSetEdit << " isRW="<<m_doc->isReadWrite() << endl;
// kdDebug() << " m_printing=" << m_printing << " mousemode=" << m_mouseMode << " (MM_EDIT=" << MM_EDIT<<")"<<endl;
- TQKeyEvent * keyev = TQT_TQKEYEVENT(e);
+ TQKeyEvent * keyev = static_cast<TQKeyEvent*>(e);
#ifndef NDEBUG
// Debug keys
if ( ( keyev->state() & ControlButton ) && ( keyev->state() & ShiftButton ) )
@@ -1768,7 +1768,7 @@ bool KWCanvas::eventFilter( TQObject *o, TQEvent *e )
{
// kdDebug() << " KeyPress m_currentFrameSetEdit=" << m_currentFrameSetEdit << " isRW="<<m_doc->isReadWrite() << endl;
// kdDebug() << " m_printing=" << m_printing << " mousemode=" << m_mouseMode << " (MM_EDIT=" << MM_EDIT<<")"<<endl;
- TQKeyEvent * keyev = TQT_TQKEYEVENT(e);
+ TQKeyEvent * keyev = static_cast<TQKeyEvent*>(e);
// By default PgUp and PgDown move the scrollbars and not the caret anymore - this is done here
if ( !m_doc->pgUpDownMovesCaret() && ( (keyev->state() & ShiftButton) == 0 )
&& ( keyev->key() == TQt::Key_PageUp || keyev->key() == Key_PageDown ) )
@@ -1879,7 +1879,7 @@ bool KWCanvas::eventFilter( TQObject *o, TQEvent *e )
} break;
case TQEvent::KeyRelease:
{
- TQKeyEvent * keyev = TQT_TQKEYEVENT(e);
+ TQKeyEvent * keyev = static_cast<TQKeyEvent*>(e);
if ( keyev->key() == TQt::Key_Control )
{
TQPoint mousep = mapFromGlobal(TQCursor::pos()) + TQPoint( contentsX(), contentsY() );
diff --git a/lib/kofficecore/KoContainerHandler.cpp b/lib/kofficecore/KoContainerHandler.cpp
index ff81b632a..74c49a7ed 100644
--- a/lib/kofficecore/KoContainerHandler.cpp
+++ b/lib/kofficecore/KoContainerHandler.cpp
@@ -302,7 +302,7 @@ bool KoContainerHandler::eventFilter( TQObject*, TQEvent* ev )
{
KoChild::Gadget gadget;
TQPoint pos;
- TQMouseEvent *e=TQT_TQMOUSEEVENT(ev);
+ TQMouseEvent *e=static_cast<TQMouseEvent*>(ev);
KoChild *ch=child(gadget, pos, e);
if ( e->button() == TQt::RightButton && gadget != KoChild::NoGadget )
@@ -327,7 +327,7 @@ bool KoContainerHandler::eventFilter( TQObject*, TQEvent* ev )
TQWidget *targetWidget = TQT_TQWIDGET( target() );
KoChild::Gadget gadget;
TQPoint pos;
- TQMouseEvent *e=TQT_TQMOUSEEVENT(ev);
+ TQMouseEvent *e=static_cast<TQMouseEvent*>(ev);
child(gadget, pos, e);
bool retval = true;
diff --git a/lib/kofficeui/KoTooluButton.cpp b/lib/kofficeui/KoTooluButton.cpp
index 1c5f5f1ff..bbe4145a0 100644
--- a/lib/kofficeui/KoTooluButton.cpp
+++ b/lib/kofficeui/KoTooluButton.cpp
@@ -811,7 +811,7 @@ bool KoToolButton::eventFilter( TQObject* o, TQEvent* e )
{
if ( o == m_popup ) {
if ( e->type() == TQEvent::MouseButtonPress )
- if ( hitArrow( mapFromGlobal( TQT_TQMOUSEEVENT( e )->globalPos() ) ) ) {
+ if ( hitArrow( mapFromGlobal( static_cast<TQMouseEvent*>( e )->globalPos() ) ) ) {
kdDebug() << "KoToolButton::eventFilter-------------->" << endl;
m_popup->close();
m_arrowPressed = false;
@@ -821,7 +821,7 @@ bool KoToolButton::eventFilter( TQObject* o, TQEvent* e )
}
if ( e->type() == TQEvent::MouseButtonPress ) {
- m_arrowPressed = hitArrow( TQT_TQMOUSEEVENT( e )->pos() );
+ m_arrowPressed = hitArrow( static_cast<TQMouseEvent*>( e )->pos() );
if ( m_arrowPressed )
m_popup->popup( mapToGlobal( TQPoint( 0, height() ) ) );
}
diff --git a/lib/koproperty/editor.cpp b/lib/koproperty/editor.cpp
index 2a72fdbe6..ddd235398 100644
--- a/lib/koproperty/editor.cpp
+++ b/lib/koproperty/editor.cpp
@@ -916,7 +916,7 @@ bool
Editor::eventFilter( TQObject * watched, TQEvent * e )
{
if ((watched==this || watched==viewport()) && e->type()==TQEvent::KeyPress) {
- if (handleKeyPress(TQT_TQKEYEVENT(e)))
+ if (handleKeyPress(static_cast<TQKeyEvent*>(e)))
return true;
}
return TDEListView::eventFilter(watched, e);
diff --git a/lib/koproperty/editoritem.cpp b/lib/koproperty/editoritem.cpp
index 2d2b99de5..1d186c4ce 100644
--- a/lib/koproperty/editoritem.cpp
+++ b/lib/koproperty/editoritem.cpp
@@ -157,7 +157,7 @@ class GroupWidgetBase : public TQWidget
virtual bool event( TQEvent * e ) {
if (e->type()==TQEvent::MouseButtonPress || e->type()==TQEvent::MouseButtonRelease) {
- TQMouseEvent* me = TQT_TQMOUSEEVENT(e);
+ TQMouseEvent* me = static_cast<TQMouseEvent*>(e);
if (me->button() == TQt::LeftButton) {
m_mouseDown = e->type()==TQEvent::MouseButtonPress;
update();
@@ -238,7 +238,7 @@ void GroupContainer::setContents( TQWidget* contents )
bool GroupContainer::event( TQEvent * e ) {
if (e->type()==TQEvent::MouseButtonPress) {
- TQMouseEvent* me = TQT_TQMOUSEEVENT(e);
+ TQMouseEvent* me = static_cast<TQMouseEvent*>(e);
if (me->button() == TQt::LeftButton && d->contents && d->groupWidget->rect().contains(me->pos())) {
d->groupWidget->setOpen(!d->groupWidget->isOpen());
if (d->groupWidget->isOpen())
diff --git a/lib/koproperty/editors/booledit.cpp b/lib/koproperty/editors/booledit.cpp
index 0e14bf27b..fb71a4453 100644
--- a/lib/koproperty/editors/booledit.cpp
+++ b/lib/koproperty/editors/booledit.cpp
@@ -131,7 +131,7 @@ bool
BoolEdit::eventFilter(TQObject* watched, TQEvent* e)
{
if(e->type() == TQEvent::KeyPress) {
- TQKeyEvent* ev = TQT_TQKEYEVENT(e);
+ TQKeyEvent* ev = static_cast<TQKeyEvent*>(e);
const int k = ev->key();
if(k == TQt::Key_Space || k == TQt::Key_Enter || k == TQt::Key_Return) {
if (m_toggle)
diff --git a/lib/koproperty/editors/fontedit.cpp b/lib/koproperty/editors/fontedit.cpp
index 0ea29b6e8..e53e785f3 100644
--- a/lib/koproperty/editors/fontedit.cpp
+++ b/lib/koproperty/editors/fontedit.cpp
@@ -138,7 +138,7 @@ bool
FontEdit::eventFilter(TQObject* watched, TQEvent* e)
{
if(e->type() == TQEvent::KeyPress) {
- TQKeyEvent* ev = TQT_TQKEYEVENT(e);
+ TQKeyEvent* ev = static_cast<TQKeyEvent*>(e);
if(ev->key() == Key_Space) {
m_edit->button()->animateClick();
return true;
diff --git a/lib/koproperty/editors/pixmapedit.cpp b/lib/koproperty/editors/pixmapedit.cpp
index b6454a96c..070de038b 100644
--- a/lib/koproperty/editors/pixmapedit.cpp
+++ b/lib/koproperty/editors/pixmapedit.cpp
@@ -206,7 +206,7 @@ bool
PixmapEdit::eventFilter(TQObject *o, TQEvent *ev)
{
if(o == m_edit) {
- if(ev->type() == TQEvent::MouseButtonPress && TQT_TQMOUSEEVENT(ev)->button()==TQt::LeftButton) {
+ if(ev->type() == TQEvent::MouseButtonPress && static_cast<TQMouseEvent*>(ev)->button()==TQt::LeftButton) {
if(m_previewPixmap.height() <= m_edit->height()
&& m_previewPixmap.width() <= m_edit->width())
return false;
@@ -227,7 +227,7 @@ PixmapEdit::eventFilter(TQObject *o, TQEvent *ev)
m_popup->hide();
}
else if(ev->type() == TQEvent::KeyPress) {
- TQKeyEvent* e = TQT_TQKEYEVENT(ev);
+ TQKeyEvent* e = static_cast<TQKeyEvent*>(ev);
if((e->key() == Key_Enter) || (e->key()== Key_Space) || (e->key() == Key_Return)) {
m_button->animateClick();
return true;
diff --git a/lib/koproperty/editors/spinbox.cpp b/lib/koproperty/editors/spinbox.cpp
index e76ca930d..81f0c1cb7 100644
--- a/lib/koproperty/editors/spinbox.cpp
+++ b/lib/koproperty/editors/spinbox.cpp
@@ -63,7 +63,7 @@ IntSpinBox::eventFilter(TQObject *o, TQEvent *e)
{
if(e->type() == TQEvent::KeyPress)
{
- TQKeyEvent* ev = TQT_TQKEYEVENT(e);
+ TQKeyEvent* ev = static_cast<TQKeyEvent*>(e);
if((ev->key()==Key_Up || ev->key()==Key_Down) && ev->state() !=ControlButton)
{
parentWidget()->eventFilter(o, e);
@@ -196,7 +196,7 @@ DoubleSpinBox::eventFilter(TQObject *o, TQEvent *e)
{
if(e->type() == TQEvent::KeyPress)
{
- TQKeyEvent* ev = TQT_TQKEYEVENT(e);
+ TQKeyEvent* ev = static_cast<TQKeyEvent*>(e);
if((ev->key()==Key_Up || ev->key()==Key_Down) && ev->state()!=ControlButton)
{
parentWidget()->eventFilter(o, e);
diff --git a/lib/koproperty/widget.cpp b/lib/koproperty/widget.cpp
index 1e1593db2..99724979b 100644
--- a/lib/koproperty/widget.cpp
+++ b/lib/koproperty/widget.cpp
@@ -109,7 +109,7 @@ Widget::eventFilter(TQObject*, TQEvent* e)
{
if(e->type() == TQEvent::KeyPress)
{
- TQKeyEvent* ev = TQT_TQKEYEVENT(e);
+ TQKeyEvent* ev = static_cast<TQKeyEvent*>(e);
if(ev->key() == Key_Escape)
{
emit rejectInput(this);