Commit graph

156 commits

Author SHA1 Message Date
Ms2ger
5c93d47292 servo: Merge #2055 - Remove trailing whitespace (from Ms2ger:trws); r=jdm
Done with `git ls-tree --name-only -r HEAD . | grep "\.rs" | xargs sed -i 's/\s\+$//g'`

Source-Repo: https://github.com/servo/servo
Source-Revision: bf405ac81ff965c0370743185b9685b7a1de8c17
2014-04-07 10:52:26 -04:00
Josh Matthews
a3b4dbff7f servo: Merge #2041 - Upgrade rust (from servo:rustup_20140321b); r=larsbergstrom
Source-Repo: https://github.com/servo/servo
Source-Revision: 83aabe327d3b713581a4183b7f23cea0c39a94c9
2014-04-04 18:52:50 -04:00
Simon Sapin
0297c25705 servo: Merge #1988 - Acid2 2 (from pcwalton:acid2-2); r=SimonSapin
r? @metajack @SimonSapin @larsbergstrom @june0cho @hyunjunekim

Source-Repo: https://github.com/servo/servo
Source-Revision: 3ec22157ca20227cd2d648744b6c711ed0ae8366
2014-04-03 21:01:48 -04:00
lpy
7c07adb1d9 servo: Merge #2022 - Get rid of match statements in Layout queries.(fixes #2019) (from lpy:issue2019); r=jdm
see #2019

Source-Repo: https://github.com/servo/servo
Source-Revision: e3bf08ea537366a1624a082999c3548fa07d4650
2014-04-01 15:31:50 -04:00
Martin Robinson
33cb8edba0 servo: Merge #2002 - Store Window.active_timers in a HashMap (from mrobinson:issue-1477); r=jdm
A HashMap allows easily looking up a timer and canceling it in
Window.ClearTimeout.

Fixes #1477.

Source-Repo: https://github.com/servo/servo
Source-Revision: 3eac31394cb509ce7e4fa61a3543f6ec22c8bde4
2014-03-31 19:07:50 -04:00
Ms2ger
b0c7fbe938 servo: Merge #1913 - Move attributes-related functions onto JS<Element> (from Ms2ger:attributes); r=jdm
Source-Repo: https://github.com/servo/servo
Source-Revision: 509ff7e52f6ea4f2f736d13f124c854d80c316c9
2014-03-20 14:46:34 -04:00
Tetsuharu OHZEKI
cb6991627c servo: Merge #1864 - Split TCast::to into TCast::to_unchecked and TCast::to (from saneyuki:split_cast_to); r=jdm
fix #1836

Source-Repo: https://github.com/servo/servo
Source-Revision: 831712206865e2c0516009b16e2ac60f754dd1a8
2014-03-20 10:58:36 -04:00
Lars Bergstrom
382dd8c9ba servo: Merge #1934 - Rust upgrade (from larsbergstrom:rust_20140224_squashed); r=jdm
For review only - don't approve yet (need to squash and land submodule updates first).

critic? @metajack

Source-Repo: https://github.com/servo/servo
Source-Revision: f7aa6e3d9b8bfcc0565624f1094241b3b8658bd8
2014-03-19 12:35:17 -04:00
Ms2ger
0728d02843 servo: Merge #1868 - Use the improved JSVal interfaces (from Ms2ger:JSVal); r=jdm
Requires https://github.com/mozilla-servo/rust-mozjs/pull/54.

Source-Repo: https://github.com/servo/servo
Source-Revision: 654f3db29511d3b7b7a49a875b86a8538d111bcf
2014-03-10 10:22:51 -04:00
Ms2ger
8a6b3d8aae servo: Merge #1829 - Remove page_from_context (from Ms2ger:page_from_context); r=jdm
Source-Repo: https://github.com/servo/servo
Source-Revision: b9b4eebab5664d026435d70bf3f2ac40c5b56826
2014-03-05 15:13:29 -05:00
Ms2ger
098edf1c89 servo: Merge #1811 - Cleanup the *Binding::Wrap functions (from Ms2ger:Wrap_); r=jdm
Source-Repo: https://github.com/servo/servo
Source-Revision: da6a571f9e147d884bf0fe0017204321f5d75f5d
2014-03-05 09:31:44 -05:00
lpy
c678726e97 servo: Merge #1802 - Remove next_subpage_id argument from parse_html.(fixes #1801) (from lpy:issue1801); r=kmcallister
see #1801

Source-Repo: https://github.com/servo/servo
Source-Revision: 4a6077ca4cb6e2d54e2f558c18f45849c9d3c47d
2014-03-03 19:58:28 -05:00
Keegan McAllister
030c0fa802 servo: Merge #1800 - Fix a dynamic borrow failure with iframes (from kmcallister:subpage-id); r=jdm
Source-Repo: https://github.com/servo/servo
Source-Revision: a30041e9608b041dcf2a46f6b9f5e183817a55ae
2014-03-03 18:16:27 -05:00
Josh Matthews
1101a9f707 servo: Merge #1755 - De-@mut the script crate (from jdm:demut); r=jdm,metajack
Requires https://github.com/mozilla-servo/rust-mozjs/pull/49.

Source-Repo: https://github.com/servo/servo
Source-Revision: ea29e3a001fb70b5e94af7a676345b4046771315
2014-02-28 13:46:38 -05:00
Tetsuharu OHZEKI
a010046858 servo: Merge #1783 - Implement "resize" DOM Event (from saneyuki:resize); r=jdm
#1715

Source-Repo: https://github.com/servo/servo
Source-Revision: def5483579fad1e7f77ca96bd10fc5eb85e37740
2014-02-28 11:07:43 -05:00
lpy
042d6c49af servo: Merge #1776 - Add url getter to Page.(fixes #1762) (from lpy:issue1762); r=jdm
see #1762

Source-Repo: https://github.com/servo/servo
Source-Revision: 82b74a373a404c334ae711ec78dd4d06690f2cbb
2014-02-28 02:04:49 -05:00
Ms2ger
ea8e887ed8 servo: Merge #1751 - Handle removing the src attribute from an img element (from Ms2ger:image-loading); r=jdm
Source-Repo: https://github.com/servo/servo
Source-Revision: e006c111f583bb327f9b83cedcbf7a7fbcc3123c
2014-02-25 13:49:34 -05:00
Ms2ger
63a5574635 servo: Merge #1739 - Merge HTMLDocument into Document (from Ms2ger:document-cleanup); r=jdm
The specs currently have only Document; this may well change, but the split won't be along the lines we've implemented right now. In the meantime, this simplifies our code quite a bit.

Source-Repo: https://github.com/servo/servo
Source-Revision: 22760b6665c75f6908bcfd7cad4de111187ac6f7
2014-02-24 17:13:46 -05:00
Josh Matthews
6ce95abf91 servo: Merge #1591 - Convert all DOM types from @mut to JSManaged (from jdm:jsmanaged); r=Ms2ger
Source-Repo: https://github.com/servo/servo
Source-Revision: ffcf3b2905b7f9e886904015b1583e93f78f1199
2014-02-24 15:19:51 -05:00
Ms2ger
3f6bd354a8 servo: Merge #1703 - Various cleanup related to strings (from Ms2ger:strings-cleanup); r=jdm
Source-Repo: https://github.com/servo/servo
Source-Revision: 41f55059a80156408368e375c2118066798958b9
2014-02-16 06:02:05 -05:00
Keegan McAllister
3a87a6327c servo: Merge #1691 - Restore failure handling (from kmcallister:linked-failure); r=pcwalton
We probably leak some threads and resources, e.g. when the script task crashes and doesn't get a chance to send layout data back to layout to be deallocated.

Not tested with iframes yet.

Source-Repo: https://github.com/servo/servo
Source-Revision: f1de0b738134f153a398866f76d1b5d0213d3c02
2014-02-13 18:08:07 -05:00
HyunJune Kim
4f88a0031b servo: Merge #1633 - Pseudo class hover (from parkjaeman:pseudo-class-hover); r=larsbergstrom
Fix #790 partially.
I am sure I need to merge with @jdm's event handler for dom.
As son as the event handler is implemented, I will fix.
And this is implement Hover Event. If over element, Currently Full reflow.
After PR, will make partial reflow.
Thank you!

Source-Repo: https://github.com/servo/servo
Source-Revision: ccfd595d6ebd0dcd7a81d1ef9fa05801cd955f8a
2014-02-09 21:35:09 -05:00
Tetsuharu OHZEKI
93bf096dc6 servo: Merge #1642 - Reduce copying on parse_url() call sites (from saneyuki:1535); r=SimonSapin
this will fix #1535

r?

Source-Repo: https://github.com/servo/servo
Source-Revision: aae5be557af75263b764f010857561059a57d38f
2014-02-08 15:10:43 -05:00
Simon Sapin
c43dc93fa3 servo: Merge #1608 - Rename make_url/current_url to parse_url/base_url (from SimonSapin:url); r=metajack
Align with spec terminology.

Source-Repo: https://github.com/servo/servo
Source-Revision: fe1bb6a325a750566afaa26158b8ad5ab6cec59a
2014-02-07 14:31:35 -05:00
Lars Bergstrom
77a80051d5 servo: Merge #1597 - Ensure ref tests wait to write their PNG until the page has fully loaded and reflowed (from larsbergstrom:add_page_loaded); r=pcwalton
Add a LoadComplete message so that script informs the constellation, which can then inform the compositor (and anyone else, later) about the completion of loading a page. This is important for ref tests, which should not emit a PNG until load has completed, even if we perform a composite before then.

Note that we must *also* wait for the `ready_state` to indicate that additionally layout has completed any associated reflow with the page, otherwise we could get the `LoadComplete` while the final reflow is still in progress and thus would write out the `n-1`'th reflow result.

r? @pcwalton

Source-Repo: https://github.com/servo/servo
Source-Revision: e9a0c8184f1af460583fe5ab2615e01d08ffc22f
2014-01-30 12:49:28 -08:00
Bruno de Oliveira Abinader
452407e34c servo: Merge #1583 - Implement document.URL & document.documentURI (from brunoabinader:document-url); r=Ms2ger
Specs:
http://dom.spec.whatwg.org/#dom-document-url
http://dom.spec.whatwg.org/#dom-document-documenturi

This is a sub-task for #1428.

Source-Repo: https://github.com/servo/servo
Source-Revision: 572959c3e6d233f470f7851b470bf3f73f8d4191
2014-01-30 08:58:40 -08:00
Simon Sapin
21cb888158 servo: Merge #1561 - Refactor namespaces (from SimonSapin:refactor-namespace); r=pcwalton
This builds on top of #1560 (… which I realize now may confuse Critic)

This refactors Namespace to reduce the overall amount of copying and conversion. In particular, it makes parsed selectors contain Namespace enums rather than strings.

Source-Repo: https://github.com/servo/servo
Source-Revision: edda06115ac61c691e7762bcdb3e70b48b1c65bc
2014-01-25 13:19:02 -08:00
Jack Moffitt
ca21b7bc1d servo: Merge #1533 - Change get_attr() to get_attr_val_for_layout() (from metajack:unsafe-get-attr); r=jdm
The old code was used by both layout and script, but was erroneously
borrowing for the layout case (which causes parallelism
problems). script now uses only `value_ref()` or `get_attribute()`, and
layout now has its own unsafe version that dances around the borrows of
`@mut Attr`.

Source-Repo: https://github.com/servo/servo
Source-Revision: d11e4318871e8ed237292985f30063f719bbfb0d
2014-01-22 16:28:20 -08:00
Lars Bergstrom
7611e8ef3f servo: Merge #1500 - Fix crashes and deadlocks when running the content tests (from larsbergstrom:content_fixup); r=metajack
r? @metajack

Source-Repo: https://github.com/servo/servo
Source-Revision: 9b7425000b6b5df1e409699f8faead47eb9e41a8
2014-01-15 19:40:00 -08:00
Patrick Walton
0f1886c8bb servo: Merge #1490 - script: Stop trusting pointers to DOM nodes that layout provides (from pcwalton:distrust-layout-new); r=jdm
Pointers to DOM nodes from layout could go stale if incremental reflow
does not correctly destroy dead nodes. Therefore, we ask the JavaScript
garbage collector to verify that each DOM node is indeed a valid pointer
before calling event handlers on it, and fail otherwise.

Depends on the `get-addressable-gc-thing` branches of `mozjs` and `rust-mozjs`.

r? @jdm

Source-Repo: https://github.com/servo/servo
Source-Revision: c876335d227d4f826b5ece66fb388134cf29fce4
2014-01-14 22:06:56 -08:00
zmike
d37a94aca8 servo: Merge #1457 - add names for all servo spawned tasks (from zmike:master); r=jdm
this should resolve #1169

Source-Repo: https://github.com/servo/servo
Source-Revision: 563d6ef91a43a4ebefb87281db7e4813d2afcee6
2014-01-13 12:11:35 -08:00
Jack Moffitt
ab8faa4f7f servo: Merge #1473 - Upgrade to latest Rust (from metajack:rustup-20131219); r=jdm
Source-Repo: https://github.com/servo/servo
Source-Revision: 943ab4a4f0e3074e78d96ad94b7e96a46edacf79

--HG--
rename : servo/src/components/main/layout/box.rs => servo/src/components/main/layout/box_.rs
2014-01-12 19:16:21 -08:00
Patrick Walton
f375bf9d80 servo: Merge #1409 - script: Don't do anything before the window size comes in (from pcwalton:fix-get-bounding-client-rect); r=jdm
This fixes the `getBoundingClientRect()` content test.

r? @jdm

Source-Repo: https://github.com/servo/servo
Source-Revision: de36f37ac76125be9b7bff02736d8f5c7b10e995
2014-01-07 19:46:25 -08:00
Ms2ger
91ea6c3e9f servo: Merge #1438 - Pass a Namespace to Element::{get_attribute,get_attr} (from Ms2ger:cleanup-get_attribute); r=jdm
Passing these around as strings is an anti-pattern, IMO.

Source-Repo: https://github.com/servo/servo
Source-Revision: cb336a18317195512a276971856081cb8ef86b0e
2013-12-23 10:49:05 -08:00
Patrick Walton
cf773ab0f2 servo: Merge #1424 - Harden layout (from pcwalton:harden-layout); r=pcwalton
This changeset gets rid of the `FooView` phantom type in favor of a more brute force approach that just whitelists methods that layout is allowed to call. The set is surprisingly small now that layout isn't going to the DOM for much.

If this approach turns out not to scale, we can do something fancier, but I'd rather just have it be safe and secure first and then refactor later for programmer happiness.

r? @kmcallister

Source-Repo: https://github.com/servo/servo
Source-Revision: 824c7ac613ebb80bb432ff6425c5e25c642b6afb
2013-12-17 18:16:05 -08:00
Patrick Walton
dace488433 servo: Merge #1422 - script: Make trees less generic (from pcwalton:less-generic-trees); r=metajack
r? @metajack

Source-Repo: https://github.com/servo/servo
Source-Revision: e4495453c8b06f31bdbb984e92a184eb2d67c3d6
2013-12-17 13:49:17 -08:00
Patrick Walton
f200e1c4f2 servo: Merge #1408 - layout: Stop going to the DOM for iframe sizes (from pcwalton:stop-going-to-dom-for-iframes); r=larsbergstrom
r? @larsbergstrom

Source-Repo: https://github.com/servo/servo
Source-Revision: a9980b992c47e6fcac1f6c4510e36a49aa22fbbd
2013-12-13 15:19:16 -08:00
Patrick Walton
b88eae4ace servo: Merge #1405 - constellation: Stop using futures for frame sizes (from pcwalton:defuture); r=larsbergstrom
This will allow us to stop going to the DOM in order to handle iframe
sizing. Instead we can just store the pipeline and frame IDs of iframes
inside the flow tree itself.

r? @kmcallister

Source-Repo: https://github.com/servo/servo
Source-Revision: aa1ebbbdb0243f098921103f02bb9b7dbcc40441
2013-12-13 11:28:10 -08:00
Ms2ger
220079de75 servo: Merge #1403 - Mark some rust files as non-executable (from Ms2ger:exec); r=metajack
Source-Repo: https://github.com/servo/servo
Source-Revision: 499aa97fa4424cad9585e57987665542003e2597
2013-12-13 09:40:26 -08:00
Keegan McAllister
c31215880b servo: Merge #1394 - Restore restyle damage computation but disable reflow pruning for now (from kmcallister:style-damage); r=pcwalton
This fixes the computation of restyle damage on `color-change-text.html`, which can be seen with `RUST_LOG=servo::layout::layout_task`.

However we can't prune the layout traversals yet, because we don't reuse `Flow` objects between reflows, so we have no old values to fall back to.

I think this used to work because `FlowContexts` (as they were called then) were stored in a DOM node's `LayoutData` and reused.  But it's possible that it never really worked, and my testing when I landed the restyle damage code was insufficient (I didn't understand the layout code nearly as well back then).

r? @pcwalton

Source-Repo: https://github.com/servo/servo
Source-Revision: 144737ce1b582952a894f29e30e16134c73b2464
2013-12-12 15:17:27 -08:00
Simon Sapin
525a29a0b7 servo: Merge #1368 - Fix #1264: support namespaced attribute selectors (from SimonSapin:master)
Source-Repo: https://github.com/servo/servo
Source-Revision: fc80be982a75e02093b4096bea6799953fe904b9
2013-12-11 09:16:47 -08:00
Keegan McAllister
93e617b0aa servo: Merge #1360 - Reflow with full style damage when content changes (from kmcallister:content-changed); r=jdm
r? @jdm

Source-Repo: https://github.com/servo/servo
Source-Revision: f7cc49c30f42a5154ece9ec6bc40487f2b7fd5cc
2013-12-09 13:07:24 -08:00
june0cho
f1d7e4f0d4 servo: Merge #1262 - Implement local bookmark(hashtag #) for Acid2 (from june0cho:acid2_local_bookmark); r=jdm
To test this, execute the followings:
    test_local_bookmark.html#text1
    test_local_bookmark.html#text2
    test_local_bookmark.html#text3
    test_local_bookmark.html#top
    test_local_bookmark.html#h3
    test_local_bookmark.html#num
    acid2.html#top
     - The link from acid2.html works now. ( `<a href="#top">`)

Thanks to @metajack!

Source-Repo: https://github.com/servo/servo
Source-Revision: 0c4b10cc2cccd2263ad9e9b1c7e84d5093d26195
2013-11-30 14:37:11 -08:00
Patrick Walton
cd47830e0a servo: Merge #1271 - Rewrite flow construction to be incrementalizable and parallelizable (from pcwalton:incremental-reflow); r=larsbergstrom
This replaces flow construction with a strict bottom-up tree traversal,
allowing for parallelism. Each step of the traversal creates a flow or
a `ConstructionItem`, similar to how Gecko works. {ib} splits are
handled by not creating `InlineFlow`s until the containing block is
reached.

This should be able to be incrementalized by storing the `Flow` from
layout to layout, and performing fixups during flow construction
and/or wiping containing blocks in a previous pass.

r? @larsbergstrom

Source-Repo: https://github.com/servo/servo
Source-Revision: 736a258c26b6118c617e6dccb65d75988bcf5ee9
2013-11-18 11:54:00 -08:00
Ms2ger
69a8696016 servo: Merge #1266 - Make the HTML parser parse into the document rather than an element (from Ms2ger:double-root); r=jdm
This removes the duplicate html element.

Source-Repo: https://github.com/servo/servo
Source-Revision: 9a7ded729cc358832227dfe6966cb69bb001104b
2013-11-17 06:29:33 -08:00
Ms2ger
4477564b48 servo: Merge #1250 - Remove type_id arguments from Event::new and UIEvent::new (from Ms2ger:event-new); r=jdm
Source-Repo: https://github.com/servo/servo
Source-Revision: 8880419a76e4e2e23b7e1bccd4c83994ad1570a1
2013-11-15 07:34:25 -08:00
Tetsuharu OHZEKI
0655961310 servo: Merge #1209 - Stop passing DOMStrings via borrowed pointer (from saneyuki:domstr); r=jdm
This will fix #1201.
This maybe the work in progress.

@jdm:
* Should we pass `DOMString` directly to `dom::utils::null_str_as_...`?
* Do you have any good idea to update the comment in `CodegenRust.py`?

Source-Repo: https://github.com/servo/servo
Source-Revision: 7f13566d57b90468b0ab2a58fd2e4ba387510e4b
2013-11-14 09:40:31 -08:00
Ms2ger
1b24df4acf servo: Merge #1215 - Make DOMString represent a non-nullable string (from Ms2ger:DOMString-nonnull); r=jdm
Source-Repo: https://github.com/servo/servo
Source-Revision: 6a0201a5a6df613d63574fe1b63a1cb0f5ff892f
2013-11-12 05:53:09 -08:00
Josh Matthews
f66e219a92 servo: Merge #1213 - Add a spec-incompliant load event (from jdm:loadevent); r=kmcallister
It's good enough for now, since we don't track document resources at all. Should be good enough for #841.

Source-Repo: https://github.com/servo/servo
Source-Revision: da4ca510496c5596ddc3593909ebd1db2f5bf957
2013-11-12 01:01:34 -08:00
Jack Moffitt
c3d01cba20 servo: Merge #1163 - Rust upgrade (from metajack:kmc-rust-upgrade); r=kmcallister
Most work courtesy of @kmcallister.

I already reviewed Keegan's work, so just the last two commits need attention.

Source-Repo: https://github.com/servo/servo
Source-Revision: 352acbb8335fcf78f2d62dc781fa9d86b9368f9c
2013-10-31 16:34:14 -07:00
Josh Matthews
9ff8840630 servo: Merge #1161 - Make Document a Node (from jdm:docnode); r=metajack
r? @metajack

Source-Repo: https://github.com/servo/servo
Source-Revision: d54994a4003481aad8a2b6611d30a2f64b50f071
2013-10-31 13:31:42 -07:00
Patrick Walton
cee348e4ef servo: Merge #1128 - Revert "Make Document a Node." for breaking Acid1 (from pcwalton:revert-document-node); r=metajack
This reverts commit 4e47d59165d186d0938fe9ffd726b2c1b83d50f4.

Conflicts:

	src/components/script/dom/domparser.rs

r? @metajack

Source-Repo: https://github.com/servo/servo
Source-Revision: 0490cc09ddc0f06d2a65cc6e43faffe994850aa6
2013-10-24 15:54:50 -07:00
Josh Matthews
3a9a8a3d73 servo: Merge #1079 - Make Document a Node (from jdm:docnode); r=jdm,metajack
The bit I don't like about these changes is that I ended up hiding the document node from the CSS selecting/matching code, so it continues thinking of the document's first child as the root. When I tried to send the full tree including the document node to layout, the layout code refused to create any child flows. When I sent the document's first child without hiding the document, it saw inherited values for properties like font-family, and later tried to treat the document node as an Element when searching for named nodes.

Source-Repo: https://github.com/servo/servo
Source-Revision: 13644ccab1942c053c3fd5e4a19bb75d9ebe8739
2013-10-24 09:15:55 -07:00
Jack Moffitt
b40ed3e857 servo: Merge #1067 - Rust upgrade (from metajack:rust-up-20131014); r=jdm
This upgrades to this morning's master. We have unfortunately broken the Android build, but I will update that in a second pull request as I think it's more than a single upgrade behind.

Source-Repo: https://github.com/servo/servo
Source-Revision: 797143a1d3e09b4ddd35a1ce5948be424ec3f9ef
2013-10-22 09:16:17 -07:00
Ms2ger
ef05d248e9 servo: Merge #1099 - Remove {Node, Document}::{with_base, with_mut_base} (from Ms2ger:abstract-borrowed-pointers); r=jdm
Source-Repo: https://github.com/servo/servo
Source-Revision: 4d8f7fd056cc59cce02de9f3e710116ea8a85afe
2013-10-21 09:37:03 -07:00
Keegan McAllister
8cd56709a6 servo: Merge #1082 - Misc small changes (from kmcallister:misc); r=jdm
Source-Repo: https://github.com/servo/servo
Source-Revision: 38cea1b2d5c04133f7598380b8e22d31feb8bb17
2013-10-17 20:13:07 -07:00
Keegan McAllister
a236e1f721 servo: Merge #1077 - Short-term fixes for non-ASCII in JavaScript (from kmcallister:jsstr); r=jdm
This doesn't resolve the big questions of how Servo will represent strings; it's just about doing the conversion correctly for our existing types.

Source-Repo: https://github.com/servo/servo
Source-Revision: ebe1c1353ca0ffe1f0e195f4ed66abb982f303ee
2013-10-17 16:34:30 -07:00
Simon Sapin
4080bdd5ac servo: Merge #1075 - More style system (from SimonSapin:newnewcss); r=kmcallister
I believe this is all the preparatory work discussed in #1006 and #1057: The new 'style' crate implements the whole style system (including parsing, matching and cascading) and only depends on cssparser and util, so that gfx, script and main can all depend on it.

Next: porting the layout code to this. (Really, this time! I think.)

Source-Repo: https://github.com/servo/servo
Source-Revision: 6db57e6f72c85cd5233f431817f9344aed8eab87

--HG--
rename : servo/src/components/gfx/geometry.rs => servo/src/components/util/geometry.rs
2013-10-16 15:37:42 -07:00
Ms2ger
a307fb4023 servo: Merge #1072 - Issue #1071 - Ensure that Documents always have a non-null Window (from Ms2ger:crash-domparser); r=jdm
Turns out that documents without a window `fail!` a lot, because we need the `cx` all over.

Source-Repo: https://github.com/servo/servo
Source-Revision: 509934cf65acb1061cf4b012556ff6782e3203c9
2013-10-16 02:37:09 -07:00
Ms2ger
f6d158d953 servo: Merge #1051 - Make Document::root private (from Ms2ger:private-root); r=jdm
In preparation for removing it as part of making Document a Node.

Source-Repo: https://github.com/servo/servo
Source-Revision: 8d3c7a2ded69f035f8fc98a38dd337237cb7db2a
2013-10-14 10:22:00 -07:00
Ms2ger
24573051a2 servo: Merge #1027 - Issue #888 - Node's owner document should never be None (from Ms2ger:owner-document); r=jdm
I'm not happy about `is_in_doc`, but that should improve once @jdm lands his document-as-node changes.

Source-Repo: https://github.com/servo/servo
Source-Revision: b0ac5911ec8e818ff88e8177aa97415e7729141c
2013-10-10 02:27:59 -07:00
Bobby Holley
f08243e914 servo: Merge #1028 - Rename various bits of reflector-related machinery (from bholley:reflector_rename); r=jdm
There are still a few instances of "wrapper"-ish names scattered throughout the code, but this is a good start.

Source-Repo: https://github.com/servo/servo
Source-Revision: 89dd9dd8eb2e473dffd5ad2d5d75012b15f75570
2013-10-09 05:40:12 -07:00
Ms2ger
cc1633ff33 servo: Merge #1016 - Don't require passing a root element to Document::new (needed for issue #888) (from Ms2ger:ownerdoc); r=jdm
Source-Repo: https://github.com/servo/servo
Source-Revision: 77f8dba48b21e200b4b9c6d35db853581b9804bc
2013-10-08 05:16:01 -07:00
Josh Matthews
106072789d servo: Merge #1005 - Various fixes for crashes and frequent task failure at shutdown (from jdm:failfixes); r=metajack
Fixes #1004. I haven't seen the other ones be reported, but I saw often saw `task <unnamed> failed at 'RenderChan.send: render port closed', /home/jdm/sdb/servo/src/components/gfx/render_task.rs:76`, `task <unnamed> failed at 'receiving on closed channel', /home/jdm/sdb/servo/src/compiler/rust/src/libstd/rt/comm.rs:487`, and failed assertions due to layout running after we had begun tearing down the window.

Source-Repo: https://github.com/servo/servo
Source-Revision: 096af85834e25d86487e82851331d93374782eac
2013-10-01 23:54:50 -07:00
Brian Anderson
b8bcb42dac servo: Merge #1002 - Run script in its own thread to avoid starving other tasks (from brson:scriptthread); r=jdm
This appears to fix the problem with the Rust logo stopping during the demo.

Though this is the right way to spawn a SpiderMonkey thread, I'm not entirely sure why this fixes the problem in all scenarios. With enough threads (i.e. `RUST_THREADS=32`), and running with some Rust patches that are available on master (which I applied during testing), I would expect work stealing to not allow starvation here. In my tests though I see the problem even with lots of threads, so this may yet indicate a scheduler bug. Still, SpiderMonkey should get its own thread.

Source-Repo: https://github.com/servo/servo
Source-Revision: be5deb2a680524b7f802d20bb058175b3853489b
2013-10-01 15:52:41 -07:00
Keegan McAllister
8241767f49 servo: Merge #977 - Handle HTTP 3xx redirects (from kmcallister:redirect); r=jdm
Source-Repo: https://github.com/servo/servo
Source-Revision: b7d186dec2de90707b8e0fc09551e543a0744282
2013-09-24 12:45:44 -07:00
Tim Kuehn
fcc0879b91 servo: Merge #966 - Close the correct pipelines when evicted from navigation context (from tikue:master); r=metajack
Fixes #967 and #965

This has been wrong for a long time. Previously, only the pipeline associated with the root frame evicted would be shut down. 1) It shouldn't necessarily be closed, because there could be references to it still in the navigation context, and 2) Presumably none of the children pipelines of the root frame were ever exiting.

It's hard to test this right now because #965 covers up other pipeline exiting issues, but when that's fixed, a pathological case in which things would have broken down would be:

1) Load a page with an iframe that contains a link
2) Click the link
3) Press backspace to navigate back
4) Navigate to any new page, at which point the forward page would be evicted from the navigation context, and the outer frame's pipeline would be shut down improperly.
5) Press backspace, at which point there is no longer a pipeline for the old page, because it was shut down prematurely. Presumably this would cause a crash.

I also changed the FrameTree function ```find_mut``` to ```find``` because find_mut implies it's doing something to cause mutability, but the mutability is caused by the type of object being iterated over, nothing else.

Additionally, script was exiting completely when receiving an exit message. Instead, it needs to handle exit messages according to who sent it. It should only close the subframes of the frame whose pipeline sent the exit message. This is now fixed.

Inexplicably, script was also closing the compositor upon receiving an exit message. This doesn't seem like it'd ever be the right thing to do. *Edit: this is _only_ the right thing to do when received from the window.* I've fixed that. I don't think anyone shuts down the compositor now. *Edit: the script shuts down the compositor only when receiving an exit from the window.*

Source-Repo: https://github.com/servo/servo
Source-Revision: 401176b72d9ac9e4493ca27fca5aa5450500a333
2013-09-23 21:24:42 -07:00
Tim Kuehn
db974d5912 servo: Merge #961 - Fix profiler usage when not flagged (from tikue:master); r=kmcallister
* Profiler is now close to a no-op when ```-p``` is not passed in
* The profiler's printing ```Timer``` now stops looping when the profiler is closed
* Most task ```Chans``` are now newtype ```structs```
* Some more ```Cell``` removals in places where ```spawn_with``` is appropriate

Source-Repo: https://github.com/servo/servo
Source-Revision: e576a1cf7eb3191e6a740b8537517b28fbb4950c
2013-09-20 15:39:46 -07:00
Tim Kuehn
989c86c230 servo: Merge #958 - use spawn_with in lieu of cells (from tikue:master); r=pcwalton
Cells are generally less readable, and spawn_with makes many of them unnecessary.

Source-Repo: https://github.com/servo/servo
Source-Revision: b85497b76a7e002f816333fa2aa5fd2096ffce41
2013-09-19 14:36:56 -07:00
James Graham
360ae850ad servo: Merge #954 - Add support for clearTimeout (from jgraham:clear_timeout); r=metajack
Source-Repo: https://github.com/servo/servo
Source-Revision: 849ff1b754009625243d5abe80f87d24aeab2b40
2013-09-18 18:45:53 -07:00
Josh Matthews
1fcfe54675 servo: Merge #947 - Make DOM manipulation wait until layout's complete, and implement a textContent setter (from jdm:textcontent-setter2); r=metajack
Source-Repo: https://github.com/servo/servo
Source-Revision: a67fda0f462a9956396ea19d057bb7637047c7b2
2013-09-16 21:09:49 -07:00
Josh Matthews
0d39db9fd1 servo: Merge #940 - Fix images encountered while parsing not displaying (from jdm:imagefix); r=metajack
Source-Repo: https://github.com/servo/servo
Source-Revision: bcc6c5250718962429f0cebae254539593b62c11
2013-09-14 08:18:55 -07:00
Josh Matthews
8061820604 servo: Merge #938 - Move border computation into unpruned traversal. Get rid of extraneous e (from jdm:borderincremental); r=metajack
...xplicit initial reflow. Fixes #935.

Source-Repo: https://github.com/servo/servo
Source-Revision: 34f740396e5f7b65e9bced4a750a07310256d856
2013-09-13 16:45:59 -07:00
Patrick Walton
4fd774988e servo: Merge #927 - script: Implement image source setting from script and write a demo for this (from pcwalton:image-src-set); r=pcwalton
r? @metajack

Source-Repo: https://github.com/servo/servo
Source-Revision: 3c7a837ee648ddf3ffe99dc16844b7f5692a5f45
2013-09-12 18:24:50 -07:00
Keegan McAllister
dbd4a035d3 servo: Merge #928 - Combine resize events for each pipeline and process when layout is idle (from kmcallister:resize); r=pcwalton
Source-Repo: https://github.com/servo/servo
Source-Revision: 44949351398ac759f7a2f5e27f4986163ec3df85
2013-09-12 18:00:56 -07:00
Josh Matthews
4fe15c0cc6 servo: Merge #926 - Fix a dynamic borrow error when executing timer callbacks (from jdm:pagewhoops); r=metajack
r? @metajack

Source-Repo: https://github.com/servo/servo
Source-Revision: 18442257382d33d55b3aaec1978a57df3dfd087e
2013-09-12 17:06:52 -07:00
Josh Matthews
3b86421613 servo: Merge #914 - *Page -> @Page (from jdm:unsafepage); r=jdm,metajack
Haven't figured out what to do about page_from_context yet, but this is a big improvement.

Source-Repo: https://github.com/servo/servo
Source-Revision: 8994dc3a1e2b62fe0fee65f84f46ac3fe17dbb9c
2013-09-12 14:48:59 -07:00
Josh Matthews
a4edb19a43 servo: Merge #915 - Trigger a reflow when nodes are appended and removed from the document. (from jdm:pinglayout); r=metajack
...Fixes #907.

Source-Repo: https://github.com/servo/servo
Source-Revision: 4cf80cd49c69a0da4b9d8c7df0ca5a9ece3b5a64
2013-09-12 11:43:00 -07:00
Josh Matthews
de16a45365 servo: Merge #908 - Fix segfault caused by document wrapper being GCed (from jdm:gccrash); r=metajack
Source-Repo: https://github.com/servo/servo
Source-Revision: 2372a841494dce56bc56467f2bcdb77ffa997cdd
2013-09-11 16:00:56 -07:00
Josh Matthews
8d20f1caf7 servo: Merge #900 - Make sandboxed iframes run with different script tasks (from jdm:sandbox); r=metajack
The rust-mozjs change is just updating it to tip; do not be alarmed.

Source-Repo: https://github.com/servo/servo
Source-Revision: 39252b25f792ae1b9c7e7d269083b18d29d9101a
2013-09-11 12:22:59 -07:00
Josh Matthews
19927445c1 servo: Merge #883 - Make the global object be the Window object. Fixes #833 (from jdm:newglobal); r=kmcallister
Requires https://github.com/mozilla-servo/rust-mozjs/pull/34.

Source-Repo: https://github.com/servo/servo
Source-Revision: 0dd90c75d87844350c4cf5deb69e49f44a853f97
2013-09-09 17:06:53 -07:00
Josh Matthews
32f90658c9 servo: Merge #864 - Make querying layout for content boxes an infallible operation (from jdm:displaylist); r=metajack
Source-Repo: https://github.com/servo/servo
Source-Revision: b5dcbd287d43e7e89c339c358a800c2332328a51
2013-09-04 08:21:58 -07:00
Tom Schuster
40721ef3d8 servo: Merge #853 - Pass the javscript file url to the evaluate function (from evilpie:file-url); r=metajack
This makes the JavaScript error prettier.

Source-Repo: https://github.com/servo/servo
Source-Revision: 7ea10ff8af09051d6b201a3fb26967b2f17780b2
2013-08-31 20:03:59 -07:00
Brian Anderson
af9c11325a servo: Merge #821 - Update Rust (from brson:master); r=brson,metajack,metajack
Still needs https://github.com/mozilla-servo/glfw-rs/pull/5 and https://github.com/mozilla-servo/rust-mozjs/pull/31

Source-Repo: https://github.com/servo/servo
Source-Revision: c532c739644be0285d14540acd679f7bf18db10b
2013-08-30 15:21:36 -07:00
Josh Matthews
d3ab70dc1c servo: Merge #814 - Make window.close() close the window (from jdm:windowclose2); r=metajack
Fixed #671.

Source-Repo: https://github.com/servo/servo
Source-Revision: dfdba06f8763ad92dc602eca9a4cc194ed5807c9
2013-08-28 19:15:36 -07:00
eschweic
c264e27ce2 servo: Merge #748 - Initial iframe support (from eschweic:iframes); r=pcwalton
Fixes tests and replaces #702.

Source-Repo: https://github.com/servo/servo
Source-Revision: e4bfad144edd3fcd491aeb6df14a864ecf6159d2
2013-08-20 10:54:58 -07:00
Keegan McAllister
f8dd4f7823 servo: Merge #735 - Upgrade to latest Rust (from kmcallister:rust-upgrade); r=kmcallister,metajack
Was #734.

Source-Repo: https://github.com/servo/servo
Source-Revision: 2359587cbbc77a86d92c9628f19bc883818c563f
2013-08-16 15:46:03 -07:00
Brian Anderson
46740949b8 servo: Merge #731 - Don't use 'select' (from metajack:noselect); r=pcwalton
The new runtime isn't quite mature enough to deal with it, and this
is faster anyway.

Rebased to land #728.

Source-Repo: https://github.com/servo/servo
Source-Revision: 693bbaf095e3db607ab12b9217be2a7fd9e6350b
2013-08-15 11:44:39 -07:00
Keegan McAllister
d92fd2e23f servo: Merge #656 - Fix freeze scope extension warning (from kmcallister:dynamic-freeze); r=jdm
Fixes #455 (for now)

Also add a comment about how what we're doing here is unsafe (for reasons that are mostly unrelated to the warning)

r? @tkuehn

Source-Repo: https://github.com/servo/servo
Source-Revision: 13afd25679a3d39692a3dc745339d978a6d133b7
2013-07-31 21:57:33 -07:00
Tim Kuehn
c104cb89bc servo: Merge #647 - added subpage ids to map from iframe to all associated pipelines (from tikue:master); r=metajack
This will be necessary for the constellation to properly assign sizes to iframes when a parent layout performs reflow.

Source-Repo: https://github.com/servo/servo
Source-Revision: feee4ddcb23a072e60bfe76cbaa738215e065ad6
2013-07-31 14:42:29 -07:00
Josh Matthews
33361059de servo: Merge #641 - Generate HTMLDocument bindings (from jdm:htmldoc2); r=jdm
There are several mechanical changes here that make this look more intimidating than it is. DOMStrings are now passed by reference, and Event and Event_ have swapped names. Finally, there are the various places that need to use `document.with_base |doc| { document.foo }` instead of `document.foo`.

Source-Repo: https://github.com/servo/servo
Source-Revision: 0c105b5307bb69e8d43a1c6263b09c1b8e52c355
2013-07-30 13:30:24 -07:00
Tim Kuehn
5271768982 servo: Merge #628 - Structural changes to support Iframes (from tikue:master); r=metajack
Completed:
  * Replace pipeline navigation context with frame tree navigation context
  * Reuse script task for same origin iframes
  * Block on size future for iframe reflow
  * Remove global script context
  * Change codegen to use specific page context rather than script context.

Still to do:
  * Compositor's handling of relative frame positions
  * Compositor currently only asks for tiles from outermost frame
  * Window events are forwarded to the outermost frame's script. Should be routed to proper script via constellation.
  * Layout's sending of updated iframe sizes to constellation or size future (initial size only) as reflow is performed

Source-Repo: https://github.com/servo/servo
Source-Revision: d9e71edb10973b0bd1739ac3221f1d87aec421ec
2013-07-29 21:21:19 -07:00
Keegan McAllister
398c15e0dd servo: Merge #619 - Fix crash with script timers, and other fixes (from kmcallister:script-redisplay); r=jdm
Stuff I found in the process of working on incremental layout.

Source-Repo: https://github.com/servo/servo
Source-Revision: f34a13a8b566d42a94f2127a3e3c6e6a36fb8180
2013-07-25 09:51:23 -07:00
Keegan McAllister
8ddaa83f51 servo: Merge #608 - Shut down old pipelines on navigation (from kmcallister:script-exit); r=metajack
Source-Repo: https://github.com/servo/servo
Source-Revision: 25fdcb3dca2016196f9e7b5714004b88a524f9cc
2013-07-22 13:33:20 -07:00
Tim Kuehn
b506916614 servo: Merge #580 - Beginnings of iframe handling and navigation bug fix (from tikue:master); r=metajack
Fixes #579.

Source-Repo: https://github.com/servo/servo
Source-Revision: 11873117a1cb01d1e030819c50f84b57a7a1a1f4
2013-07-11 17:51:34 -07:00
Tim Kuehn
6001471851 servo: Merge #559 - fixed fallout from the recent rust update afflicting the profiler (from tikue:master); r=metajack
r? @metajack this includes the rust-azure pointer change

Source-Repo: https://github.com/servo/servo
Source-Revision: b0495eb7fdf01245b3dfeb62ba0764e1ff9f2c75
2013-07-10 16:15:51 -07:00
Jack Moffitt
dc43ed81aa servo: Merge #563 - Replace GLUT with GLFW (from metajack:glfw); r=metajack
This code replaces glut with glfw. The motivation here is address the GPU driver bugs on Linux when using multiple `Display *` pointers with shared GL contexts instead of a single common one. GLFW has native access methods which provide access to its `Display *`, which appears to be unique among all the similar toolkits.

Details:
- Adds glfw and glfw-rs to the build
- Removes GLUT code and replaces it with GLFW versions
- Fixes hard coded initial window values
- Fixes clean targets
- Event loop doesn't block on windowing events anymore

Source-Repo: https://github.com/servo/servo
Source-Revision: 34a35054e9e113b9033fc050eaf25c82223c9aff
2013-07-10 06:57:36 -07:00
Tim Kuehn
2bbd78a465 servo: Merge #550 - Modular pipelines (from tikue:master); r=metajack
When loading pages, the constellation spawns a new script<-->layout<-->renderer pipeline that loads in the background while scripts continue executing on the currently loaded page.

Source-Repo: https://github.com/servo/servo
Source-Revision: 213d9a011a63842434df4e8ce3c359d08232aefa
2013-07-03 09:42:47 -07:00
Seth Fowler
789cdfa9e4 servo: Merge #551 - Don't send a resize event if the window size didn't change (from sethfowler:run-layout-once); r=metajack
Performance will be better and benchmarking easier if we don't run layout an extra unnecessary time when loading a page from the commandline. This is happening because we always send a resize event to the script task from the compositor whenever the platform tells us one happened, even if the window size didn't change. This PR fixes this by checking that the window size is actually different before sending the event.

Source-Repo: https://github.com/servo/servo
Source-Revision: fed4f951c19f5c8cfc474814c7e8ca6ebc257232
2013-06-27 19:12:34 -07:00
Brian Anderson
abe922ef08 servo: Merge #546 - Update for language changes (from brson:master); r=metajack
Source-Repo: https://github.com/servo/servo
Source-Revision: bc520e0143a82c20b01df518e7be486552a40538
2013-06-26 15:36:53 -07:00