iOS Guides | Samples

MonoTouch.UIKit.UITableViewDelegate Class

A class that receives notifications from a UITableView. MonoTouch developers should generally use UITableViewSource instead of this class.

See Also: UITableViewDelegate

Syntax

[MonoTouch.Foundation.Model]
[MonoTouch.Foundation.Protocol]
[MonoTouch.Foundation.Register("UITableViewDelegate", false)]
public class UITableViewDelegate : UIScrollViewDelegate, IUITableViewDelegate, IDisposable

Remarks

Implementing UITableView often requires subclasses of both UITableViewDataSource and UITableViewDelegate to provide data and behavior for the table view. MonoTouch provides a single class - UITableViewSource - so that only one class needs to be implemented.

The UITableViewDelegate class methods provide a table view with the ability to manage selection, configure section headers and footers, delete and reorder cells and control the editing menu.

Related content

Requirements

Namespace: MonoTouch.UIKit
Assembly: monotouch (in monotouch.dll)
Assembly Versions: 0.0.0.0

The members of MonoTouch.UIKit.UITableViewDelegate are listed below.

See Also: UIScrollViewDelegate

Public Constructors

Default constructor that initializes a new instance of this class with no parameters.
A constructor that initializes the object from the data stored in the unarchiver object.
Constructor to call on derived classes to skip initialization and merely allocate the object.
A constructor used when creating managed representations of unmanaged objects; Called by the runtime.

Public Methods

AccessoryButtonTapped(UITableView, NSIndexPath)
Called when the user taps the DetailDisclosureButton accessory on the row located at indexPath.
AccessoryForRow(UITableView, NSIndexPath) : UITableViewCellAccessory
Deprecated in iOS 3.0. Use UITableViewCell.Accessory and UITableViewCell.AccessoryView when configuring table view cells.
CanFocusRow(UITableView, NSIndexPath) : Boolean
Whether the row at the specified indexPath may receive focus.
CanPerformAction(UITableView, Selector, NSIndexPath, NSObject) : Boolean
Whether the editing menu should omit the Copy or Paste command for the specified row.
CellDisplayingEnded(UITableView, UITableViewCell, NSIndexPath)
Called when a table row is removed from a UITableView (for example, due to scrolling).
CustomizeMoveTarget(UITableView, NSIndexPath, NSIndexPath) : NSIndexPath
Return a new index path to change the final location of a row being moved by the user.
override
DecelerationEnded(UIScrollView)
Called when deceleration has ended (at the end of a scrolling movement).
override
DecelerationStarted(UIScrollView)
Called when deceleration has started (at the end of a scrolling movement).
DidEndEditing(UITableView, NSIndexPath)
Called when the table view has left editing mode for the row specified by indexPath.
DidUpdateFocus(UITableView, UITableViewFocusUpdateContext, UIFocusAnimationCoordinator)
Indicates that the focus changed as detailed in the context.
override
DidZoom(UIScrollView)
Called when the table view is being zoomed.
override
DraggingEnded(UIScrollView, Boolean)
Called when dragging has ended.
override
DraggingStarted(UIScrollView)
Called when dragging is about to begin.
EditActionsForRow(UITableView, NSIndexPath) : UITableViewRowAction[]
Returns an array of row actions to display after the user swipes the row in the tableView table view that is identified by indexPath.
EditingStyleForRow(UITableView, NSIndexPath) : UITableViewCellEditingStyle
Called for each row being displayed by the table view, to determine what editing style to use for that row.
EstimatedHeight(UITableView, NSIndexPath) : Single
The estimated height of the cell at the indexPath.
EstimatedHeightForFooter(UITableView, Int32) : Single
The estimated height of the footer for the specified section.
EstimatedHeightForHeader(UITableView, Int32) : Single
The estimated height of the header for the specified section.
FooterViewDisplayingEnded(UITableView, UIView, Int32)
Called when a section footer view is removed from the table (for instance, due to scrolling).
GetHeightForFooter(UITableView, Int32) : Single
Called to determine the height of the footer for the section specified by section.
GetHeightForHeader(UITableView, Int32) : Single
Called to determine the height of the header for the section specified by section.
GetHeightForRow(UITableView, NSIndexPath) : Single
Called to determine the height of the row at indexPath.
GetIndexPathForPreferredFocusedView(UITableView) : NSIndexPath
The index path of the table's preferred focus view.
GetViewForFooter(UITableView, Int32) : UIView
Returns a view object to display at the end of the given section.
GetViewForHeader(UITableView, Int32) : UIView
Returns a view object to display at the start of the given section.
HeaderViewDisplayingEnded(UITableView, UIView, Int32)
Called when a section header is removed from a table (for instance, due to scrolling).
IndentationLevel(UITableView, NSIndexPath) : Int32
Get the indentation level for the row specified by indexPath.
PerformAction(UITableView, Selector, NSIndexPath, NSObject)
Called to perform a copy or paste operation on the row specified by indexPath.
RowDeselected(UITableView, NSIndexPath)
Called when the row specified by indexPath is de-selected.
RowHighlighted(UITableView, NSIndexPath)
Called when a row is highlighted.
RowSelected(UITableView, NSIndexPath)
Called when the row specified by indexPath is selected.
RowUnhighlighted(UITableView, NSIndexPath)
Called when a row is unhighlighted.
override
ScrollAnimationEnded(UIScrollView)
Called when a scrolling animation in the scroll view is finished.
override
Scrolled(UIScrollView)
Called when the user scrolls the content.
override
ScrolledToTop(UIScrollView)
Called when the scroll view is scrolled to the top of the content.
ShouldHighlightRow(UITableView, NSIndexPath) : Boolean
Called prior to highlighting. If this method returns false, the row will not be highlighted.
ShouldIndentWhileEditing(UITableView, NSIndexPath) : Boolean
Whether the row specified by indexPath should be indented while the table is in edit mode.
override
ShouldScrollToTop(UIScrollView) : Boolean
Called by the scroll view subclass to determine whether it should scroll to the top of the content.
ShouldShowMenu(UITableView, NSIndexPath) : Boolean
Whether the editing menu should be displayed for the row specified by indexPath.
ShouldUpdateFocus(UITableView, UITableViewFocusUpdateContext) : Boolean
Called prior to the tableView either losing or receiving focus. If either focus environment returns false, the focus update is canceled.
TitleForDeleteConfirmation(UITableView, NSIndexPath) : String
Sets the text of the Delete button for the specified row.
override
ViewForZoomingInScrollView(UIScrollView) : UIView
Returns the view to scale when zooming is about to occur in the scroll view.
WillBeginEditing(UITableView, NSIndexPath)
Called when the table view is about to enter swipe-to-delete editing mode.
WillDeselectRow(UITableView, NSIndexPath) : NSIndexPath
Called prior to the de-selection of a row.
WillDisplay(UITableView, UITableViewCell, NSIndexPath)
Called just before a cell is rendered for the row specified by indexPath.
WillDisplayFooterView(UITableView, UIView, Int32)
Called prior to the display of a footer view for a section.
WillDisplayHeaderView(UITableView, UIView, Int32)
Called prior to the display of a header view for a section.
override
WillEndDragging(UIScrollView, PointF, ref PointF)
Called when the user finishes scrolling the content.
WillSelectRow(UITableView, NSIndexPath) : NSIndexPath
Called when a row is about to be selected.
override
ZoomingEnded(UIScrollView, UIView, Single)
Called when content zooming is complete.
override
ZoomingStarted(UIScrollView, UIView)
Called when a zooming operation is about to start.