mirror of
https://github.com/cefsharp/CefSharp.git
synced 2026-12-04 10:22:55 +00:00
561b50b2cd
Fix up some urls in the custom scheme popup test Add PopupTest.html to WPF example menu
22 lines
868 B
C#
22 lines
868 B
C#
// Copyright © 2010-2015 The CefSharp Authors. All rights reserved.
|
|
//
|
|
// Use of this source code is governed by a BSD-style license that can be found in the LICENSE file.
|
|
|
|
namespace CefSharp.Example
|
|
{
|
|
internal class CefSharpSchemeHandlerFactory : ISchemeHandlerFactory
|
|
{
|
|
public const string SchemeName = "custom";
|
|
public const string SchemeNameTest = "test";
|
|
|
|
public IResourceHandler Create(IBrowser browser, IFrame frame, string schemeName, IRequest request)
|
|
{
|
|
if (schemeName == SchemeName && request.Url.EndsWith("CefSharp.Core.xml", System.StringComparison.OrdinalIgnoreCase))
|
|
{
|
|
//Display the debug.log file in the browser
|
|
return ResourceHandler.FromFileName("CefSharp.Core.xml", ".xml");
|
|
}
|
|
return new CefSharpSchemeHandler();
|
|
}
|
|
}
|
|
} |