From 4d279d94ade1c0d455404312b3c9cfde0078c547 Mon Sep 17 00:00:00 2001 From: Winson Chung Date: Thu, 21 Jul 2011 11:46:32 -0700 Subject: Fixing various issues with the dock. - Prevent crash due to no overlays in certain device configurations - Fixing kb crash and adding content description for Apps button Change-Id: Ie2a2bc29e7b9408a165f93d108fdd803193afc29 --- src/com/android/launcher2/Hotseat.java | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'src/com/android/launcher2/Hotseat.java') diff --git a/src/com/android/launcher2/Hotseat.java b/src/com/android/launcher2/Hotseat.java index deab131..491691e 100644 --- a/src/com/android/launcher2/Hotseat.java +++ b/src/com/android/launcher2/Hotseat.java @@ -57,6 +57,7 @@ public class Hotseat extends FrameLayout { public void setup(Launcher launcher) { mLauncher = launcher; + setOnKeyListener(new HotseatBubbleTextViewKeyEventListener()); } CellLayout getLayout() { @@ -96,11 +97,14 @@ public class Hotseat extends FrameLayout { inflater.inflate(R.layout.application, mContent, false); allAppsButton.setCompoundDrawablesWithIntrinsicBounds(null, context.getResources().getDrawable(R.drawable.apps_hotseat_button), null, null); - // button.setText(context.getString(R.string.all_apps_button_label)); + // allAppsButton.setText(context.getString(R.string.all_apps_button_label)); + allAppsButton.setContentDescription(context.getString(R.string.all_apps_button_label)); allAppsButton.setOnClickListener(new View.OnClickListener() { @Override public void onClick(android.view.View v) { - mLauncher.showAllApps(true); + if (mLauncher != null) { + mLauncher.showAllApps(true); + } } }); -- cgit v1.1