Closed Bug 627723 Opened 15 years ago Closed 15 years ago

When a gtk widget on a page is clicked, the widget/window does not gain focus

Categories

(Core Graveyard :: Embedding: GTK Widget, defect)

1.9.2 Branch
x86
Linux
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED DUPLICATE of bug 533245

People

(Reporter: tim, Unassigned)

Details

Attachments

(1 file)

User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10_6_6; en-us) AppleWebKit/533.19.4 (KHTML, like Gecko) Version/5.0.3 Safari/533.19.4 Build Identifier: 1.9.2.13 When using GtkEmbed, if the emded frame doesn't have focus, it connot be focused by clicking on a gtk rendered widget within the page. (i.e. <input type="text">). It is possible to first click elsewhere on the webpage, and then the gtk rendered widget. Even though they don't get focus / raise the window, they do still receive the click events, and any listening javascript code still gets executed. Reproducible: Always Steps to Reproduce: 1. Build embedding/browser/gtk/tests 2. Run embedding/browser/gtk/tests/TestGtkEmbed 3. Visit a website with an input field (i.e. google.com) 4. Click the URL bar, to ensure it and not the embedded browser has focus. 4. Attempt to set the focus on the input field on the webpage by clicking on it. Actual Results: input field does not get focus Expected Results: input field gets focus
Attached patch Simple patch.Splinter Review
I've added a patch, though I'm rather unfamiliar with code base so I'm not sure if 1) This is the correct location to do so, and 2) If this has any undesired side effects, though from what I understand of the code, the window is only raised if it's not already raised. Also, the FLAG_RAISE is only added on a mouse down event, which is from what I can tell, the only time when it's needed. i.e. using the keyboard to tab into it, is fine. In my limited testing, it solves the issue.
Version: unspecified → 1.9.2 Branch
The above does not solve the issue. Also, this is a duplicate of https://bugzilla.mozilla.org/show_bug.cgi?id=533245
Status: UNCONFIRMED → RESOLVED
Closed: 15 years ago
Resolution: --- → DUPLICATE
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: