On 16/04/2010 18:04, [email protected] wrote:
Author: vfr Date: Fri Apr 16 18:04:35 2010 New Revision: 34165 URL:
http://www.lyx.org/trac/changeset/34165
Log: Refactor GuiApplication::getStatus().
* I didn't like the fact that the heart of the dispatch/status
machinery is in the default clause of a long switch statement. Now,
it is clear that we enter the app in getStatus, which then asks the
GuiApplication itself, the GuiView, the current BufferView, the
current Buffer, the document BufferView, the document Buffer,
* Shouldn't we let BufferView call the Buffer getStatus() functions
?,
Yes for me. I would even let GuiView call the BufferView getStatus()
* This also makes sure that if a command is not handled, it is turned
off. Before r34164 this was caused by the default clause in
BufferView,
* Now it is prevented that if the document BufferView is the same as
the current BufferView, that the getStatus() functions are called
twice,
* A warning can be outputted if the LFUN is not handled.
PS I want to do the same for the dispatch function.
You are welcome to do it.
Abdel.