如何创建一个像kiosk一样的UI,让用户永远不会退出或切换到另一个应用程序? [英] How to create a kiosk-like UI, so that the user can never exit from it or switch to another application?

查看:126
本文介绍了如何创建一个像kiosk一样的UI,让用户永远不会退出或切换到另一个应用程序?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我需要创建一个简单的Delphi应用程序,kiosk样式。

I need to create a simple Delphi application, kiosk style.

这是一个非常简单的事情,一个单一的形式,用户写一些个人信息注册一个事件。 4 TEdit和TButton。

It is a very simple thing, a single form where the user writes some personal info to register to an event. 4 TEdit and a TButton.

我想要实现的是避免用户在输入TEdit或单击TButton时执行任何操作。例如我不希望他做ALT TAB(开关应用程序),按键盘上的Windows键,执行ctrl-alt-canc等...

What I want to achieve is to avoid the user does any action different then typing in TEdit or clicking on the TButton. For example I don't want he does ALT TAB (switchin applications), pressing windows key on keyboard, doing ctrl-alt-canc, etc...

我可以添加一个启用/禁用此Kiosk模式的Passowrd保护按钮,这样我需要退出信息亭模式,只需按该按钮并退出。

I can add a passowrd protected Button that enables/disables this "Kiosk mode", in this way as I need to exit the kiosk mode I simply press that button and exit.

在Delphi中实现这个Kiosk模式,而不是手动截取所有的击键?或者有没有人已经开发出来,以便共享?

How to achieve this "kiosk mode" in Delphi without intercepting all the keystrokes manually? Or did anyone already develop this so it can be shared?

推荐答案

我想你最好创建一个新的桌面,并在其中运行您的应用程序。当您的应用程序完成后,您可以带回用户的桌面。这就是Windows登录屏幕的工作原理。当然,Windows登录屏幕使用特殊的安全桌面。您的应用程序在单独的桌面将被隔离。您将拥有一个没有开始菜单,任务栏或桌面图标的桌面背景,因为explorer.exe没有自动运行。当然,可以使用任务管理器启动新进程,但Windows中的桌面是安全的对象;因此,如果需要,您可以做出限制。当然,如果你的应用程序有足够的权限。

I think you'd better create a new desktop, and run your app in there. When your app is done, you can bring back user's desktop. That is how Windows login screen works. Of course Windows login screen uses a special secure desktop. Your app in a separate desktop would be isolated. You will have a desktop background with no start menu, taskbar, or desktop icons because explorer.exe is not running there automatically. Of course a can start a new process, using Task Manager, but desktops in Windows are securable objects; therefore, you can make restrictions if you want. Of course if your app has sufficient permissions.

要创建一个新的桌面,可以使用 CreateDesktop Windows API,要切换到新创建的桌面,可以使用OpenDesktop功能。

To create a new desktop, you can use CreateDesktop Windows API, and to switch to the newly created desktop, you can use OpenDesktop function.

这篇关于如何创建一个像kiosk一样的UI,让用户永远不会退出或切换到另一个应用程序?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆