Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>The handling of Objective-C <code>Class</code> is mostly hidden in the API provided by MonoTouch. It's mostly the <code>System.Type</code> and <code>description</code> is mostly the <code>ToString</code> - but that won't show some internals.</p> <p>Here's a few things (simple to more complex) you can try:</p> <p>Calling <code>ToString</code> on the <code>view</code> instance <em>might</em> include the original class name (as part of the description) - but it's not the same as calling <code>description</code> of the <code>class</code> itself.</p> <pre><code> foreach (UIView view in cell.Subviews) { if (view.ToString ().Contains ("UITableViewCellReorderControl")) { } } </code></pre> <p>Next try to see if <code>Name</code> on <code>Class</code> is identical to <code>description</code>.</p> <pre><code>foreach (UIView view in cell.Subviews) { MonoTouch.ObjCRuntime.Class c = new MonoTouch.ObjCRuntime.Class (view.GetType ()); if (c.Name == "UITableViewCellReorderControl") { } } </code></pre> <p>Finally really call the <code>description</code> selector on the <code>Class</code> instance. Something like (untried):</p> <pre><code>MonoTouch.ObjCRuntime.Selector description = new MonoTouch.ObjCRuntime.Selector ("description"); foreach (UIView view in cell.Subviews) { MonoTouch.ObjCRuntime.Class c = new MonoTouch.ObjCRuntime.Class (view.GetType ()); var name = NSString.FromHandle (MonoTouch.ObjCRuntime.Messaging.IntPtr_objc_msgSend (c.Handle, description.Handle)); if (name == "UITableViewCellReorderControl") { } } </code></pre>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload