How to enable drag-selection in Berkelium?

581 views Asked by At

I've got an application that's using Berkelium for an embedded web browser, and I'm having trouble getting the drag-selection to work. I've seen examples of other WebKit-based applications that have it working just like a normal browser (Steam, Awesomium demo), so I feel like it shouldn't be that difficult to get working, but I don't know what may be wrong.

I'm passing in all of the mouse down, mouse move, and mouse up events to the Berkelium browser (mouseButton and mouseMoved functions on the Window) and I feel like that's all I should need to do? I wasn't able to find any help online about this, so hopefully someone here might know what's going on or where to look!

Thanks!

2

There are 2 answers

0
Robert Basler On

I tried drag selection in Berkelium in my app. It works in fields, it doesn't seem to work for page text.

0
Mikecito On

It looks like the second comment on this page could be a fix for you:

http://code.google.com/p/berkelium-sharp/issues/detail?id=1#c2

The shift clicking apparently works fine to highlight text, so if you send a shift down along with button down, and a shift with button up, it will select the text along with it when the user drags.

I'm not sure if this will have an adverse affect on things like selecting multiple options on a list, but if you don't have that type of thing in the site you're trying to support, it wouldn't matter. I can't think of any other adverse effects right now, but I'm sure some probably exist.

This user says it worked for him, so it's worth a shot.