bugGnash - The GNU Flash player - Bugs: bug #21808, Plugin doesn't send key events to...

 
 

bug #21808: Plugin doesn't send key events to the standalone player

Submitted by:  Sandro Santilli <strk>
Submitted on:  Sat 15 Dec 2007 05:27:16 PM UTC  
 
Category: pluginSeverity: 4 - Important
Release: NoneStatus: Fixed
Privacy: PublicAssigned to: None
Open/Closed: Closed

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

(Jump to the original submission Jump to the original submission)

Mon 17 Dec 2007 10:06:09 AM UTC, comment #7:

better require some user action to grab focus.
The alternative of 'click' would be 'on mouse over' event
(first mouse_move I guess).
This is usually a desktop user preference (sloppy focus/click to focus...)

Sandro Santilli <strk>
Project Member
Mon 17 Dec 2007 09:51:27 AM UTC, comment #6:

Now you can play pacman in the browser...

One other question would be whether to set focus automatically to start with. At the moment you have to click on the movie first.

Problems would arise if there were other elements (e.g. text inputs) that want the focus or, for example, small flash advertisments that get loaded last and grab the focus from the main flash game in the middle.

There are also javascript methods for setting focus (I think).

Anyway, this particular bug is fixed.

Benjamin Wolsey <bwy>
Project Member
Mon 17 Dec 2007 09:38:32 AM UTC, comment #5:

committed, with focus grabbed on mouse click and by _drawing_area.
I'm not sure there's a windows at all when runnign in Xembed

Sandro Santilli <strk>
Project Member
Mon 17 Dec 2007 09:11:57 AM UTC, comment #4:

http://marc.info/?l=gtk-app-devel&m=117554095119894&w=2 (and the next in the thread) address this problem.

http://standards.freedesktop.org/xembed-spec/0.5/ar01s03.html discusses keyboard events.

In any case, clicking outside the plugin automatically grabs the focus away from the canvas (and won't give it back unless the canvas grabs it again).

Benjamin Wolsey <bwy>
Project Member
Mon 17 Dec 2007 08:56:33 AM UTC, comment #3:

Do we really need to be getting focus explicitly ?
How would we kill the focus ?

Sandro Santilli <strk>
Project Member
Mon 17 Dec 2007 08:20:44 AM UTC, comment #2:

The problem seems to be with gtk not correctly setting the focus, so that keyboard event don't get passed to the right widget.

A fix involves making the drawing area able to receive focus:

GTK_WIDGET_SET_FLAGS (GTK_WIDGET(_drawing_area), GTK_CAN_FOCUS);

and then, presumably when users click in the window (or the drawing area?), ensuring that the canvas grabs the focus:

gtk_widget_grab_focus(GTK_WIDGET(_drawing_area));

Benjamin Wolsey <bwy>
Project Member
Sun 16 Dec 2007 09:18:27 AM UTC, comment #1:

I can confirm that.

Benjamin Wolsey <bwy>
Project Member
Sat 15 Dec 2007 05:27:16 PM UTC, original submission:

It seems all key events are retained by firefox and not sent
to the plugin at all...

Can anyone else confirm or is it just me ?
This is current head as of Dec 15 2007,

Sandro Santilli <strk>
Project Member

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by bwy (Posted a comment)
  • -unavailable- added by strk (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 4 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Mon 17 Dec 2007 09:51:27 AM UTCbwyStatusReady For Test=>Fixed
      Open/ClosedOpen=>Closed
    Mon 17 Dec 2007 09:38:32 AM UTCstrkStatusConfirmed=>Ready For Test
    Sun 16 Dec 2007 10:14:22 AM UTCstrkStatusNone=>Confirmed

    Back to the top


    Powered by Savane 3.1-cleanup1