mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-01-17 11:08:06 +00:00
ChatRoom: Fix delete
This commit is contained in:
parent
9912c46e35
commit
840942ca3a
8 changed files with 67 additions and 13 deletions
|
|
@ -46,6 +46,8 @@
|
|||
@property (nonatomic, retain) IBOutlet UIView *messageView;
|
||||
@property (nonatomic, retain) IBOutlet UIImageView *messageBackgroundImage;
|
||||
@property (nonatomic, retain) IBOutlet UIImageView *footerBackgroundImage;
|
||||
@property (nonatomic, retain) IBOutlet UITapGestureRecognizer *listTapGestureRecognizer;
|
||||
|
||||
@property (nonatomic, copy) NSString *remoteAddress;
|
||||
|
||||
- (IBAction)onBackClick:(id)event;
|
||||
|
|
|
|||
|
|
@ -37,6 +37,7 @@
|
|||
@synthesize messageView;
|
||||
@synthesize messageBackgroundImage;
|
||||
@synthesize footerBackgroundImage;
|
||||
@synthesize listTapGestureRecognizer;
|
||||
|
||||
|
||||
#pragma mark - Lifecycle Functions
|
||||
|
|
@ -63,6 +64,7 @@
|
|||
[messageView release];
|
||||
[messageBackgroundImage release];
|
||||
[footerBackgroundImage release];
|
||||
[listTapGestureRecognizer release];
|
||||
[super dealloc];
|
||||
}
|
||||
|
||||
|
|
@ -292,6 +294,15 @@ static void message_status(LinphoneChatMessage* msg,LinphoneChatMessageState sta
|
|||
|
||||
#pragma mark - UITextFieldDelegate Functions
|
||||
|
||||
- (BOOL)growingTextViewShouldBeginEditing:(HPGrowingTextView *)growingTextView {
|
||||
if(editButton.selected) {
|
||||
[tableController setEditing:FALSE animated:TRUE];
|
||||
[editButton setOff];
|
||||
[listTapGestureRecognizer setEnabled:TRUE];
|
||||
}
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
- (void)growingTextView:(HPGrowingTextView *)growingTextView willChangeHeight:(float)height {
|
||||
int diff = height - growingTextView.bounds.size.height;
|
||||
|
||||
|
|
@ -323,6 +334,7 @@ static void message_status(LinphoneChatMessage* msg,LinphoneChatMessageState sta
|
|||
}
|
||||
|
||||
- (IBAction)onEditClick:(id)event {
|
||||
[listTapGestureRecognizer setEnabled:[tableController isEditing]];
|
||||
[tableController setEditing:![tableController isEditing] animated:TRUE];
|
||||
[messageField resignFirstResponder];
|
||||
}
|
||||
|
|
|
|||
|
|
@ -205,7 +205,7 @@ static UIFont *CELL_FONT = nil;
|
|||
|
||||
#pragma mark - Action Functions
|
||||
|
||||
- (IBAction)onDeleteClick: (id) event {
|
||||
- (IBAction)onDeleteClick:(id)event {
|
||||
if(chat != NULL) {
|
||||
UIView *view = [self superview];
|
||||
// Find TableViewCell
|
||||
|
|
|
|||
|
|
@ -117,6 +117,7 @@
|
|||
<string key="NSReuseIdentifierKey">_NS:9</string>
|
||||
<reference key="IBUIBackgroundColor" ref="765717609"/>
|
||||
<bool key="IBUIClipsSubviews">YES</bool>
|
||||
<bool key="IBUIUserInteractionEnabled">NO</bool>
|
||||
<string key="targetRuntimeIdentifier">IBCocoaTouchFramework</string>
|
||||
</object>
|
||||
<object class="IBUILabel" id="504194589">
|
||||
|
|
@ -334,7 +335,7 @@
|
|||
<reference key="destination" ref="841351856"/>
|
||||
<int key="IBEventType">7</int>
|
||||
</object>
|
||||
<int key="connectionID">20</int>
|
||||
<int key="connectionID">32</int>
|
||||
</object>
|
||||
</array>
|
||||
<object class="IBMutableOrderedSet" key="objectRecords">
|
||||
|
|
@ -447,7 +448,7 @@
|
|||
<string key="16.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string key="18.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<real value="2" key="18.IBUIButtonInspectorSelectedEdgeInsetMetadataKey"/>
|
||||
<real value="1" key="18.IBUIButtonInspectorSelectedStateConfigurationMetadataKey"/>
|
||||
<real value="0.0" key="18.IBUIButtonInspectorSelectedStateConfigurationMetadataKey"/>
|
||||
<string key="2.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string key="22.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
<string key="26.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
|
||||
|
|
@ -461,7 +462,7 @@
|
|||
<nil key="activeLocalization"/>
|
||||
<dictionary class="NSMutableDictionary" key="localizations"/>
|
||||
<nil key="sourceID"/>
|
||||
<int key="maxID">31</int>
|
||||
<int key="maxID">32</int>
|
||||
</object>
|
||||
<object class="IBClassDescriber" key="IBDocument.Classes">
|
||||
<array class="NSMutableArray" key="referencedPartialClassDescriptions">
|
||||
|
|
|
|||
|
|
@ -492,6 +492,14 @@
|
|||
</object>
|
||||
<int key="connectionID">70</int>
|
||||
</object>
|
||||
<object class="IBConnectionRecord">
|
||||
<object class="IBCocoaTouchOutletConnection" key="connection">
|
||||
<string key="label">listTapGestureRecognizer</string>
|
||||
<reference key="source" ref="372490531"/>
|
||||
<reference key="destination" ref="148818944"/>
|
||||
</object>
|
||||
<int key="connectionID">71</int>
|
||||
</object>
|
||||
<object class="IBConnectionRecord">
|
||||
<object class="IBCocoaTouchOutletConnection" key="connection">
|
||||
<string key="label">dataSource</string>
|
||||
|
|
@ -761,7 +769,7 @@
|
|||
<nil key="activeLocalization"/>
|
||||
<dictionary class="NSMutableDictionary" key="localizations"/>
|
||||
<nil key="sourceID"/>
|
||||
<int key="maxID">70</int>
|
||||
<int key="maxID">71</int>
|
||||
</object>
|
||||
<object class="IBClassDescriber" key="IBDocument.Classes">
|
||||
<array class="NSMutableArray" key="referencedPartialClassDescriptions">
|
||||
|
|
@ -813,6 +821,7 @@
|
|||
<string key="footerBackgroundImage">UIImageView</string>
|
||||
<string key="footerView">UIView</string>
|
||||
<string key="headerView">UIView</string>
|
||||
<string key="listTapGestureRecognizer">UITapGestureRecognizer</string>
|
||||
<string key="messageBackgroundImage">UIImageView</string>
|
||||
<string key="messageField">HPGrowingTextView</string>
|
||||
<string key="messageView">UIView</string>
|
||||
|
|
@ -848,6 +857,10 @@
|
|||
<string key="name">headerView</string>
|
||||
<string key="candidateClassName">UIView</string>
|
||||
</object>
|
||||
<object class="IBToOneOutletInfo" key="listTapGestureRecognizer">
|
||||
<string key="name">listTapGestureRecognizer</string>
|
||||
<string key="candidateClassName">UITapGestureRecognizer</string>
|
||||
</object>
|
||||
<object class="IBToOneOutletInfo" key="messageBackgroundImage">
|
||||
<string key="name">messageBackgroundImage</string>
|
||||
<string key="candidateClassName">UIImageView</string>
|
||||
|
|
|
|||
|
|
@ -474,6 +474,14 @@
|
|||
</object>
|
||||
<int key="connectionID">70</int>
|
||||
</object>
|
||||
<object class="IBConnectionRecord">
|
||||
<object class="IBCocoaTouchOutletConnection" key="connection">
|
||||
<string key="label">listTapGestureRecognizer</string>
|
||||
<reference key="source" ref="372490531"/>
|
||||
<reference key="destination" ref="148818944"/>
|
||||
</object>
|
||||
<int key="connectionID">71</int>
|
||||
</object>
|
||||
<object class="IBConnectionRecord">
|
||||
<object class="IBCocoaTouchOutletConnection" key="connection">
|
||||
<string key="label">dataSource</string>
|
||||
|
|
@ -743,7 +751,7 @@
|
|||
<nil key="activeLocalization"/>
|
||||
<dictionary class="NSMutableDictionary" key="localizations"/>
|
||||
<nil key="sourceID"/>
|
||||
<int key="maxID">70</int>
|
||||
<int key="maxID">71</int>
|
||||
</object>
|
||||
<object class="IBClassDescriber" key="IBDocument.Classes">
|
||||
<array class="NSMutableArray" key="referencedPartialClassDescriptions">
|
||||
|
|
@ -795,6 +803,7 @@
|
|||
<string key="footerBackgroundImage">UIImageView</string>
|
||||
<string key="footerView">UIView</string>
|
||||
<string key="headerView">UIView</string>
|
||||
<string key="listTapGestureRecognizer">UITapGestureRecognizer</string>
|
||||
<string key="messageBackgroundImage">UIImageView</string>
|
||||
<string key="messageField">HPGrowingTextView</string>
|
||||
<string key="messageView">UIView</string>
|
||||
|
|
@ -830,6 +839,10 @@
|
|||
<string key="name">headerView</string>
|
||||
<string key="candidateClassName">UIView</string>
|
||||
</object>
|
||||
<object class="IBToOneOutletInfo" key="listTapGestureRecognizer">
|
||||
<string key="name">listTapGestureRecognizer</string>
|
||||
<string key="candidateClassName">UITapGestureRecognizer</string>
|
||||
</object>
|
||||
<object class="IBToOneOutletInfo" key="messageBackgroundImage">
|
||||
<string key="name">messageBackgroundImage</string>
|
||||
<string key="candidateClassName">UIImageView</string>
|
||||
|
|
|
|||
|
|
@ -212,17 +212,17 @@
|
|||
<dict>
|
||||
<key>backup</key>
|
||||
<dict>
|
||||
<key>10</key>
|
||||
<key>11</key>
|
||||
<dict>
|
||||
<key>class</key>
|
||||
<string>BLWrapperHandle</string>
|
||||
<key>name</key>
|
||||
<string>Classes/ChatRoomViewController/10/ChatRoomViewController.xib</string>
|
||||
<string>Classes/ChatRoomViewController/11/ChatRoomViewController.xib</string>
|
||||
</dict>
|
||||
</dict>
|
||||
</dict>
|
||||
<key>change date</key>
|
||||
<date>2012-09-13T15:16:23Z</date>
|
||||
<date>2012-09-13T16:01:39Z</date>
|
||||
<key>changed values</key>
|
||||
<array/>
|
||||
<key>class</key>
|
||||
|
|
@ -232,7 +232,7 @@
|
|||
<key>flags</key>
|
||||
<integer>0</integer>
|
||||
<key>hash</key>
|
||||
<string>17cff3d2e83eebab4ab29a3d6e6361ce
|
||||
<string>1017e47ad2fcb46b91d384f53e88bb41
|
||||
</string>
|
||||
<key>name</key>
|
||||
<string>ChatRoomViewController.xib</string>
|
||||
|
|
@ -443,9 +443,9 @@
|
|||
<key>versions</key>
|
||||
<dict>
|
||||
<key>en</key>
|
||||
<string>10</string>
|
||||
<string>11</string>
|
||||
<key>fr</key>
|
||||
<string>10</string>
|
||||
<string>11</string>
|
||||
</dict>
|
||||
</dict>
|
||||
<dict>
|
||||
|
|
|
|||
|
|
@ -492,6 +492,14 @@
|
|||
</object>
|
||||
<int key="connectionID">70</int>
|
||||
</object>
|
||||
<object class="IBConnectionRecord">
|
||||
<object class="IBCocoaTouchOutletConnection" key="connection">
|
||||
<string key="label">listTapGestureRecognizer</string>
|
||||
<reference key="source" ref="372490531"/>
|
||||
<reference key="destination" ref="148818944"/>
|
||||
</object>
|
||||
<int key="connectionID">71</int>
|
||||
</object>
|
||||
<object class="IBConnectionRecord">
|
||||
<object class="IBCocoaTouchOutletConnection" key="connection">
|
||||
<string key="label">dataSource</string>
|
||||
|
|
@ -761,7 +769,7 @@
|
|||
<nil key="activeLocalization"/>
|
||||
<dictionary class="NSMutableDictionary" key="localizations"/>
|
||||
<nil key="sourceID"/>
|
||||
<int key="maxID">70</int>
|
||||
<int key="maxID">71</int>
|
||||
</object>
|
||||
<object class="IBClassDescriber" key="IBDocument.Classes">
|
||||
<array class="NSMutableArray" key="referencedPartialClassDescriptions">
|
||||
|
|
@ -813,6 +821,7 @@
|
|||
<string key="footerBackgroundImage">UIImageView</string>
|
||||
<string key="footerView">UIView</string>
|
||||
<string key="headerView">UIView</string>
|
||||
<string key="listTapGestureRecognizer">UITapGestureRecognizer</string>
|
||||
<string key="messageBackgroundImage">UIImageView</string>
|
||||
<string key="messageField">HPGrowingTextView</string>
|
||||
<string key="messageView">UIView</string>
|
||||
|
|
@ -848,6 +857,10 @@
|
|||
<string key="name">headerView</string>
|
||||
<string key="candidateClassName">UIView</string>
|
||||
</object>
|
||||
<object class="IBToOneOutletInfo" key="listTapGestureRecognizer">
|
||||
<string key="name">listTapGestureRecognizer</string>
|
||||
<string key="candidateClassName">UITapGestureRecognizer</string>
|
||||
</object>
|
||||
<object class="IBToOneOutletInfo" key="messageBackgroundImage">
|
||||
<string key="name">messageBackgroundImage</string>
|
||||
<string key="candidateClassName">UIImageView</string>
|
||||
Loading…
Add table
Reference in a new issue