All Projects → Leondev7 → flutter_fab_dialer

Leondev7 / flutter_fab_dialer

Licence: BSD-3-Clause license
Floating action button dialer

Programming Languages

dart
5743 projects
swift
15916 projects
kotlin
9241 projects
objective c
16641 projects - #2 most used programming language

Projects that are alternatives of or similar to flutter fab dialer

Fabsmenu
A simple library to use a menu of FloatingActionButtons from Design Support Library that follow Material Design Guidelines
Stars: ✭ 324 (+390.91%)
Mutual labels:  menu, floatingactionbutton, fab
Floatingtoolbar
A toolbar that morphs from a FloatingActionButton
Stars: ✭ 1,540 (+2233.33%)
Mutual labels:  floatingactionbutton, fab
Hover
🎈 The smartest floating button
Stars: ✭ 81 (+22.73%)
Mutual labels:  floatingactionbutton, fab
LavaFab
💧 Android floating action button menu with "lava" animation
Stars: ✭ 51 (-22.73%)
Mutual labels:  menu, fab
Fab
🛍️ A Floating Action Button for macOS. Inspired by Material Design, and written in Swift.
Stars: ✭ 24 (-63.64%)
Mutual labels:  floatingactionbutton, fab
Fabulousfilter
Android library to animate Floating Action Button to Bottom Sheet Dialog and vice-versa
Stars: ✭ 2,477 (+3653.03%)
Mutual labels:  floatingactionbutton, fab
Jjfloatingactionbutton
Floating Action Button for iOS
Stars: ✭ 243 (+268.18%)
Mutual labels:  floatingactionbutton, fab
Dragfloatingactionbutton
一个可以随处拖曳FloatingActionButton,边缘自动吸附,可设置按钮悬浮透明度,拖曳避免阻挡界面视图无法查看。
Stars: ✭ 258 (+290.91%)
Mutual labels:  menu, floatingactionbutton
Expandablemenu
Expandable Menu button
Stars: ✭ 47 (-28.79%)
Mutual labels:  menu, fab
Omfm
Another floating action button menu with expand/collapse behavior, in kotlin
Stars: ✭ 86 (+30.3%)
Mutual labels:  menu, floatingactionbutton
Springfabmenu
A menu of FloatingActionButton items, designed to be anchored on an AppBarLayout.
Stars: ✭ 116 (+75.76%)
Mutual labels:  menu, floatingactionbutton
Hhfloatingview
An easy to use and setup floating view for your app. 🎡
Stars: ✭ 93 (+40.91%)
Mutual labels:  menu, floatingactionbutton
Fab Circular Menu
A Flutter package to create a nice circular menu using a Floating Action Button.
Stars: ✭ 152 (+130.3%)
Mutual labels:  menu, floatingactionbutton
Timomenu
📋A pop-up menu for android that supports multi-row scrollable submenus.
Stars: ✭ 247 (+274.24%)
Mutual labels:  menu
JonContextMenu
A beautiful and minimalist arc menu like the Pinterest one, written in Swift
Stars: ✭ 60 (-9.09%)
Mutual labels:  menu
Kyarctab
Arcuated tab view controller with toggleing animation, 2 ~ 4 tabs are enabled. What's more, you can swipe left or right to toggle the views.
Stars: ✭ 246 (+272.73%)
Mutual labels:  menu
Dropdownmenukit
UIKit drop down menu, simple yet flexible and written in Swift
Stars: ✭ 246 (+272.73%)
Mutual labels:  menu
SliderMenu
A simple Menu inspired by SWRevealView Controller and Google Material Menu
Stars: ✭ 35 (-46.97%)
Mutual labels:  menu
xdg-xmenu
Generate menu for xmenu
Stars: ✭ 31 (-53.03%)
Mutual labels:  menu
Pygame Menu
Menu for pygame. Simple, lightweight and easy to use
Stars: ✭ 244 (+269.7%)
Mutual labels:  menu

Introduction

This is a Widget build for having an alternative to default menus

alt text

There are four types of fab menu items

With text and image associated

  FabMiniMenuItem.withTextWithImage(
          img,
          4.0,
          "Button menu",
          _logCounter,
          "Click me",
          Colors.blue,
          Colors.white,
          true
        ),

With only text associated

  FabMiniMenuItem.withText(
          new Icon(Icons.add),
          Colors.blue,
          4.0,
          "Button menu",
          _incrementCounter,
          "Click me",
          Colors.blue,
          Colors.white,
          true
        )

With no text and image associated

  FabMiniMenuItem.noTextWithImage(
          img,
          4.0,
          "Button menu",
          _incrementCounter,
          false
        )

With no text and no image associated

  FabMiniMenuItem.noText(
          new Icon(Icons.add),
          Colors.blue,
          4.0,
          "Button menu",
          _logCounter,
          false
        )

Usage

Create a list with your desired elements and customize each one

 var _fabMiniMenuItemList = [
      new FabMiniMenuItem.withTextWithImage(
        img,
        4.0,
        "Button menu",
        _logCounter,
        "Click me",
        Colors.blue,
        Colors.white,
        true
      ),

      new FabMiniMenuItem.withText(
        new Icon(Icons.add),
        Colors.blue,
        4.0,
        "Button menu",
        _incrementCounter,
        "Click me",
        Colors.blue,
        Colors.white,
        true
      ),
      new FabMiniMenuItem.noText(
        new Icon(Icons.add),
        Colors.blue,
        4.0,
        "Button menu",
        _logCounter,
        false
      ),

      new FabMiniMenuItem.noTextWithImage(
        img,
        4.0,
        "Button menu",
        _incrementCounter,
        false
      )
    ];

Add the Dialer to your UI

class _MyHomePageState extends State<MyHomePage> {

  //Provides an image of a cat
  static String getNewCatUrl() {
     return 'http://thecatapi.com/api/images/get?format=src&type=jpg&size=small'
         '#${new DateTime.now().millisecondsSinceEpoch}';
   }

   int _counter = 0;

  //Adds value to counter
   void _incrementCounter() {
     setState(() {
       _counter++;
     });
   }

   //Prints the value of the counter
   void _logCounter() {
     setState(() {
       print(_counter);
     });
   }

  @override
   Widget build(BuildContext context) {

     ImageProvider img = new NetworkImage(getNewCatUrl());

    //The list of FabMiniMenuItems that we are going to use
     var _fabMiniMenuItemList = [
       new FabMiniMenuItem.withTextWithImage(
         img,
         4.0,
         "Button menu",
         _logCounter,
         "Click me",
         Colors.blue,
         Colors.white,
         true
       ),

       new FabMiniMenuItem.withText(
         new Icon(Icons.add),
         Colors.blue,
         4.0,
         "Button menu",
         _incrementCounter,
         "Click me",
         Colors.blue,
         Colors.white,
         true
       ),
       new FabMiniMenuItem.noText(
         new Icon(Icons.add),
         Colors.blue,
         4.0,
         "Button menu",
         _logCounter,
         false
       ),

       new FabMiniMenuItem.noTextWithImage(
         img,
         4.0,
         "Button menu",
         _incrementCounter,
         false
       )
     ];

     return new Scaffold(
       appBar: new AppBar(
         title: new Text(widget.title),
       ),
       //Using a Stack will assure that the Dialer will appear at the end of your layout
       body:  new Stack(
         children: <Widget>[
           new Center(
             child: new Column(
               children: <Widget>[
                 new Text('You have pushed the button this many times:'),
                 new Text('$_counter', style: Theme.of(context).textTheme.display1),
               ],
             ),
           ),
           new FabDialer(_fabMiniMenuItemList, Colors.blue, new Icon(Icons.add)),
         ],
       ),
     );
   }
}
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].