FM: Fix the issue with Ellipsize

When the string length is greater than button size, adding single "."
instead of "...".

Change-Id: I5b13d37bf2100bba9805d3d0cc98de8b6b82c937
CRs-Fixed: 624375
diff --git a/fmapp2/res/layout-800x480/fmradio.xml b/fmapp2/res/layout-800x480/fmradio.xml
index 83b9f7c..e209769 100644
--- a/fmapp2/res/layout-800x480/fmradio.xml
+++ b/fmapp2/res/layout-800x480/fmradio.xml
@@ -129,9 +129,9 @@
                 style="@style/ButtonStripLeft"
                 android:text="@string/add_station"
                 android:textAppearance="?android:attr/textAppearanceMedium"
-                android:textSize="15sp"
+                android:textSize="16sp"
                 android:singleLine="true"
-                android:layout_width="80dp"
+                android:layout_width="96dp"
                 android:layout_weight="1"
                 android:layout_height="wrap_content"/>
 
@@ -139,9 +139,9 @@
                 style="@style/ButtonStripMiddle"
                 android:text="@string/add_station"
                 android:textAppearance="?android:attr/textAppearanceMedium"
-                android:textSize="15sp"
+                android:textSize="16sp"
                 android:singleLine="true"
-                android:layout_width="80dp"
+                android:layout_width="96dp"
                 android:layout_weight="1"
                 android:layout_height="wrap_content"/>
 
@@ -149,9 +149,9 @@
                 style="@style/ButtonStripMiddle"
                 android:text="@string/add_station"
                 android:textAppearance="?android:attr/textAppearanceMedium"
-                android:textSize="15sp"
+                android:textSize="16sp"
                 android:singleLine="true"
-                android:layout_width="80dp"
+                android:layout_width="96dp"
                 android:layout_weight="1"
                 android:layout_height="wrap_content"/>
 
@@ -159,9 +159,9 @@
                 style="@style/ButtonStripMiddle"
                 android:text="@string/add_station"
                 android:textAppearance="?android:attr/textAppearanceMedium"
-                android:textSize="15sp"
+                android:textSize="16sp"
                 android:singleLine="true"
-                android:layout_width="80dp"
+                android:layout_width="96dp"
                 android:layout_weight="1"
                 android:layout_height="wrap_content"/>
 
@@ -169,9 +169,9 @@
                 style="@style/ButtonStripMiddle"
                 android:text="@string/add_station"
                 android:textAppearance="?android:attr/textAppearanceMedium"
-                android:textSize="15sp"
+                android:textSize="16sp"
                 android:singleLine="true"
-                android:layout_width="80dp"
+                android:layout_width="96dp"
                 android:layout_weight="1"
                 android:layout_height="wrap_content"/>
 
@@ -179,9 +179,9 @@
                 style="@style/ButtonStripMiddle"
                 android:text="@string/add_station"
                 android:textAppearance="?android:attr/textAppearanceMedium"
-                android:textSize="15sp"
+                android:textSize="16sp"
                 android:singleLine="true"
-                android:layout_width="80dp"
+                android:layout_width="96dp"
                 android:layout_weight="1"
                 android:layout_height="wrap_content"/>
 
@@ -189,9 +189,9 @@
                 style="@style/ButtonStripRight"
                 android:text="@string/add_station"
                 android:textAppearance="?android:attr/textAppearanceMedium"
-                android:textSize="15sp"
+                android:textSize="16sp"
                 android:singleLine="true"
-                android:layout_width="80dp"
+                android:layout_width="96dp"
                 android:layout_weight="1"
                 android:layout_height="wrap_content"/>
 
diff --git a/fmapp2/src/com/caf/fmradio/FMRadio.java b/fmapp2/src/com/caf/fmradio/FMRadio.java
index df97413..b7ab6e7 100644
--- a/fmapp2/src/com/caf/fmradio/FMRadio.java
+++ b/fmapp2/src/com/caf/fmradio/FMRadio.java
@@ -2046,6 +2046,11 @@
             String display = "";
             if (station != null) {
                display = station.getName();
+                Log.e(LOGTAG, "Venkat:before" + display );
+                if (display.length() > 6)
+		 display = display.substring(0,6)+"...";
+	       Log.e(LOGTAG, "Venkat: after" + display );
+		mPresetButtons[buttonIndex].setEllipsize(TextUtils.TruncateAt.END);
                mPresetButtons[buttonIndex].setText(display);
                mPresetButtons[buttonIndex].setTag(station);
                addedStations++;