SnapdragonCamera:Fix wrong Countdown tip position

The hight and width of CountDownTitle will be zero when it's
not measured.Use screen width instead of its width and if its
height is zero, measure it first,then get the height.

Change-Id: I31a4aa5d4796f0b6f8085161e7eb60fcc07b2bbb
CRs-Fixed: 1083455
diff --git a/src/com/android/camera/ui/CountDownView.java b/src/com/android/camera/ui/CountDownView.java
old mode 100644
new mode 100755
index 6420fd2..7e1f28d
--- a/src/com/android/camera/ui/CountDownView.java
+++ b/src/com/android/camera/ui/CountDownView.java
@@ -153,16 +153,21 @@
 
     public void setOrientation(int orientation) {
         mRemainingSecondsView.setRotation(-orientation);
-
         mCountDownTitle.setRotation(-orientation);
+        int width = getResources().getDisplayMetrics().widthPixels;
+        int height = mCountDownTitle.getMeasuredHeight();
+        if (height == 0) {
+            measure(MeasureSpec.UNSPECIFIED,MeasureSpec.UNSPECIFIED);
+            height = mCountDownTitle.getMeasuredHeight();
+        }
         int dx = 0, dy = 0;
         switch (orientation) {
             case 90:
-                dy = (mCountDownTitle.getWidth() - mCountDownTitle.getHeight()) / 2;
+                dy = (width - height) / 2;
                 dx = -dy;
                 break;
             case 270:
-                dx = dy = (mCountDownTitle.getWidth() - mCountDownTitle.getHeight()) / 2;
+                dx = dy = (width - height) / 2;
                 break;
             case 180:
                 break;