Applescript 中的非阻塞对话框 [英] Non-blocking Dialog box in Applescript

查看:27
本文介绍了Applescript 中的非阻塞对话框的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我必须编写一个小脚本来为我们的应用程序部署补丁.补丁将替换应用程序中的几个文件.我决定使用 Applescript 部署补丁.要复制的文件很大,复制文件需要一些时间.我想知道是否有任何方法可以获得一个对话框,它不会阻止脚本的执行,以便我可以在应用补丁时显示一些消息,如更新...等,然后在病房之后关闭对话框.

I have to write a small script to deploy a patch for our Application. The patch will replace a couple of files in the application.I decided to depploy the patch using Applescript. The files to be copied are quite large and it takes some time for the files to be copied. I wanted to know if there is any way I can get a dialog box which doesn't block the execution of the script so that I can display some message like Updating.. etc while the patch is applied and then close the dialog box after wards.

谢谢希瓦普拉萨德

推荐答案

有一个名为 Akua Sweets(旧但好用)的脚本添加项,它有一个显示进度命令.在 osaxen.com 上获取.它位于页面顶部的最受欢迎"部分.

There's a scripting addition called Akua Sweets (oldy but goody) that has a display progress command. Get it at osaxen.com. it's in the 'most popular' section at the top of the page.

编辑哦,臭虫,这仅适用于 OS9.它在当时真的很有用,我记得我经常使用它(当然,在那些日子里,一切都需要更长的时间,所以进度条的需求量更大).

edit Oh, bugger, that's only for OS9. It was really useful back in the day, I remember using it a lot (of course everything took a lot longer in those days so progress bars were more in demand).

另一个编辑你给了我灵感,我使用了几个需要进度条的脚本,所以我去寻找并在 http://osaxen.com/files/extrasuites1.1.html

another edit You got me inspired, there's a couple of scripts I use that need progress bars, so I went looking and found this scripting addition at http://osaxen.com/files/extrasuites1.1.html

一次又一次这里是基本教程,了解如何操作它在界面生成器中.我认为这可能是正确的方法.

and again here's a basic tutorial for how to do it in interface builder. I think that's probably the right way to do it.

这篇关于Applescript 中的非阻塞对话框的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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