I reverted WebSession.C in my git and then applied the fix you 
suggested...and...WSuggestionPopup works again!

Thanks!  Please make the fix to wt.git when you get a chance.

-- Dan


On 11/2/10 1:59 PM, "Daniel Ginsburg" <[email protected]> 
wrote:

Hi Koen,

I tried to make this fix in the latest git, but unfortunately the latest git 
caused a crash in my app which I feel I should report.  Below is the crash and 
I also happened to have just done a git build on 10/29/10 which did not crash 
and I suspect the diff below shows the reason for the crash in the latest 
repository.

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x7fffe37f6710 (LWP 9521)]
Wt::WebSession::notify (this=0x0, event=...) at 
/chb/users/ginsburg/Downloads/wt.git_11_02_10/wt/src/web/WebSession.C:1164
1164      if (!app_->initialized_) {
(gdb) backtrace
#0  Wt::WebSession::notify (this=0x0, event=...) at 
/chb/users/ginsburg/Downloads/wt.git_11_02_10/wt/src/web/WebSession.C:1164
#1  0x00000000004fc7ea in Wt::DispatchThread::doEvent (this=0x7fffe80d8230) at 
/chb/users/ginsburg/workspace3/trunk/www/wt/src/pl_gui/lib/DispatchThread.C:150
#2  0x00000000004fd501 in Wt::DispatchObject::qt_metacall (this=0x7dc8c0, 
_c=QMetaObject::InvokeMetaMethod, _id=<value optimized out>, _a=<value 
optimized out>) at 
/chb/users/ginsburg/workspace3/trunk/www/wt/build_shaka/src/pl_gui/lib/moccedDispatchThread.C:76
#3  0x00007ffff5252d49 in QObject::event(QEvent*) () from 
/usr/lib/libQtCore.so.4
#4  0x00007ffff524306c in QCoreApplication::notifyInternal(QObject*, QEvent*) 
() from /usr/lib/libQtCore.so.4
#5  0x00007ffff52457e7 in QCoreApplicationPrivate::sendPostedEvents(QObject*, 
int, QThreadData*) () from /usr/lib/libQtCore.so.4
#6  0x00007ffff526c9d3 in ?? () from /usr/lib/libQtCore.so.4
#7  0x00007ffff4a198c2 in g_main_context_dispatch () from /lib/libglib-2.0.so.0
#8  0x00007ffff4a1d748 in ?? () from /lib/libglib-2.0.so.0
#9  0x00007ffff4a1d8fc in g_main_context_iteration () from /lib/libglib-2.0.so.0
#10 0x00007ffff526c513 in 
QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () 
from /usr/lib/libQtCore.so.4
#11 0x00007ffff5241992 in 
QEventLoop::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from 
/usr/lib/libQtCore.so.4
#12 0x00007ffff5241d6c in 
QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from 
/usr/lib/libQtCore.so.4
#13 0x00007ffff514bd59 in QThread::exec() () from /usr/lib/libQtCore.so.4
#14 0x00000000004fc967 in Wt::DispatchThread::run (this=0x7fffe80d8230) at 
/chb/users/ginsburg/workspace3/trunk/www/wt/src/pl_gui/lib/DispatchThread.C:69
#15 0x00007ffff514e775 in ?? () from /usr/lib/libQtCore.so.4
#16 0x00007ffff43749ca in start_thread () from /lib/libpthread.so.0
#17 0x00007ffff21a76fd in clone () from /lib/libc.so.6
#18 0x0000000000000000 in ?? ()
(gdb)


diff WebSession.C ~/Downloads/wt.git_10_29_10/wt/src/web/WebSession.C
1164,1168d1163
<   if (!app_->initialized_) {
<     app_->initialize();
<     app_->initialized_ = true;
<   }
<
1170a1166
>     app_->initialize();



On 11/2/10 12:35 PM, "Koen Deforche" <[email protected]> wrote:

Hey Daniel,

2010/11/2 Ginsburg, Daniel <[email protected]>:
> Hi Koen,
>
> What was the fix for the WDatePicker?  If it's the same problem, it might 
> take me less time to fix the Wt code than to create a reproducer app, so 
> maybe I'll just try fixing Wt if you can point me in the right direction.

The fix I would suggest is in WSuggestionPopup.js:

   function positionPopup(edit) {
     WT.positionAtWidget(el.id, edit.id, WT.Vertical);
   }

change to:

   function positionPopup(edit) {
     WT.positionAtWidget(el.id, edit.id, WT.Vertical, true);
   }

You can copy this file to WSuggestionPopup.min.js before rebuilding --
we use the google JavaScript minifier for this but it is not done by
the build itself.

Regards,
koen

------------------------------------------------------------------------------
Nokia and AT&T present the 2010 Calling All Innovators-North America contest
Create new apps & games for the Nokia N8 for consumers in  U.S. and Canada
$10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing
Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store
http://p.sf.net/sfu/nokia-dev2dev
_______________________________________________
witty-interest mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/witty-interest


--
Dan Ginsburg / email: [email protected]
Principal Software Architect
Fetal-Neonatal Neuroimaging and Development Science Center
Children's Hospital Boston
300 Longwood Avenue
Boston, MA 02115
Phone: 857-218-5140

------------------------------------------------------------------------------
Nokia and AT&T present the 2010 Calling All Innovators-North America contest
Create new apps & games for the Nokia N8 for consumers in  U.S. and Canada
$10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing
Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store
http://p.sf.net/sfu/nokia-dev2dev
_______________________________________________
witty-interest mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/witty-interest


--
Dan Ginsburg / email: [email protected]
Principal Software Architect
Fetal-Neonatal Neuroimaging and Development Science Center
Children's Hospital Boston
300 Longwood Avenue
Boston, MA 02115
Phone: 857-218-5140

------------------------------------------------------------------------------
Nokia and AT&T present the 2010 Calling All Innovators-North America contest
Create new apps & games for the Nokia N8 for consumers in  U.S. and Canada
$10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing
Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store 
http://p.sf.net/sfu/nokia-dev2dev
_______________________________________________
witty-interest mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/witty-interest

Reply via email to