Replace 'Event' #define strings

Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
(cherry picked from commit 05d3e5e5e6)
r14.1.x
Michele Calgaro 1 year ago
parent 832a6a8631
commit 0851e201c3
Signed by: MicheleC
GPG Key ID: 2A75B7CA8ADED5CF

@ -1008,7 +1008,7 @@ bool Amarok::genericEventHandler( TQWidget *recipient, TQEvent *e )
//please don't remove!
case TQEvent::Wheel:
{
#define e TQT_TQWHEELEVENT(e)
#define e static_cast<TQWheelEvent*>(e)
//this behaviour happens for the systray and the player window
//to override one, override it in that class
@ -1045,7 +1045,7 @@ bool Amarok::genericEventHandler( TQWidget *recipient, TQEvent *e )
//KDE policy states we should hide to tray and not quit() when the
//close window button is pushed for the main widget
TQT_TQCLOSEEVENT(e)->accept(); //if we don't do this the info box appears on quit()!
static_cast<TQCloseEvent*>(e)->accept(); //if we don't do this the info box appears on quit()!
if( AmarokConfig::showTrayIcon() && !e->spontaneous() && !kapp->sessionSaving() )
{

@ -334,7 +334,7 @@ CollectionBrowser::eventFilter( TQObject *o, TQEvent *e )
//there are a few keypresses that we intercept
#define e TQT_TQKEYEVENT(e)
#define e static_cast<TQKeyEvent*>(e)
if( o == m_searchEdit ) //the search lineedit
{
@ -3621,7 +3621,7 @@ CollectionView::eventFilter( TQObject* o, TQEvent* e )
{
if( o == header()
&& e->type() == TQEvent::MouseButtonPress
&& TQT_TQMOUSEEVENT( e )->button() == TQt::RightButton
&& static_cast<TQMouseEvent*>( e )->button() == TQt::RightButton
&& m_viewMode == modeFlatView )
{
TDEPopupMenu popup;
@ -3639,7 +3639,7 @@ CollectionView::eventFilter( TQObject* o, TQEvent* e )
popup.setItemVisible( Score, AmarokConfig::useScores() );
popup.setItemVisible( Rating, AmarokConfig::useRatings() );
const int returnID = popup.exec( TQT_TQMOUSEEVENT(e)->globalPos() );
const int returnID = popup.exec( static_cast<TQMouseEvent*>(e)->globalPos() );
if ( returnID != -1 )
{

@ -3826,7 +3826,7 @@ ContextBrowser::eventFilter( TQObject *o, TQEvent *e )
switch( e->type() )
{
case 6/*TQEvent::KeyPress*/:
#define e TQT_TQKEYEVENT(e)
#define e static_cast<TQKeyEvent*>(e)
if( o == m_addLabelEdit ) //the add label lineedit
{
@ -3864,7 +3864,7 @@ ContextBrowser::eventFilter( TQObject *o, TQEvent *e )
break;
}
return KTabWidget::eventFilter( TQT_TQOBJECT(o), TQT_TQEVENT(e) );
return KTabWidget::eventFilter( o, e );
}
void ContextBrowser::showWikipedia( const TQString &url, bool fromHistory, bool replaceHistory )

@ -375,7 +375,7 @@ bool MultiTabBarInternal::eventFilter( TQObject *, TQEvent *e )
//PATCH by markey: Allow switching of tabs with mouse wheel
if ( e->type() == TQEvent::Wheel ) {
TQWheelEvent* event = TQT_TQWHEELEVENT( e );
TQWheelEvent* event = static_cast<TQWheelEvent*>( e );
const int delta = event->delta() / 120;
// Determine which tab is currently active

@ -557,7 +557,7 @@ bool PlayerWidget::event( TQEvent *e )
return true;
case 6/*TQEvent::KeyPress*/:
if (TQT_TQKEYEVENT(e)->key() == TQt::Key_D/* && (m_pAnalyzer->inherits("TQGLWidget")*/)
if (static_cast<TQKeyEvent*>(e)->key() == TQt::Key_D/* && (m_pAnalyzer->inherits("TQGLWidget")*/)
{
if( m_pAnalyzer->parent() )
{
@ -703,7 +703,7 @@ PlayerWidget::eventFilter( TQObject *o, TQEvent *e )
{
case TQEvent::Close:
TQT_TQCLOSEEVENT(e)->accept(); //close the window!
static_cast<TQCloseEvent*>(e)->accept(); //close the window!
return true; //don't let PlaylistWindow have the event - see PlaylistWindow::closeEvent()
case TQEvent::Hide:

@ -2726,8 +2726,8 @@ Playlist::columnResizeEvent( int col, int oldw, int neww )
bool
Playlist::eventFilter( TQObject *o, TQEvent *e )
{
#define me TQT_TQMOUSEEVENT(e)
#define ke TQT_TQKEYEVENT(e)
#define me static_cast<TQMouseEvent*>(e)
#define ke static_cast<TQKeyEvent*>(e)
if( o == header() && e->type() == TQEvent::MouseButtonPress && me->button() == TQt::RightButton )
{
@ -2754,7 +2754,7 @@ Playlist::eventFilter( TQObject *o, TQEvent *e )
popup.insertItem( i18n("&Fit to Width"), SMARTRESIZING );
popup.setItemChecked( SMARTRESIZING, m_smartResizing );
int col = popup.exec( TQT_TQMOUSEEVENT(e)->globalPos() );
int col = popup.exec( static_cast<TQMouseEvent*>(e)->globalPos() );
switch( col ) {
case HIDE:

@ -639,7 +639,7 @@ bool PlaylistWindow::eventFilter( TQObject *o, TQEvent *e )
//there are a few keypresses that we intercept
#define e TQT_TQKEYEVENT(e)
#define e static_cast<TQKeyEvent*>(e)
if(( e->key() == Key_F2 ) && (e->state() == 0))
{
@ -805,7 +805,7 @@ void PlaylistWindow::closeEvent( TQCloseEvent *e )
Q_UNUSED( e );
hide();
#else
Amarok::genericEventHandler( TQT_TQWIDGET(this), TQT_TQEVENT(e) );
Amarok::genericEventHandler( this, e );
#endif
}

@ -75,7 +75,7 @@ Amarok::TrayIcon::event( TQEvent *e )
return Amarok::genericEventHandler( this, e );
case TQEvent::Timer:
if( TQT_TQTIMEREVENT(e)->timerId() != blinkTimerID )
if( static_cast<TQTimerEvent*>(e)->timerId() != blinkTimerID )
return KSystemTray::event( e );
// if we're playing, blink icon
@ -88,7 +88,7 @@ Amarok::TrayIcon::event( TQEvent *e )
return true;
case TQEvent::MouseButtonPress:
if( TQT_TQMOUSEEVENT(e)->button() == TQt::MidButton )
if( static_cast<TQMouseEvent*>(e)->button() == TQt::MidButton )
{
EngineController::instance()->playPause();

Loading…
Cancel
Save