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
Jonny Borges
2021-07-24 16:50:01 -0300
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
4fa5f60866210350eae1ef414c879555521d3516
4fa5f608
1 parent
31cce1f0
update to 4.2.5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
125 additions
and
123 deletions
CHANGELOG.md
lib/get_instance/src/get_instance.dart
lib/get_navigation/src/root/get_cupertino_app.dart
lib/get_navigation/src/root/get_material_app.dart
pubspec.yaml
CHANGELOG.md
View file @
4fa5f60
##
[
4.2.4
]
-
Added anchorRoute and filterPages to
// anchorRoute: '/',
// filterPages:
##
[
4.2.5
]
-
Added anchorRoute and filterPages to GetRouterOutlet (@ahmednfwela)
-
Added scrollBehavior and scaffoldMessengerKey to GetMaterialapp(@ejabu and @alionour)
-
Fix error when child on MaterialApp is null (@ahmednfwela)
-
Fix Korean docs (@rws08)
-
Fix error with onClose called before routeTransition on Get.offNamed
## [4.2.4]
-
Fix Get.offAll removing GetxServices from memory
...
...
lib/get_instance/src/get_instance.dart
View file @
4fa5f60
...
...
@@ -240,7 +240,7 @@ class GetInstance {
}
for
(
final
element
in
keysToRemove
)
{
reload
(
key:
element
);
reload
(
key:
element
,
closeInstance:
false
);
//_routesKey.remove(element);
}
...
...
@@ -459,7 +459,11 @@ class GetInstance {
});
}
void
reload
<
S
>({
String
?
tag
,
String
?
key
,
bool
force
=
false
})
{
void
reload
<
S
>(
{
String
?
tag
,
String
?
key
,
bool
force
=
false
,
bool
closeInstance
=
true
})
{
final
newKey
=
key
??
_getKey
(
S
,
tag
);
final
builder
=
_getDependency
<
S
>(
tag:
tag
,
key:
newKey
);
...
...
@@ -479,7 +483,7 @@ class GetInstance {
return
;
}
if
(
i
is
GetLifeCycleBase
)
{
if
(
i
is
GetLifeCycleBase
&&
closeInstance
)
{
i
.
onDelete
();
Get
.
log
(
'"
$newKey
" onDelete() called'
);
}
...
...
lib/get_navigation/src/root/get_cupertino_app.dart
View file @
4fa5f60
...
...
@@ -196,122 +196,121 @@ class GetCupertinoApp extends StatelessWidget {
];
}
Widget
defaultBuilder
(
BuildContext
context
,
Widget
?
child
)
{
return
Directionality
(
textDirection:
textDirection
??
(
rtlLanguages
.
contains
(
Get
.
locale
?.
languageCode
)
?
TextDirection
.
rtl
:
TextDirection
.
ltr
),
child:
builder
==
null
?
(
child
??
Material
())
:
builder
!(
context
,
child
??
Material
()),
);
}
@override
Widget
build
(
BuildContext
context
)
=>
GetBuilder
<
GetMaterialController
>(
init:
Get
.
rootController
,
dispose:
(
d
)
{
onDispose
?.
call
();
},
initState:
(
i
)
{
Get
.
engine
!.
addPostFrameCallback
((
timeStamp
)
{
onReady
?.
call
();
});
if
(
locale
!=
null
)
Get
.
locale
=
locale
;
init:
Get
.
rootController
,
dispose:
(
d
)
{
onDispose
?.
call
();
},
initState:
(
i
)
{
Get
.
engine
!.
addPostFrameCallback
((
timeStamp
)
{
onReady
?.
call
();
});
if
(
locale
!=
null
)
Get
.
locale
=
locale
;
if
(
fallbackLocale
!=
null
)
Get
.
fallbackLocale
=
fallbackLocale
;
if
(
fallbackLocale
!=
null
)
Get
.
fallbackLocale
=
fallbackLocale
;
if
(
translations
!=
null
)
{
Get
.
addTranslations
(
translations
!.
keys
);
}
else
if
(
translationsKeys
!=
null
)
{
Get
.
addTranslations
(
translationsKeys
!);
}
if
(
translations
!=
null
)
{
Get
.
addTranslations
(
translations
!.
keys
);
}
else
if
(
translationsKeys
!=
null
)
{
Get
.
addTranslations
(
translationsKeys
!);
}
Get
.
customTransition
=
customTransition
;
Get
.
customTransition
=
customTransition
;
initialBinding
?.
dependencies
();
if
(
getPages
!=
null
)
{
Get
.
addPages
(
getPages
!);
}
initialBinding
?.
dependencies
();
if
(
getPages
!=
null
)
{
Get
.
addPages
(
getPages
!);
}
Get
.
smartManagement
=
smartManagement
;
onInit
?.
call
();
Get
.
smartManagement
=
smartManagement
;
onInit
?.
call
();
Get
.
config
(
enableLog:
enableLog
??
Get
.
isLogEnable
,
logWriterCallback:
logWriterCallback
,
defaultTransition:
defaultTransition
??
Get
.
defaultTransition
,
defaultOpaqueRoute:
opaqueRoute
??
Get
.
isOpaqueRouteDefault
,
defaultPopGesture:
popGesture
??
Get
.
isPopGestureEnable
,
defaultDurationTransition:
transitionDuration
??
Get
.
defaultTransitionDuration
,
);
},
builder:
(
_
)
=>
routerDelegate
!=
null
?
CupertinoApp
.
router
(
routerDelegate:
routerDelegate
!,
routeInformationParser:
routeInformationParser
!,
backButtonDispatcher:
backButtonDispatcher
,
routeInformationProvider:
routeInformationProvider
,
key:
_
.
unikey
,
theme:
theme
,
builder:
(
context
,
child
)
{
return
Directionality
(
textDirection:
textDirection
??
(
rtlLanguages
.
contains
(
Get
.
locale
?.
languageCode
)
?
TextDirection
.
rtl
:
TextDirection
.
ltr
),
child:
builder
==
null
?
child
!
:
builder
!(
context
,
child
),
);
},
title:
title
,
onGenerateTitle:
onGenerateTitle
,
color:
color
,
locale:
Get
.
locale
??
locale
,
localizationsDelegates:
localizationsDelegates
,
localeListResolutionCallback:
localeListResolutionCallback
,
localeResolutionCallback:
localeResolutionCallback
,
supportedLocales:
supportedLocales
,
showPerformanceOverlay:
showPerformanceOverlay
,
checkerboardRasterCacheImages:
checkerboardRasterCacheImages
,
checkerboardOffscreenLayers:
checkerboardOffscreenLayers
,
showSemanticsDebugger:
showSemanticsDebugger
,
debugShowCheckedModeBanner:
debugShowCheckedModeBanner
,
shortcuts:
shortcuts
,
)
:
CupertinoApp
(
key:
_
.
unikey
,
theme:
theme
,
navigatorKey:
(
navigatorKey
==
null
?
Get
.
key
:
Get
.
addKey
(
navigatorKey
!)),
home:
home
,
routes:
routes
??
const
<
String
,
WidgetBuilder
>{},
initialRoute:
initialRoute
,
onGenerateRoute:
(
getPages
!=
null
?
generator
:
onGenerateRoute
),
onGenerateInitialRoutes:
(
getPages
==
null
||
home
!=
null
)
?
onGenerateInitialRoutes
:
initialRoutesGenerate
,
onUnknownRoute:
onUnknownRoute
,
navigatorObservers:
(
navigatorObservers
==
null
?
<
NavigatorObserver
>[
GetObserver
(
routingCallback
,
Get
.
routing
)
]
:
<
NavigatorObserver
>[
GetObserver
(
routingCallback
,
Get
.
routing
)
]
..
addAll
(
navigatorObservers
!)),
builder:
(
context
,
child
)
{
return
Directionality
(
textDirection:
textDirection
??
(
rtlLanguages
.
contains
(
Get
.
locale
?.
languageCode
)
?
TextDirection
.
rtl
:
TextDirection
.
ltr
),
child:
builder
==
null
?
child
!
:
builder
!(
context
,
child
),
);
},
title:
title
,
onGenerateTitle:
onGenerateTitle
,
color:
color
,
locale:
Get
.
locale
??
locale
,
localizationsDelegates:
localizationsDelegates
,
localeListResolutionCallback:
localeListResolutionCallback
,
localeResolutionCallback:
localeResolutionCallback
,
supportedLocales:
supportedLocales
,
showPerformanceOverlay:
showPerformanceOverlay
,
checkerboardRasterCacheImages:
checkerboardRasterCacheImages
,
checkerboardOffscreenLayers:
checkerboardOffscreenLayers
,
showSemanticsDebugger:
showSemanticsDebugger
,
debugShowCheckedModeBanner:
debugShowCheckedModeBanner
,
shortcuts:
shortcuts
,
// actions: actions,
));
Get
.
config
(
enableLog:
enableLog
??
Get
.
isLogEnable
,
logWriterCallback:
logWriterCallback
,
defaultTransition:
defaultTransition
??
Get
.
defaultTransition
,
defaultOpaqueRoute:
opaqueRoute
??
Get
.
isOpaqueRouteDefault
,
defaultPopGesture:
popGesture
??
Get
.
isPopGestureEnable
,
defaultDurationTransition:
transitionDuration
??
Get
.
defaultTransitionDuration
,
);
},
builder:
(
_
)
=>
routerDelegate
!=
null
?
CupertinoApp
.
router
(
routerDelegate:
routerDelegate
!,
routeInformationParser:
routeInformationParser
!,
backButtonDispatcher:
backButtonDispatcher
,
routeInformationProvider:
routeInformationProvider
,
key:
_
.
unikey
,
theme:
theme
,
builder:
defaultBuilder
,
title:
title
,
onGenerateTitle:
onGenerateTitle
,
color:
color
,
locale:
Get
.
locale
??
locale
,
localizationsDelegates:
localizationsDelegates
,
localeListResolutionCallback:
localeListResolutionCallback
,
localeResolutionCallback:
localeResolutionCallback
,
supportedLocales:
supportedLocales
,
showPerformanceOverlay:
showPerformanceOverlay
,
checkerboardRasterCacheImages:
checkerboardRasterCacheImages
,
checkerboardOffscreenLayers:
checkerboardOffscreenLayers
,
showSemanticsDebugger:
showSemanticsDebugger
,
debugShowCheckedModeBanner:
debugShowCheckedModeBanner
,
shortcuts:
shortcuts
,
)
:
CupertinoApp
(
key:
_
.
unikey
,
theme:
theme
,
navigatorKey:
(
navigatorKey
==
null
?
Get
.
key
:
Get
.
addKey
(
navigatorKey
!)),
home:
home
,
routes:
routes
??
const
<
String
,
WidgetBuilder
>{},
initialRoute:
initialRoute
,
onGenerateRoute:
(
getPages
!=
null
?
generator
:
onGenerateRoute
),
onGenerateInitialRoutes:
(
getPages
==
null
||
home
!=
null
)
?
onGenerateInitialRoutes
:
initialRoutesGenerate
,
onUnknownRoute:
onUnknownRoute
,
navigatorObservers:
(
navigatorObservers
==
null
?
<
NavigatorObserver
>[
GetObserver
(
routingCallback
,
Get
.
routing
)
]
:
<
NavigatorObserver
>[
GetObserver
(
routingCallback
,
Get
.
routing
)
]
..
addAll
(
navigatorObservers
!)),
builder:
defaultBuilder
,
title:
title
,
onGenerateTitle:
onGenerateTitle
,
color:
color
,
locale:
Get
.
locale
??
locale
,
localizationsDelegates:
localizationsDelegates
,
localeListResolutionCallback:
localeListResolutionCallback
,
localeResolutionCallback:
localeResolutionCallback
,
supportedLocales:
supportedLocales
,
showPerformanceOverlay:
showPerformanceOverlay
,
checkerboardRasterCacheImages:
checkerboardRasterCacheImages
,
checkerboardOffscreenLayers:
checkerboardOffscreenLayers
,
showSemanticsDebugger:
showSemanticsDebugger
,
debugShowCheckedModeBanner:
debugShowCheckedModeBanner
,
shortcuts:
shortcuts
,
// actions: actions,
),
);
}
...
...
lib/get_navigation/src/root/get_material_app.dart
View file @
4fa5f60
...
...
@@ -220,8 +220,8 @@ class GetMaterialApp extends StatelessWidget {
?
TextDirection
.
rtl
:
TextDirection
.
ltr
),
child:
builder
==
null
?
(
child
??
SizedBox
.
shrink
())
:
builder
!(
context
,
child
),
?
(
child
??
Material
())
:
builder
!(
context
,
child
??
Material
()),
);
}
...
...
pubspec.yaml
View file @
4fa5f60
name
:
get
description
:
Open screens/snackbars/dialogs without context, manage states and inject dependencies easily with GetX.
version
:
4.2.
4
version
:
4.2.
5
homepage
:
https://github.com/jonataslaw/getx
environment
:
...
...
Please
register
or
login
to post a comment