Bug 86202 - Web Inspector: Can't type spaces in "Override User Agent" field
Summary: Web Inspector: Can't type spaces in "Override User Agent" field
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Web Inspector (Deprecated) (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Alexander Pavlov (apavlov)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-05-11 05:51 PDT by Alexander Pavlov (apavlov)
Modified: 2012-05-11 06:42 PDT (History)
10 users (show)

See Also:


Attachments
Patch (2.72 KB, patch)
2012-05-11 06:11 PDT, Alexander Pavlov (apavlov)
no flags Details | Formatted Diff | Diff
Patch (3.13 KB, patch)
2012-05-11 06:26 PDT, Alexander Pavlov (apavlov)
yurys: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alexander Pavlov (apavlov) 2012-05-11 05:51:19 PDT
What steps will reproduce the problem?
1. On any web page, open the developer tools (either from "View", "Developer" or by pressing Command+Option+J).
2. Click the gear icon in the lower right corner of the window.
3. Check the checkbox near where it says "Override User Agent".
4. Pick "Other..." from the dropdown menu to enter your own user agent string.
5. Try to type "Mozilla/5.0 (whatever)".

What is the expected result?
I should be able to enter the user agent string I am trying to type.

What happens instead?
Pressing the space bar closes the settings popup.

Please provide any additional information below. Attach a screenshot if
possible.
I am able to work around the problem by copying a space and pasting it into the text field.

Upstreaming http://code.google.com/p/chromium/issues/detail?id=125796
Comment 1 Alexander Pavlov (apavlov) 2012-05-11 06:11:13 PDT
Created attachment 141394 [details]
Patch
Comment 2 Yury Semikhatsky 2012-05-11 06:16:37 PDT
Comment on attachment 141394 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=141394&action=review

> Source/WebCore/inspector/front-end/HelpScreen.js:50
> +    this.closeKeys = [

Can we have a virtual method instead and override it in SettingsScreen or pass the key set as a parameter to the constructor? We don't override fields in the front-end code.
Comment 3 Alexander Pavlov (apavlov) 2012-05-11 06:26:42 PDT
Created attachment 141398 [details]
Patch
Comment 4 Alexander Pavlov (apavlov) 2012-05-11 06:42:03 PDT
Committed r116762: <http://trac.webkit.org/changeset/116762>