Toggle navigation
Toggle navigation
This project
Loading...
Sign in
flutter_package
/
fluttertpc_get
Go to a project
Toggle navigation
Projects
Groups
Snippets
Help
Toggle navigation pinning
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Authored by
Jorge
2020-08-27 17:24:53 +0200
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
166655c61b939e9b4d9a87b48de7ba96276c9fd6
166655c6
1 parent
7d7dad66
fixed error
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
6 deletions
lib/src/core/log.dart
lib/src/navigation/routes/observers/route_observer.dart
lib/src/core/log.dart
View file @
166655c
import
'package:flutter/foundation.dart'
;
import
'package:get/instance_manager.dart'
;
import
'dart:developer'
as
developer
;
typedef
LogWriterCallback
=
void
Function
(
String
text
,
{
String
name
,
bool
isError
});
typedef
LogWriterCallback
=
void
Function
(
String
text
,
{
@required
String
name
,
bool
isError
});
void
defaultLogWriterCallback
(
String
value
,
{
String
name
,
bool
isError
=
false
})
{
void
defaultLogWriterCallback
(
String
value
,
{
@required
String
name
,
bool
isError
=
false
})
{
if
(
isError
||
GetConfig
.
isLogEnable
)
developer
.
log
(
value
,
name:
name
);
}
...
...
lib/src/navigation/routes/observers/route_observer.dart
View file @
166655c
...
...
@@ -72,13 +72,13 @@ class GetObserver extends NavigatorObserver {
String
routeName
=
name
(
route
);
if
(
isSnackbar
)
{
GetConfig
.
log
(
"
[GETX] OPEN SNACKBAR
$routeName
"
);
GetConfig
.
log
(
"
OPEN SNACKBAR
$routeName
"
,
name:
'[GETX]'
);
}
else
if
(
isBottomSheet
)
{
GetConfig
.
log
(
"
[GETX] OPEN
$routeName
"
);
GetConfig
.
log
(
"
OPEN
$routeName
"
,
name:
'[GETX]'
);
}
else
if
(
isDialog
)
{
GetConfig
.
log
(
"
[GETX] OPEN
$routeName
"
);
GetConfig
.
log
(
"
OPEN
$routeName
"
,
name:
'[GETX]'
);
}
else
if
(
isGetPageRoute
)
{
GetConfig
.
log
(
"
[GETX] GOING TO ROUTE
$routeName
"
);
GetConfig
.
log
(
"
GOING TO ROUTE
$routeName
"
,
name:
'[GETX]'
);
}
GetConfig
.
currentRoute
=
routeName
;
...
...
Please
register
or
login
to post a comment