[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: kdebase/kate/app
From: Christoph Cullmann <cullmann () kde ! org>
Date: 2005-04-24 16:36:19
Message-ID: 20050424163619.9554E62B () office ! kde ! org
[Download RAW message or body]
CVS commit by cullmann:
kill whole eventFilter, yeah, without dockwigets and kmdi there are less hacks needed \
;)
M +6 -7 katemainwindow.cpp 1.304
M +3 -1 katemainwindow.h 1.100
--- kdebase/kate/app/katemainwindow.cpp #1.303:1.304
@@ -225,6 +225,6 @@ void KateMainWindow::setupMainWindow ()
t = createToolView("kate_greptool", KMultiTabBar::Bottom, SmallIcon("filefind"), \
i18n("Find in Files") ); greptool = new GrepTool( t, "greptool" );
- greptool->installEventFilter( this );
connect(greptool, SIGNAL(itemSelected(const QString &,int)), this, \
SLOT(slotGrepToolItemSelected(const QString &,int))); + \
connect(t,SIGNAL(visibleChanged(bool)),this, SLOT(updateGrepDir \
(bool)));
// WARNING HACK - anders: showing the greptool seems to make the menu accels \
work greptool->show();
@@ -232,5 +232,4 @@ void KateMainWindow::setupMainWindow ()
t = createToolView("kate_console", KMultiTabBar::Bottom, SmallIcon("konsole"), \
i18n("Terminal")); console = new KateConsole (t, "console",viewManager());
- console->installEventFilter( this );
}
@@ -743,17 +742,17 @@ void KateMainWindow::slotFullScreen(bool
}
-bool KateMainWindow::eventFilter( QObject *o, QEvent *e )
+void KateMainWindow::updateGrepDir (bool visible)
{
+ // grepdlg gets hidden
+ if (!visible)
+ return;
- if ( o == greptool && e->type() == QEvent::Show && m_viewManager->activeView() )
+ if ( m_viewManager->activeView() )
{
if ( m_viewManager->activeView()->getDoc()->url().isLocalFile() )
{
greptool->updateDirName( \
m_viewManager->activeView()->getDoc()->url().directory() );
- return true;
}
}
-
- return KateMDI::MainWindow::eventFilter( o, e );
}
--- kdebase/kate/app/katemainwindow.h #1.99:1.100
@@ -162,6 +162,8 @@ class KateMainWindow : public KateMDI::M
void openURL (const QString &name=0L);
+ private slots:
+ void updateGrepDir (bool visible);
+
protected:
- bool eventFilter( QObject*, QEvent * );
bool event( QEvent * );
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic