├── app ├── .gitignore ├── src │ ├── main │ │ ├── res │ │ │ ├── values │ │ │ │ ├── dimens.xml │ │ │ │ ├── strings.xml │ │ │ │ ├── colors.xml │ │ │ │ └── styles.xml │ │ │ ├── mipmap-hdpi │ │ │ │ ├── ic_launcher.png │ │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-mdpi │ │ │ │ ├── ic_launcher.png │ │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xhdpi │ │ │ │ ├── ic_launcher.png │ │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxhdpi │ │ │ │ ├── ic_launcher.png │ │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxxhdpi │ │ │ │ ├── ic_launcher.png │ │ │ │ └── ic_launcher_round.png │ │ │ ├── menu │ │ │ │ └── menu_main.xml │ │ │ └── layout │ │ │ │ ├── view_list_no_selection_item.xml │ │ │ │ ├── view_list_item.xml │ │ │ │ ├── activity_main.xml │ │ │ │ └── content_main.xml │ │ ├── java │ │ │ └── gr │ │ │ │ └── escsoft │ │ │ │ └── michaelprimez │ │ │ │ └── searchablespinnerexamples │ │ │ │ ├── SearchableSpinnerApp.java │ │ │ │ ├── SimpleListAdapter.java │ │ │ │ ├── SimpleArrayListAdapter.java │ │ │ │ └── MainActivity.java │ │ └── AndroidManifest.xml │ ├── test │ │ └── java │ │ │ └── gr │ │ │ └── escsoft │ │ │ └── michaelprimez │ │ │ └── searchablespinnerexamples │ │ │ └── ExampleUnitTest.java │ └── androidTest │ │ └── java │ │ └── gr │ │ └── escsoft │ │ └── michaelprimez │ │ └── searchablespinnerexamples │ │ └── ExampleInstrumentedTest.java ├── proguard-rules.pro └── build.gradle ├── searchablespinner ├── .gitignore ├── src │ ├── main │ │ ├── java │ │ │ └── gr │ │ │ │ └── escsoft │ │ │ │ └── michaelprimez │ │ │ │ └── searchablespinner │ │ │ │ ├── interfaces │ │ │ │ ├── IStatusListener.java │ │ │ │ ├── ISpinnerSelectedView.java │ │ │ │ └── OnItemSelectedListener.java │ │ │ │ ├── tools │ │ │ │ ├── UITools.java │ │ │ │ └── EditCursorColor.java │ │ │ │ ├── SelectedView.java │ │ │ │ └── SearchableSpinner.java │ │ ├── res │ │ │ ├── values │ │ │ │ ├── strings.xml │ │ │ │ └── attrs.xml │ │ │ ├── drawable │ │ │ │ └── spinner_drawable.xml │ │ │ └── layout │ │ │ │ ├── view_list.xml │ │ │ │ └── view_searchable_spinner.xml │ │ └── AndroidManifest.xml │ ├── test │ │ └── java │ │ │ └── gr │ │ │ └── escsoft │ │ │ └── michaelprimez │ │ │ └── searchablespinner │ │ │ └── ExampleUnitTest.java │ └── androidTest │ │ └── java │ │ └── gr │ │ └── escsoft │ │ └── michaelprimez │ │ └── searchablespinner │ │ └── ExampleInstrumentedTest.java ├── proguard-rules.pro └── build.gradle ├── settings.gradle ├── searchablespinner.gif ├── .gitignore ├── gradle.properties ├── README.md ├── .idea └── markdown-navigator.xml └── LICENSE /app/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /searchablespinner/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /settings.gradle: -------------------------------------------------------------------------------- 1 | include ':app', ':searchablespinner' 2 | -------------------------------------------------------------------------------- /app/src/main/res/values/dimens.xml: -------------------------------------------------------------------------------- 1 | 2 | 16dp 3 | 4 | -------------------------------------------------------------------------------- /searchablespinner.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelprimez/searchablespinner/HEAD/searchablespinner.gif -------------------------------------------------------------------------------- /app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelprimez/searchablespinner/HEAD/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelprimez/searchablespinner/HEAD/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelprimez/searchablespinner/HEAD/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelprimez/searchablespinner/HEAD/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelprimez/searchablespinner/HEAD/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-hdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelprimez/searchablespinner/HEAD/app/src/main/res/mipmap-hdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-mdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelprimez/searchablespinner/HEAD/app/src/main/res/mipmap-mdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelprimez/searchablespinner/HEAD/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelprimez/searchablespinner/HEAD/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelprimez/searchablespinner/HEAD/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | *.iml 2 | .gradle 3 | /local.properties 4 | /.idea/workspace.xml 5 | /.idea/libraries 6 | .DS_Store 7 | /build 8 | /captures 9 | .externalNativeBuild 10 | -------------------------------------------------------------------------------- /app/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | SearchableSpinnerExamples 3 | Reset 4 | No Selection 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/values/colors.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | #3F51B5 4 | #303F9F 5 | #FF4081 6 | #BDBDBD 7 | 8 | -------------------------------------------------------------------------------- /searchablespinner/src/main/java/gr/escsoft/michaelprimez/searchablespinner/interfaces/IStatusListener.java: -------------------------------------------------------------------------------- 1 | package gr.escsoft.michaelprimez.searchablespinner.interfaces; 2 | 3 | /** 4 | * Created by michael on 3/19/17. 5 | */ 6 | 7 | public interface IStatusListener { 8 | void spinnerIsOpening(); 9 | void spinnerIsClosing(); 10 | } 11 | -------------------------------------------------------------------------------- /searchablespinner/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | SearchableSpinner 3 | Done Search 4 | Start search 5 | Search... 6 | No Items Found 7 | 8 | -------------------------------------------------------------------------------- /searchablespinner/src/main/java/gr/escsoft/michaelprimez/searchablespinner/interfaces/ISpinnerSelectedView.java: -------------------------------------------------------------------------------- 1 | package gr.escsoft.michaelprimez.searchablespinner.interfaces; 2 | 3 | import android.view.View; 4 | 5 | /** 6 | * Created by michael on 2/12/17. 7 | */ 8 | 9 | public interface ISpinnerSelectedView { 10 | View getNoSelectionView(); 11 | View getSelectedView(int position); 12 | } 13 | -------------------------------------------------------------------------------- /searchablespinner/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 5 | 6 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /searchablespinner/src/main/java/gr/escsoft/michaelprimez/searchablespinner/interfaces/OnItemSelectedListener.java: -------------------------------------------------------------------------------- 1 | package gr.escsoft.michaelprimez.searchablespinner.interfaces; 2 | 3 | import android.view.View; 4 | import android.widget.AdapterView; 5 | 6 | /** 7 | * Created by michael on 1/14/17. 8 | */ 9 | 10 | public interface OnItemSelectedListener { 11 | void onItemSelected(View view, int position, long id); 12 | void onNothingSelected(); 13 | } 14 | -------------------------------------------------------------------------------- /app/src/main/res/menu/menu_main.xml: -------------------------------------------------------------------------------- 1 | 5 | 10 | 11 | -------------------------------------------------------------------------------- /app/src/main/java/gr/escsoft/michaelprimez/searchablespinnerexamples/SearchableSpinnerApp.java: -------------------------------------------------------------------------------- 1 | package gr.escsoft.michaelprimez.searchablespinnerexamples; 2 | 3 | import android.app.Application; 4 | 5 | import com.facebook.stetho.Stetho; 6 | 7 | /** 8 | * Created by michael on 1/8/17. 9 | */ 10 | 11 | public class SearchableSpinnerApp extends Application { 12 | @Override 13 | public void onCreate() { 14 | super.onCreate(); 15 | Stetho.initializeWithDefaults(this); 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /searchablespinner/src/main/java/gr/escsoft/michaelprimez/searchablespinner/tools/UITools.java: -------------------------------------------------------------------------------- 1 | package gr.escsoft.michaelprimez.searchablespinner.tools; 2 | 3 | import android.content.Context; 4 | 5 | /** 6 | * Created by michael on 12/31/16. 7 | */ 8 | 9 | public class UITools { 10 | 11 | private UITools() { } 12 | 13 | public static int dpToPx(Context context, float dp) { 14 | final float scale = context.getResources().getDisplayMetrics().density; 15 | return Math.round(dp * scale); 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /app/src/test/java/gr/escsoft/michaelprimez/searchablespinnerexamples/ExampleUnitTest.java: -------------------------------------------------------------------------------- 1 | package gr.escsoft.michaelprimez.searchablespinnerexamples; 2 | 3 | import org.junit.Test; 4 | 5 | import static org.junit.Assert.*; 6 | 7 | /** 8 | * Example local unit test, which will execute on the development machine (host). 9 | * 10 | * @see Testing documentation 11 | */ 12 | public class ExampleUnitTest { 13 | @Test 14 | public void addition_isCorrect() throws Exception { 15 | assertEquals(4, 2 + 2); 16 | } 17 | } -------------------------------------------------------------------------------- /searchablespinner/src/test/java/gr/escsoft/michaelprimez/searchablespinner/ExampleUnitTest.java: -------------------------------------------------------------------------------- 1 | package gr.escsoft.michaelprimez.searchablespinner; 2 | 3 | import org.junit.Test; 4 | 5 | import static org.junit.Assert.*; 6 | 7 | /** 8 | * Example local unit test, which will execute on the development machine (host). 9 | * 10 | * @see Testing documentation 11 | */ 12 | public class ExampleUnitTest { 13 | @Test 14 | public void addition_isCorrect() throws Exception { 15 | assertEquals(4, 2 + 2); 16 | } 17 | } -------------------------------------------------------------------------------- /searchablespinner/src/main/res/drawable/spinner_drawable.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /gradle.properties: -------------------------------------------------------------------------------- 1 | # Project-wide Gradle settings. 2 | 3 | # IDE (e.g. Android Studio) users: 4 | # Gradle settings configured through the IDE *will override* 5 | # any settings specified in this file. 6 | 7 | # For more details on how to configure your build environment visit 8 | # http://www.gradle.org/docs/current/userguide/build_environment.html 9 | 10 | # Specifies the JVM arguments used for the daemon process. 11 | # The setting is particularly useful for tweaking memory settings. 12 | org.gradle.jvmargs=-Xmx1536m 13 | 14 | # When configured, Gradle will run in incubating parallel mode. 15 | # This option should only be used with decoupled projects. More details, visit 16 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects 17 | # org.gradle.parallel=true 18 | -------------------------------------------------------------------------------- /app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 10 | 11 | 15 | 16 |