mirror of
https://github.com/inventree/inventree-app.git
synced 2025-06-12 18:25:26 +00:00
Move the "edit" button to the app bar
This commit is contained in:
@ -11,6 +11,10 @@ abstract class RefreshableState<T extends StatefulWidget> extends State<T> {
|
||||
// Storage for context once "Build" is called
|
||||
BuildContext context;
|
||||
|
||||
List<Widget> getAppBarActions(BuildContext context) {
|
||||
return [];
|
||||
}
|
||||
|
||||
String getAppBarTitle(BuildContext context) { return "App Bar Title"; }
|
||||
|
||||
void initState() {
|
||||
@ -37,6 +41,7 @@ abstract class RefreshableState<T extends StatefulWidget> extends State<T> {
|
||||
AppBar getAppBar(BuildContext context) {
|
||||
return AppBar(
|
||||
title: Text(getAppBarTitle(context)),
|
||||
actions: getAppBarActions(context),
|
||||
);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user