forked from zulip/zulip-flutter
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
content: Implement inline video preview
Fixes: zulip#356
- Loading branch information
1 parent
3075f53
commit c729b5e
Showing
8 changed files
with
451 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
import 'package:flutter/widgets.dart'; | ||
|
||
/// An animation that is always considered complete and | ||
/// immediately notifies listeners. | ||
/// | ||
/// This is different from [kAlwaysCompleteAnimation] where | ||
/// it doesn't notify the listeners. | ||
class MockCompletedAnimation extends Animation<double> { | ||
const MockCompletedAnimation(); | ||
|
||
@override | ||
void addListener(VoidCallback listener) { | ||
listener(); | ||
} | ||
|
||
@override | ||
void removeListener(VoidCallback listener) { } | ||
|
||
@override | ||
void addStatusListener(AnimationStatusListener listener) { | ||
listener(AnimationStatus.completed); | ||
} | ||
|
||
@override | ||
void removeStatusListener(AnimationStatusListener listener) { } | ||
|
||
@override | ||
AnimationStatus get status => AnimationStatus.completed; | ||
|
||
@override | ||
double get value => 1.0; | ||
|
||
@override | ||
String toString() => 'MockCompletedAnimation'; | ||
} |
Oops, something went wrong.