[ wxwindows-Bugs-1645726 ] Several events can be processed
simultaneously
SourceForge.net
noreply at sourceforge.net
Fri Jan 26 17:10:52 PST 2007
Bugs item #1645726, was opened at 2007-01-27 03:10
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=109863&aid=1645726&group_id=9863
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: OlegTs (olegts)
Assigned to: Nobody/Anonymous (nobody)
Summary: Several events can be processed simultaneously
Initial Comment:
[wxMSW 2.8.0, WindowsXP, VS8.0]
Hi!
I have a situation, when there is another path of execution in my application when it processes wxListCtrl updates in OnTimer event and in same time I press toolbar button.
To reconstruct the problem I had create simple application, which have main frame and one toolbar button.
In Create method of it in addtion I start timer:
BEGIN_EVENT_TABLE( MainFrame, wxFrame )
EVT_TIMER( -1, OnTimer )
EVT_MENU( ID_TOOL1, MainFrame::OnTool1Click )
END_EVENT_TABLE()
bool MainFrame::Create( wxWindow* parent, wxWindowID id, const wxString& caption, const wxPoint& pos, const wxSize& size, long style )
{
...
m_Timer.SetOwner(this);
m_Timer.Start(10);
}
void MainFrame::OnTimer(wxTimerEvent &event)
{
int l = 0;
for (int i = 0; i < 0x7fffffff; i++)
{
l++;
//wxThread::Sleep(10);
}
wxLogMessage("From OnTimer");
}
void MainFrame::OnTool1Click( wxCommandEvent& event )
{
wxMessageBox("In handler");
}
When I run programm it seems look ok, CPU is fully buzy but when I press toolbar button, in 10 seconds MessageBox "In handler" appeares.
This is very strange for me and this seems the problem of Windows but not wxWidgets. But it is a good idea if it is possible, to store message in queue and not process it until programm in other event handler.
Best Regards,
Oleg
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=109863&aid=1645726&group_id=9863
More information about the wx-dev
mailing list