Comments (2)
The reason was simply that the function isn't technically correct. It
implies that there can only be one view with the given class name prefix,
when in fact that's never a constraint. With the UITableView example you
give, indexPathForSelectedRow makes sense for table views where
allowsMultipleSelection == NO as there can only ever be one selected row. A
more correct version of this would be named something like
-firstSubviewWithClassNameorSuperClassNamePrefix:, but under the principle
of "less API is better API" we chose not to add this method. The equivalent
[[view subviewsWithClassNameOrSuperClassNamePrefix:prefix] firstObject] is
only marginally longer and just as clear.
On Wed, Aug 22, 2012 at 2:45 PM, Biclops [email protected] wrote:
I don't understand what is the reason why
subviewWithClassNameOrSuperClassNamePrefix is marked as deprecated. Under
the covers it calls subviewsWithClassNameOrSuperClassNamePrefix, which
returns an array rather than the first instance of a designated class. It
simply puts a nice convenient wrapper around the function to get the first
element in the array.Is it because the keepers of the code, simply don't want to upkeep the
subviewWithClassNameOrSuperClassNamePrefix function?There's plenty of functions that behave in a similar manner in the
Objective C library. One example off the top of my head is for functions
indexPathForSelectedRow, and indexPathsForSelectedRows for UITableView's.—
Reply to this email directly or view it on GitHubhttps://github.com//issues/147.
from kif.
I see. That makes. Thanks for speedy response.
from kif.
Related Issues (20)
- KIF types each character twice HOT 1
- tapView() not working on SwiftUI views in Xcode 12 with KIF 3.8.6 HOT 3
- Xcode 13.4: NSFunctionExpression with selector is forbidden. HOT 11
- KIF-based UI tests crashes in Xcode 13.4 HOT 2
- Question: Does KIF require a mac? HOT 5
- Xcode 14 "Failed to select from Picker" HOT 6
- iOS16 press on keyboard doesn't work HOT 5
- KIF causes exception on using WKWebView HOT 2
- KIF with SwiftUI element HOT 2
- Tappable SwiftUI view that is not tapped by KIF HOT 3
- How to tap on system photo picker #help-wanted HOT 1
- Problems with async test HOT 6
- Way to use Quick6 Nimble11 with KIF UI testing framework
- Screen edge pan gesture is not recognized HOT 8
- [Question/Help] How to write E2E UI Integrations tests? HOT 2
- Is KIF real rendering? HOT 2
- iOS 17 - Entering text using a KIFUITestActor into a text field is broken HOT 2
- [Requirement] Privacy manifest for new sensitive APIs HOT 2
- Black screenshots on test failures on ios 17. HOT 6
- Possibility of intergrating with Swift Test HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from kif.