Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
F
fluttertoast
Overview
Overview
Details
Activity
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
songyanzhi
fluttertoast
Commits
faabfc4d
Commit
faabfc4d
authored
Jul 08, 2020
by
Karthik Ponnam
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Static Fluttertoast patch
parent
d99334a4
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
27 additions
and
2 deletions
+27
-2
example/pubspec.lock
+1
-1
lib/fluttertoast.dart
+25
-0
pubspec.yaml
+1
-1
No files found.
example/pubspec.lock
View file @
faabfc4d
...
...
@@ -66,7 +66,7 @@ packages:
path: ".."
relative: true
source: path
version: "6.0.
0
"
version: "6.0.
1
"
matcher:
dependency: transitive
description:
...
...
lib/fluttertoast.dart
View file @
faabfc4d
...
...
@@ -6,6 +6,31 @@ enum Toast { LENGTH_SHORT, LENGTH_LONG }
enum
ToastGravity
{
TOP
,
BOTTOM
,
CENTER
,
TOP_LEFT
,
TOP_RIGHT
,
BOTTOM_LEFT
,
BOTTOM_RIGHT
,
CENTER_LEFT
,
CENTER_RIGHT
}
@Deprecated
(
"Will be removed in further release"
)
class
Fluttertoast
{
@Deprecated
(
"Will be removed in further release"
)
static
void
showToast
(
BuildContext
context
,
{
ToastGravity
gravity
=
ToastGravity
.
BOTTOM
,
String
msg
,
int
toastDuration
=
3
})
{
FlutterToast
flutterToast
=
FlutterToast
(
context
);
Widget
toast
=
Container
(
padding:
const
EdgeInsets
.
symmetric
(
horizontal:
24.0
,
vertical:
12.0
),
decoration:
BoxDecoration
(
borderRadius:
BorderRadius
.
circular
(
25.0
),
color:
Color
.
fromRGBO
(
61
,
61
,
61
,
.
7
),
),
child:
Text
(
msg
,
style:
TextStyle
(
color:
Colors
.
white
),
),
);
flutterToast
.
showToast
(
child:
toast
,
gravity:
gravity
,
toastDuration:
Duration
(
seconds:
toastDuration
),
);
}
}
class
FlutterToast
{
BuildContext
context
;
...
...
pubspec.yaml
View file @
faabfc4d
name
:
fluttertoast
description
:
Toast Library for Flutter, Easily create toast messages in single line of code
version
:
6.0.
0
version
:
6.0.
1
homepage
:
https://github.com/PonnamKarthik/FlutterToast
issue_tracker
:
https://github.com/ponnamkarthik/FlutterToast/issues
...
...
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