Custom rightField image and target/action for UITextField in a UISearchBar

Originator:christophercjensen
Number:rdar://7667209 Date Originated:19-Feb-2010 04:42 PM
Status:open Resolved:
Product:iPhone SDK Product Version:3.1.3
Classification:Enhancement Reproducible:
 
Summary:
I want to have a custom image and action for the rightView of the UITextField subview in the UISearchBar

Steps to Reproduce:
n/a

Expected Results:
an accesible UIImageView that can be set to any image, and with a user set target/action (see screenshot)

Actual Results:
n/a

Regression:
n/a

Notes:
I currently accomplish this by digging into the UISearchBar's subviews hunting for the UITextField:
	for (id subview in _searchBar.subviews) {
		if ([[[subview class] description] isEqual:@"UISearchBarTextField"]) {
			//add custom info button to textfield
		}
	}

Comments


Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!