Permalink
Browse files

Merge pull request #3408 from pingwang2011/timob-10086

timob-10086: Android: Window: Honeycomb - BackgroundColor of new window not shown when new window opened in a tab
  • Loading branch information...
2 parents 30d1747 + a4b848d commit d84a15edb5e963b993088313304f584105182e10 @krowley krowley committed Nov 20, 2012
Showing with 15 additions and 0 deletions.
  1. +15 −0 android/titanium/src/java/org/appcelerator/titanium/view/TiUIDecorView.java
@@ -6,8 +6,11 @@
*/
package org.appcelerator.titanium.view;
+import org.appcelerator.titanium.TiC;
import org.appcelerator.titanium.proxy.DecorViewProxy;
+import android.os.Build;
+
public class TiUIDecorView extends TiUIView
{
@@ -17,4 +20,16 @@ public TiUIDecorView(DecorViewProxy decorViewProxy)
setNativeView(decorViewProxy.getLayout());
}
+
+ @Override
+ public void add(TiUIView child)
+ {
+ super.add(child);
+
+ // Honeycomb has issues to redraw the decor view after adding a child. (TIMOB-10126)
+ // So we force it to invalidate the decor view here.
+ if (Build.VERSION.SDK_INT >= TiC.API_LEVEL_HONEYCOMB && Build.VERSION.SDK_INT < TiC.API_LEVEL_ICE_CREAM_SANDWICH) {
+ getNativeView().postInvalidate();
+ }
+ }
}

0 comments on commit d84a15e

Please sign in to comment.