LuxChat  2.0
Instant messenger for iOS
Instance Methods | List of all members
<JSQMessagesCollectionViewDelegateFlowLayout> Protocol Reference

#import <JSQMessagesCollectionViewDelegateFlowLayout.h>

Inheritance diagram for <JSQMessagesCollectionViewDelegateFlowLayout>:
JSQMessagesViewController ESChatView

Instance Methods

(CGFloat) - collectionView:layout:heightForCellTopLabelAtIndexPath:
 
(CGFloat) - collectionView:layout:heightForMessageBubbleTopLabelAtIndexPath:
 
(CGFloat) - collectionView:layout:heightForCellBottomLabelAtIndexPath:
 
(void) - collectionView:didTapAvatarImageView:atIndexPath:
 
(void) - collectionView:didTapMessageBubbleAtIndexPath:
 
(void) - collectionView:didLongTapMessageBubbleAtIndexPath:
 
(void) - collectionView:didTapCellAtIndexPath:touchLocation:
 
(void) - collectionView:header:didTapLoadEarlierMessagesButton:
 

Detailed Description

The JSQMessagesCollectionViewDelegateFlowLayout protocol defines methods that allow you to manage additional layout information for the collection view and respond to additional actions on its items. The methods of this protocol are all optional.

Method Documentation

- (void) collectionView: (JSQMessagesCollectionView *)  collectionView
didTapAvatarImageView: (UIImageView *)  avatarImageView
atIndexPath: (NSIndexPath *)  indexPath 
optional

Notifies the delegate that the avatar image view at the specified indexPath did receive a tap event.

Parameters
collectionViewThe collection view object that is notifying the delegate of the tap event.
avatarImageViewThe avatar image view that was tapped.
indexPathThe index path of the item for which the avatar was tapped.
- (void) collectionView: (JSQMessagesCollectionView *)  collectionView
didTapCellAtIndexPath: (NSIndexPath *)  indexPath
touchLocation: (CGPoint)  touchLocation 
optional

Notifies the delegate that the cell at the specified indexPath did receive a tap event at the specified touchLocation.

Parameters
collectionViewThe collection view object that is notifying the delegate of the tap event.
indexPathThe index path of the item for which the message bubble was tapped.
touchLocationThe location of the touch event in the cell's coordinate system.
Warning
This method is only called if position is not within the bounds of the cell's avatar image view or message bubble image view. In other words, this method is not called when the cell's avatar or message bubble are tapped. There are separate delegate methods for these two cases.
See also
- collectionView:didTapAvatarImageView:atIndexPath:
collectionView:didTapMessageBubbleAtIndexPath:atIndexPath:
- (void) collectionView: (JSQMessagesCollectionView *)  collectionView
didTapMessageBubbleAtIndexPath: (NSIndexPath *)  indexPath 
optional

Notifies the delegate that the message bubble at the specified indexPath did receive a tap event.

Parameters
collectionViewThe collection view object that is notifying the delegate of the tap event.
indexPathThe index path of the item for which the message bubble was tapped.
- (void) collectionView: (JSQMessagesCollectionView *)  collectionView
header: (JSQMessagesLoadEarlierHeaderView *)  headerView
didTapLoadEarlierMessagesButton: (UIButton *)  sender 
optional

Notifies the delegate that the collection view's header did receive a tap event.

Parameters
collectionViewThe collection view object that is notifying the delegate of the tap event.
headerViewThe header view in the collection view.
senderThe button that was tapped.
- (CGFloat) collectionView: (JSQMessagesCollectionView *)  collectionView
layout: (JSQMessagesCollectionViewFlowLayout *)  collectionViewLayout
heightForCellBottomLabelAtIndexPath: (NSIndexPath *)  indexPath 
optional

Asks the delegate for the height of the cellBottomLabel for the item at the specified indexPath.

Parameters
collectionViewThe collection view object displaying the flow layout.
collectionViewLayoutThe layout object requesting the information.
indexPathThe index path of the item.
Returns
The height of the cellBottomLabel for the item at indexPath.
See also
JSQMessagesCollectionViewCell.
- (CGFloat) collectionView: (JSQMessagesCollectionView *)  collectionView
layout: (JSQMessagesCollectionViewFlowLayout *)  collectionViewLayout
heightForCellTopLabelAtIndexPath: (NSIndexPath *)  indexPath 
optional

Asks the delegate for the height of the cellTopLabel for the item at the specified indexPath.

Parameters
collectionViewThe collection view object displaying the flow layout.
collectionViewLayoutThe layout object requesting the information.
indexPathThe index path of the item.
Returns
The height of the cellTopLabel for the item at indexPath.
See also
JSQMessagesCollectionViewCell.
- (CGFloat) collectionView: (JSQMessagesCollectionView *)  collectionView
layout: (JSQMessagesCollectionViewFlowLayout *)  collectionViewLayout
heightForMessageBubbleTopLabelAtIndexPath: (NSIndexPath *)  indexPath 
optional

Asks the delegate for the height of the messageBubbleTopLabel for the item at the specified indexPath.

Parameters
collectionViewThe collection view object displaying the flow layout.
collectionViewLayoutThe layout object requesting the information.
indexPathThe index path of the item.
Returns
The height of the messageBubbleTopLabel for the item at indexPath.
See also
JSQMessagesCollectionViewCell.

The documentation for this protocol was generated from the following file: