本文整理汇总了C#中System.Web.HttpBrowserCapabilities.AddBrowser方法的典型用法代码示例。如果您正苦于以下问题:C# HttpBrowserCapabilities.AddBrowser方法的具体用法?C# HttpBrowserCapabilities.AddBrowser怎么用?C# HttpBrowserCapabilities.AddBrowser使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类System.Web.HttpBrowserCapabilities
的用法示例。
在下文中一共展示了HttpBrowserCapabilities.AddBrowser方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: BlackberryProcess
private bool BlackberryProcess(NameValueCollection headers, HttpBrowserCapabilities browserCaps)
{
IDictionary capabilities = browserCaps.Capabilities;
string target = browserCaps[string.Empty];
RegexWorker worker = new RegexWorker(browserCaps);
if (!worker.ProcessRegex(target, @"BlackBerry(?'deviceName'\w+)/(?'version'(?'major'\d+)(\.(?'minor'\d+)?)\w*)"))
{
return false;
}
capabilities["layoutEngine"] = "BlackBerry";
capabilities["browser"] = "BlackBerry";
capabilities["majorversion"] = worker["${major}"];
capabilities["minorversion"] = worker["${minor}"];
capabilities["type"] = worker["BlackBerry${major}"];
capabilities["mobileDeviceModel"] = worker["${deviceName}"];
capabilities["isMobileDevice"] = "true";
capabilities["version"] = worker["${version}"];
capabilities["ecmascriptversion"] = "3.0";
capabilities["javascript"] = "true";
capabilities["javascriptversion"] = "1.3";
capabilities["w3cdomversion"] = "1.0";
capabilities["supportsAccesskeyAttribute"] = "true";
capabilities["tagwriter"] = "System.Web.UI.HtmlTextWriter";
capabilities["cookies"] = "true";
capabilities["frames"] = "true";
capabilities["javaapplets"] = "true";
capabilities["supportsCallback"] = "true";
capabilities["supportsDivNoWrap"] = "false";
capabilities["supportsFileUpload"] = "true";
capabilities["supportsMultilineTextBoxDisplay"] = "true";
capabilities["supportsXmlHttp"] = "true";
capabilities["tables"] = "true";
capabilities["canInitiateVoiceCall"] = "true";
browserCaps.AddBrowser("BlackBerry");
this.BlackberryProcessGateways(headers, browserCaps);
bool ignoreApplicationBrowsers = false;
this.BlackberryProcessBrowsers(ignoreApplicationBrowsers, headers, browserCaps);
return true;
}
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:39,代码来源:BrowserCapabilitiesFactory.cs
示例2: OperaProcess
private bool OperaProcess(NameValueCollection headers, HttpBrowserCapabilities browserCaps)
{
IDictionary capabilities = browserCaps.Capabilities;
string target = browserCaps[string.Empty];
RegexWorker worker = new RegexWorker(browserCaps);
if (!worker.ProcessRegex(target, @"Opera[ /](?'version'(?'major'\d+)(\.(?'minor'\d+)?)(?'letters'\w*))"))
{
return false;
}
worker.ProcessRegex(browserCaps[string.Empty], @"Presto/(?'layoutVersion'\d+)");
capabilities["browser"] = "Opera";
capabilities["majorversion"] = worker["${major}"];
capabilities["minorversion"] = worker["${minor}"];
capabilities["type"] = worker["Opera${major}"];
capabilities["version"] = worker["${version}"];
capabilities["layoutEngine"] = "Presto";
capabilities["layoutEngineVersion"] = worker["${layoutVersion}"];
capabilities["ecmascriptversion"] = "3.0";
capabilities["javascript"] = "true";
capabilities["javascriptversion"] = "1.5";
capabilities["letters"] = worker["${letters}"];
capabilities["w3cdomversion"] = "1.0";
capabilities["tagwriter"] = "System.Web.UI.HtmlTextWriter";
capabilities["cookies"] = "true";
capabilities["frames"] = "true";
capabilities["javaapplets"] = "true";
capabilities["supportsAccesskeyAttribute"] = "true";
capabilities["supportsCallback"] = "true";
capabilities["supportsFileUpload"] = "true";
capabilities["supportsMultilineTextBoxDisplay"] = "true";
capabilities["supportsXmlHttp"] = "true";
capabilities["tables"] = "true";
capabilities["inputType"] = "keyboard";
capabilities["isColor"] = "true";
capabilities["isMobileDevice"] = "false";
capabilities["maximumRenderedPageSize"] = "300000";
capabilities["screenBitDepth"] = "8";
capabilities["supportsBold"] = "true";
capabilities["supportsCss"] = "true";
capabilities["supportsDivNoWrap"] = "true";
capabilities["supportsFontName"] = "true";
capabilities["supportsFontSize"] = "true";
capabilities["supportsImageSubmit"] = "true";
capabilities["supportsItalic"] = "true";
browserCaps.AddBrowser("Opera");
this.OperaProcessGateways(headers, browserCaps);
bool ignoreApplicationBrowsers = true;
if (!this.Opera8to9Process(headers, browserCaps) && !this.Opera10Process(headers, browserCaps))
{
ignoreApplicationBrowsers = false;
}
this.OperaProcessBrowsers(ignoreApplicationBrowsers, headers, browserCaps);
return true;
}
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:54,代码来源:BrowserCapabilitiesFactory.cs
示例3: Opera8to9Process
private bool Opera8to9Process(NameValueCollection headers, HttpBrowserCapabilities browserCaps)
{
IDictionary capabilities = browserCaps.Capabilities;
string target = (string) capabilities["majorversion"];
RegexWorker worker = new RegexWorker(browserCaps);
if (!worker.ProcessRegex(target, "[8-9]"))
{
return false;
}
target = (string) capabilities["Version"];
if (worker.ProcessRegex(target, "9.80"))
{
return false;
}
capabilities["supportsMaintainScrollPositionOnPostback"] = "true";
browserCaps.AddBrowser("Opera8to9");
this.Opera8to9ProcessGateways(headers, browserCaps);
bool ignoreApplicationBrowsers = false;
this.Opera8to9ProcessBrowsers(ignoreApplicationBrowsers, headers, browserCaps);
return true;
}
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:21,代码来源:BrowserCapabilitiesFactory.cs
示例4: Opera10Process
private bool Opera10Process(NameValueCollection headers, HttpBrowserCapabilities browserCaps)
{
IDictionary capabilities = browserCaps.Capabilities;
string target = browserCaps[string.Empty];
RegexWorker worker = new RegexWorker(browserCaps);
if (!worker.ProcessRegex(target, @"Opera/10\.|Version/10\."))
{
return false;
}
capabilities["version"] = "10.00";
capabilities["majorversion"] = "10";
capabilities["minorversion"] = "00";
capabilities["supportsMaintainScrollPositionOnPostback"] = "true";
browserCaps.AddBrowser("Opera10");
this.Opera10ProcessGateways(headers, browserCaps);
bool ignoreApplicationBrowsers = false;
this.Opera10ProcessBrowsers(ignoreApplicationBrowsers, headers, browserCaps);
return true;
}
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:19,代码来源:BrowserCapabilitiesFactory.cs
示例5: MozillaProcess
private bool MozillaProcess(NameValueCollection headers, HttpBrowserCapabilities browserCaps)
{
IDictionary capabilities = browserCaps.Capabilities;
string target = browserCaps[string.Empty];
RegexWorker worker = new RegexWorker(browserCaps);
if (!worker.ProcessRegex(target, "Mozilla"))
{
return false;
}
capabilities["browser"] = "Mozilla";
capabilities["cookies"] = "false";
capabilities["inputType"] = "keyboard";
capabilities["isColor"] = "true";
capabilities["isMobileDevice"] = "false";
capabilities["maximumRenderedPageSize"] = "300000";
capabilities["screenBitDepth"] = "8";
capabilities["supportsBold"] = "true";
capabilities["supportsCss"] = "true";
capabilities["supportsDivNoWrap"] = "true";
capabilities["supportsFontName"] = "true";
capabilities["supportsFontSize"] = "true";
capabilities["supportsImageSubmit"] = "true";
capabilities["supportsItalic"] = "true";
capabilities["type"] = "Mozilla";
browserCaps.AddBrowser("Mozilla");
this.MozillaProcessGateways(headers, browserCaps);
bool ignoreApplicationBrowsers = true;
if (((!this.IeProcess(headers, browserCaps) && !this.ChromeProcess(headers, browserCaps)) && (!this.FirefoxProcess(headers, browserCaps) && !this.IemobileProcess(headers, browserCaps))) && !this.SafariProcess(headers, browserCaps))
{
ignoreApplicationBrowsers = false;
}
this.MozillaProcessBrowsers(ignoreApplicationBrowsers, headers, browserCaps);
return true;
}
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:34,代码来源:BrowserCapabilitiesFactory.cs
示例6: IeProcess
private bool IeProcess(NameValueCollection headers, HttpBrowserCapabilities browserCaps)
{
IDictionary capabilities = browserCaps.Capabilities;
string target = browserCaps[string.Empty];
RegexWorker worker = new RegexWorker(browserCaps);
if (!worker.ProcessRegex(target, @"MSIE (?'version'(?'major'\d+)(\.(?'minor'\d+)?)(?'letters'\w*))(?'extra'[^)]*)"))
{
return false;
}
target = browserCaps[string.Empty];
if (worker.ProcessRegex(target, "IEMobile"))
{
return false;
}
worker.ProcessRegex(browserCaps[string.Empty], @"Trident/(?'layoutVersion'\d+)");
capabilities["browser"] = "IE";
capabilities["layoutEngine"] = "Trident";
capabilities["layoutEngineVersion"] = worker["${layoutVersion}"];
capabilities["extra"] = worker["${extra}"];
capabilities["isColor"] = "true";
capabilities["letters"] = worker["${letters}"];
capabilities["majorversion"] = worker["${major}"];
capabilities["minorversion"] = worker["${minor}"];
capabilities["screenBitDepth"] = "8";
capabilities["type"] = worker["IE${major}"];
capabilities["version"] = worker["${version}"];
browserCaps.AddBrowser("IE");
this.IeProcessGateways(headers, browserCaps);
this.IebetaProcess(headers, browserCaps);
bool ignoreApplicationBrowsers = true;
if (!this.Ie6to9Process(headers, browserCaps))
{
ignoreApplicationBrowsers = false;
}
this.IeProcessBrowsers(ignoreApplicationBrowsers, headers, browserCaps);
return true;
}
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:37,代码来源:BrowserCapabilitiesFactory.cs
示例7: IemobileProcess
private bool IemobileProcess(NameValueCollection headers, HttpBrowserCapabilities browserCaps)
{
IDictionary capabilities = browserCaps.Capabilities;
string target = browserCaps[string.Empty];
RegexWorker worker = new RegexWorker(browserCaps);
if (!worker.ProcessRegex(target, @"IEMobile.(?'version'(?'major'\d+)(\.(?'minor'\d+)?)\w*)"))
{
return false;
}
worker.ProcessRegex(browserCaps[string.Empty], @"MSIE (?'msieMajorVersion'\d+)");
capabilities["layoutEngine"] = "Trident";
capabilities["browser"] = "IEMobile";
capabilities["majorversion"] = worker["${major}"];
capabilities["minorversion"] = worker["${minor}"];
capabilities["type"] = worker["IEMobile${msieMajorVersion}"];
capabilities["isMobileDevice"] = "true";
capabilities["version"] = worker["${version}"];
capabilities["ecmascriptversion"] = "3.0";
capabilities["jscriptversion"] = "5.6";
capabilities["javascript"] = "true";
capabilities["javascriptversion"] = "1.5";
capabilities["msdomversion"] = worker["${majorversion}.${minorversion}"];
capabilities["w3cdomversion"] = "1.0";
capabilities["supportsAccesskeyAttribute"] = "true";
capabilities["tagwriter"] = "System.Web.UI.HtmlTextWriter";
capabilities["cookies"] = "true";
capabilities["frames"] = "true";
capabilities["javaapplets"] = "true";
capabilities["supportsCallback"] = "true";
capabilities["supportsDivNoWrap"] = "false";
capabilities["supportsFileUpload"] = "true";
capabilities["supportsMultilineTextBoxDisplay"] = "true";
capabilities["supportsXmlHttp"] = "true";
capabilities["tables"] = "true";
capabilities["vbscript"] = "true";
capabilities["inputType"] = "virtualKeyboard";
capabilities["numberOfSoftkeys"] = "2";
browserCaps.AddBrowser("IEMobile");
this.IemobileProcessGateways(headers, browserCaps);
this.MonoProcess(headers, browserCaps);
this.PixelsProcess(headers, browserCaps);
this.OsProcess(headers, browserCaps);
this.CpuProcess(headers, browserCaps);
this.VoiceProcess(headers, browserCaps);
bool ignoreApplicationBrowsers = false;
this.IemobileProcessBrowsers(ignoreApplicationBrowsers, headers, browserCaps);
return true;
}
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:48,代码来源:BrowserCapabilitiesFactory.cs
示例8: Ie8Process
private bool Ie8Process(NameValueCollection headers, HttpBrowserCapabilities browserCaps)
{
IDictionary capabilities = browserCaps.Capabilities;
string target = (string) capabilities["majorversion"];
RegexWorker worker = new RegexWorker(browserCaps);
if (!worker.ProcessRegex(target, "8"))
{
return false;
}
capabilities["jscriptversion"] = "6.0";
browserCaps.AddBrowser("IE8");
this.Ie8ProcessGateways(headers, browserCaps);
bool ignoreApplicationBrowsers = false;
this.Ie8ProcessBrowsers(ignoreApplicationBrowsers, headers, browserCaps);
return true;
}
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:16,代码来源:BrowserCapabilitiesFactory.cs
示例9: ChromeProcess
private bool ChromeProcess(NameValueCollection headers, HttpBrowserCapabilities browserCaps)
{
IDictionary capabilities = browserCaps.Capabilities;
string target = browserCaps[string.Empty];
RegexWorker worker = new RegexWorker(browserCaps);
if (!worker.ProcessRegex(target, @"Chrome/(?'version'(?'major'\d+)(\.(?'minor'\d+)?)\w*)"))
{
return false;
}
worker.ProcessRegex(browserCaps[string.Empty], @"AppleWebKit/(?'layoutVersion'\d+)");
capabilities["layoutEngine"] = "WebKit";
capabilities["layoutEngineVersion"] = worker["${layoutVersion}"];
capabilities["browser"] = "Chrome";
capabilities["majorversion"] = worker["${major}"];
capabilities["minorversion"] = worker["${minor}"];
capabilities["type"] = worker["Chrome${major}"];
capabilities["version"] = worker["${version}"];
capabilities["ecmascriptversion"] = "3.0";
capabilities["javascript"] = "true";
capabilities["javascriptversion"] = "1.7";
capabilities["w3cdomversion"] = "1.0";
capabilities["supportsAccesskeyAttribute"] = "true";
capabilities["tagwriter"] = "System.Web.UI.HtmlTextWriter";
capabilities["cookies"] = "true";
capabilities["frames"] = "true";
capabilities["javaapplets"] = "true";
capabilities["supportsCallback"] = "true";
capabilities["supportsDivNoWrap"] = "false";
capabilities["supportsFileUpload"] = "true";
capabilities["supportsMaintainScrollPositionOnPostback"] = "true";
capabilities["supportsMultilineTextBoxDisplay"] = "true";
capabilities["supportsXmlHttp"] = "true";
capabilities["tables"] = "true";
browserCaps.AddBrowser("Chrome");
this.ChromeProcessGateways(headers, browserCaps);
bool ignoreApplicationBrowsers = false;
this.ChromeProcessBrowsers(ignoreApplicationBrowsers, headers, browserCaps);
return true;
}
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:39,代码来源:BrowserCapabilitiesFactory.cs
示例10: Ie6to9Process
private bool Ie6to9Process(NameValueCollection headers, HttpBrowserCapabilities browserCaps)
{
IDictionary capabilities = browserCaps.Capabilities;
string target = (string) capabilities["majorversion"];
RegexWorker worker = new RegexWorker(browserCaps);
if (!worker.ProcessRegex(target, @"[6-9]|[1-9]\d+"))
{
return false;
}
capabilities["ecmascriptversion"] = "3.0";
capabilities["jscriptversion"] = "5.6";
capabilities["javascript"] = "true";
capabilities["javascriptversion"] = "1.5";
capabilities["msdomversion"] = worker["${majorversion}.${minorversion}"];
capabilities["w3cdomversion"] = "1.0";
capabilities["ExchangeOmaSupported"] = "true";
capabilities["activexcontrols"] = "true";
capabilities["backgroundsounds"] = "true";
capabilities["cookies"] = "true";
capabilities["frames"] = "true";
capabilities["javaapplets"] = "true";
capabilities["supportsCallback"] = "true";
capabilities["supportsFileUpload"] = "true";
capabilities["supportsMultilineTextBoxDisplay"] = "true";
capabilities["supportsMaintainScrollPositionOnPostback"] = "true";
capabilities["supportsVCard"] = "true";
capabilities["supportsXmlHttp"] = "true";
capabilities["tables"] = "true";
capabilities["supportsAccessKeyAttribute"] = "true";
capabilities["tagwriter"] = "System.Web.UI.HtmlTextWriter";
capabilities["vbscript"] = "true";
browserCaps.AddBrowser("IE6to9");
this.Ie6to9ProcessGateways(headers, browserCaps);
bool ignoreApplicationBrowsers = true;
if (!this.Ie7Process(headers, browserCaps) && !this.Ie8Process(headers, browserCaps))
{
ignoreApplicationBrowsers = false;
}
this.Ie6to9ProcessBrowsers(ignoreApplicationBrowsers, headers, browserCaps);
return true;
}
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:41,代码来源:BrowserCapabilitiesFactory.cs
示例11: GenericdownlevelProcess
private bool GenericdownlevelProcess(NameValueCollection headers, HttpBrowserCapabilities browserCaps)
{
IDictionary capabilities = browserCaps.Capabilities;
string target = browserCaps[string.Empty];
RegexWorker worker = new RegexWorker(browserCaps);
if (!worker.ProcessRegex(target, "^Generic Downlevel$"))
{
return false;
}
capabilities["cookies"] = "false";
capabilities["ecmascriptversion"] = "1.0";
capabilities["tables"] = "true";
capabilities["type"] = "Downlevel";
browserCaps.Adapters["System.Web.UI.WebControls.Menu, System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"] = "System.Web.UI.WebControls.Adapters.MenuAdapter";
browserCaps.AddBrowser("GenericDownlevel");
this.GenericdownlevelProcessGateways(headers, browserCaps);
bool ignoreApplicationBrowsers = false;
this.GenericdownlevelProcessBrowsers(ignoreApplicationBrowsers, headers, browserCaps);
return true;
}
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:20,代码来源:BrowserCapabilitiesFactory.cs
示例12: Firefox3Process
private bool Firefox3Process(NameValueCollection headers, HttpBrowserCapabilities browserCaps)
{
IDictionary capabilities = browserCaps.Capabilities;
string target = (string) capabilities["majorversion"];
RegexWorker worker = new RegexWorker(browserCaps);
if (!worker.ProcessRegex(target, @"[3-9]|[1-9]\d+"))
{
return false;
}
capabilities["javascriptversion"] = "1.8";
capabilities["supportsMaintainScrollPositionOnPostback"] = "true";
browserCaps.AddBrowser("Firefox3");
this.Firefox3ProcessGateways(headers, browserCaps);
bool ignoreApplicationBrowsers = true;
if (!this.Firefox35Process(headers, browserCaps))
{
ignoreApplicationBrowsers = false;
}
this.Firefox3ProcessBrowsers(ignoreApplicationBrowsers, headers, browserCaps);
return true;
}
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:21,代码来源:BrowserCapabilitiesFactory.cs
示例13: Firefox35Process
private bool Firefox35Process(NameValueCollection headers, HttpBrowserCapabilities browserCaps)
{
string target = (string) browserCaps.Capabilities["minorversion"];
RegexWorker worker = new RegexWorker(browserCaps);
if (!worker.ProcessRegex(target, "^[5-9]"))
{
return false;
}
browserCaps.AddBrowser("Firefox35");
this.Firefox35ProcessGateways(headers, browserCaps);
bool ignoreApplicationBrowsers = false;
this.Firefox35ProcessBrowsers(ignoreApplicationBrowsers, headers, browserCaps);
return true;
}
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:14,代码来源:BrowserCapabilitiesFactory.cs
示例14: DefaultProcess
//.........这里部分代码省略.........
capabilities["ecmascriptversion"] = "0.0";
capabilities["frames"] = "false";
capabilities["gatewayMajorVersion"] = "0";
capabilities["gatewayMinorVersion"] = "0";
capabilities["gatewayVersion"] = "None";
capabilities["hasBackButton"] = "true";
capabilities["hidesRightAlignedMultiselectScrollbars"] = "false";
capabilities["inputType"] = "telephoneKeypad";
capabilities["isColor"] = "false";
capabilities["isMobileDevice"] = "false";
capabilities["javaapplets"] = "false";
capabilities["jscriptversion"] = "0.0";
capabilities["javascript"] = "false";
capabilities["majorversion"] = "0";
capabilities["maximumHrefLength"] = "10000";
capabilities["maximumRenderedPageSize"] = "2000";
capabilities["maximumSoftkeyLabelLength"] = "5";
capabilities["minorversion"] = "0";
capabilities["mobileDeviceManufacturer"] = "Unknown";
capabilities["mobileDeviceModel"] = "Unknown";
capabilities["msdomversion"] = "0.0";
capabilities["numberOfSoftkeys"] = "0";
capabilities["platform"] = "Unknown";
capabilities["preferredImageMime"] = "image/gif";
capabilities["preferredRenderingMime"] = "text/html";
capabilities["preferredRenderingType"] = "html32";
capabilities["rendersBreakBeforeWmlSelectAndInput"] = "false";
capabilities["rendersBreaksAfterHtmlLists"] = "true";
capabilities["rendersBreaksAfterWmlAnchor"] = "false";
capabilities["rendersBreaksAfterWmlInput"] = "false";
capabilities["rendersWmlDoAcceptsInline"] = "true";
capabilities["rendersWmlSelectsAsMenuCards"] = "false";
capabilities["requiredMetaTagNameValue"] = "";
capabilities["requiresAbsolutePostbackUrl"] = "false";
capabilities["requiresAdaptiveErrorReporting"] = "false";
capabilities["requiresAttributeColonSubstitution"] = "false";
capabilities["requiresContentTypeMetaTag"] = "false";
capabilities["requiresControlStateInSession"] = "false";
capabilities["requiresDBCSCharacter"] = "false";
capabilities["requiresFullyQualifiedRedirectUrl"] = "false";
capabilities["requiresLeadingPageBreak"] = "false";
capabilities["requiresNoBreakInFormatting"] = "false";
capabilities["requiresOutputOptimization"] = "false";
capabilities["requiresPhoneNumbersAsPlainText"] = "false";
capabilities["requiresPostRedirectionHandling"] = "false";
capabilities["requiresSpecialViewStateEncoding"] = "false";
capabilities["requiresUniqueFilePathSuffix"] = "false";
capabilities["requiresUniqueHtmlCheckboxNames"] = "false";
capabilities["requiresUniqueHtmlInputNames"] = "false";
capabilities["requiresUrlEncodedPostfieldValues"] = "false";
capabilities["requiresXhtmlCssSuppression"] = "false";
capabilities["screenBitDepth"] = "1";
capabilities["supportsAccesskeyAttribute"] = "false";
capabilities["supportsBodyColor"] = "true";
capabilities["supportsBold"] = "false";
capabilities["supportsCallback"] = "false";
capabilities["supportsCacheControlMetaTag"] = "true";
capabilities["supportsCss"] = "false";
capabilities["supportsDivAlign"] = "true";
capabilities["supportsDivNoWrap"] = "false";
capabilities["supportsEmptyStringInCookieValue"] = "true";
capabilities["supportsFileUpload"] = "false";
capabilities["supportsFontColor"] = "true";
capabilities["supportsFontName"] = "false";
capabilities["supportsFontSize"] = "false";
capabilities["supportsImageSubmit"] = "false";
capabilities["supportsIModeSymbols"] = "false";
capabilities["supportsInputIStyle"] = "false";
capabilities["supportsInputMode"] = "false";
capabilities["supportsItalic"] = "false";
capabilities["supportsJPhoneMultiMediaAttributes"] = "false";
capabilities["supportsJPhoneSymbols"] = "false";
capabilities["SupportsMaintainScrollPositionOnPostback"] = "false";
capabilities["supportsMultilineTextBoxDisplay"] = "false";
capabilities["supportsQueryStringInFormAction"] = "true";
capabilities["supportsRedirectWithCookie"] = "true";
capabilities["supportsSelectMultiple"] = "true";
capabilities["supportsUncheck"] = "true";
capabilities["supportsVCard"] = "false";
capabilities["tables"] = "false";
capabilities["tagwriter"] = "System.Web.UI.Html32TextWriter";
capabilities["type"] = "Unknown";
capabilities["vbscript"] = "false";
capabilities["version"] = "0.0";
capabilities["w3cdomversion"] = "0.0";
capabilities["win16"] = "false";
capabilities["win32"] = "false";
browserCaps.AddBrowser("Default");
this.DefaultProcessGateways(headers, browserCaps);
this.CrawlerProcess(headers, browserCaps);
this.PlatformProcess(headers, browserCaps);
this.WinProcess(headers, browserCaps);
bool ignoreApplicationBrowsers = true;
if ((!this.BlackberryProcess(headers, browserCaps) && !this.OperaProcess(headers, browserCaps)) && (!this.GenericdownlevelProcess(headers, browserCaps) && !this.MozillaProcess(headers, browserCaps)))
{
ignoreApplicationBrowsers = false;
}
this.DefaultProcessBrowsers(ignoreApplicationBrowsers, headers, browserCaps);
return true;
}
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:101,代码来源:BrowserCapabilitiesFactory.cs
示例15: SafariProcess
private bool SafariProcess(NameValueCollection headers, HttpBrowserCapabilities browserCaps)
{
IDictionary capabilities = browserCaps.Capabilities;
string target = browserCaps[string.Empty];
RegexWorker worker = new RegexWorker(browserCaps);
if (!worker.ProcessRegex(target, "Safari"))
{
return false;
}
target = browserCaps[string.Empty];
if (worker.ProcessRegex(target, "Chrome"))
{
return false;
}
worker.ProcessRegex(browserCaps[string.Empty], @"AppleWebKit/(?'layoutVersion'\d+)");
capabilities["layoutEngine"] = "WebKit";
capabilities["layoutEngineVersion"] = worker["${layoutVersion}"];
capabilities["browser"] = "Safari";
capabilities["type"] = "Safari";
browserCaps.AddBrowser("Safari");
this.SafariProcessGateways(headers, browserCaps);
this.IphoneProcess(headers, browserCaps);
this.IpodProcess(headers, browserCaps);
bool ignoreApplicationBrowsers = true;
if (!this.Safari3to4Process(headers, browserCaps))
{
ignoreApplicationBrowsers = false;
}
this.SafariProcessBrowsers(ignoreApplicationBrowsers, headers, browserCaps);
return true;
}
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:31,代码来源:BrowserCapabilitiesFactory.cs