Beispiel #1
0
 private void SettingsOnExplorerSkinningChanged()
 {
     if (!(_skinWindow is ExplorerSkinWindow) && ExplorerSkinWindow.IsExplorerWindow(_skinWindow.Parent))
     {
         BorderSkinningManager.RestoreBorder(_skinWindow.Parent);
         _skinWindow.Dispose();
     }
 }
        public SkinningSettingsUpdater(BorderSkinningManager borderSkinningManager)
        {
            _borderSkinningManager = borderSkinningManager;

            Settings.BorderSkinningChanged += OnSkinningChangedHandler;

            OnSkinningChangedHandler();
        }
        public bool HandleNewWindow(TopLevelWindow window, BorderSkinningManager manager)
        {
            if (Settings.Settings.ExplorerSkinning && ExplorerSkinWindow.IsExplorerWindow(window))
            {
                manager.AddSkinWindow(new ExplorerSkinWindow(window, Settings.Settings.ExplorerSkin));

                return true;
            }

            return false;
        }
Beispiel #4
0
        public bool HandleNewWindow(TopLevelWindow window, BorderSkinningManager manager)
        {
            if (Settings.Settings.ExplorerSkinning && ExplorerSkinWindow.IsExplorerWindow(window))
            {
                manager.AddSkinWindow(new ExplorerSkinWindow(window, Settings.Settings.ExplorerSkin));

                return(true);
            }

            return(false);
        }
        protected virtual void Dispose(bool disposing)
        {
            if (!_skinWindow.IsClosing)
            {
                BorderSkinningManager.RestoreBorder(_skinWindow.Parent);
            }

            DisposeTimer();
            _skinWindow = null;

            DeattachFromWindowsHook();
        }
Beispiel #6
0
        public bool HandleNewWindow(TopLevelWindow window, BorderSkinningManager manager)
        {
            ExcludedWindow exludeInfo = ExcludeList[window];

            if (exludeInfo != null)
            {
                if (exludeInfo.HasSkin)
                {
                    manager.AddSkinWindow(new SkinableWindowBorder(window, exludeInfo.Skin, true));
                }

                return(true);
            }

            return(false);
        }
        public bool HandleNewWindow(TopLevelWindow window, BorderSkinningManager manager)
        {
            if (IncludeList.HasWindows)
            {
                ExcludedWindow included = IncludeList[window];

                if (included == null)
                {
                    return(true);
                }

                if (included.Skin != null)
                {
                    manager.AddSkinWindow(new SkinableWindowBorder(window, included.Skin, false));
                    return(true);
                }
            }

            return(false);
        }
Beispiel #8
0
        public static void Main()
        {
            try {
                ErrorManager.Start();
                Settings.Settings.Load();
                SettingsDialogue.StartTray();

                BorderSkinningManager = new BorderSkinningManager(WindowsHook);
                BorderSkinningManager.NewWindowHandlers.Insert(0, new ExplorerNewWindowHandler());
                BorderSkinningManager.NewWindowHandlers.Insert(0, new ExclusionNewWindowHandler());
                BorderSkinningManager.NewWindowHandlers.Insert(0, new InclusionNewWindowHandler());
                BorderSkinningManager.NewWindowHandlers.Insert(0, new PreventShutdownSkinningNewWindowHandler());

                _skinningSettingsUpdater = new SkinningSettingsUpdater(BorderSkinningManager);

                WindowsHook.Start();

                Application.Run();
            } catch (Exception ex) {
                ErrorManager.ProccessError(ex);
            }
        }
Beispiel #9
0
 private void SettingsOnBorderSkinningChanged()
 {
     BorderSkinningManager.RestoreBorder(_skinWindow.Parent);
     _skinWindow.Dispose();
 }