23
Mystery Meat 2.0 Ted Drake, Intuit Accessibility Poonam Tathavadkar, TurboTax CSUN 2017 Slides: slideshare.net/7mary4

Mystery Meat 2.0 – Making hidden mobile interactions accessible

Embed Size (px)

Citation preview

Mystery Meat 2.0

Ted Drake, Intuit Accessibility Poonam Tathavadkar, TurboTax CSUN 2017 Slides: slideshare.net/7mary4

Android Touch and Hold

Android’s Right Click

• Default:Touch and hold

• With TalkBack:Double tap and hold to long press

• Add context-specific menu

Mint Transactions

Developers• onLongClick

Called when a view has been clicked and held.

• Define and Show your menu

• Not for vital interactions. This is a short cut.

iOS 3D Touch

3D Touch

• Peek: Quick glance at relevant information and actions

• Pop: Open full content previewed in the Peek

• Quick Actions: Custom task list from app icon

video of experience

Quick Actions

Developers

• Use accessibilityHint to suggest what’s contained within the Peek

• Don’t make peek the only way to perform an action

• Standard components - Accessible by default

Swipe Revealed Actions

It’s Deductible Actions

editActionsForRowAtIndexPath

• Defines the actions to display in response to swiping the specified row.

• Accessible by default

• Define:

• Target Action and Response

• Visible Text

• Background color

functableView(_tableView:UITableView,commitedi8ngStyle:UITableViewCellEdi8ngStyle,forRowAtindexPath:IndexPath){//Don'tremovethisfunc8on,eventhoughit'sempty.It'srequiredtoalloweditAc8onsForRowAtIndexPathtobecalled.}functableView(_tableView:UITableView,editAc8onsForRowAtindexPath:IndexPath)->[UITableViewRowAc8on]?{letmoreRowAc8on=UITableViewRowAc8on(style:UITableViewRowAc8onStyle.default,8tle:"More",handler:{ac8on,indexpathintableView.setEdi8ng(false,animated:true)letdona8on=self.dona8ons[indexPath.row]letcell=tableView.cellForRow(at:indexPath)!self.shareAc8on(dona8onas!Dona8onEn8ty,cell:cell)});moreRowAc8on.backgroundColor=UXStyle.standardTableRowAc8onColor()letdeleteRowAc8on=UITableViewRowAc8on(style:UITableViewRowAc8onStyle.default/*Destruc8ve*/,8tle:"Delete",handler:{ac8on,indexpathindo{letpreviousDona8onCount=self.dona8ons.countletdona8on=self.dona8ons[indexPath.row]DataAccessor.sharedInstance.addAuditRecord(ac8on:"Dona8ondeleted",details:(dona8onas!Dona8onEn8ty).auditEntryDetails)tryself.deleteDona8on(dona8on)self.loadDona8ons()letnewDona8onCount=self.dona8ons.countifnewDona8onCount==previousDona8onCount-1{self.tableView.deleteRows(at:[indexPath],with:.automa8c)}else{self.tableView.reloadData()}}catchleterror{ErrorHandler.handleErrorWithAlert(errorasNSError,viewController:self)}});return[deleteRowAc8on,moreRowAc8on];}

Swipe Based Navigation

Default Experience

With VoiceOver

Swipe Navigation

• Animated transition between views

• Next and Back flow with every screen

• Eliminates navigation buttons

• No buttons? Accessibility?

• Have I reached the end of the screen?

Detect Accessibility ON

• UIAccessibility kit provides two methods • UIAccessibilityIsSwitchControlRunning • UIAccessibilityIsVoiceOverRunning

• True == Show Navigation Buttons

State Change Notification• User enables VoiceOver while on a screen

• Detect the status change

• UIAccessibilitySwitchControlStatusDidChangeNotification

• UIAccessibilityVoiceOverStatusChanged

• Refresh screen and insert navigation buttons

TurboTax Helper Function• How can we refactor code to detect any

accessibility related settings and address them together?

• Helper function to the rescue !

• NSNotificationCenter adds observers to track any settings that may require us to show buttons.

• This is an OR logic. Example - if voice over OR switch control status changed, display buttons.

Questions and Answers