jamesmontemagno/MediaPlugin

Change the Action Bar color & Title on Select a Photo UI.

abhaylakkad opened this issue · 1 comments

When navigated to show the Albums/Pick files, the default color of Action Bar is Blue. I tried to override the action bar color from my application but no Luck.

In my main application i called it like below -
var file = await CrossMedia.Current.PickPhotoAsync();

In Android application i tried to override the color like below -
public class MainApplication : Application, Application.IActivityLifecycleCallbacks
{
public MainApplication(IntPtr handle, JniHandleOwnership transer)
: base(handle, transer)
{
}
public override void OnCreate()
{
base.OnCreate();
RegisterActivityLifecycleCallbacks(this);
}

public void OnActivityCreated(Activity activity, Bundle savedInstanceState)
{
if (activity != null)
{

         activity.Window.ClearFlags(WindowManagerFlags.TranslucentStatus);
        activity.Window.AddFlags(WindowManagerFlags.DrawsSystemBarBackgrounds);
       activity.Window.SetStatusBarColor(Android.Graphics.Color.LightPink);
         activity.Window.SetTitleColor(Android.Graphics.Color.LightPink);
     }
     CrossCurrentActivity.Current.Activity = activity;

}
}

The title bar color works fine inside my application... i want to make the color same when i click the browse button and it opens the UI to choose file.
temp1

Nope, it is the device displaying that not the plugin