• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Accessibility
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Accessibility


  • Subject: Re: Accessibility
  • From: Brian Christmas <email@hidden>
  • Date: Fri, 07 Oct 2016 13:28:25 +1100

G’day Bill.

I’ve come to the realization that your snippert always returns true due to the method of my Application Installation.

My App had embedded in it a ‘Scripts’ folder, that contains a number of suplementary Apps, some .pdfs, and several '.scpts’.

On opening my App, from say the desktop, it first trashes a folder ‘Mail Manager’ in the Application folder, creates a new Folder, then copies everything from its embedded ‘Scripts’ folder to the new  folder, or in the case of the scripts, to the Mail Rules folder, and to the Folder Action Folder. Then, finally, it moves itself to the folder, and uses a shell script to close itself, dwell 2 seconds, and then re-opens itself. All moves are with ‘replace’, just in case.

It then uses a routine I’ve written to add a ‘sticky’ Dock Icon, then checks for whether or not it’s Accessibility is true or false, and if false, opens a dialog window, and opens the ‘Accessibilty’ pane. It then cycles until the user has actually turned on accessibilty.

It’s final act, on a new install, is to get the user to select an inbox, and it sets up the mail rule, then it commences running. 
 
Unfortunatel during this process, the Accessibily box for the App is usually always ticked,  and the disloag window warning it must be unticked, and re-ticked.

Because of this fact, your snippet seems to always return ‘true’, whereas my method returns the correct value.

I HAVE to allow for the fact that my end users are Mac illiterate, and EVERYTHING has to be idiot proof. When I had a lot of separate items, and a long installation pdf, it took them forever, and they oftem made mistakes. This procedure seems to be bullet proof, provided they never drag the new App into an existing ‘Applications:Mail Manager’ folder.

I might need to elaborate in my Points.

A thought, I’ll add my routime for creatung the ‘sticky’ Dock Icon to the points.

I’ve tried posting my list to the ‘ObjC list', but it’s too large, and I don’t think the moderators will let it through. If anyone on that list wants a copy sent direct, please email me.

Thanks, & regards

Santa

On 6 Oct. 2016, at 9:16 pm, Bill Cheeseman <email@hidden> wrote:


On Oct 5, 2016, at 11:36 PM, Brian Christmas <email@hidden> wrote:

Some time ago, Bill wrote this as a way of reading the Accessability of a App.

However, under Sierra,  this seems to always return a true....

tell application "System Events" to set GUIScriptingEnabled to UI elements enabled -- read-only in OS X 10.9 Mavericks and newer

It works fine here under macOS v10.12.0 Sierra. You don't say how you're running it, so I have no idea why it would always return true for you.

I am running it in a Script Editor window and reading the value in the Script Editor window's Result pane. I open the Privacy tab in the Security & Privacy pane of System Preferences, select the Accessibility List, authenticate to open the lock, and uncheck Script Editor in the Accessibility list. I then run the script in Script Editor, and it returns false. Then I check Script Editor in the Accessibility list, run the script in Script Editor, and it returns true. All as advertised.

It reports whether accessibility is enabled for the application that is running the script. When you run a script in Script Editor, that is Script Editor. When you run it in some other application or as an applet, that is whatever application is running the script.

-- 

Bill Cheeseman - email@hidden
And what, you ask, was the beginning of it all?
And it is this......
Existence that multiplied itself
For sheer delight of being
And plunged with numberless trillions of forms
So that it might
find
itself
innumerably

Sri Aurobindo



 _______________________________________________
Do not post admin requests to the list. They will be ignored.
applescriptobjc-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >Accessibility (From: Brian Christmas <email@hidden>)

  • Prev by Date: Accessibility
  • Next by Date: Re: Sierra: sound routine no longer works
  • Previous by thread: Accessibility
  • Next by thread: Re: Sierra: sound routine no longer works
  • Index(es):
    • Date
    • Thread