Giter VIP home page Giter VIP logo

fluttercommunity / responsive_scaffold Goto Github PK

View Code? Open in Web Editor NEW
361.0 361.0 42.0 18.29 MB

Responsive Scaffold - On mobile it shows a list and pushes to details and on tablet it shows the List and the selected item. Maintainer: @rodydavis

Home Page: https://fluttercommunity.github.io/responsive_scaffold/

License: MIT License

Kotlin 0.60% Swift 1.69% Objective-C 0.06% Dart 79.62% Makefile 5.94% C++ 7.00% Batchfile 3.45% HTML 1.64%
flutter material material-design responsive scaffold

responsive_scaffold's Introduction

Flutter Community: responsive_scaffold

Buy Me A Coffee Donate pub package github pages

responsive_scaffold

View the online demo here!

On mobile it shows a list and pushes to details and on tablet it shows the List and the selected item.

Online Demo: https://fluttercommunity.github.io/responsive_scaffold/

Getting Started

3 Column Layout

example

Responsive Layout

Follows Material Design Layout Docs.

md-layout

Here is a demo on various sizes.

image image image image image image

Example

import 'package:flutter/material.dart';
import 'package:responsive_scaffold/responsive_scaffold.dart';

class LayoutExample extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return ResponsiveScaffold(
      title: Text('Responsive Layout Example'),
      drawer: ListView(
        children: <Widget>[
          ListTile(
            leading: Icon(Icons.settings),
            title: Text('Settings Page'),
          ),
          ListTile(
            leading: Icon(Icons.info),
            title: Text('Info Page'),
          ),
          ListTile(
            leading: Icon(Icons.library_books),
            title: Text('Library Page'),
          ),
          ListTile(
            leading: Icon(Icons.help),
            title: Text('Help Page'),
          ),
        ],
      ),
      endIcon: Icons.filter_list,
      endDrawer: ListView(
        children: <Widget>[
          ListTile(
            leading: Icon(Icons.filter_list),
            title: Text('Filter List'),
            subtitle: Text('Hide and show items'),
            trailing: Switch(
              value: true,
              onChanged: (val) {},
            ),
          ),
          ListTile(
            leading: Icon(Icons.image_aspect_ratio),
            title: Text('Size Settings'),
            subtitle: Text('Change size of images'),
          ),
          ListTile(
            title: Slider(
              value: 0.5,
              onChanged: (val) {},
            ),
          ),
          ListTile(
            leading: Icon(Icons.sort_by_alpha),
            title: Text('Sort List'),
            subtitle: Text('Change layout behavior'),
            trailing: Switch(
              value: false,
              onChanged: (val) {},
            ),
          ),
        ],
      ),
      trailing: IconButton(
        icon: Icon(Icons.search),
        onPressed: () {},
      ),
      body: Center(
        child: RaisedButton(
          child: Text('Close'),
          onPressed: () {
            Navigator.pop(context);
          },
        ),
      ),
      floatingActionButton: FloatingActionButton(
        child: Icon(Icons.add),
        backgroundColor: Theme.of(context).accentColor,
        onPressed: () {},
      ),
    );
  }
}

Responsive List

  • You can use this in two modes ResponsiveListScaffold and ResponsiveListScaffold.builder.
  • On Mobile the ListView will push to the details screen

tablet push mobile

  • On Tablet it will show a Master Detail View.
  • You can add additional Slivers to the Scrollview and the AppBar is optional.
Example
import 'package:flutter/material.dart';

import 'package:responsive_scaffold/responsive_scaffold.dart';

void main() => runApp(MyApp());

class MyApp extends StatefulWidget {
  @override
  _MyAppState createState() => _MyAppState();
}

class _MyAppState extends State<MyApp> {
  var _scaffoldKey = new GlobalKey<ScaffoldState>();

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: ResponsiveListScaffold.builder(
        scaffoldKey: _scaffoldKey,
        detailBuilder: (BuildContext context, int index, bool tablet) {
          return DetailsScreen(
            // appBar: AppBar(
            //   elevation: 0.0,
            //   title: Text("Details"),
            //   actions: [
            //     IconButton(
            //       icon: Icon(Icons.share),
            //       onPressed: () {},
            //     ),
            //     IconButton(
            //       icon: Icon(Icons.delete),
            //       onPressed: () {
            //         if (!tablet) Navigator.of(context).pop();
            //       },
            //     ),
            //   ],
            // ),
            body: Scaffold(
              appBar: AppBar(
                elevation: 0.0,
                title: Text("Details"),
                automaticallyImplyLeading: !tablet,
                actions: [
                  IconButton(
                    icon: Icon(Icons.share),
                    onPressed: () {},
                  ),
                  IconButton(
                    icon: Icon(Icons.delete),
                    onPressed: () {
                      if (!tablet) Navigator.of(context).pop();
                    },
                  ),
                ],
              ),
              bottomNavigationBar: BottomAppBar(
                elevation: 0.0,
                child: Container(
                  child: IconButton(
                    icon: Icon(Icons.share),
                    onPressed: () {},
                  ),
                ),
              ),
              body: Container(
                child: Center(
                  child: Text("Item: $index"),
                ),
              ),
            ),
          );
        },
        nullItems: Center(child: CircularProgressIndicator()),
        emptyItems: Center(child: Text("No Items Found")),
        slivers: <Widget>[
          SliverAppBar(
            title: Text("App Bar"),
          ),
        ],
        itemCount: 100,
        itemBuilder: (BuildContext context, int index) {
          return ListTile(
            leading: Text(index.toString()),
          );
        },
        bottomNavigationBar: BottomAppBar(
          elevation: 0.0,
          child: Container(
            child: IconButton(
              icon: Icon(Icons.share),
              onPressed: () {},
            ),
          ),
        ),
        floatingActionButton: FloatingActionButton(
          child: Icon(Icons.add),
          onPressed: () {
            _scaffoldKey.currentState.showSnackBar(SnackBar(
              content: Text("Snackbar!"),
            ));
          },
        ),
      ),
    );
  }
}

responsive_scaffold's People

Contributors

happy-tanuki avatar jeroen-meijer avatar maikub avatar rodydavis avatar thevzurd avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

responsive_scaffold's Issues

Generating error when implementing

Launching lib\main.dart on Android SDK built for x86 in debug mode...
lib\main.dart:1
/C:/src/flutter/.pub-cache/hosted/pub.dartlang.org/responsive_scaffold-1.3.0+2/lib/templates/list/responsive_list.dart:217:11: Error: No named parameter with the name 'resizeToAvoidBottomPadding'.
resizeToAvoidBottomPadding: resizeToAvoidBottomPadding,
^^^^^^^^^^^^^^^^^^^^^^^^^^
/C:/src/flutter/packages/flutter/lib/src/material/scaffold.dart:1451:9: Context: Found this candidate, but the arguments don't match.
const Scaffold({
^^^^^^^^
/C:/src/flutter/.pub-cache/hosted/pub.dartlang.org/responsive_scaffold-1.3.0+2/lib/templates/list/views/tablet.dart:188:15: Error: No named parameter with the name 'resizeToAvoidBottomPadding'.
resizeToAvoidBottomPadding: widget?.resizeToAvoidBottomPadding,
^^^^^^^^^^^^^^^^^^^^^^^^^^
/C:/src/flutter/packages/flutter/lib/src/material/scaffold.dart:1451:9: Context: Found this candidate, but the arguments don't match.
const Scaffold({
^^^^^^^^
2

FAILURE: Build failed with an exception.

  • Where:
    Script 'C:\src\flutter\packages\flutter_tools\gradle\flutter.gradle' line: 991

  • What went wrong:
    Execution failed for task ':app:compileFlutterBuildDebug'.

Process 'command 'C:\src\flutter\bin\flutter.bat'' finished with non-zero exit value 1

  • Try:
    Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

  • Get more help at https://help.gradle.org

Add initialScrollOffset

I have a long list that I want to display on mobile and tablet, but I need the list to start a certain position. Could you let us pass a scrollcontroller to let us set initialScrollOffset or pass the index of an item to have the List display that item at the top?

Add `ResponsiveScaffold` equivalent for non-drawer lists

Thank you for this library! It's exactly what I was looking for, and I was afraid I'd have to build a crappy version of it myself until I found this.

If I understand the documentation correctly it seems that ResponsiveScaffold solves simple use cases and requires low effort to integrate, while ResponsiveListScaffold.builder solves more use cases and requires high effort to integrate.

To find out that the former only supports drawers, not persistent lists was a surprise to me. I can integrate ResponsiveScaffold into my app easily (which is a fantastic experience!) without changing much code, but I want my "index of items" view to be a screen on phones, or a left-half / left-third part of screen on tablets (the same as the "Responsive List" in the demo). Instead it is a drawer on both.

To use the more complex ResponsiveListScaffold.builder to get the behavior I want requires complexity I'm not willing to shoot for right now, especially because I'm dealing with Iterators that would be hard to index into, so a heavy refactor would be called for.

Thanks!

How to navigate to other page without losing ListView in responsive_scaffold package?

Hi there!

I used responsive_scaffold package to display a list of items on left side screen and show a detail of item list on right side of the screen as in attached image.

My question is how to navigate to another page and only change the details page without losing list, because when used a Navigator.push () changes whole page and not just the right part of screen, which would be detail.
Captura de pantalla 2021-08-30 a las 8 22 08

How to add a ScrollController to detect if I scroll to bottom at list in ResponsiveListScaffold?

Hi there!

I am working on an application and I want to implement your packages, but I have a question about how to do it.

When I navigate to the page, I load 20 items from API first and then if scroll to bottom of the list, load next 20 items and add them to bottom of the list.

Now, I do it with ListView.builder () and ScrollController with a listener that when the listener detects that user scrolls to bottom of list view, it throws a method to load the following items, but in ResponsiveListScaffold it does not have a controller of displacement,
How can I make for what if I scroll to bottom of the list, lauch a method to load following items?

Thanks for all.

resizeToAvoidBottomPadding not supported (flutter2)

resizeToAvoidBottomPadding not recognised with latest build using flutter 2 stable release.
C:/flutter/.pub-cache/hosted/pub.dartlang.org/responsive_scaffold-1.3.0+2/lib/templates/list/responsive_list.dart:217:11: Error: No named parameter with the name 'resizeToAvoidBottomPadding'.

Changing some initial ResponsiveScaffold Properties

Hey, I am working with your responsive_scaffold and its a good solution make the app crossplattform compatible and more responsibe.

I am now on the point where the responsive_scaffold facing its limits.

Generally its adaptive to many cases.

But regarding to the appbar its a bit impractical. You can only overgive the title and actions to adjust this,
But what if i want use crossplatorm backbuttons and using the bottom functionality of the appbar for example for tab views? --> I need to build my appbar on my own.

i have some ideas regarding to the responsive scaffold:

  • So i think its more useful if title and trailing + appbar specific stuff will be removed.
  • floatingActionButtons are bound to the bottom of the scaffold body, but why not to the scaffolds floating action button properties?

In my opinion the responsive_scaffold is just a container which gives 100% controle over the scaffold but enables the power to makes the scaffold responsible regarding to the device(so what its doing atm).

What do you think about it? Correct me if I am wrong.

And I wonder why no more people use this package, bec responsiblitie is a main theme in flutter?!?!

Thank you for this package btw! Good work.

Best regards from germany,

Robin

image

Still active?

This is a really useful package! So, I'm asking myself if it is still in active development? There are lots of open issues and useful pull requests, The last closed pull request is from one and a half years ago! It would be a pity if the development did not continue. ๐Ÿ™๐Ÿผ

Unable to use ResponsiveScaffold when not the first screen

My first ResponsiveScaffold was for the Home Screen, so I did not notice this deficiency right away. However, my next ResponsiveScaffold was for a secondary screen, and now I can't go back to the home screen because there is no Back action because automaticallyImplyLeading is hard-coded to be false:

automaticallyImplyLeading: false,

๐Ÿค” Why is it hard coded to be false? (Why not just let it default to be true?)

Alternatively (and maybe better), can this setting please be controlled by Responsive Scaffold?

Errors in example on Linux run

I cannot run example under Linux (Linux Mint 19.3 Cinnamon - based on Ubuntu 18.04).
After flutter pub get and flutter run I get:

Launching lib/main.dart on Linux in debug mode...
Exception: No Linux desktop project configured. See https://flutter.dev/desktop#add-desktop-support-to-an-existing-app to learn about adding Linux support to a project.

After flutter create . and flutter run I get:

Launching lib/main.dart on Linux in debug mode...
ERROR: ../lib/templates/list/responsive_list.dart:217:11: Error: No named parameter with the name 'resizeToAvoidBottomPadding'.
ERROR:           resizeToAvoidBottomPadding: resizeToAvoidBottomPadding,
ERROR:           ^^^^^^^^^^^^^^^^^^^^^^^^^^                             
ERROR: ../../../../development/flutter/packages/flutter/lib/src/material/scaffold.dart:1451:9: Context: Found this candidate, but the arguments don't match.
ERROR:   const Scaffold({                                               
ERROR:         ^^^^^^^^                                                 
ERROR: ../lib/templates/list/views/tablet.dart:188:15: Error: No named parameter with the name 'resizeToAvoidBottomPadding'.
ERROR:               resizeToAvoidBottomPadding: widget?.resizeToAvoidBottomPadding,
ERROR:               ^^^^^^^^^^^^^^^^^^^^^^^^^^                         
ERROR: ../../../../development/flutter/packages/flutter/lib/src/material/scaffold.dart:1451:9: Context: Found this candidate, but the arguments don't match.
ERROR:   const Scaffold({                                               
ERROR:         ^^^^^^^^                                                 
Building Linux application...                                           
Exception: Build process failed

flutter doctor

[โœ“] Flutter (Channel dev, 1.26.0-17.2.pre, on Linux, locale pl_PL.UTF-8)
[โœ“] Android toolchain - develop for Android devices (Android SDK version 29.0.3)
[โœ“] Chrome - develop for the web
[โœ“] Linux toolchain - develop for Linux desktop
[โœ“] Android Studio
[โœ“] VS Code (version 1.53.0)
[โœ“] Connected device (2 available)

โ€ข No issues found!

Cheking if drawer is opened

when I put a Key to the ResponsiveScaffold, and check the state of the drawer by key.currentState.isDrawerOpen it always returns FALSE always, why is that and Is there any solution for this problem!

Drawer has unwanted padding on iPad

The drawer of the ResponsiveScaffold has some unwanted padding at the top and bottom end. Looks almost like some SafeArea stuff. I can't remove it to replicate the issue just use ResponsiveScaffold and make a drawer with some background color different than white. Here some example: https://imgur.com/a/QQ2cgRE

Error with 'drawerScrimColor'

stacktrace:

2019-06-01 07:59:17.358 29040-29081/com.example.path_manager I/flutter: โ•โ•โ•ก EXCEPTION CAUGHT BY WIDGETS LIBRARY โ•žโ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•
2019-06-01 07:59:17.375 29040-29081/com.example.path_manager I/flutter: The following _CompileTimeError was thrown building LayoutBuilder:
2019-06-01 07:59:17.375 29040-29081/com.example.path_manager I/flutter: 'package:responsive_scaffold/templates/3-column/three_column_navigation.dart': error:
2019-06-01 07:59:17.375 29040-29081/com.example.path_manager I/flutter: file:///C:/Users/magillus/AppData/Roaming/Pub/Cache/hosted/pub.dartlang.org/responsive_scaffold-1.1.0+3/lib/templates/3-column/three_column_navigation.dart:120:21:
2019-06-01 07:59:17.375 29040-29081/com.example.path_manager I/flutter: Error: No named parameter with the name 'drawerScrimColor'.
2019-06-01 07:59:17.375 29040-29081/com.example.path_manager I/flutter:                     drawerScrimColor: Colors.transparent,
2019-06-01 07:59:17.375 29040-29081/com.example.path_manager I/flutter:                     ^^^^^^^^^^^^^^^^
2019-06-01 07:59:17.377 29040-29081/com.example.path_manager I/flutter: When the exception was thrown, this was the stack:
2019-06-01 07:59:17.392 29040-29081/com.example.path_manager I/flutter: #0      _LayoutBuilderElement._layout.<anonymous closure> (package:flutter/src/widgets/layout_builder.dart:113:26)
2019-06-01 07:59:17.393 29040-29081/com.example.path_manager I/flutter: #1      BuildOwner.buildScope (package:flutter/src/widgets/framework.dart:2258:19)
2019-06-01 07:59:17.393 29040-29081/com.example.path_manager I/flutter: #2      _LayoutBuilderElement._layout (package:flutter/src/widgets/layout_builder.dart:109:11)
2019-06-01 07:59:17.393 29040-29081/com.example.path_manager I/flutter: #3      RenderObject.invokeLayoutCallback.<anonymous closure> (package:flutter/src/rendering/object.dart:1740:58)
2019-06-01 07:59:17.393 29040-29081/com.example.path_manager I/flutter: #4      PipelineOwner._enableMutationsToDirtySubtrees (package:flutter/src/rendering/object.dart:797:15)
2019-06-01 07:59:17.393 29040-29081/com.example.path_manager I/flutter: #5      RenderObject.invokeLayoutCallback (package:flutter/src/rendering/object.dart:1740:13)
2019-06-01 07:59:17.393 29040-29081/com.example.path_manager I/flutter: #6      _RenderLayoutBuilder.performLayout (package:flutter/src/widgets/layout_builder.dart:207:5)
2019-06-01 07:59:17.393 29040-29081/com.example.path_manager I/flutter: #7      RenderObject.layout (package:flutter/src/rendering/object.dart:1644:7)
2019-06-01 07:59:17.393 29040-29081/com.example.path_manager I/flutter: #8      _RenderProxyBox&RenderBox&RenderObjectWithChildMixin&RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:105:13)
2019-06-01 07:59:17.393 29040-29081/com.example.path_manager I/flutter: #9      RenderObject.layout (package:flutter/src/rendering/object.dart:1644:7)
2019-06-01 07:59:17.393 29040-29081/com.example.path_manager I/flutter: #10     _RenderProxyBox&RenderBox&RenderObjectWithChildMixin&RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:105:13)
2019-06-01 07:59:17.393 29040-29081/com.example.path_manager I/flutter: #11     RenderObject.layout (package:flutter/src/rendering/object.dart:1644:7)
2019-06-01 07:59:17.394 29040-29081/com.example.path_manager I/flutter: #12     _RenderProxyBox&RenderBox&RenderObjectWithChildMixin&RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:105:13)
2019-06-01 07:59:17.394 29040-29081/com.example.path_manager I/flutter: #13     RenderObject.layout (package:flutter/src/rendering/object.dart:1644:7)
2019-06-01 07:59:17.394 29040-29081/com.example.path_manager I/flutter: #14     _RenderProxyBox&RenderBox&RenderObjectWithChildMixin&RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:105:13)
2019-06-01 07:59:17.394 29040-29081/com.example.path_manager I/flutter: #15     RenderObject.layout (package:flutter/src/rendering/object.dart:1644:7)
2019-06-01 07:59:17.394 29040-29081/com.example.path_manager I/flutter: #16     _RenderProxyBox&RenderBox&RenderObjectWithChildMixin&RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:105:13)
2019-06-01 07:59:17.394 29040-29081/com.example.path_manager I/flutter: #17     RenderObject.layout (package:flutter/src/rendering/object.dart:1644:7)
2019-06-01 07:59:17.394 29040-29081/com.example.path_manager I/flutter: #18     _RenderProxyBox&RenderBox&RenderObjectWithChildMixin&RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:105:13)
2019-06-01 07:59:17.394 29040-29081/com.example.path_manager I/flutter: #19     RenderObject.layout (package:flutter/src/rendering/object.dart:1644:7)
2019-06-01 07:59:17.394 29040-29081/com.example.path_manager I/flutter: #20     _RenderProxyBox&RenderBox&RenderObjectWithChildMixin&RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:105:13)
2019-06-01 07:59:17.394 29040-29081/com.example.path_manager I/flutter: #21     RenderObject.layout (package:flutter/src/rendering/object.dart:1644:7)
2019-06-01 07:59:17.394 29040-29081/com.example.path_manager I/flutter: #22     RenderOffstage.performLayout (package:flutter/src/rendering/proxy_box.dart:3013:14)
2019-06-01 07:59:17.394 29040-29081/com.example.path_manager I/flutter: #23     RenderObject.layout (package:flutter/src/rendering/object.dart:1644:7)
2019-06-01 07:59:17.394 29040-29081/com.example.path_manager I/flutter: #24     RenderStack.performLayout (package:flutter/src/rendering/stack.dart:510:15)
2019-06-01 07:59:17.395 29040-29081/com.example.path_manager I/flutter: #25     RenderObject._layoutWithoutResize (package:flutter/src/rendering/object.dart:1519:7)
2019-06-01 07:59:17.395 29040-29081/com.example.path_manager I/flutter: #26     PipelineOwner.flushLayout (package:flutter/src/rendering/object.dart:766:18)
2019-06-01 07:59:17.397 29040-29081/com.example.path_manager I/flutter: #27     _WidgetsFlutterBinding&BindingBase&GestureBinding&ServicesBinding&SchedulerBinding&PaintingBinding&SemanticsBinding&RendererBinding.drawFrame (package:flutter/src/rendering/binding.dart:347:19)
2019-06-01 07:59:17.398 29040-29081/com.example.path_manager I/flutter: #28     _WidgetsFlutterBinding&BindingBase&GestureBinding&ServicesBinding&SchedulerBinding&PaintingBinding&SemanticsBinding&RendererBinding&WidgetsBinding.drawFrame (package:flutter/src/widgets/binding.dart:701:13)
2019-06-01 07:59:17.399 29040-29081/com.example.path_manager I/flutter: #29     _WidgetsFlutterBinding&BindingBase&GestureBinding&ServicesBinding&SchedulerBinding&PaintingBinding&SemanticsBinding&RendererBinding._handlePersistentFrameCallback (package:flutter/src/rendering/binding.dart:286:5)
2019-06-01 07:59:17.401 29040-29081/com.example.path_manager I/flutter: #30     _WidgetsFlutterBinding&BindingBase&GestureBinding&ServicesBinding&SchedulerBinding._invokeFrameCallback (package:flutter/src/scheduler/binding.dart:1012:15)
2019-06-01 07:59:17.402 29040-29081/com.example.path_manager I/flutter: #31     _WidgetsFlutterBinding&BindingBase&GestureBinding&ServicesBinding&SchedulerBinding.handleDrawFrame (package:flutter/src/scheduler/binding.dart:952:9)
2019-06-01 07:59:17.402 29040-29081/com.example.path_manager I/flutter: #32     _WidgetsFlutterBinding&BindingBase&GestureBinding&ServicesBinding&SchedulerBinding._handleDrawFrame (package:flutter/src/scheduler/binding.dart:864:5)
2019-06-01 07:59:17.402 29040-29081/com.example.path_manager I/flutter: #36     _invoke (dart:ui/hooks.dart:219:10)
2019-06-01 07:59:17.402 29040-29081/com.example.path_manager I/flutter: #37     _drawFrame (dart:ui/hooks.dart:178:3)
2019-06-01 07:59:17.403 29040-29081/com.example.path_manager I/flutter: (elided 3 frames from package dart:async)
2019-06-01 07:59:17.403 29040-29081/com.example.path_manager I/flutter: โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•

Flutter doctor output:

Doctor summary (to see all details, run flutter doctor -v):
[โˆš] Flutter (Channel beta, v1.5.4-hotfix.2, on Microsoft Windows [Version 10.0.17134.765], locale en-US)

[โˆš] Android toolchain - develop for Android devices (Android SDK version 28.0.3)
[โˆš] Android Studio (version 3.4)
[โˆš] IntelliJ IDEA Ultimate Edition (version 2018.1)
[โˆš] IntelliJ IDEA Ultimate Edition (version 2019.1)
[โˆš] VS Code (version 1.34.0)
[โˆš] VS Code, 32-bit edition (version 1.33.0)
[โˆš] Connected device (1 available)

โ€ข No issues found!

initState not called in the Widget used in DetailScreen

Hi,

I am using ResponsiveListScaffold.builder to show lists on the left and once the user selects a list item on the left I show the Video View on the right.

I am facing a problem right now with that the initState function. It is not being called once I select a different list item from the left.

Since we initialize the Video Player inside the initState, the detail screen keep playing the old video, however, the other content (Text Widgets etc) is changed since they are being used in the build function.

Is there any solution to manually call initState of the detail screen once user select the item from the itemBuilder

Thanks.

[feature-request] Add cutom appBar, bottomNavigationBar and floatingActionButtonLocation

n many cases, it's required not to have the FAB on top on desktops as well as having a fully customized app bar and a bottomNavigationBar. That's why I suggest the following changes:

final Widget appBar;
final ResponsiveFloatingActionButtonLocation floatingActionButtomLocation;
final Widget bottomNavigationBar;

/// somehow implement `drawerDocked` or if possible simply extend the existing FloatingActionButtonLocation enum
enum ResponsiveFloatingActionButtonLocation {
    drawerDocked,
    ...
}


/// within the build() method you could remove the appBarButton from the drawer if needed by
Widget build() {
    widget.appBar.leading = null;
    widget.automaticallyImplyLeading = false;
}

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.