(UNMAINTAINED) An implemention of Filter Menu concept for android

Related tags

Menu FilterMenu
Overview

FilterMenu

Maven Central

This is a library project with a custom view that implements concept of Filter Menu(https://dribbble.com/shots/1956586-Filter-Menu) made by Anton Aheichanka for android

Quick Overview

  • Download sample Apk

  • Screenshots

    screenshot
  • Youtube Video

    Youtube Video

Futures

  • Detect edge automatically
  • Support for android menu resource

Getting Started

  • Download the source to use it as library project, or grab via Maven
<dependency>
  <groupId>com.linroid.filtermenu</groupId>
  <artifactId>library</artifactId>
  <version>{last-version}</version>
  <type>aar</type>
</dependency>

or Gradle

compile 'com.linroid.filtermenu:library:0.2.+@aar'
  • Declare FilterMenuLayout inside your layout

    <com.linroid.filtermenu.library.FilterMenuLayout
        android:id="@+id/filter_menu"
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:elevation="8dp"
        custom:fm_expandedRadius="96dp"
        custom:fm_collapsedRadius="24dp"
        custom:fm_centerBottom="50dp"
        custom:fm_centerRight="50dp"
        custom:fm_primaryColor="#ff37aa4a"
        custom:fm_primaryDarkColor="#ff20622b">
    </com.linroid.filtermenu.library.FilterMenuLayout>
    
    
    <!--circle radius size when menu expanded-->
    custom:fm_expandedRadius
    <!--circle radius size when menu collapsed-->
    custom:fm_collapsedRadius
    <!--set the position of circle, the menu will auto align.
        You should only set two directions at most.-->
    custom:fm_center[Left|Top|Right|Bottom]
    <!-- If true, centers the circle horizontally.-->
    custom:fm_centerHorizontal
    <!-- If true, centers the circle vertically.-->
    custom:fm_centerVertical
    <!--primary color-->
    custom:fm_primaryColor
    <!--color of inner circle when menu expanded-->
    custom:fm_primaryDarkColor
  • Initial menu items via java code

    FilterMenuLayout layout = (FilterMenuLayout) findViewById(R.id.filter_menu);
    FilterMenu menu = new FilterMenu.Builder(this)
        .addItem(R.drawable....)
        //.inflate(R.menu....)//inflate  menu resource
        .attach(layout)
        .withListener(new FilterMenu.OnMenuChangeListener() {
            @Override
            public void onMenuItemClick(View view, int position) {
            }
            @Override
            public void onMenuCollapse() {
            }
            @Override
            public void onMenuExpand() {
            }
        })
        .build();

ChangeLog

  • 0.2.0
    • support for android menu resource
    • support for centerHorizontal and centerVertical attribute

License

Copyright 2015 linroid

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Comments
  • The aar on jcenter may has some problem.

    The aar on jcenter may has some problem.

    When i use the aar on jcenter, something was wrong. If i use the aar made by the master project, it can be OK. So i wonder the aar on jcenter may has some problem.

    opened by Ivolian 3
  • Crash

    Crash

    11-19 19:05:05.502 11148-11148/com.yoavst.mashov.debug E/Parcel: Class not found when unmarshalling:
                                                                     java.lang.ClassNotFoundException: Invalid name:
                                                                         at java.lang.Class.classForName(Native Method)
                                                                         at java.lang.Class.forName(Class.java:309)
                                                                         at java.lang.Class.forName(Class.java:273)
                                                                         at android.os.Parcel.readParcelableCreator(Parcel.java:2281)
                                                                         at android.os.Parcel.readParcelable(Parcel.java:2245)
                                                                         at android.view.AbsSavedState.<init>(AbsSavedState.java:57)
                                                                         at android.view.View$BaseSavedState.<init>(View.java:20270)
                                                                         at com.linroid.filtermenu.library.FilterMenuLayout$SavedState.<init>(FilterMenuLayout.java:853)
                                                                         at com.linroid.filtermenu.library.FilterMenuLayout$SavedState.<init>(FilterMenuLayout.java:830)
                                                                         at com.linroid.filtermenu.library.FilterMenuLayout$SavedState$1.createFromParcel(FilterMenuLayout.java:834)
                                                                         at com.linroid.filtermenu.library.FilterMenuLayout$SavedState$1.createFromParcel(FilterMenuLayout.java:832)
                                                                         at android.os.Parcel.readParcelable(Parcel.java:2252)
                                                                         at android.os.Parcel.readValue(Parcel.java:2152)
                                                                         at android.os.Parcel.readSparseArrayInternal(Parcel.java:2546)
                                                                         at android.os.Parcel.readSparseArray(Parcel.java:1874)
    
    opened by yoavst 2
  • Impossible to build

    Impossible to build

    \app\build\intermediates\exploded-aar\com.android.support\appcompat-v7\21.0.3\res\values\values.xml Error:(2) Attribute "primaryColor" has already been defined Error:Execution failed for task ':app:processDebugResources'.

    com.android.ide.common.process.ProcessException: org.gradle.process.internal.ExecException: Process 'command 'C:\Program Files (x86)\Android\android-sdk\build-tools\21.1.2\aapt.exe'' finished with non-zero exit value 1

    It seems that you do not have to use attribut name primaryColor in attrs.xml

    opened by sguiheux 2
  • 在小米2中会闪退

    在小米2中会闪退

    系统版本 MIUI 5,基于Android 4.4.4

    java.lang.RuntimeException: Unable to start activity ComponentInfo{org.bitnp.netcheckin2/org.bitnp.netcheckin2.ui.MainActivity}: android.os.BadParcelableException: ClassNotFoundException when unmarshalling: at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2207) at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2256) at android.app.ActivityThread.access$800(ActivityThread.java:147) at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1209) at android.os.Handler.dispatchMessage(Handler.java:102) at android.os.Looper.loop(Looper.java:136) at android.app.ActivityThread.main(ActivityThread.java:5133) at java.lang.reflect.Method.invokeNative(Native Method) at java.lang.reflect.Method.invoke(Method.java:515) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:808) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:624) at dalvik.system.NativeStart.main(Native Method) Caused by: android.os.BadParcelableException: ClassNotFoundException when unmarshalling: at android.os.Parcel.readParcelableCreator(Parcel.java:2154) at android.os.Parcel.readParcelable(Parcel.java:2104) at android.view.AbsSavedState.(AbsSavedState.java:57) at android.view.View$BaseSavedState.(View.java:18684) at com.linroid.filtermenu.library.FilterMenuLayout$SavedState.(FilterMenuLayout.java:841) at com.linroid.filtermenu.library.FilterMenuLayout$SavedState.(FilterMenuLayout.java:812) at com.linroid.filtermenu.library.FilterMenuLayout$SavedState$1.createFromParcel(FilterMenuLayout.java:852) at com.linroid.filtermenu.library.FilterMenuLayout$SavedState$1.createFromParcel(FilterMenuLayout.java:850) at android.os.Parcel.readParcelable(Parcel.java:2111) at android.os.Parcel.readValue(Parcel.java:2020) at android.os.Parcel.readSparseArrayInternal(Parcel.java:2382) at android.os.Parcel.readSparseArray(Parcel.java:1742) at android.os.Parcel.readValue(Parcel.java:2077) at android.os.Parcel.readArrayMapInternal(Parcel.java:2321) at android.os.Bundle.unparcel(Bundle.java:249) at android.os.Bundle.getSparseParcelableArray(Bundle.java:1273) at com.android.internal.policy.impl.PhoneWindow.restoreHierarchyState(PhoneWindow.java:1748) at android.app.Activity.onRestoreInstanceState(Activity.java:970) at android.app.Activity.performRestoreInstanceState(Activity.java:942) at android.app.Instrumentation.callActivityOnRestoreInstanceState(Instrumentation.java:1138) at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2175) ... 11 more

    暂时只有在小米2和2A的旧系MIUI中发现了这个问题。

    opened by zhehuaz 1
  •  无法使用attr定义的样式,设置后造成FC。

    无法使用attr定义的样式,设置后造成FC。

    无法使用样式中定义的attr属性。设置后会造成FC。

        app:primaryColor="?attr/colorPrimary"
        app:primaryDarkColor="?attr/colorPrimaryDark"
    

    解决方案如下:修改FilterMenuLayout 的 init(ctx,attrs)第二行

        TypedArray ta = ctx.getResources().obtainAttributes(attrs, R.styleable.FilterMenuLayout);
    

        TypedArray ta = ctx.obtainStyledAttributes(attrs, R.styleable.FilterMenuLayout);
    
    opened by ywwxhz 1
  • How do I equally distribute 3 buttons across the FilterMenu ?

    How do I equally distribute 3 buttons across the FilterMenu ?

    Right now the 3 buttons I've put in using Java code and .addItem() have been thrown out randomly and misaligned, making the FilterMenu look very ugly. How can I adjust the buttons to be 90° from each other or 60° or something.

    opened by davidv171 0
  • adding 4 menu in layout in different directions

    adding 4 menu in layout in different directions

    By default when we add four menu in layout then they align in northeast (NE), southeast (SE), southwest (SW), and northwest (NW). but i want to rotate them by 45 Degrees i,e they should align in North, South, East, West something like this. jkwr5

    What changes should be done so that i can use this library.

    opened by navia-android-developer 0
Classic Power Menu is a Power Menu Replacement for Android 11+

Classic Power Menu is a Power Menu Replacement for Android 11+, with the main aim being restoring power menu options (Device Controls & Quick Access Wallet) on Android 12.

Kieron Quinn 385 Dec 31, 2022
🚀 A very customizable library that allows you to present menu items (from menu resource and/or other sources) to users as a bottom sheet.

SlidingUpMenu A library that allows you to present menu items (from menu resource and/or other sources) to users as a bottom sheet. Gradle Dependency

Rasheed Sulayman 26 Jul 17, 2022
DropDownMenu for Android,Filter the list based on multiple condition.

DropDownMenu DropDownMenu for Android,filter the list based on multiple condition. To get this project into your build Step 1. Add the specific reposi

Jay.Fang 808 Nov 10, 2022
Android-NewPopupMenu 3.9 0.0 Java is an android library to create popup menu with GoogleMusic app-like style.

Android-NewPopupMenu Android-NewPopupMenu is an android library to create popup menu with GoogleMusic app-like style. Requirements Tested with APIv4 H

u1aryz 159 Nov 21, 2022
an animated circular menu for Android

CircularFloatingActionMenu An animated, customizable circular floating menu for Android, inspired by Path app. Getting Started Requirements API >= 15

Oğuz Bilgener 2.7k Dec 24, 2022
A menu which can ... BOOM! - Android

BoomMenu 2.0.0 Comes Finally Approximately 8 months ago, I got an inspiration to creating something that can boom and show menu, which I named it Boom

Nightonke 5.8k Dec 27, 2022
Android Satellite Menu

#Satellite Menu 'Path' has a very attractive menu sitting on the left bottom corner of the screen. Satellite Menu is the open version of this menu. Fo

Siyamed SINIR 1.4k Nov 15, 2022
An android custom view which looks like the menu in Path 2.0 (for iOS).

ArcMenu & RayMenu ArcMenu An android custom view which looks like the menu in Path 2.0 (for iOS). RayMenu About The user experience in Path 2.0 (for i

daCapricorn 1.3k Nov 29, 2022
Navigation menu for Android (based off Google+ app)

RibbonMenu Navigation menu for Android (based on Google+ app). Usage Menus are created in xml as normal, adding text and an icon. In the layout you wa

David Scott 487 Nov 24, 2022
Simple and easy to use circular menu widget for Android.

Deprecated This project is no longer maintained. No new issues or pull requests will be accepted. You can still use the source or fork the project to

Anup Cowkur 420 Nov 25, 2022
A multicard menu that can open and close with animation on android

MultiCardMenu A multicard menu that can open and close with animation on android,require API level >= 11 Demo ##Usage <net.wujingchao.android.view.

null 562 Nov 10, 2022
Implementation of "Side Navigation" or "Fly-in app menu" pattern for Android (based on Google+ app)

Android SideNavigation Library Implementation of "Side Navigation" or "Fly-in app menu" pattern for Android (based on Google+ app). Description The Go

Evgeny Shishkin 319 Nov 25, 2022
An Android Library that allows users to pull down a menu and select different actions. It can be implemented inside ScrollView, GridView, ListView.

AndroidPullMenu AndroidPullMenu is an Open Source Android library that allows developers to easily create applications with pull menu. The aim of this

Armando TBA 181 Nov 29, 2022
Android Overlay Menu

Overlay Menu Android Overlay Menu Demo: Installation: Add this dependency to your gradle script: compile 'it.sephiroth.android.library.overlaymenu:ove

Alessandro Crugnola 122 Nov 10, 2022
A floating menu library for Android.

Hover Hover is a floating menu implementation for Android. Goals The goals of Hover are to: Provide an easy-to-use, out-of-the-box floating menu imple

Google 2.7k Dec 27, 2022
A powerful & customizable menu implementation for android.

A powerful & customizable menu implementation for android. It supports any level of nested menu structures along with custom header and footer views, and much more. Follow the steps below to import the library to your project. You will also find some sample codes.

Nowrose Muhammad Ragib 5 Nov 8, 2022
Side menu with some categories to choose.

Side Menu Side menu with some categories to choose. Check this project on dribbble. Check this project on Behance. God bless Ukraine! Sample Sample &

Yalantis 5.2k Dec 23, 2022
You can easily add awesome animated context menu to your app.

ContextMenu You can easily add awesome animated context menu to your app. Check this project on dribbble Check this project on Behance Usage: For a wo

Yalantis 3.8k Dec 28, 2022