firefox - Firefox 托管的 xbap 应用程序中的奇怪工具栏

标签 firefox iframe embed xbap

我有一个 xbap 应用程序,它基本上是托管在 WPF 控件中的 Windows 窗体。当我用 Firefox 运行它时,我得到了工具栏,但我似乎无法删除它。如果我直接执行 xbap,此工具栏不会在 IE 中出现,但如果我将 xbap 嵌入到 iframe 中,它就会出现。

alt text

有什么想法如何删除它吗?

最佳答案

使用 Page.ShowsNavigationUI 属性将其隐藏。来自 MSDN Documentation ,您可以在 XAML 中执行此操作:

<Page
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    Title="HomePage"
    ShowsNavigationUI="False"
>


...


</Page>

,或代码:

using System;
using System.Windows;
using System.Windows.Controls;

namespace CSharp
{
    public partial class HomePage : Page
    {
        public HomePage()
        {
            InitializeComponent();

            // Hide host's navigation UI
            this.ShowsNavigationUI = false;
        }
    }
}

此外,在 WPF 集成允许 native 浏览器导航 UI 控制 XBAP 应用程序的浏览器中,工具栏不会出现:

Because WPF does not integrate with the navigation UI for Microsoft Internet Explorer 6, it provides its own navigation UI, which can be shown or hidden by setting ShowsNavigationUI. WPF does integrate with the Windows Internet Explorer 7 navigation UI, so setting ShowsNavigationUI on pages in Windows Internet Explorer 7 has no effect.

关于firefox - Firefox 托管的 xbap 应用程序中的奇怪工具栏,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/2081245/

相关文章:

macos - Mac : reloading document in Chrome or Firefox?

Alpine Docker 镜像中带有 Firefox-ESR 的 Selenium

iOS 嵌入视频,视频在另一个 View 中仍然播放

python - 使用 Python + Selenium 选择 iframe

javascript - 如果 iframe 的内容来自同一域,是否可以使 div 跟随 iframe 内的另一个元素

php - 如何使用 php 在网站上嵌入 youtube channel 视频

twitter-bootstrap - 嵌入式视频显示了另一个视频

javascript - 如何在 javascript firefox 中获取鼠标滚轮事件

javascript - Firefox 缺少 window.event 的解决方法?

html - 如何在响应式 div 中调整模拟智能手机屏幕的大小?