Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
F
Front-End
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
abdullh.alsoleman
Front-End
Commits
2873880f
Commit
2873880f
authored
Aug 22, 2015
by
Adam Barth
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix analyzer warnings
parent
89c11447
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
4 additions
and
24 deletions
+4
-24
main.dart
examples/fitness/lib/main.dart
+1
-1
settings.dart
examples/fitness/lib/settings.dart
+0
-8
document_child_mutations_test.dart
packages/unit/test/engine/document_child_mutations_test.dart
+3
-15
No files found.
examples/fitness/lib/main.dart
View file @
2873880f
...
...
@@ -124,7 +124,7 @@ class FitnessApp extends App {
name:
'/settings'
,
builder:
(
navigator
,
route
)
=>
new
SettingsFragment
(
navigator:
navigator
,
userData:
_userData
as
UserData
,
userData:
_userData
,
updater:
settingsUpdater
)
),
...
...
examples/fitness/lib/settings.dart
View file @
2873880f
...
...
@@ -28,14 +28,6 @@ class SettingsFragment extends StatefulComponent {
updater
(
backup:
value
?
BackupMode
.
enabled
:
BackupMode
.
disabled
);
}
void
_goalWeightChanged
(
double
value
)
{
assert
(
updater
!=
null
);
setState
(()
{
optimism
=
value
?
StockMode
.
optimistic
:
StockMode
.
pessimistic
;
});
sendUpdates
();
}
Widget
buildToolBar
()
{
return
new
ToolBar
(
left:
new
IconButton
(
...
...
packages/unit/test/engine/document_child_mutations_test.dart
View file @
2873880f
...
...
@@ -70,30 +70,18 @@ void main() {
test
(
"should throw when inserting multiple elements"
,
()
{
doc
.
appendChild
(
doc
.
createElement
(
"div"
));
var
oldChild
=
doc
.
appendChild
(
doc
.
createText
(
" text "
));
doc
.
appendChild
(
doc
.
createText
(
" text "
));
expect
(
childElementCount
(
doc
),
equals
(
1
));
var
newChild
=
doc
.
createElement
(
"div"
);
// expect(() {
// doc.replaceChild(newChild, 0);
// }, throws);
// expect(() {
// doc.insertBefore(newChild, oldChild);
// }, throws);
doc
.
createElement
(
"div"
);
});
test
(
"should throw when inserting multiple elements with a fragment"
,
()
{
var
oldChild
=
doc
.
appendChild
(
doc
.
createElement
(
"div"
));
doc
.
appendChild
(
doc
.
createElement
(
"div"
));
expect
(
childElementCount
(
doc
),
equals
(
1
));
var
fragment
=
doc
.
createDocumentFragment
();
fragment
.
appendChild
(
doc
.
createText
(
" text "
));
fragment
.
appendChild
(
doc
.
createElement
(
"div"
));
fragment
.
appendChild
(
doc
.
createElement
(
"div"
));
fragment
.
appendChild
(
doc
.
createText
(
" "
));
// expect(() {
// doc.replaceChild(fragment, 0);
// }, throws);
// expect(() {
// doc.insertBefore(fragment, oldChild);
// }, throws);
});
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment