Skip to content

Debloat any Android or Google TV over Wi-Fi and get an Apple TV-style home.

Launcher: OK on the App library pill ends reorder mode and opens the library (#1044)

Uneasha94115f9f7c5
diff --git a/launcher/app/src/main/java/com/gathin/tvhome/MainActivity.java b/launcher/app/src/main/java/com/gathin/tvhome/MainActivity.java
index 5be43c946..d28c11934 100644
--- a/launcher/app/src/main/java/com/gathin/tvhome/MainActivity.java
+++ b/launcher/app/src/main/java/com/gathin/tvhome/MainActivity.java
@@ -1149,6 +1149,15 @@ public class MainActivity extends Activity implements AppAdapter.TileListener {
return true;
}
int pos = focusedTilePosition();
+ View focus = getCurrentFocus();
+ if (ok && focus != null && focus.getId() == R.id.btnLibrary) {
+ // The App library pill sits in the grid but is no tile: OK ends the mode (saving the order) and opens it.
+ if (!down) {
+ endReorder();
+ onLibraryRequested();
+ }
+ return true;
+ }
if (ok && grid.hasFocus()) {
// RecyclerView can briefly report NO_POSITION during a move or rebind. Still consume
// OK on the grid: falling through would let the focused card open its app in reorder mode.