Andre Poenitz <[EMAIL PROTECTED]> writes: | On Wed, Aug 28, 2002 at 08:38:39AM +0200, Lars Gullik Bjønnes wrote: | > Not too bad. But I feel that the switch/cases are a bit too big and | > really should be kept in separate functions. | | I said I'll move them down to LyXText (which will make them slimmer). | If they are still big than, I'll put them into seperate functions. | Certainly today... | | > Also, one thing I'd really like to see (not necessarily in this | > patch), is to split the mouse lfuns ... not that is not what I want... | > | > I want it to be possible to do a | > | > \bind mouse-button-1 place-cursor | > | > kindo of binding. This means that the mouse buttons must be seen as a | > kind of keyboard-key. (keysym if you want) | | Sort of LFUN re-mapping. Should be possible. Actually I like the idea | because it makes things more flexible... | | > This also implies that there should not be _any_ kind of special LFUNS | > for mouse handling, but that you use key-bindings to achieve that | > instead. Then we should not need any kind of special casing in the | > code on "which button was pressed" or any explicit mouse button | > handling at all. | | I'd approach this a bit differently. Assume for a while we have | inset-local bindings and that lfun re-map feature. | | The workarea could still generate mouse FuncRequest. After all, the | workarea is completely ignorant of text, formulas etc. It only knows it got | clicked and has to do something with it. So it passes the mouse lfun to | BufferView::dispatch(), and as BufferView is ignorant of this, too, it gets | passed in the default branch to LyXText::dispatch().
I do not really agree, and feel that this would be more cleanly supported by "context"-bindings. But of course if we spread the dispatch out to thin, that will be a real hassle. What I really want is for all dispatch to be really ignorant about mouse buttons. (and the rest of the code as well...) -- Lgb