Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Fetching contributors…

Cannot retrieve contributors at this time

file 25 lines (24 sloc) 0.725 kb
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25
using System;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;

namespace Ocell
{
    public static class ThemeFunctions
    {
        public static void ChangeBackgroundIfLightTheme(Panel LayoutRoot)
        {
            bool isDarkTheme = ((Visibility)Application.Current.Resources["PhoneDarkThemeVisibility"] == Visibility.Visible);
            if (!isDarkTheme)
            {
                LayoutRoot.Background = new SolidColorBrush(Colors.Transparent);
            }
        }
    }
}
Something went wrong with that request. Please try again.