aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/dom/location.rs
Commit message (Collapse)AuthorAgeFilesLines
* Support stringifier attributesKagami Sascha Rosylight2019-10-291-6/+1
|
* clean-up navigationGregory Terzian2019-07-181-6/+31
| | | | | | | | | | | | | | | | | | | | security: check target and source origin before executing JS url implement replacement-enabled flag as a HistoryEntryReplacement enum add source origin string on loaddata add LoadOrigin iframe: remove optional load-data auxiliaries: add load-data into info constellation: remove url from Pipeline::new check load origin: link to whatwg issue switch loadorigin toplevel to constellation
* set referrer in window.load_urlRussell Cousineau2019-04-191-7/+17
| | | | | | | | - this conforms to follow-hyperlinks spec step 13 - this conforms to window-open spec step 14.3 - replace uses of `referrer_url` with `referrer` - in Request class, change "no-referrer" to "" - set websocket fetch referrer to "no-referrer"
* Update MPL license to https (part 3)Jan Andre Ikenmeyer2018-11-191-1/+1
|
* Reorder importsPyfisch2018-11-061-1/+1
|
* `cargo fix --edition`Simon Sapin2018-11-061-10/+10
|
* Format script componentchansuke2018-09-191-7/+11
|
* Remove use of unstable box syntax.Simon Sapin2017-10-161-1/+1
| | | | | | | | | | | | | | | | | | | | http://www.robohornet.org gives a score of 101.36 on master, and 102.68 with this PR. The latter is slightly better, but probably within noise level. So it looks like this PR does not affect DOM performance. This is expected since `Box::new` is defined as: ```rust impl<T> Box<T> { #[inline(always)] pub fn new(x: T) -> Box<T> { box x } } ``` With inlining, it should compile to the same as box syntax.
* Rename Root<T> to DomRoot<T>Anthony Ramine2017-09-261-2/+2
| | | | | | | In a later PR, DomRoot<T> will become a type alias of Root<Dom<T>>, where Root<T> will be able to handle all the things that need to be rooted that have a stable traceable address that doesn't move for the whole lifetime of the root. Stay tuned.
* Rename JS<T> to Dom<T>Anthony Ramine2017-09-261-3/+3
|
* Rename dom::bindings::js to dom::bindings::rootAnthony Ramine2017-09-261-1/+1
|
* Untry scriptSimon Sapin2017-06-181-19/+19
|
* Fix various build warningsAaron Cunningham2017-04-241-0/+1
| | | | | | This should remove six separate warnings when building servo. One of the warnings was an unused mut, and the other were various dead code warnings
* added origin to globalscopeddh2017-04-241-1/+5
|
* Implement setter for document.domainAlan Jeffrey2017-03-151-1/+1
|
* Added some same-origin-domain checks.Alan Jeffrey2017-03-141-33/+81
|
* Make #[dom_struct] a proc_macro attributeAnthony Ramine2017-02-241-0/+1
|
* Implement Location.replacePu Xingyu2016-11-181-0/+12
|
* Move fragment navigation into Document objectPu Xingyu2016-11-181-4/+5
| | | | | | | Move the `check_and_scroll_fragment()` method into Document, make the mothod set the fragment of url after navigation, and use the `perform_a_scroll()` method to scroll rather than an individual method. Also removes the broken `Window.fragment` fields.
* Urlmageddon: Use refcounted urls more often.Emilio Cobos Álvarez2016-11-171-3/+3
|
* Make reflect_dom_object take a &GlobalScopeAnthony Ramine2016-10-061-2/+1
|
* Make Assign throw error on invalid urlEric Coan2016-09-261-1/+5
|
* Bring referrer policy delivery to <a> and <link> via rel attributeYing-Ruei Liang(KK)2016-09-201-4/+4
|
* Replace current session entry for reloadsConnor Brewster2016-09-191-4/+4
|
* Ensure that a navigation to the same URL is aborted. Fixes #10952.Josh Matthews2016-06-291-1/+4
|
* Move DOMString back to scriptAnthony Ramine2016-05-241-2/+1
| | | | This entirely removes the 'non-geckolib' feature of the util crate.
* add origin to location and url apiChandler Abraham2016-01-211-0/+5
|
* Use Url.join instead of UrlParser.base_url(...).parse (#9002)Mathieu Agopian2015-12-181-3/+3
|
* Replaced DOMString constructor by conversion functions.Alan Jeffrey2015-11-121-1/+1
| | | | | | Replaced DOMString(...) by DOMString::from(...). Replaced ....0 by String::from(...). Removed any uses of .to_owner() in DOMString::from("...").
* Make DOMString a newtype around String, rather than a typedef.Ms2ger2015-11-041-1/+1
| | | | | | | | | | This should make it somewhat easier to experiment with alternative representations in the future. To reduce churn, this commit leaves the String field public, though. Also, this will allow us to use the default String type to represent the IDL USVString type, which explicitly forbids unpaired surrogates, ans as such is a better match to the Rust String type.
* rearrange imports to be in alphabetical orderrohan.prinja2015-10-301-1/+1
|
* more refactoringrohan.prinja2015-10-301-1/+1
|
* Update URL-related interfaces and their tests up to specAnthony Ramine2015-10-191-43/+21
| | | | | | | | | The URL spec recently changed and the variour "mixins" interfaces are gone, this commit updates our code and WPT accordingly. The new expected failures related to HTMLAnchorElement and HTMLAreaElement's attributes are due to their moving to the HTMLHyperLinkElementUtils interface, which is not anymore in a separate <script class=untested> element.
* Do not root Location::windowAnthony Ramine2015-10-191-11/+8
|
* implement window.location.reload()Paul Rouget2015-09-211-0/+5
|
* Fix reported test-tidy errors for unmerged import blocksBrandon Fairchild2015-09-191-1/+0
| | | | This merges import blocks that were reported by tidy as unmerged.
* Implement setters in URLUtilsAnthony Ramine2015-08-301-9/+68
|
* Make the traits for the IDL interfaces take &selfAnthony Ramine2015-08-271-13/+13
|
* Remove helper traitsAnthony Ramine2015-08-271-6/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Now that JSRef<T> is gone, there is no need to have helper traits. On components/script/*.rs: # Remove imports. /^ *use dom::[a-z]+::\{.*Helpers/ { s/\{(Raw[^L]|[^L][^a])[a-zA-Z]+Helpers, /\{/ s/, (Raw[^L]|[^L][^a])[a-zA-Z]+Helpers([,}])/\2/g s/\{([a-zA-Z]+)\}/\1/ /\{\}/d s/::self;$/;/ } /^ *use dom::[a-z]+::\{?(Raw[^L]|[^L][^a])[a-zA-Z]+Helpers\}?;$/d On components/script/dom/*.rs: # Ignore layout things. /^(pub )?(impl|trait).*Layout.* \{/,/^}$/ { P; D; } # Delete helpers traits. /^(pub )?trait ([^L][^ ]|L[^a])[^ ]+Helpers(<'a>)? \{$/,/^\}$/D # Patch private helpers. /^impl.*Private.*Helpers/,/^\}$/ { s/^impl<'a> Private([^L][^ ]|L[^a])[^ ]+Helpers(<'a>)? for &'a ([^ ]+) \{$/impl \3 {/ /^ *(unsafe )?fn .*\(self.*[<&]'a/ { s/&'a /\&/g s/<'a, /</g } /^ *(unsafe )?fn /s/\(self([,)])/\(\&self\1/ } # Patch public helpers. /^impl.*Helpers/,/^\}$/ { s/^impl(<'a>)? ([^L][^ ]|L[^a])[^ ]+Helpers(<'a>)? for (&'a )?([^ ]+) \{$/impl \5 {/ /^ *(unsafe )?fn .*\(self.*[<&]'a/ { s/&'a /\&/g s/<'a, /</g } /^ *(unsafe )?fn .*\(&?self[,)]/s/(unsafe )?fn/pub &/ /^ *pub (unsafe )?fn /s/\(self([,)])/\(\&self\1/ } The few error cases were then fixed by hand.
* make dom_struct derive HeapSizeOf,João Oliveira2015-08-271-1/+0
| | | | closes #7357
* sort all usesJohann Tuffe2015-08-201-1/+1
|
* Measure heap memory usage for more types. Fixes #6951Bogdan Cuza2015-08-131-0/+1
|
* Handle url parse errors in Location#assign more gracefully.Ms2ger2015-08-071-4/+3
|
* Push the url parsing out of Window::load_url.Ms2ger2015-08-071-2/+9
| | | | This will allow the two callers to decide on the base url independently.
* Implement URL and trivially missing URLUtils membersAnthony Ramine2015-06-201-3/+33
| | | | Fixes #6322.
* Upgrade to SM 39Michael Wu2015-06-191-6/+6
|
* Properly generate proxy stringifiersAnthony Ramine2015-04-291-1/+1
|
* Uniformise root() methodsAnthony Ramine2015-04-281-1/+1
| | | | | They now live in traits Rootable, OptionalOptionalRootable, OptionalRootable and ResultRootable.
* Add/update comments with links to specCorey Farwell2015-04-141-0/+5
| | | | | | | | | | Extracted out of #5649 * add more hyperlinks to associated specification for structs/methods * follow redirects and update links * replace broken links * removal of WHATWG multipage page name since the page name is not guaranteed to be stable
* Update some URLs.Ms2ger2015-04-141-1/+1
| | | | | The HTML spec's division into pages is not stable, so it is safer to use the URL without a specific page (which will redirect).