From 2b043aaaaba80edce3e2797f24f468a231053a06 Mon Sep 17 00:00:00 2001 From: Albert Vaca Date: Sat, 29 Nov 2014 22:04:21 -0800 Subject: [PATCH] Reverted hack of including our own design for selectors Switched to the standard abc_list_selector_holo_dark, that has no problems in the current appcompat library. Using it from XML file instead of source. This reverts changes from 03ede77bd1543333fc5778f310dafe7a28908f05 --- ...atcompatselector_list_activated_holo.9.png | Bin 115 -> 0 bytes ...tkatcompatselector_list_focused_holo.9.png | Bin 139 -> 0 bytes ...compatselector_list_longpressed_holo.9.png | Bin 115 -> 0 bytes ...ompatselector_list_pressed_holo_dark.9.png | Bin 115 -> 0 bytes ...tor_list_selector_disabled_holo_dark.9.png | Bin 189 -> 0 bytes ...atcompatselector_list_activated_holo.9.png | Bin 110 -> 0 bytes ...tkatcompatselector_list_focused_holo.9.png | Bin 117 -> 0 bytes ...compatselector_list_longpressed_holo.9.png | Bin 110 -> 0 bytes ...ompatselector_list_pressed_holo_dark.9.png | Bin 110 -> 0 bytes ...tor_list_selector_disabled_holo_dark.9.png | Bin 172 -> 0 bytes ...atcompatselector_list_activated_holo.9.png | Bin 121 -> 0 bytes ...tkatcompatselector_list_focused_holo.9.png | Bin 154 -> 0 bytes ...compatselector_list_longpressed_holo.9.png | Bin 121 -> 0 bytes ...ompatselector_list_pressed_holo_dark.9.png | Bin 121 -> 0 bytes ...tor_list_selector_disabled_holo_dark.9.png | Bin 190 -> 0 bytes ...atcompatselector_list_activated_holo.9.png | Bin 133 -> 0 bytes ...tkatcompatselector_list_focused_holo.9.png | Bin 158 -> 0 bytes ...compatselector_list_longpressed_holo.9.png | Bin 133 -> 0 bytes ...ompatselector_list_pressed_holo_dark.9.png | Bin 133 -> 0 bytes ...tor_list_selector_disabled_holo_dark.9.png | Bin 273 -> 0 bytes ...elector_activated_background_holo_dark.xml | 20 ------------- ...mpatselector_item_background_holo_dark.xml | 26 ----------------- ...lector_background_transition_holo_dark.xml | 20 ------------- ...compatselector_list_selector_holo_dark.xml | 27 ------------------ res/layout/list_item_entry.xml | 4 ++- .../themes_kitkatcompatselector.xml | 14 --------- res/values/colors_kitkatcompatselector.xml | 4 --- res/values/styles_kitkatcompatselector.xml | 18 ------------ res/values/themes_kitkatcompatselector.xml | 16 ----------- .../UserInterface/List/DeviceItem.java | 4 --- .../UserInterface/List/SmallEntryItem.java | 3 +- 31 files changed, 4 insertions(+), 152 deletions(-) delete mode 100644 res/drawable-hdpi/kitkatcompatselector_list_activated_holo.9.png delete mode 100644 res/drawable-hdpi/kitkatcompatselector_list_focused_holo.9.png delete mode 100644 res/drawable-hdpi/kitkatcompatselector_list_longpressed_holo.9.png delete mode 100644 res/drawable-hdpi/kitkatcompatselector_list_pressed_holo_dark.9.png delete mode 100644 res/drawable-hdpi/kitkatcompatselector_list_selector_disabled_holo_dark.9.png delete mode 100644 res/drawable-mdpi/kitkatcompatselector_list_activated_holo.9.png delete mode 100644 res/drawable-mdpi/kitkatcompatselector_list_focused_holo.9.png delete mode 100644 res/drawable-mdpi/kitkatcompatselector_list_longpressed_holo.9.png delete mode 100644 res/drawable-mdpi/kitkatcompatselector_list_pressed_holo_dark.9.png delete mode 100644 res/drawable-mdpi/kitkatcompatselector_list_selector_disabled_holo_dark.9.png delete mode 100644 res/drawable-xhdpi/kitkatcompatselector_list_activated_holo.9.png delete mode 100644 res/drawable-xhdpi/kitkatcompatselector_list_focused_holo.9.png delete mode 100644 res/drawable-xhdpi/kitkatcompatselector_list_longpressed_holo.9.png delete mode 100644 res/drawable-xhdpi/kitkatcompatselector_list_pressed_holo_dark.9.png delete mode 100644 res/drawable-xhdpi/kitkatcompatselector_list_selector_disabled_holo_dark.9.png delete mode 100644 res/drawable-xxhdpi/kitkatcompatselector_list_activated_holo.9.png delete mode 100644 res/drawable-xxhdpi/kitkatcompatselector_list_focused_holo.9.png delete mode 100644 res/drawable-xxhdpi/kitkatcompatselector_list_longpressed_holo.9.png delete mode 100644 res/drawable-xxhdpi/kitkatcompatselector_list_pressed_holo_dark.9.png delete mode 100644 res/drawable-xxhdpi/kitkatcompatselector_list_selector_disabled_holo_dark.9.png delete mode 100644 res/drawable/kitkatcompatselector_activated_background_holo_dark.xml delete mode 100644 res/drawable/kitkatcompatselector_item_background_holo_dark.xml delete mode 100644 res/drawable/kitkatcompatselector_list_selector_background_transition_holo_dark.xml delete mode 100644 res/drawable/kitkatcompatselector_list_selector_holo_dark.xml delete mode 100644 res/values-v11/themes_kitkatcompatselector.xml delete mode 100644 res/values/colors_kitkatcompatselector.xml delete mode 100644 res/values/styles_kitkatcompatselector.xml delete mode 100644 res/values/themes_kitkatcompatselector.xml diff --git a/res/drawable-hdpi/kitkatcompatselector_list_activated_holo.9.png b/res/drawable-hdpi/kitkatcompatselector_list_activated_holo.9.png deleted file mode 100644 index d0344937394999439de30e92958243306aa27a0d..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 115 zcmeAS@N?(olHy`uVBq!ia0vp^+#t-s1|(OmDOUqhR-P`7Are!QQx35FpLnB(=Y`DU zwf^UmF19e8tMZmM6bx$N@d*1fe}Pt!ubQW!vSX-8Iolb|BP|@t3~XlX!qwj$L8dTx My85}Sb4q9e0LJ4W`Tzg` diff --git a/res/drawable-hdpi/kitkatcompatselector_list_focused_holo.9.png b/res/drawable-hdpi/kitkatcompatselector_list_focused_holo.9.png deleted file mode 100644 index 8c03ae50e2a0c0103521b101fe80fc77d7741471..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 139 zcmeAS@N?(olHy`uVBq!ia0vp^+#t-s1|(OmDOUqhL7py-Are!QQx35FpLnB(=Y`DU zwf^Zz7h9OlRe3Kr6bx$N@d*1P@0+8|%zQXa!}r3I`V5n}qdq&HL`WzoHpxici{Lqs mY2@cHDJg9s(?cuyC{kcif|*A4j^95`Gq9-KV8B6o6ra`I!Z80pW;7d5zZGhRBg zm{FnhT6Xzih3ZMUGkfBc^kAT_eS7{3zPQ8d#DAmxW005+5P610vf>J>FVdQ I&MBb@0LY~up8x;= diff --git a/res/drawable-mdpi/kitkatcompatselector_list_focused_holo.9.png b/res/drawable-mdpi/kitkatcompatselector_list_focused_holo.9.png deleted file mode 100644 index 19a95d23e2ef7855890f396581df2052416a693c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 117 zcmeAS@N?(olHy`uVBq!ia0vp^93afW1|*O0@9PFqHl8kyAre!Q6C7CoFO=Yukd%;+ z=-F;J_hbX>oUhaTk`Jjh^31rw-&>A>wStRlgLzsY P&>RL&S3j3^P6mdK II;Vst0Q=S;oB#j- diff --git a/res/drawable-mdpi/kitkatcompatselector_list_selector_disabled_holo_dark.9.png b/res/drawable-mdpi/kitkatcompatselector_list_selector_disabled_holo_dark.9.png deleted file mode 100644 index 92da2f0dd3711a2ceb843768cafd6b91a2807b43..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 172 zcmeAS@N?(olHy`uVBq!ia0vp^{6MVD!3HFkzrK_Oq*#ibJVQ8upoSx*1IXtr@Q5sC zVBqcqVMg#;uvX%d>fBtxy+SfFGJhTv9Z9>9n%%Tr7{oI+Q@DMao9hQt@O?p#8;eZd15IY| MboFyt=akR{068-?^#A|> diff --git a/res/drawable-xhdpi/kitkatcompatselector_list_activated_holo.9.png b/res/drawable-xhdpi/kitkatcompatselector_list_activated_holo.9.png deleted file mode 100644 index f5d6a5db5a2c52b9b35f1ccec92cd6994bd6a472..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 121 zcmeAS@N?(olHy`uVBq!ia0vp^d?3uh1|;P@bT0xa2TvEr5RHk+DF^ueE&eEZQPjZ5 zz`#HvzqU%OoiXBIWPYZyT9AoCbK}JhIe{(PC;pQ%RGR+G>{7V$nffKiRFxSfFJ_nA Tw{i6>pjix_u6{1-oD!MBG^KY{1F+O=c#7B^T-g;;i& z7zqX)KE%-J{iWi_2jPuoLM&gdb9nE0(K%~@9mCl-JhP{kd~yX^#^CAd=d#Wzp$PyY CJ2Q*` diff --git a/res/drawable-xhdpi/kitkatcompatselector_list_longpressed_holo.9.png b/res/drawable-xhdpi/kitkatcompatselector_list_longpressed_holo.9.png deleted file mode 100644 index b9652ca1b328f61c7ee85a4987060114d9c829b0..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 121 zcmeAS@N?(olHy`uVBq!ia0vp^d?3uh1|;P@bT0xa2TvEr5RHk+DF^ueE&eEZQPjZ5 zz`&s9$A^W2?TitP4Gj*m!kSVO4j#yG;pez@+oQf$Vxo7k^vl(P&+LO9PZDI<`k7sF TU0Rm`&@2W|S3j3^P6FVdQ&MBb@07kVeegFUf diff --git a/res/drawable-xxhdpi/kitkatcompatselector_list_focused_holo.9.png b/res/drawable-xxhdpi/kitkatcompatselector_list_focused_holo.9.png deleted file mode 100644 index 2ac927b696d94bca2955b0fabccb0116ab768661..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 158 zcmeAS@N?(olHy`uVBq!ia0vp^A|TAc1|)ksWqE;As;7%%h(&L5$^rg=j|I|?ENz_F z*w}cm;`Qa3EIevlbG}aVOJ3CGcp~A7!zo5?W|hn{hZOgVw(l^vW9DqEk6PwG#i z$7GL%tCs5UO!(8It^c^kchwEMEQMO07SX3Wx~e9fWoB3z&$U)_#};Xzg$$mqelF{r G5}E**PdK0e diff --git a/res/drawable-xxhdpi/kitkatcompatselector_list_longpressed_holo.9.png b/res/drawable-xxhdpi/kitkatcompatselector_list_longpressed_holo.9.png deleted file mode 100644 index 5c750bb8c3e40ddb9e3ef878a926137191c8036c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 133 zcmeAS@N?(olHy`uVBq!ia0vp^A|TAc1|)ksWqE;=kEe@ch(&L5$^rg=j|I|?ENz_F z*x2~+a65l53y&HX2M5O$!@$D|DF#^zr94Nbnw&73uqxq-!z+mn_v f!4s@)Z_LDSK9*h8yl7)H&|C&jS3j3^P6zS4 diff --git a/res/drawable-xxhdpi/kitkatcompatselector_list_pressed_holo_dark.9.png b/res/drawable-xxhdpi/kitkatcompatselector_list_pressed_holo_dark.9.png deleted file mode 100644 index 8cdca02ea52e0be01f1fbdbba74c334578fc464f..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 133 zcmeAS@N?(olHy`uVBq!ia0vp^A|TAc1|)ksWqE;=kEe@ch(&L5$^rg=j|I|?ENz_F z*x2~+%uHiG79KUO88c?QNnh0Fcp~A7!z+mn?aT?e3ZVyAG+r?jNOx1e?y#yUkXe&` ggT%71x-=Gsd0W|4zu2*^2Aa#@>FVdQ&MBb@00jsuBLDyZ diff --git a/res/drawable-xxhdpi/kitkatcompatselector_list_selector_disabled_holo_dark.9.png b/res/drawable-xxhdpi/kitkatcompatselector_list_selector_disabled_holo_dark.9.png deleted file mode 100644 index 908f76b4a3906f9c37dcf74dea201a5e77b8a949..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 273 zcmeAS@N?(olHy`uVBq!ia0vp^x!3HElju`U;DYhhUcNd2LAh=-f^2tCE&H|6f zVg?3oVGw3ym^DWND9B#o>FdgVmzz~g#yWQ`|4E?GJWm(LkcwMxZy9nm81S%OkpK9g z>G`x>H?BIa2>A7H5|82@#pFpFGnJ=Z3-13jdD;`NP4zS0|J|8-$ibOduz%t0o)<-O m7l;Sk3x2=<;?sY>l=wIL diff --git a/res/drawable/kitkatcompatselector_activated_background_holo_dark.xml b/res/drawable/kitkatcompatselector_activated_background_holo_dark.xml deleted file mode 100644 index 747de57e..00000000 --- a/res/drawable/kitkatcompatselector_activated_background_holo_dark.xml +++ /dev/null @@ -1,20 +0,0 @@ - - - - - - - diff --git a/res/drawable/kitkatcompatselector_item_background_holo_dark.xml b/res/drawable/kitkatcompatselector_item_background_holo_dark.xml deleted file mode 100644 index 75eec01c..00000000 --- a/res/drawable/kitkatcompatselector_item_background_holo_dark.xml +++ /dev/null @@ -1,26 +0,0 @@ - - - - - - - - - - - - - diff --git a/res/drawable/kitkatcompatselector_list_selector_background_transition_holo_dark.xml b/res/drawable/kitkatcompatselector_list_selector_background_transition_holo_dark.xml deleted file mode 100644 index 1ac8306a..00000000 --- a/res/drawable/kitkatcompatselector_list_selector_background_transition_holo_dark.xml +++ /dev/null @@ -1,20 +0,0 @@ - - - - - - - diff --git a/res/drawable/kitkatcompatselector_list_selector_holo_dark.xml b/res/drawable/kitkatcompatselector_list_selector_holo_dark.xml deleted file mode 100644 index 13c4f776..00000000 --- a/res/drawable/kitkatcompatselector_list_selector_holo_dark.xml +++ /dev/null @@ -1,27 +0,0 @@ - - - - - - - - - - - - - - diff --git a/res/layout/list_item_entry.xml b/res/layout/list_item_entry.xml index c43d6956..c772d8f5 100644 --- a/res/layout/list_item_entry.xml +++ b/res/layout/list_item_entry.xml @@ -8,8 +8,10 @@ android:minHeight="?android:attr/listPreferredItemHeight" android:gravity="center_vertical" android:paddingRight="?android:attr/scrollbarSize" + android:background="@drawable/abc_list_selector_holo_dark" android:orientation="vertical"> - + - - - - - - - \ No newline at end of file diff --git a/res/values/colors_kitkatcompatselector.xml b/res/values/colors_kitkatcompatselector.xml deleted file mode 100644 index 950493b0..00000000 --- a/res/values/colors_kitkatcompatselector.xml +++ /dev/null @@ -1,4 +0,0 @@ - - - #33b5e5 - diff --git a/res/values/styles_kitkatcompatselector.xml b/res/values/styles_kitkatcompatselector.xml deleted file mode 100644 index dde24620..00000000 --- a/res/values/styles_kitkatcompatselector.xml +++ /dev/null @@ -1,18 +0,0 @@ - - - - - - - - - - - - \ No newline at end of file diff --git a/res/values/themes_kitkatcompatselector.xml b/res/values/themes_kitkatcompatselector.xml deleted file mode 100644 index af0599d2..00000000 --- a/res/values/themes_kitkatcompatselector.xml +++ /dev/null @@ -1,16 +0,0 @@ - - - - - - - - \ No newline at end of file diff --git a/src/org/kde/kdeconnect/UserInterface/List/DeviceItem.java b/src/org/kde/kdeconnect/UserInterface/List/DeviceItem.java index 22c71401..247254b2 100644 --- a/src/org/kde/kdeconnect/UserInterface/List/DeviceItem.java +++ b/src/org/kde/kdeconnect/UserInterface/List/DeviceItem.java @@ -24,7 +24,6 @@ package org.kde.kdeconnect.UserInterface.List; import android.app.Activity; import android.content.Intent; import android.view.LayoutInflater; -import android.view.MotionEvent; import android.view.View; import android.widget.TextView; @@ -47,9 +46,6 @@ public class DeviceItem implements ListAdapter.Item { public View inflateView(LayoutInflater layoutInflater) { final View v = layoutInflater.inflate(R.layout.list_item_entry, null); - //Highlight when selected effect - v.setBackgroundDrawable(layoutInflater.getContext().getResources().getDrawable(R.drawable.kitkatcompatselector_list_selector_holo_dark)); - TextView titleView = (TextView)v.findViewById(R.id.list_item_entry_title); if (titleView != null) titleView.setText(device.getName()); if (device.compareProtocolVersion() != 0) { diff --git a/src/org/kde/kdeconnect/UserInterface/List/SmallEntryItem.java b/src/org/kde/kdeconnect/UserInterface/List/SmallEntryItem.java index f00b9d34..8672d73e 100644 --- a/src/org/kde/kdeconnect/UserInterface/List/SmallEntryItem.java +++ b/src/org/kde/kdeconnect/UserInterface/List/SmallEntryItem.java @@ -50,8 +50,7 @@ public class SmallEntryItem implements ListAdapter.Item { if (titleView != null) titleView.setText(title); if (clickListener != null) { titleView.setOnClickListener(clickListener); - v.setBackgroundDrawable(layoutInflater.getContext().getResources().getDrawable(R.drawable.kitkatcompatselector_list_selector_holo_dark)); - + v.setBackgroundDrawable(layoutInflater.getContext().getResources().getDrawable(R.drawable.abc_list_selector_holo_dark)); } return v;