425 Commits

Author SHA1 Message Date
Adam Barth
730d37dce1 Fix the build
TBR=ojan@chromium.org

Review URL: https://codereview.chromium.org/846643005
2015-01-17 01:02:52 -08:00
Ojan Vafai
100094dbf3 Delete document marker related invalidation code.
I believe this doesn't change behavior, but it's hard
to know since we don't have spellchecking hooked up.
Also, delete setToolTip. This is for tooltips on spelling
markers. We don't support tooltips.

R=esprehn@chromium.org

Review URL: https://codereview.chromium.org/830273006
2015-01-16 20:01:02 -08:00
Elliott Sprehn
992eaea546 Remove attrs sky doesn't support.
This removes the attributes sky doesn't intend to support. It
removes references to the attrs, but leaves behind a lot of
plumbing that will be cleaned up in the future. This at least
removes the API surface.

R=ojan@chromium.org

Review URL: https://codereview.chromium.org/855803002
2015-01-16 19:42:52 -08:00
Elliott Sprehn
1b2ab0c6db Don't queue mutation records when attributes don't change value.
There's no reason to queue records when an attribute didn't really
change value.

R=ojan@chromium.org

Review URL: https://codereview.chromium.org/840223006
2015-01-16 19:21:28 -08:00
Elliott Sprehn
4ddf1ce17a Fix the build.
TBR=jamesr@chromium.org

Review URL: https://codereview.chromium.org/854803003
2015-01-16 18:48:17 -08:00
Elliott Sprehn
543049dd5c Remove viewportDefiningElement.
This was used for quirky scrollbar behavior on the web related to
which element defined in the viewport (body, html, etc.). In Sky we plan to
allow multiple elements as direct children of the Document so we need to get
rid of checks like this. The good news is this already does nothing in sky
because the root never has scrollbars automatically.

R=ojan@chromium.org

Review URL: https://codereview.chromium.org/858713002
2015-01-16 18:35:12 -08:00
Ojan Vafai
af37dc8fde Delete some noop and dead scrollbar code.
R=esprehn@chromium.org

Review URL: https://codereview.chromium.org/856443005
2015-01-16 18:15:11 -08:00
Elliott Sprehn
38c4d27f53 Remove custom element :unresolved.
Sky doesn't do upgrades and unknown elements become <error>
so this doesn't make sense.

R=ojan@chromium.org

Review URL: https://codereview.chromium.org/842033004
2015-01-16 17:50:18 -08:00
Elliott Sprehn
9bb2664b06 Get rid of ensureStyleResolver().
It doesn't have side effects anymore, and active documents always
have a StyleResolver.

R=ojan@chromium.org

Review URL: https://codereview.chromium.org/838003008
2015-01-16 17:49:32 -08:00
Ojan Vafai
d591ca1f14 Delete a bunch of noop paint invalidation code.
This deletes invalidateRect and all it's callers.
There are no logic changes, just deletes.

R=esprehn@chromium.org

Review URL: https://codereview.chromium.org/842113005
2015-01-16 17:42:47 -08:00
Ojan Vafai
0f117ce13f Removed unused paintInvalidationRect member.
R=abarth@chromium.org

Review URL: https://codereview.chromium.org/854963002
2015-01-16 17:39:52 -08:00
Ojan Vafai
6ea92165d0 Merge diffNeedsFullLayout methods.
Now that we don't have paint invalidation, the distinction
is meaningless.

R=abarth@chromium.org

Review URL: https://codereview.chromium.org/851203003
2015-01-16 17:38:40 -08:00
Adam Barth
b8df508de7 Add support for GestureEvents to Sky
We'll likely change the API over time, but this is a start.

R=esprehn@chromium.org

Review URL: https://codereview.chromium.org/857533002
2015-01-16 15:42:01 -08:00
Adam Barth
f1cbcfa80b Add PointerEvent interface to Sky
Currently this interface is constructable from script but isn't used internally
by the engine.

R=esprehn@chromium.org

Review URL: https://codereview.chromium.org/846783003
2015-01-16 15:35:59 -08:00
Elliott Sprehn
d28c27efe5 Simplify Node::textContent().
We can make it iterative, and use isTextNode() which is just a bitfield check.

R=abarth@chromium.org

Review URL: https://codereview.chromium.org/855733005
2015-01-16 15:35:03 -08:00
Elliott Sprehn
5e18888a0b Be more strict about attributes in sky-binder.
Instead of making all the built in attributes be global we match them to the
elements they actually apply to. I also removed a bunch of attributes that no
longer work in Sky (but haven't been removed from HTMLAttributeNames.in) yet,
or which we plan to remove.

I also removed the title property from HTMLElement. The <sky-box> widget forgot
to declare its title attribute and no error was generated because of the title
property existing on all elements. Sky doesn't have this so lets remove the API
now and clean up the C++ later.

R=ojan@chromium.org

Review URL: https://codereview.chromium.org/807243003
2015-01-16 14:41:07 -08:00
Ojan Vafai
4256d4a224 Remove background obscuration checks.
This is an optimization to avoid painting backgrounds
that are obscured. It's a lot of complexity that it's
not clear we'll need given that we're using a GL backend.
Also, we can add it back in more easily/efficiently in the future
once we have a display list architecture.

This also means we can remove the needsPaintInvalidation
dirty bit and some opacity information on filters.

R=esprehn@chromium.org

Review URL: https://codereview.chromium.org/856563006
2015-01-15 17:11:44 -08:00
Adam Barth
c312fcbaa4 Trace RenderLayer::paint
R=esprehn@chromium.org

Review URL: https://codereview.chromium.org/851473005
2015-01-15 15:18:02 -08:00
Elliott Sprehn
8f1c3bacfc Trim the deps of StyleResolver.h
TBR=abarth@chromium.org

Review URL: https://codereview.chromium.org/794783003
2015-01-15 13:11:10 -08:00
Ojan Vafai
6d49e56b24 Simplify the paint invalidation bits.
The only thing they're used for now is to clear the
background obscuration state on RenderBox. They're
also used in RenderLayerModelObject::styleWillChange,
but that usage seems like a huge premature optimization.
Unfortunately, the RenderBox one walks up the ancestor
chain, so it's likely a necessary performance optimization.

R=esprehn@chromium.org

Review URL: https://codereview.chromium.org/851033002
2015-01-15 13:02:00 -08:00
Adam Barth
81e3233e3e Add a trace event for running microtasks
Otherwise there are mysterious gaps in the trace.

R=eseidel@chromium.org

Review URL: https://codereview.chromium.org/853883005
2015-01-15 10:28:11 -08:00
Ojan Vafai
eb68343228 Remove deferredfiltersenabled settings.
I have no idea what this setting does, but I just mechanically
removed it since it's always set to true.

R=abarth@chromium.org

Review URL: https://codereview.chromium.org/848243002
2015-01-14 18:58:27 -08:00
Ojan Vafai
3b4eb72066 Delete unused paint invalidation function.
TBR=esprehn@chromium.org

Review URL: https://codereview.chromium.org/856453002
2015-01-14 18:48:43 -08:00
Ojan Vafai
21f4801613 Remove some unused paint invalidation members from RenderObject.
R=abarth@chromium.org

Review URL: https://codereview.chromium.org/854563005
2015-01-14 16:22:08 -08:00
Ojan Vafai
99f75b810d Inline paintInvalidationOrMarkForLayout.
The name doesn't really match what it does at all.

R=abarth@chromium.org

Review URL: https://codereview.chromium.org/854573003
2015-01-14 16:18:39 -08:00
Ojan Vafai
d563e42443 Unprefix -webkit-filter and add a pixel test for it.
R=abarth@chromium.org

Review URL: https://codereview.chromium.org/850103003
2015-01-14 15:14:46 -08:00
Ojan Vafai
8e3f746bad Remove assorted dead paint invalidation code.
R=abarth@chromium.org

Review URL: https://codereview.chromium.org/850763008
2015-01-14 13:46:39 -08:00
Adam Barth
e89b1dda15 lowlevel/img.sky flaky crashes
We don't need to pump pending speculations if we don't have any.

R=esprehn@chromium.org, eseidel@chromium.org
BUG=447763

Review URL: https://codereview.chromium.org/852043003
2015-01-14 13:32:21 -08:00
Ojan Vafai
22bc13f2cf Delete canInvalidatePaintDuringPerformLayout.
It doesn't do anything anymore.

R=abarth@chromium.org

Review URL: https://codereview.chromium.org/850763007
2015-01-14 13:31:33 -08:00
Ojan Vafai
3e26389e5d Delete PaintInvalidationState. It's unused.
Delete selection paint invalidation code.

There is a slight change in behavior in FrameSelection::revealSelection.
If you have a non-collapsed selection, then we'll center the start
of the selection instead of the whole selection in some cases. There's
a ton of callers of this code, so it's hard to be sure if any of this
actually changes behavior for sky. In manual testing, I couldn't find
any scenarios where there was a difference. Almost universally,
when we call revealSelection, we have a CaretSelection. The only
case I could think of where we have a RangeSelection is when
modifying an off-screen selection (e.g. shift+right), but in that case
we pass the RevealExtent option, so this patch doesn't change behavior
there.

Removing that caller makes all the rest of this rect computing
code into dead code.

R=abarth@chromium.org

Review URL: https://codereview.chromium.org/823123003
2015-01-14 13:25:49 -08:00
Ojan Vafai
5f718d3e63 Delete selection paint invalidation code.
There is a slight change in behavior in FrameSelection::revealSelection.
If you have a non-collapsed selection, then we'll center the start
of the selection instead of the whole selection in some cases. There's
a ton of callers of this code, so it's hard to be sure if any of this
actually changes behavior for sky. In manual testing, I couldn't find
any scenarios where there was a difference. Almost universally,
when we call revealSelection, we have a CaretSelection. The only
case I could think of where we have a RangeSelection is when
modifying an off-screen selection (e.g. shift+right), but in that case
we pass the RevealExtent option, so this patch doesn't change behavior
there.

Removing that caller makes all the rest of this rect computing
code into dead code.

R=abarth@chromium.org

Review URL: https://codereview.chromium.org/847303003
2015-01-14 13:25:16 -08:00
Ojan Vafai
d441d00961 Delete some dead ScrollAlignment code.
R=abarth@chromium.org

Review URL: https://codereview.chromium.org/796623004
2015-01-14 11:14:53 -08:00
Elliott Sprehn
6f8568037a Move @font-face logic from ScopedStyleResolver to StyleEngine.
R=abarth@chromium.org, ojan@chromium.org

Review URL: https://codereview.chromium.org/851873002
2015-01-14 11:07:22 -08:00
Ojan Vafai
3c91916589 Remove the PaintInvalidation DocumentLifeCycle states.
We no longer have paint invalidation.

R=esprehn@chromium.org

Review URL: https://codereview.chromium.org/847393003
2015-01-14 11:03:51 -08:00
Elliott Sprehn
e71cf28f76 Merge StyleSheetCollection into ScopedStyleResolver.
There's no reason to keep two identical lists of the sheets
and have this separate object. I also moved the updating
logic out of StyleResolver and into ScopedStyleResolver
which makes more sense. There's still some weirdness since
some global state still exists in the StyleResolver, but
that's something we can fix in future patches.

R=ojan@chromium.org

Review URL: https://codereview.chromium.org/852703002
2015-01-13 18:37:00 -08:00
Elliott Sprehn
3528612650 All documents should have a RegistrationContext.
There's no reason to have a concept of a document with no
registration context.

R=abarth@chromium.org

Review URL: https://codereview.chromium.org/841873006
2015-01-13 17:00:51 -08:00
Elliott Sprehn
66f96ff9bf Remove embedder custom elements.
In Sky there's no concept of embedder custom elements with
different naming rules. Lets remove this machinery.

R=abarth@chromium.org

Review URL: https://codereview.chromium.org/838463004
2015-01-13 16:27:56 -08:00
Elliott Sprehn
f90f735f9b Remove extension check from CustomElementRegistry.
We only have the main world, we don't need this check.

R=abarth@chromium.org

Review URL: https://codereview.chromium.org/788773006
2015-01-13 16:01:49 -08:00
Elliott Sprehn
6a9084c3ee Remove custom element upgrades.
This removes the upgrade candidate machinery so now if an
element is created before it's registered it'll never get
turned into the correct type. created() callbacks and the
correct wrappers being created can stil happen async though
because certain operations are not safe to run script inside
of (ex. the parser or editing).

R=abarth@chromium.org

Review URL: https://codereview.chromium.org/843063005
2015-01-13 16:01:26 -08:00
Elliott Sprehn
d8f1313e81 Always set affected by bits in ElementRuleCollector.
We need to always set these bits, not just if the selector
matched otherwise :hover and friends won't ever match.

BUG=448465
R=ojan@chromium.org

Review URL: https://codereview.chromium.org/852643002
2015-01-13 14:11:02 -08:00
Elliott Sprehn
1eb36b8721 Remove RuleSet::viewportDependentMediaQueryResults.
Sky doesn't support @media rules, <style> elements must use
the media attribute which instead stores the media query
info on the CSSStyleSheet instead.

R=abarth@chromium.org

Review URL: https://codereview.chromium.org/850463003
2015-01-13 11:34:14 -08:00
Elliott Sprehn
a5d3fcd3d4 Remove some dead code.
These methods have no callers. I also added a TODO
to actually clear the font cache properly.

R=abarth@chromium.org

Review URL: https://codereview.chromium.org/816423004
2015-01-12 23:33:11 -08:00
Elliott Sprehn
60748a6f94 Remove StyleEngine::usesFirstLineRules().
It always returns false, and Sky doesn't support first
line rules.

R=abarth@chromium.org, ojan@chromium.org

Review URL: https://codereview.chromium.org/847053002
2015-01-12 23:32:28 -08:00
Elliott Sprehn
90ca29a436 Remove Document::shouldScheduleLayout.
All it does is call isActive() now.

R=abarth@chromium.org

Review URL: https://codereview.chromium.org/853433002
2015-01-12 23:32:13 -08:00
Elliott Sprehn
43a9629b49 Remove isRenderingReady.
All this method did was check if imports were loaded, and sky's parser
will wait on imports anyway, so there's no reason to block rendering
on imports as they'll likely be at the top of the document and stop
the rest of the page from being appended or rendered.

Sky apps will probably also want more control over rendering and not
want the old school web style of incremental rendering.

R=abarth@chromium.org, ojan@chromium.org

Review URL: https://codereview.chromium.org/835273006
2015-01-12 22:11:01 -08:00
Elliott Sprehn
c4ecc2236b Remove didRemoveAllPendingStylesheet.
Nothing calls this now, and sky has no concept of pending stylesheets.

TBR=ojan@chromium.org

Review URL: https://codereview.chromium.org/849773002
2015-01-12 20:33:20 -08:00
Elliott Sprehn
689b91c36d Replace sheet change methods with styleResolverChanged.
Unlike blink in sky we just want to mark tree scopes dirty. We can
remove these methods, the dirty tree scope tracking we'll add in
the future will take care of this.

R=ojan@chromium.org

Review URL: https://codereview.chromium.org/836893003
2015-01-12 18:23:55 -08:00
Elliott Sprehn
7fd0df2238 Remove tracking of pending sheets.
I was going to remove all this anyway since we don't need it in sky, all sheets
are local and there's no concept of a pending sheet now.

I also removed the dirty bit I added to StyleSheetCollection. The bit
is not correct and is preventing us from correctly processing sheets and
invalidating style. I'll add it back later when I understand how to add
the dirty bit correctly.

R=ojan@chromium.org

Review URL: https://codereview.chromium.org/846183002
2015-01-12 18:15:23 -08:00
Ojan Vafai
f97bad962e Get rid of the full invalidation bool on FrameView.
It doesn't do anything anymore. Also, delete some now
dead paint invalidation code in RenderObject.

R=esprehn@chromium.org

Review URL: https://codereview.chromium.org/849763002
2015-01-12 18:14:27 -08:00
Ojan Vafai
a044a6d074 Get rid of the *AndFullPaintInvalidation methods.
They now do the same thing as the non-AdnFullPaintInvalidation
versions.

R=esprehn@chromium.org

Review URL: https://codereview.chromium.org/840483004
2015-01-12 17:51:19 -08:00