am e779386a: Merge "Fixing handling of the EQUALS key" into honeycomb
* commit 'e779386a38fcde24ee8ada01b2eb8df14fa40f1c':
Fixing handling of the EQUALS key
diff --git a/src/com/android/calculator2/EventListener.java b/src/com/android/calculator2/EventListener.java
index ad800ae..78f3bab 100644
--- a/src/com/android/calculator2/EventListener.java
+++ b/src/com/android/calculator2/EventListener.java
@@ -31,7 +31,7 @@
mPanelSwitcher = panelSwitcher;
}
- //@Override
+ @Override
public void onClick(View view) {
int id = view.getId();
switch (id) {
@@ -63,7 +63,7 @@
}
}
- //@Override
+ @Override
public boolean onLongClick(View view) {
int id = view.getId();
if (id == R.id.del) {
@@ -73,9 +73,7 @@
return false;
}
- private static final char[] EQUAL = {'='};
-
- //@Override
+ @Override
public boolean onKey(View view, int keyCode, KeyEvent keyEvent) {
int action = keyEvent.getAction();
@@ -92,7 +90,7 @@
//Calculator.log("KEY " + keyCode + "; " + action);
- if (keyEvent.getMatch(EQUAL, keyEvent.getMetaState()) == '=') {
+ if (keyEvent.getUnicodeChar() == '=') {
if (action == KeyEvent.ACTION_UP) {
mHandler.onEnter();
}