New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Mutation observer API #16190
Closed
+612
−452
Closed
Mutation observer API #16190
Changes from 1 commit
Commits
Show all changes
23 commits
Select commit
Hold shift + click to select a range
73f2c6e
Initial Files for MutationObserverAPI
srivassumit bee1340
add a vector of MutationObserver objects as a member of ScriptThread
srivassumit a5af9a2
Merge branch 'master' of https://github.com/servo/servo into Mutation…
srivassumit 4ec5d92
Merge branch 'master' of https://github.com/servo/servo into Mutation…
srivassumit 16c09d4
incomplete code for mutationobserver and mutationrecord
srivassumit e162f8a
fixed build errors, Constructor is pending
srivassumit b0af820
Resolving merge conflicts
krishnakarthick1993 8e6d4e9
added Mutation Observer Constructor
srivassumit 4797cc3
Merge branch 'MutationObserver-dev' of https://github.com/srivassumit…
srivassumit dd9ea19
Merge branch 'master' of https://github.com/servo/servo into Mutation…
srivassumit 4db8c26
changes for constructor
srivassumit 1a7e2d4
Merge branch 'master' of https://github.com/servo/servo into Mutation…
srivassumit ef51869
Update mutationrecord.rs
srivassumit 2d10eb7
Update script_thread.rs
srivassumit 3dd78ed
more changes as per review comments
srivassumit 0160982
fixed test test-tidy issues, accessed ScriptThread from mutationobserver
srivassumit eefb95b
Merge branch 'master' of https://github.com/servo/servo into Mutation…
srivassumit 2cce8c5
modifications for review comments
srivassumit 7115abd
Merge branch 'master' of https://github.com/servo/servo into Mutation…
srivassumit 2821def
changes as per review comments
srivassumit a82e79d
Merge branch 'master' of https://github.com/servo/servo into Mutatio…
srivassumit 3bd4438
removed unused imports and fixed review comments.
srivassumit c6739ef
removed unused import
srivassumit File filter...
Filter file types
Jump to…
Jump to file
Failed to load files.
Initial Files for MutationObserverAPI
- Loading branch information
commit 73f2c6ef125a4a972d085c2ded21dd8ee702cabd
| @@ -0,0 +1,8 @@ | ||
| use dom_struct::dom_struct; | ||
|
|
||
| #[dom_struct] | ||
| pub struct MutationObserver { | ||
| } | ||
|
|
||
| impl MutationObserver { | ||
| } |
| @@ -0,0 +1,8 @@ | ||
| use dom_struct::dom_struct; | ||
|
|
||
| #[dom_struct] | ||
| pub struct MutationRecord { | ||
| } | ||
|
|
||
| impl MutationRecord { | ||
| } |
| @@ -0,0 +1,20 @@ | ||
| [Pref="dom.mutation_observer.enabled", Constructor(MutationCallback callback)] | ||
| interface MutationObserver { | ||
| void observe(Node target, optional MutationObserverInit options); | ||
| void disconnect(); | ||
| sequence<MutationRecord> takeRecords(); | ||
|
||
| }; | ||
|
|
||
| callback MutationCallback = void (sequence<MutationRecord> mutations, MutationObserver observer); | ||
|
|
||
| dictionary MutationObserverInit { | ||
| boolean childList = false; | ||
| boolean attributes; | ||
| boolean characterData; | ||
| boolean subtree = false; | ||
| boolean attributeOldValue; | ||
| boolean characterDataOldValue; | ||
| sequence<DOMString> attributeFilter; | ||
| }; | ||
|
|
||
|
|
||
| @@ -0,0 +1,13 @@ | ||
| [Pref="dom.mutation_observer.enabled", Exposed=Window] | ||
| interface MutationRecord | ||
| { | ||
| readonly attribute DOMString type; | ||
| [SameObject] readonly attribute Node target; | ||
| [SameObject] readonly attribute NodeList addedNodes; | ||
| [SameObject] readonly attribute NodeList removedNodes; | ||
| readonly attribute Node? previousSibling; | ||
| readonly attribute Node? nextSibling; | ||
| readonly attribute DOMString? attributeName; | ||
| readonly attribute DOMString? attributeNamespace; | ||
| readonly attribute DOMString? oldValue; | ||
jdm
Member
|
||
| }; | ||
| @@ -0,0 +1,2 @@ | ||
| prefs: ["dom.mutation_observer.enabled:true"] | ||
|
|
ProTip!
Use n and p to navigate between commits in a pull request.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Let's comment out all of these methods in this file until we actually implement them.