加入收藏 | 设为首页 | 会员中心 | 我要投稿 云计算网_泰州站长网 (http://www.0523zz.com/)- 视觉智能、AI应用、CDN、行业物联网、智能数字人!
当前位置: 首页 > 服务器 > 搭建环境 > Windows > 正文

如何在Windows Vista及更高版本上进入Windows Flip 3D模式?

发布时间:2021-05-24 04:11:39 所属栏目:Windows 来源:网络整理
导读:可以通过编程方式在 Windows Vista以上的系统上触发 Flip 3D mode 吗? 它与您手动按CTRL WIN TAB一样 Shell 对象具有可以调用此模式的 WindowSwitcher 方法. 这里是Delphi的代码示例: uses ComObj;procedure EnterWindowSwitcherMode;var Shell: OleVari

可以通过编程方式在 Windows Vista以上的系统上触发 Flip 3D mode吗?

它与您手动按CTRL WIN TAB一样

Shell对象具有可以调用此模式的 WindowSwitcher方法.

这里是Delphi的代码示例:

uses
  ComObj;

procedure EnterWindowSwitcherMode;
var
  Shell: OleVariant;
begin
  try
    Shell := CreateOleObject('Shell.Application');
    Shell.WindowSwitcher;
  finally
    Shell := Unassigned;
  end;
end;

procedure TForm1.Button1Click(Sender: TObject);
begin
  if Win32MajorVersion >= 6 then // are we at least on Windows Vista ?
  begin
    try
      EnterWindowSwitcherMode;
    except
      on E: Exception do
        ShowMessage(E.ClassName + ': ' + E.Message);
    end;
  end;
end;

更新:

或者在这里提到的Norbert Willhelm,还有IShellDispatch5对象接口,实际上引入了WindowSwitcher方法.所以这里是另一个版本的相同…

以下代码需要Shell32_TLB.pas单元,您可以在Delphi中创建这样的方式(请注意,您必须至少具有第一次使用IShellDispatch5界面的Windows Vista):

>转到菜单Component / Import Component
>继续选择导入类型库
>选择Microsoft Shell控件和自动化并完成向导

和代码:

uses
  Shell32_TLB;

procedure EnterWindowSwitcherMode;
var
  // on Windows Vista and Windows 7 (at this time :)
  // is Shell declared as IShellDispatch5 object interface
  AShell: Shell;
begin
  try
    AShell := CoShell.Create;
    AShell.WindowSwitcher;
  finally
    AShell := nil;
  end;
end;

(编辑:云计算网_泰州站长网)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    热点阅读