Regression of KHTML's smart popup feature

Dawit A. adawit at kde.org
Sun Jan 26 11:31:50 GMT 2003


On Sunday 26 January 2003 10:31, David Faure wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> (following up on the right list)
>
> On Saturday 25 January 2003 02:08, Dawit A. wrote:
> > Hi,
> >
> > I traced the cause for BR# 52720, 52902 and 53377 to a recent commit to
> > both the HEAD and KDE 3 1 branches that replaced CLICK EVENT with
> > KHTML ECMA CLICK EVENT to "make khtml's event handling suck a little
> > less." See -r 1.50 khtml/ecma/kjs binding.cpp.  Unfortunately, the
> > replacement event does not seem to be emitted whenever an onClick event
> > is generated.  Instead the event that reaches the javascript interpreter
> > is still CLICK EVENT.  This causes
> > ScriptInterpreter::isWindowOpenAllowed() to always fail and hence break
> > the smart popup feature. Can one of the khtml/kjs hackers more familiar
> > with the code, please look into this ?  Specially the person that broke
> > it :)
>
> Hmm, so s/KHTML ECMA CLICK EVENT/CLICK EVENT/ (in kjs binding.cpp)
> fixes it, right?

It should since the debug statement in the ::isWindowOpenAllowed states that 
the event received has id = 4 and according to the enumrations declared in  
DOM::EventImpl the 4th enum is CLICK_EVENT.  

I however am unable to test this right now because 
KJS::Window::retreiveWindow(...) currently crashes on any javascript code 
that gets executed. :(  I had to disable javascript completely to use 
konquqeor.  This worked fine until I updated khtml yesterday. Backtrace 
attached.

Regards,
Dawit A.
-------------- next part --------------
0x41196b59 in wait4 () from /lib/libc.so.6
#0  0x41196b59 in wait4 () from /lib/libc.so.6
#1  0x412134ac in __DTOR_END__ () from /lib/libc.so.6
#2  0x4105f9c3 in waitpid () from /lib/libpthread.so.0
#3  0x406b4690 in KCrash::defaultCrashHandler(int) ()
   from /opt/kde3/lib/libkdecore.so.4
#4  <signal handler called>
#5  0x408894db in __dynamic_cast ()
   from /usr/lib/gcc-lib/i686-pc-linux-gnu/3.2.1/libstdc++.so.5
#6  0x4188a002 in KJS::Window::retrieveWindow(KHTMLPart*) ()
   from /opt/kde3/lib/libkhtml.so.4
#7  0x418a0e70 in KJSProxyImpl::createHTMLEventHandler(QString, QString) ()
   from /opt/kde3/lib/libkhtml.so.4
#8  0x41786c1b in KHTMLPart::createHTMLEventListener(QString) ()
   from /opt/kde3/lib/libkhtml.so.4
#9  0x417ac601 in DOM::DocumentImpl::createHTMLEventListener(QString) ()
   from /opt/kde3/lib/libkhtml.so.4
#10 0x417d1bfa in DOM::HTMLElementImpl::parseAttribute(DOM::AttributeImpl*) ()
   from /opt/kde3/lib/libkhtml.so.4
#11 0x417d35ed in DOM::HTMLAnchorElementImpl::parseAttribute(DOM::AttributeImpl*) () from /opt/kde3/lib/libkhtml.so.4
#12 0x417b5969 in DOM::ElementImpl::setAttributeMap(DOM::NamedAttrMapImpl*) ()
   from /opt/kde3/lib/libkhtml.so.4
#13 0x417c54ce in khtml::KHTMLParser::parseToken(khtml::Token*) ()
   from /opt/kde3/lib/libkhtml.so.4
#14 0x417cd34e in khtml::HTMLTokenizer::processToken() ()
   from /opt/kde3/lib/libkhtml.so.4
#15 0x417cbafc in khtml::HTMLTokenizer::parseTag(khtml::DOMStringIt&) ()
   from /opt/kde3/lib/libkhtml.so.4
#16 0x417cc83f in khtml::HTMLTokenizer::write(QString const&, bool) ()
   from /opt/kde3/lib/libkhtml.so.4
#17 0x41770c88 in KHTMLPart::write(char const*, int) ()
   from /opt/kde3/lib/libkhtml.so.4
#18 0x4176e1ae in KHTMLPart::slotData(KIO::Job*, QMemArray<char> const&) ()
   from /opt/kde3/lib/libkhtml.so.4
#19 0x417874bc in KHTMLPart::qt_invoke(int, QUObject*) ()
   from /opt/kde3/lib/libkhtml.so.4
#20 0x40b0cce9 in QObject::activate_signal(QConnectionList*, QUObject*) ()
   from /usr/qt/3/lib/libqt-mt.so.3
#21 0x401782e4 in KIO::TransferJob::data(KIO::Job*, QMemArray<char> const&) ()
   from /opt/kde3/lib/libkio.so.4
#22 0x40163593 in KIO::TransferJob::slotData(QMemArray<char> const&) ()
   from /opt/kde3/lib/libkio.so.4
#23 0x40178824 in KIO::TransferJob::qt_invoke(int, QUObject*) ()
   from /opt/kde3/lib/libkio.so.4
#24 0x40b0cce9 in QObject::activate_signal(QConnectionList*, QUObject*) ()
   from /usr/qt/3/lib/libqt-mt.so.3
#25 0x40152282 in KIO::SlaveInterface::data(QMemArray<char> const&) ()
   from /opt/kde3/lib/libkio.so.4
#26 0x4014ee9f in KIO::SlaveInterface::dispatch(int, QMemArray<char> const&) ()
   from /opt/kde3/lib/libkio.so.4
#27 0x4014ebd0 in KIO::SlaveInterface::dispatch() ()
   from /opt/kde3/lib/libkio.so.4
#28 0x4014bab5 in KIO::Slave::gotInput() () from /opt/kde3/lib/libkio.so.4
#29 0x4014e100 in KIO::Slave::qt_invoke(int, QUObject*) ()
   from /opt/kde3/lib/libkio.so.4
#30 0x40b0cce9 in QObject::activate_signal(QConnectionList*, QUObject*) ()
   from /usr/qt/3/lib/libqt-mt.so.3
#31 0x40b0cdc5 in QObject::activate_signal(int, int) ()
   from /usr/qt/3/lib/libqt-mt.so.3
#32 0x40decbc2 in QSocketNotifier::activated(int) ()
   from /usr/qt/3/lib/libqt-mt.so.3
#33 0x40b29210 in QSocketNotifier::event(QEvent*) ()
   from /usr/qt/3/lib/libqt-mt.so.3
#34 0x40aaede4 in QApplication::internalNotify(QObject*, QEvent*) ()
   from /usr/qt/3/lib/libqt-mt.so.3
#35 0x40aae94b in QApplication::notify(QObject*, QEvent*) ()
   from /usr/qt/3/lib/libqt-mt.so.3
#36 0x40621819 in KApplication::notify(QObject*, QEvent*) ()
   from /opt/kde3/lib/libkdecore.so.4
#37 0x40a89b98 in QEventLoop::activateSocketNotifiers() ()
   from /usr/qt/3/lib/libqt-mt.so.3
#38 0x40a67487 in QEventLoop::processEvents(unsigned) ()
   from /usr/qt/3/lib/libqt-mt.so.3
#39 0x40ac2b56 in QEventLoop::enterLoop() () from /usr/qt/3/lib/libqt-mt.so.3
#40 0x40ac29f8 in QEventLoop::exec() () from /usr/qt/3/lib/libqt-mt.so.3
#41 0x40aaf011 in QApplication::exec() () from /usr/qt/3/lib/libqt-mt.so.3
#42 0x415099da in main () from /opt/kde3/lib/konqueror.so
#43 0x0804cc41 in launch(int, char const*, char const*, char const*, int, char const*, bool, char const*, bool, char const*) ()
#44 0x0804d993 in handle_launcher_request(int) ()
#45 0x0804de7c in handle_requests(int) ()
#46 0x0804ec24 in main ()
#47 0x410ffe44 in __libc_start_main () from /lib/libc.so.6


More information about the kfm-devel mailing list