Developer forums (C::B DEVELOPMENT STRICTLY!) > CodeCompletion redesign
new CC branch built failed
Biplab:
--- Quote from: ollydbg on November 27, 2009, 03:18:45 pm ---I just find a serious bug! SVN rev 5942
when any editor is opened, it seems the the CPU usage was 50%, and the title bar of Code::Blocks gets flashed continuously. :(
Does any one meet the same problem, it seems there is no problem before rev 5939.
--- End quote ---
I didn't notice any flashing. Tested on Linux. However I'll try to do more testing tomorrow to find any issues with it.
BTW, I didn't track this thread. Rev 5939 was necessary to fix another bug. In OpenFileList plugin, the open file tree shows wrong path of recently opened editor. The bug is noticeable when a file is opened by clicking on project tree. Sending cbEVT_EDITOR_ACTIVATED event fixed that.
Jenna:
Just investigated a little deeper:
the BrowseTracker-plugin calls SetActiveEditor in its OnIdle-function (and this one is called quiet often of course).
Biplab:
--- Quote from: jens on November 27, 2009, 04:29:34 pm ---I can confirm this (on linux).
I have a small plugin, that hooks into C::B event-sink to debug C::B's internal events, and we get flooded with cbEVT_EDITOR_ACTIVATED.
Removing Biplabs commit from svn r5939 fixed this issue.
--- End quote ---
It was not sent before and thus it's usual that you get a number of such events after that change was made.
Nevertheless, I'll test it more tomorrow and revert the commit if that's necessary.
Biplab:
--- Quote from: jens on November 27, 2009, 04:39:48 pm ---Just investigated a little deeper:
the BrowseTracker-plugin calls SetActiveEditor in its OnIdle-function (and this one is called quiet often of course).
--- End quote ---
Thanks for the quick update. IMO, code in BrowseTracker plugin should be changed. OnIdle function will be called frequently resulting in flooding of such event.
ollydbg:
--- Quote from: Biplab on November 27, 2009, 04:42:30 pm ---IMO, code in BrowseTracker plugin should be changed. OnIdle function will be called frequently resulting in flooding of such event.
--- End quote ---
Agreed :D
--- Code: ---void BrowseTracker::OnIdle(wxIdleEvent& event)
// ----------------------------------------------------------------------------
{
event.Skip();
// Focus the new selected editor. This doesn't work if a long compile
// is active since there's no idle time. User will have to click into
// the editor window to activate it.
// This used to be done by the CB editor manager, but someone removed the UI hook.
if ((not Manager::Get()->IsAppShuttingDown()) && m_UpdateUIFocusEditor)
{
if (m_UpdateUIFocusEditor)
{
EditorBase* eb = m_UpdateUIFocusEditor;
if (not eb) return;
m_UpdateUIFocusEditor = 0;
Manager::Get()->GetEditorManager()->SetActiveEditor(eb);
eb->SetFocus();
#if defined(LOGGING)
LOGIT( _T("BT OnIdle Focused Editor[%p] Title[%s]"), eb, eb->GetTitle().c_str() );
#endif
// re-sort the browse marks
wxCommandEvent ev;
OnMenuSortBrowse_Marks(ev);
}
}
}
--- End code ---
Note:
--- Quote ---// This used to be done by the CB editor manager, but someone removed the UI hook.
--- End quote ---
:D
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version