Jean-Marc Lasgouttes a écrit :
"Abdelrazak" == Abdelrazak Younes <[EMAIL PROTECTED]> writes:
Abdelrazak> Jean-Marc Lasgouttes a écrit : At the time, I had the
Abdelrazak> feeling that menus opened faster yes. But I did not
Abdelrazak> measured it scientifically. Beside, the code is a bit
Abdelrazak> simpler in "QLPopupMenu.C" because of having a private
Abdelrazak> Menu member in "QLPopupMenu.h". If you really don't want
Abdelrazak> this, I can revert to a dynamically created Menu but I
Abdelrazak> thought that this clear() method is simple enough and is
Abdelrazak> logical together with size(), empty(), etc.
Could you point me to the part of the code where things happen?
Abdelrazak> Sure, this is in QLPopuoMenu.C: line 71 clear is used with
Abdelrazak> private member 'topLevelMenu'
I am not against adding a clear() method, but would not it be better
to have MenuBackend::expand clear the menu first? It seems to be the
assumption in all frontends.
Please tell me if you are going to add it or not. If not I will put a
work-around in the qt4 frontend (which does not compile without it).
Also, could you explain why it should speed up operation?
Two things:
1) no construction
2) no need to copy the FuncRequest in QLAction (a const ref is used instead)
Abdel.