summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGilles Debunne <debunne@google.com>2010-11-01 11:29:24 -0700
committerGilles Debunne <debunne@google.com>2010-11-16 12:01:16 -0800
commitfe4d5defd07962d622182bcc9a4eb8027ba23e8d (patch)
tree7aaba91de27d4a06ce4b302c463b5ad4316bf502
parent9d305170dc71cb6c070a341172e19a89a5fa8db0 (diff)
downloadframeworks_base-fe4d5defd07962d622182bcc9a4eb8027ba23e8d.zip
frameworks_base-fe4d5defd07962d622182bcc9a4eb8027ba23e8d.tar.gz
frameworks_base-fe4d5defd07962d622182bcc9a4eb8027ba23e8d.tar.bz2
Multiline EditText have top and bottom brackets to differentiate from single line.
Change-Id: Iab6da75e7a823018221399c0b03dd47f7f768f21
-rw-r--r--core/java/android/widget/TextView.java9
-rw-r--r--core/res/res/drawable-hdpi/textfield_active_holo_dark.9.pngbin0 -> 1095 bytes
-rw-r--r--core/res/res/drawable-hdpi/textfield_active_holo_light.9.pngbin0 -> 1095 bytes
-rw-r--r--core/res/res/drawable-hdpi/textfield_default_holo_dark.9.pngbin187 -> 1082 bytes
-rw-r--r--core/res/res/drawable-hdpi/textfield_default_holo_light.9.pngbin184 -> 1088 bytes
-rw-r--r--core/res/res/drawable-hdpi/textfield_disabled_focused_holo_dark.9.pngbin0 -> 1081 bytes
-rw-r--r--core/res/res/drawable-hdpi/textfield_disabled_focused_holo_light.9.pngbin0 -> 1080 bytes
-rw-r--r--core/res/res/drawable-hdpi/textfield_disabled_holo_dark.9.pngbin245 -> 1069 bytes
-rw-r--r--core/res/res/drawable-hdpi/textfield_disabled_holo_light.9.pngbin236 -> 1078 bytes
-rw-r--r--core/res/res/drawable-hdpi/textfield_disabled_selected_holo_dark.9.pngbin235 -> 0 bytes
-rw-r--r--core/res/res/drawable-hdpi/textfield_disabled_selected_holo_light.9.pngbin233 -> 0 bytes
-rw-r--r--core/res/res/drawable-hdpi/textfield_multiline_active_holo_dark.9.pngbin0 -> 1124 bytes
-rw-r--r--core/res/res/drawable-hdpi/textfield_multiline_active_holo_light.9.pngbin0 -> 1122 bytes
-rw-r--r--core/res/res/drawable-hdpi/textfield_multiline_default_holo_dark.9.pngbin0 -> 1128 bytes
-rw-r--r--core/res/res/drawable-hdpi/textfield_multiline_default_holo_light.9.pngbin0 -> 1120 bytes
-rw-r--r--core/res/res/drawable-hdpi/textfield_multiline_disabled_focused_holo_dark.9.pngbin0 -> 1113 bytes
-rw-r--r--core/res/res/drawable-hdpi/textfield_multiline_disabled_focused_holo_light.9.pngbin0 -> 1113 bytes
-rw-r--r--core/res/res/drawable-hdpi/textfield_multiline_disabled_holo_dark.9.pngbin0 -> 1117 bytes
-rw-r--r--core/res/res/drawable-hdpi/textfield_multiline_disabled_holo_light.9.pngbin0 -> 1128 bytes
-rw-r--r--core/res/res/drawable-hdpi/textfield_pressed.9.pngbin3986 -> 0 bytes
-rw-r--r--core/res/res/drawable-hdpi/textfield_pressed_holo_dark.9.pngbin179 -> 0 bytes
-rw-r--r--core/res/res/drawable-hdpi/textfield_pressed_holo_light.9.pngbin187 -> 0 bytes
-rw-r--r--core/res/res/drawable-hdpi/textfield_selected_holo_dark.9.pngbin179 -> 0 bytes
-rw-r--r--core/res/res/drawable-hdpi/textfield_selected_holo_light.9.pngbin187 -> 0 bytes
-rw-r--r--core/res/res/drawable-ldpi/textfield_pressed.9.pngbin642 -> 0 bytes
-rw-r--r--core/res/res/drawable-mdpi/textfield_active_holo_dark.9.pngbin0 -> 1070 bytes
-rw-r--r--core/res/res/drawable-mdpi/textfield_active_holo_light.9.pngbin0 -> 1073 bytes
-rw-r--r--core/res/res/drawable-mdpi/textfield_default_holo_dark.9.pngbin165 -> 1068 bytes
-rw-r--r--core/res/res/drawable-mdpi/textfield_default_holo_light.9.pngbin165 -> 1071 bytes
-rw-r--r--core/res/res/drawable-mdpi/textfield_disabled_focused_holo_dark.9.pngbin0 -> 1075 bytes
-rw-r--r--core/res/res/drawable-mdpi/textfield_disabled_focused_holo_light.9.pngbin0 -> 1075 bytes
-rw-r--r--core/res/res/drawable-mdpi/textfield_disabled_holo_dark.9.pngbin214 -> 1067 bytes
-rw-r--r--core/res/res/drawable-mdpi/textfield_disabled_holo_light.9.pngbin206 -> 1069 bytes
-rw-r--r--core/res/res/drawable-mdpi/textfield_disabled_selected_holo_dark.9.pngbin228 -> 0 bytes
-rw-r--r--core/res/res/drawable-mdpi/textfield_disabled_selected_holo_light.9.pngbin219 -> 0 bytes
-rw-r--r--core/res/res/drawable-mdpi/textfield_multiline_active_holo_dark.9.pngbin0 -> 1103 bytes
-rw-r--r--core/res/res/drawable-mdpi/textfield_multiline_active_holo_light.9.pngbin0 -> 1105 bytes
-rw-r--r--core/res/res/drawable-mdpi/textfield_multiline_default_holo_dark.9.pngbin0 -> 1101 bytes
-rw-r--r--core/res/res/drawable-mdpi/textfield_multiline_default_holo_light.9.pngbin0 -> 1106 bytes
-rw-r--r--core/res/res/drawable-mdpi/textfield_multiline_disabled_focused_holo_dark.9.pngbin0 -> 1110 bytes
-rw-r--r--core/res/res/drawable-mdpi/textfield_multiline_disabled_focused_holo_light.9.pngbin0 -> 1110 bytes
-rw-r--r--core/res/res/drawable-mdpi/textfield_multiline_disabled_holo_dark.9.pngbin0 -> 1090 bytes
-rw-r--r--core/res/res/drawable-mdpi/textfield_multiline_disabled_holo_light.9.pngbin0 -> 1107 bytes
-rw-r--r--core/res/res/drawable-mdpi/textfield_pressed.9.pngbin1040 -> 0 bytes
-rw-r--r--core/res/res/drawable-mdpi/textfield_pressed_holo_dark.9.pngbin185 -> 0 bytes
-rw-r--r--core/res/res/drawable-mdpi/textfield_pressed_holo_light.9.pngbin185 -> 0 bytes
-rw-r--r--core/res/res/drawable-mdpi/textfield_selected_holo_dark.9.pngbin185 -> 0 bytes
-rw-r--r--core/res/res/drawable-mdpi/textfield_selected_holo_light.9.pngbin185 -> 0 bytes
-rw-r--r--core/res/res/drawable/edit_text.xml7
-rw-r--r--core/res/res/drawable/edit_text_holo_dark.xml11
-rw-r--r--core/res/res/drawable/edit_text_holo_light.xml11
-rw-r--r--core/res/res/drawable/edit_text_multiline_holo_dark.xml24
-rw-r--r--core/res/res/drawable/edit_text_multiline_holo_light.xml24
-rwxr-xr-xcore/res/res/values/attrs.xml5
-rw-r--r--core/res/res/values/styles.xml1
-rw-r--r--core/res/res/values/themes.xml7
56 files changed, 77 insertions, 22 deletions
diff --git a/core/java/android/widget/TextView.java b/core/java/android/widget/TextView.java
index b143325..fbc8549 100644
--- a/core/java/android/widget/TextView.java
+++ b/core/java/android/widget/TextView.java
@@ -305,6 +305,8 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener
int mTextSelectHandleRes;
int mTextEditPasteWindowLayout;
int mTextEditNoPasteWindowLayout;
+ Drawable mEditTextMultilineBackground;
+ Drawable mEditTextSingleLineBackground;
Drawable mSelectHandleLeft;
Drawable mSelectHandleRight;
@@ -751,6 +753,10 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener
mTextEditNoPasteWindowLayout = a.getResourceId(attr, 0);
break;
+ case com.android.internal.R.styleable.TextView_multilineBackground:
+ mEditTextMultilineBackground = a.getDrawable(attr);
+ break;
+
case com.android.internal.R.styleable.TextView_textLineHeight:
int lineHeight = a.getDimensionPixelSize(attr, 0);
if (lineHeight != 0) {
@@ -765,6 +771,7 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener
}
a.recycle();
+ mEditTextSingleLineBackground = getBackground();
BufferType bufferType = BufferType.EDITABLE;
final int variation =
@@ -6192,12 +6199,14 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener
if (applyTransformation) {
setTransformationMethod(SingleLineTransformationMethod.getInstance());
}
+ setBackgroundDrawable(mEditTextSingleLineBackground);
} else {
setMaxLines(Integer.MAX_VALUE);
setHorizontallyScrolling(false);
if (applyTransformation) {
setTransformationMethod(null);
}
+ setBackgroundDrawable(mEditTextMultilineBackground);
}
}
diff --git a/core/res/res/drawable-hdpi/textfield_active_holo_dark.9.png b/core/res/res/drawable-hdpi/textfield_active_holo_dark.9.png
new file mode 100644
index 0000000..a38c03a
--- /dev/null
+++ b/core/res/res/drawable-hdpi/textfield_active_holo_dark.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/textfield_active_holo_light.9.png b/core/res/res/drawable-hdpi/textfield_active_holo_light.9.png
new file mode 100644
index 0000000..6a88a69
--- /dev/null
+++ b/core/res/res/drawable-hdpi/textfield_active_holo_light.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/textfield_default_holo_dark.9.png b/core/res/res/drawable-hdpi/textfield_default_holo_dark.9.png
index 7ec2192..87d9c21 100644
--- a/core/res/res/drawable-hdpi/textfield_default_holo_dark.9.png
+++ b/core/res/res/drawable-hdpi/textfield_default_holo_dark.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/textfield_default_holo_light.9.png b/core/res/res/drawable-hdpi/textfield_default_holo_light.9.png
index c03e4f6..720ee78 100644
--- a/core/res/res/drawable-hdpi/textfield_default_holo_light.9.png
+++ b/core/res/res/drawable-hdpi/textfield_default_holo_light.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/textfield_disabled_focused_holo_dark.9.png b/core/res/res/drawable-hdpi/textfield_disabled_focused_holo_dark.9.png
new file mode 100644
index 0000000..4275da0
--- /dev/null
+++ b/core/res/res/drawable-hdpi/textfield_disabled_focused_holo_dark.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/textfield_disabled_focused_holo_light.9.png b/core/res/res/drawable-hdpi/textfield_disabled_focused_holo_light.9.png
new file mode 100644
index 0000000..3ec9c1f
--- /dev/null
+++ b/core/res/res/drawable-hdpi/textfield_disabled_focused_holo_light.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/textfield_disabled_holo_dark.9.png b/core/res/res/drawable-hdpi/textfield_disabled_holo_dark.9.png
index 6642717..227bde2 100644
--- a/core/res/res/drawable-hdpi/textfield_disabled_holo_dark.9.png
+++ b/core/res/res/drawable-hdpi/textfield_disabled_holo_dark.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/textfield_disabled_holo_light.9.png b/core/res/res/drawable-hdpi/textfield_disabled_holo_light.9.png
index 9572752..6ddfab0 100644
--- a/core/res/res/drawable-hdpi/textfield_disabled_holo_light.9.png
+++ b/core/res/res/drawable-hdpi/textfield_disabled_holo_light.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/textfield_disabled_selected_holo_dark.9.png b/core/res/res/drawable-hdpi/textfield_disabled_selected_holo_dark.9.png
deleted file mode 100644
index 0ad248c..0000000
--- a/core/res/res/drawable-hdpi/textfield_disabled_selected_holo_dark.9.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-hdpi/textfield_disabled_selected_holo_light.9.png b/core/res/res/drawable-hdpi/textfield_disabled_selected_holo_light.9.png
deleted file mode 100644
index b7a07c4..0000000
--- a/core/res/res/drawable-hdpi/textfield_disabled_selected_holo_light.9.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-hdpi/textfield_multiline_active_holo_dark.9.png b/core/res/res/drawable-hdpi/textfield_multiline_active_holo_dark.9.png
new file mode 100644
index 0000000..7528479
--- /dev/null
+++ b/core/res/res/drawable-hdpi/textfield_multiline_active_holo_dark.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/textfield_multiline_active_holo_light.9.png b/core/res/res/drawable-hdpi/textfield_multiline_active_holo_light.9.png
new file mode 100644
index 0000000..4c7d9e7
--- /dev/null
+++ b/core/res/res/drawable-hdpi/textfield_multiline_active_holo_light.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/textfield_multiline_default_holo_dark.9.png b/core/res/res/drawable-hdpi/textfield_multiline_default_holo_dark.9.png
new file mode 100644
index 0000000..09ca253
--- /dev/null
+++ b/core/res/res/drawable-hdpi/textfield_multiline_default_holo_dark.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/textfield_multiline_default_holo_light.9.png b/core/res/res/drawable-hdpi/textfield_multiline_default_holo_light.9.png
new file mode 100644
index 0000000..0a7d3a1
--- /dev/null
+++ b/core/res/res/drawable-hdpi/textfield_multiline_default_holo_light.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/textfield_multiline_disabled_focused_holo_dark.9.png b/core/res/res/drawable-hdpi/textfield_multiline_disabled_focused_holo_dark.9.png
new file mode 100644
index 0000000..54a1519
--- /dev/null
+++ b/core/res/res/drawable-hdpi/textfield_multiline_disabled_focused_holo_dark.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/textfield_multiline_disabled_focused_holo_light.9.png b/core/res/res/drawable-hdpi/textfield_multiline_disabled_focused_holo_light.9.png
new file mode 100644
index 0000000..06ca0d4
--- /dev/null
+++ b/core/res/res/drawable-hdpi/textfield_multiline_disabled_focused_holo_light.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/textfield_multiline_disabled_holo_dark.9.png b/core/res/res/drawable-hdpi/textfield_multiline_disabled_holo_dark.9.png
new file mode 100644
index 0000000..9015299
--- /dev/null
+++ b/core/res/res/drawable-hdpi/textfield_multiline_disabled_holo_dark.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/textfield_multiline_disabled_holo_light.9.png b/core/res/res/drawable-hdpi/textfield_multiline_disabled_holo_light.9.png
new file mode 100644
index 0000000..b355cb3
--- /dev/null
+++ b/core/res/res/drawable-hdpi/textfield_multiline_disabled_holo_light.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/textfield_pressed.9.png b/core/res/res/drawable-hdpi/textfield_pressed.9.png
deleted file mode 100644
index a42d87f..0000000
--- a/core/res/res/drawable-hdpi/textfield_pressed.9.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-hdpi/textfield_pressed_holo_dark.9.png b/core/res/res/drawable-hdpi/textfield_pressed_holo_dark.9.png
deleted file mode 100644
index a271ac9..0000000
--- a/core/res/res/drawable-hdpi/textfield_pressed_holo_dark.9.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-hdpi/textfield_pressed_holo_light.9.png b/core/res/res/drawable-hdpi/textfield_pressed_holo_light.9.png
deleted file mode 100644
index 521722d..0000000
--- a/core/res/res/drawable-hdpi/textfield_pressed_holo_light.9.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-hdpi/textfield_selected_holo_dark.9.png b/core/res/res/drawable-hdpi/textfield_selected_holo_dark.9.png
deleted file mode 100644
index a271ac9..0000000
--- a/core/res/res/drawable-hdpi/textfield_selected_holo_dark.9.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-hdpi/textfield_selected_holo_light.9.png b/core/res/res/drawable-hdpi/textfield_selected_holo_light.9.png
deleted file mode 100644
index 521722d..0000000
--- a/core/res/res/drawable-hdpi/textfield_selected_holo_light.9.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-ldpi/textfield_pressed.9.png b/core/res/res/drawable-ldpi/textfield_pressed.9.png
deleted file mode 100644
index 1433365..0000000
--- a/core/res/res/drawable-ldpi/textfield_pressed.9.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-mdpi/textfield_active_holo_dark.9.png b/core/res/res/drawable-mdpi/textfield_active_holo_dark.9.png
new file mode 100644
index 0000000..d37c8b2
--- /dev/null
+++ b/core/res/res/drawable-mdpi/textfield_active_holo_dark.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/textfield_active_holo_light.9.png b/core/res/res/drawable-mdpi/textfield_active_holo_light.9.png
new file mode 100644
index 0000000..16f2197
--- /dev/null
+++ b/core/res/res/drawable-mdpi/textfield_active_holo_light.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/textfield_default_holo_dark.9.png b/core/res/res/drawable-mdpi/textfield_default_holo_dark.9.png
index 3a5f36d..c98c951 100644
--- a/core/res/res/drawable-mdpi/textfield_default_holo_dark.9.png
+++ b/core/res/res/drawable-mdpi/textfield_default_holo_dark.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/textfield_default_holo_light.9.png b/core/res/res/drawable-mdpi/textfield_default_holo_light.9.png
index b8cc76f..7691f81 100644
--- a/core/res/res/drawable-mdpi/textfield_default_holo_light.9.png
+++ b/core/res/res/drawable-mdpi/textfield_default_holo_light.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/textfield_disabled_focused_holo_dark.9.png b/core/res/res/drawable-mdpi/textfield_disabled_focused_holo_dark.9.png
new file mode 100644
index 0000000..500ede3
--- /dev/null
+++ b/core/res/res/drawable-mdpi/textfield_disabled_focused_holo_dark.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/textfield_disabled_focused_holo_light.9.png b/core/res/res/drawable-mdpi/textfield_disabled_focused_holo_light.9.png
new file mode 100644
index 0000000..99f7f38
--- /dev/null
+++ b/core/res/res/drawable-mdpi/textfield_disabled_focused_holo_light.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/textfield_disabled_holo_dark.9.png b/core/res/res/drawable-mdpi/textfield_disabled_holo_dark.9.png
index a1f0c71..fab86ac 100644
--- a/core/res/res/drawable-mdpi/textfield_disabled_holo_dark.9.png
+++ b/core/res/res/drawable-mdpi/textfield_disabled_holo_dark.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/textfield_disabled_holo_light.9.png b/core/res/res/drawable-mdpi/textfield_disabled_holo_light.9.png
index 71e3103..876eb794 100644
--- a/core/res/res/drawable-mdpi/textfield_disabled_holo_light.9.png
+++ b/core/res/res/drawable-mdpi/textfield_disabled_holo_light.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/textfield_disabled_selected_holo_dark.9.png b/core/res/res/drawable-mdpi/textfield_disabled_selected_holo_dark.9.png
deleted file mode 100644
index ac6d406..0000000
--- a/core/res/res/drawable-mdpi/textfield_disabled_selected_holo_dark.9.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-mdpi/textfield_disabled_selected_holo_light.9.png b/core/res/res/drawable-mdpi/textfield_disabled_selected_holo_light.9.png
deleted file mode 100644
index bb6e953..0000000
--- a/core/res/res/drawable-mdpi/textfield_disabled_selected_holo_light.9.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-mdpi/textfield_multiline_active_holo_dark.9.png b/core/res/res/drawable-mdpi/textfield_multiline_active_holo_dark.9.png
new file mode 100644
index 0000000..2646899
--- /dev/null
+++ b/core/res/res/drawable-mdpi/textfield_multiline_active_holo_dark.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/textfield_multiline_active_holo_light.9.png b/core/res/res/drawable-mdpi/textfield_multiline_active_holo_light.9.png
new file mode 100644
index 0000000..374d457
--- /dev/null
+++ b/core/res/res/drawable-mdpi/textfield_multiline_active_holo_light.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/textfield_multiline_default_holo_dark.9.png b/core/res/res/drawable-mdpi/textfield_multiline_default_holo_dark.9.png
new file mode 100644
index 0000000..65c87ba
--- /dev/null
+++ b/core/res/res/drawable-mdpi/textfield_multiline_default_holo_dark.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/textfield_multiline_default_holo_light.9.png b/core/res/res/drawable-mdpi/textfield_multiline_default_holo_light.9.png
new file mode 100644
index 0000000..724b3fd
--- /dev/null
+++ b/core/res/res/drawable-mdpi/textfield_multiline_default_holo_light.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/textfield_multiline_disabled_focused_holo_dark.9.png b/core/res/res/drawable-mdpi/textfield_multiline_disabled_focused_holo_dark.9.png
new file mode 100644
index 0000000..5f0ad56
--- /dev/null
+++ b/core/res/res/drawable-mdpi/textfield_multiline_disabled_focused_holo_dark.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/textfield_multiline_disabled_focused_holo_light.9.png b/core/res/res/drawable-mdpi/textfield_multiline_disabled_focused_holo_light.9.png
new file mode 100644
index 0000000..df03a15
--- /dev/null
+++ b/core/res/res/drawable-mdpi/textfield_multiline_disabled_focused_holo_light.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/textfield_multiline_disabled_holo_dark.9.png b/core/res/res/drawable-mdpi/textfield_multiline_disabled_holo_dark.9.png
new file mode 100644
index 0000000..2cc7f62
--- /dev/null
+++ b/core/res/res/drawable-mdpi/textfield_multiline_disabled_holo_dark.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/textfield_multiline_disabled_holo_light.9.png b/core/res/res/drawable-mdpi/textfield_multiline_disabled_holo_light.9.png
new file mode 100644
index 0000000..a2d9d8a
--- /dev/null
+++ b/core/res/res/drawable-mdpi/textfield_multiline_disabled_holo_light.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/textfield_pressed.9.png b/core/res/res/drawable-mdpi/textfield_pressed.9.png
deleted file mode 100644
index c909ad2..0000000
--- a/core/res/res/drawable-mdpi/textfield_pressed.9.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-mdpi/textfield_pressed_holo_dark.9.png b/core/res/res/drawable-mdpi/textfield_pressed_holo_dark.9.png
deleted file mode 100644
index 7667d95..0000000
--- a/core/res/res/drawable-mdpi/textfield_pressed_holo_dark.9.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-mdpi/textfield_pressed_holo_light.9.png b/core/res/res/drawable-mdpi/textfield_pressed_holo_light.9.png
deleted file mode 100644
index 269affd..0000000
--- a/core/res/res/drawable-mdpi/textfield_pressed_holo_light.9.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-mdpi/textfield_selected_holo_dark.9.png b/core/res/res/drawable-mdpi/textfield_selected_holo_dark.9.png
deleted file mode 100644
index 7667d95..0000000
--- a/core/res/res/drawable-mdpi/textfield_selected_holo_dark.9.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-mdpi/textfield_selected_holo_light.9.png b/core/res/res/drawable-mdpi/textfield_selected_holo_light.9.png
deleted file mode 100644
index 269affd..0000000
--- a/core/res/res/drawable-mdpi/textfield_selected_holo_light.9.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable/edit_text.xml b/core/res/res/drawable/edit_text.xml
index 315278d..e9ba84b 100644
--- a/core/res/res/drawable/edit_text.xml
+++ b/core/res/res/drawable/edit_text.xml
@@ -15,11 +15,8 @@
-->
<selector xmlns:android="http://schemas.android.com/apk/res/android">
- <item android:state_window_focused="false" android:state_enabled="true"
- android:drawable="@drawable/textfield_default" />
- <item android:state_window_focused="false" android:state_enabled="false"
- android:drawable="@drawable/textfield_disabled" />
- <item android:state_pressed="true" android:drawable="@drawable/textfield_pressed" />
+ <item android:state_window_focused="false" android:state_enabled="true" android:drawable="@drawable/textfield_default" />
+ <item android:state_window_focused="false" android:state_enabled="false" android:drawable="@drawable/textfield_disabled" />
<item android:state_enabled="true" android:state_focused="true" android:drawable="@drawable/textfield_selected" />
<item android:state_enabled="true" android:drawable="@drawable/textfield_default" />
<item android:state_focused="true" android:drawable="@drawable/textfield_disabled_selected" />
diff --git a/core/res/res/drawable/edit_text_holo_dark.xml b/core/res/res/drawable/edit_text_holo_dark.xml
index b7d24ff..63ccd1d 100644
--- a/core/res/res/drawable/edit_text_holo_dark.xml
+++ b/core/res/res/drawable/edit_text_holo_dark.xml
@@ -15,14 +15,11 @@
-->
<selector xmlns:android="http://schemas.android.com/apk/res/android">
- <item android:state_window_focused="false" android:state_enabled="true"
- android:drawable="@drawable/textfield_default_holo_dark" />
- <item android:state_window_focused="false" android:state_enabled="false"
- android:drawable="@drawable/textfield_disabled_holo_dark" />
- <item android:state_pressed="true" android:drawable="@drawable/textfield_pressed_holo_dark" />
- <item android:state_enabled="true" android:state_focused="true" android:drawable="@drawable/textfield_selected_holo_dark" />
+ <item android:state_window_focused="false" android:state_enabled="true" android:drawable="@drawable/textfield_default_holo_dark" />
+ <item android:state_window_focused="false" android:state_enabled="false" android:drawable="@drawable/textfield_disabled_holo_dark" />
+ <item android:state_enabled="true" android:state_focused="true" android:drawable="@drawable/textfield_active_holo_dark" />
<item android:state_enabled="true" android:drawable="@drawable/textfield_default_holo_dark" />
- <item android:state_focused="true" android:drawable="@drawable/textfield_disabled_selected_holo_dark" />
+ <item android:state_focused="true" android:drawable="@drawable/textfield_disabled_focused_holo_dark" />
<item android:drawable="@drawable/textfield_disabled_holo_dark" />
</selector>
diff --git a/core/res/res/drawable/edit_text_holo_light.xml b/core/res/res/drawable/edit_text_holo_light.xml
index dae39e3..324acda 100644
--- a/core/res/res/drawable/edit_text_holo_light.xml
+++ b/core/res/res/drawable/edit_text_holo_light.xml
@@ -15,14 +15,11 @@
-->
<selector xmlns:android="http://schemas.android.com/apk/res/android">
- <item android:state_window_focused="false" android:state_enabled="true"
- android:drawable="@drawable/textfield_default_holo_light" />
- <item android:state_window_focused="false" android:state_enabled="false"
- android:drawable="@drawable/textfield_disabled_holo_light" />
- <item android:state_pressed="true" android:drawable="@drawable/textfield_pressed_holo_light" />
- <item android:state_enabled="true" android:state_focused="true" android:drawable="@drawable/textfield_selected_holo_light" />
+ <item android:state_window_focused="false" android:state_enabled="true" android:drawable="@drawable/textfield_default_holo_light" />
+ <item android:state_window_focused="false" android:state_enabled="false" android:drawable="@drawable/textfield_disabled_holo_light" />
+ <item android:state_enabled="true" android:state_focused="true" android:drawable="@drawable/textfield_active_holo_light" />
<item android:state_enabled="true" android:drawable="@drawable/textfield_default_holo_light" />
- <item android:state_focused="true" android:drawable="@drawable/textfield_disabled_selected_holo_light" />
+ <item android:state_focused="true" android:drawable="@drawable/textfield_disabled_focused_holo_light" />
<item android:drawable="@drawable/textfield_disabled_holo_light" />
</selector>
diff --git a/core/res/res/drawable/edit_text_multiline_holo_dark.xml b/core/res/res/drawable/edit_text_multiline_holo_dark.xml
new file mode 100644
index 0000000..67d2748
--- /dev/null
+++ b/core/res/res/drawable/edit_text_multiline_holo_dark.xml
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2010 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:state_window_focused="false" android:state_enabled="true" android:drawable="@drawable/textfield_multiline_default_holo_dark" />
+ <item android:state_window_focused="false" android:state_enabled="false" android:drawable="@drawable/textfield_multiline_disabled_holo_dark" />
+ <item android:state_enabled="true" android:state_focused="true" android:drawable="@drawable/textfield_multiline_active_holo_dark" />
+ <item android:state_enabled="true" android:drawable="@drawable/textfield_multiline_default_holo_dark" />
+ <item android:state_focused="true" android:drawable="@drawable/textfield_multiline_disabled_focused_holo_dark" />
+ <item android:drawable="@drawable/textfield_multiline_disabled_holo_dark" />
+</selector>
diff --git a/core/res/res/drawable/edit_text_multiline_holo_light.xml b/core/res/res/drawable/edit_text_multiline_holo_light.xml
new file mode 100644
index 0000000..08b3ec6
--- /dev/null
+++ b/core/res/res/drawable/edit_text_multiline_holo_light.xml
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2010 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:state_window_focused="false" android:state_enabled="true" android:drawable="@drawable/textfield_multiline_default_holo_light" />
+ <item android:state_window_focused="false" android:state_enabled="false" android:drawable="@drawable/textfield_multiline_disabled_holo_light" />
+ <item android:state_enabled="true" android:state_focused="true" android:drawable="@drawable/textfield_multiline_active_holo_light" />
+ <item android:state_enabled="true" android:drawable="@drawable/textfield_multiline_default_holo_light" />
+ <item android:state_focused="true" android:drawable="@drawable/textfield_multiline_disabled_focused_holo_light" />
+ <item android:drawable="@drawable/textfield_multiline_disabled_holo_light" />
+</selector>
diff --git a/core/res/res/values/attrs.xml b/core/res/res/values/attrs.xml
index 0b61202..55b3258 100755
--- a/core/res/res/values/attrs.xml
+++ b/core/res/res/values/attrs.xml
@@ -142,6 +142,8 @@
<attr name="editTextColor" format="reference|color" />
<!-- EditText background drawable. -->
<attr name="editTextBackground" format="reference" />
+ <!-- EditText background drawable for multiline EditText. -->
+ <attr name="editTextMultilineBackground" format="reference" />
<!-- A styled string, specifying the style to be used for showing
inline candidate text when composing with an input method. The
@@ -2508,7 +2510,8 @@
<attr name="textLineHeight" />
<!-- Indicates that a non-editable text can be selected. -->
<attr name="textIsSelectable" />
-
+ <!-- A specific background drawable used by multi-line EditText only. -->
+ <attr name="multilineBackground" format="reference"/>
</declare-styleable>
<!-- An <code>input-extras</code> is a container for extra data to supply to
an input method. Contains
diff --git a/core/res/res/values/styles.xml b/core/res/res/values/styles.xml
index b2db9b4..dc67f45 100644
--- a/core/res/res/values/styles.xml
+++ b/core/res/res/values/styles.xml
@@ -422,6 +422,7 @@
<item name="android:focusableInTouchMode">true</item>
<item name="android:clickable">true</item>
<item name="android:background">?android:attr/editTextBackground</item>
+ <item name="android:multilineBackground">?android:attr/editTextMultilineBackground</item>
<item name="android:textAppearance">?android:attr/textAppearanceMediumInverse</item>
<item name="android:textColor">?android:attr/editTextColor</item>
<item name="android:gravity">center_vertical</item>
diff --git a/core/res/res/values/themes.xml b/core/res/res/values/themes.xml
index 88e755f..dd7c8e48 100644
--- a/core/res/res/values/themes.xml
+++ b/core/res/res/values/themes.xml
@@ -72,6 +72,7 @@
<item name="editTextColor">?android:attr/textColorPrimaryInverse</item>
<item name="editTextBackground">@android:drawable/edit_text</item>
+ <item name="editTextMultilineBackground">@android:drawable/edit_text</item>
<item name="candidatesTextStyleSpans">@android:string/candidates_style</item>
@@ -685,6 +686,7 @@
<item name="editTextColor">?android:attr/textColorPrimary</item>
<item name="editTextBackground">@android:drawable/edit_text_holo_dark</item>
+ <item name="editTextMultilineBackground">@android:drawable/edit_text_multiline_holo_dark</item>
<item name="candidatesTextStyleSpans">@android:string/candidates_style</item>
@@ -917,10 +919,11 @@
<item name="textAppearanceSearchResultSubtitle">@android:style/TextAppearance.Holo.Light.SearchResult.Subtitle</item>
<item name="textAppearanceButton">@android:style/TextAppearance.Holo.Light.Widget.Button</item>
-
+
<item name="editTextColor">?android:attr/textColorPrimary</item>
<item name="editTextBackground">@android:drawable/edit_text_holo_light</item>
-
+ <item name="editTextMultilineBackground">@android:drawable/edit_text_multiline_holo_light</item>
+
<item name="candidatesTextStyleSpans">@android:string/candidates_style</item>
<item name="textCheckMark">@android:drawable/indicator_check_mark_light</item>