Bug 141868

Summary: Convert the caps lock indicator to be implemented using the shadow DOM
Product: WebKit Reporter: Sam Weinig <sam>
Component: New BugsAssignee: Sam Weinig <sam>
Status: RESOLVED FIXED    
Severity: Normal CC: ap, buildbot, mitz, rniwa, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
mitz: review+, buildbot: commit-queue-
Archive of layout-test-results from ews105 for mac-mavericks-wk2
none
Archive of layout-test-results from ews101 for mac-mavericks none

Description Sam Weinig 2015-02-21 11:48:55 PST
Convert the caps lock indicator to be implemented using the shadow DOM
Comment 1 Sam Weinig 2015-02-21 12:02:49 PST
Created attachment 247055 [details]
Patch
Comment 2 Sam Weinig 2015-02-21 12:06:38 PST
There are few things that I am not thrilled with in this patch, but I think it is a solid improvement over the status quo.

1) I could not figure out a good way to test it, as I couldn't figure out a good way to force the caps lock key to trigger. If anyone has a good idea, I am all ears (I may end up having to add a setting to make caps lock behave like it is always on).

2) I don't like content: url() trick I did to get the spacing right. I would rather really rather there be Renderer which behaved the way I want it to (be 100% height, and have it's width match whatever that height computed to be).  I could probably make a custom RenderCapsLockIndicator (or RenderSpacer...), but that seems like overkill since the truck works.
Comment 3 Radar WebKit Bug Importer 2015-02-21 12:07:03 PST
<rdar://problem/19914448>
Comment 4 Build Bot 2015-02-21 12:49:16 PST
Comment on attachment 247055 [details]
Patch

Attachment 247055 [details] did not pass mac-wk2-ews (mac-wk2):
Output: http://webkit-queues.appspot.com/results/4583438833156096

New failing tests:
tables/mozilla_expected_failures/bugs/bug92647-1.html
fast/forms/placeholder-pseudo-style.html
fast/forms/input-value.html
fast/css/text-overflow-input.html
fast/forms/basic-inputs.html
fast/forms/validation-message-appearance.html
fast/forms/input-appearance-height.html
Comment 5 Build Bot 2015-02-21 12:49:19 PST
Created attachment 247056 [details]
Archive of layout-test-results from ews105 for mac-mavericks-wk2

The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews.
Bot: ews105  Port: mac-mavericks-wk2  Platform: Mac OS X 10.9.5
Comment 6 Build Bot 2015-02-21 12:58:52 PST
Comment on attachment 247055 [details]
Patch

Attachment 247055 [details] did not pass mac-ews (mac):
Output: http://webkit-queues.appspot.com/results/6329729586036736

New failing tests:
tables/mozilla_expected_failures/bugs/bug92647-1.html
fast/forms/placeholder-pseudo-style.html
fast/forms/input-value.html
fast/css/text-overflow-input.html
fast/forms/basic-inputs.html
fast/forms/validation-message-appearance.html
fast/forms/input-appearance-height.html
Comment 7 Build Bot 2015-02-21 12:58:55 PST
Created attachment 247057 [details]
Archive of layout-test-results from ews101 for mac-mavericks

The attached test failures were seen while running run-webkit-tests on the mac-ews.
Bot: ews101  Port: mac-mavericks  Platform: Mac OS X 10.9.5
Comment 8 Alexey Proskuryakov 2015-02-21 17:46:58 PST
Comment on attachment 247055 [details]
Patch

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

> Source/WebCore/css/html.css:549
> +    content: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 17 17"><path fill="black" fill-opacity="0.4" d="M12.5 0.5A 4 4 0 0 1 16.5 4.5L 16.5 12.5A 4 4 0 0 1 12.5 16.5L 4.5 16.5A 4 4 0 0 1 0.5 12.5L 0.5 4.5A 4 4 0 0 1 4.5 0.5L 12.5 0.5M 8.5 2L 4 7L 6.25 7L 6.25 10.25L 10.75 10.25L 10.75 7L 13 7L 8.5 2M 10.75 12L 6.25 12L 6.25 14.25L 10.75 14.25L 10.75 12"/></svg>');

Would this be subject to CSP?
Comment 9 Sam Weinig 2015-02-22 15:33:35 PST
Committed r180490: <http://trac.webkit.org/changeset/180490>
Comment 10 Sam Weinig 2015-02-22 15:34:22 PST
(In reply to comment #8)
> Comment on attachment 247055 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=247055&action=review
> 
> > Source/WebCore/css/html.css:549
> > +    content: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 17 17"><path fill="black" fill-opacity="0.4" d="M12.5 0.5A 4 4 0 0 1 16.5 4.5L 16.5 12.5A 4 4 0 0 1 12.5 16.5L 4.5 16.5A 4 4 0 0 1 0.5 12.5L 0.5 4.5A 4 4 0 0 1 4.5 0.5L 12.5 0.5M 8.5 2L 4 7L 6.25 7L 6.25 10.25L 10.75 10.25L 10.75 7L 13 7L 8.5 2M 10.75 12L 6.25 12L 6.25 14.25L 10.75 14.25L 10.75 12"/></svg>');
> 
> Would this be subject to CSP?

Maybe? I'll try to make a test for it.