Skip to content
This repository has been archived by the owner on May 1, 2024. It is now read-only.

[Android] Add null check to prevent crashes when long clicking a text entry in ListView header/footer #271

Merged
merged 1 commit into from
Aug 2, 2016

Conversation

pauldipietro
Copy link
Contributor

@pauldipietro pauldipietro commented Jul 27, 2016

Description of Change

When a text entry control (Entry, Editor, SearchBar, etc.) was being used in the header or footer of a ListView on Android, a long click/press would cause a crash. This was occurring in the HandleContextMode method because it expected to be a cell. Adding a null check and breaking out of the method if the value from GetCellForPosition is null prevents this crash from occurring.

Bugs Fixed

https://bugzilla.xamarin.com/show_bug.cgi?id=40858

API Changes

None

Behavioral Changes

None

PR Checklist

  • Has tests (if omitted, state reason in description)
  • Rebased on top of master at time of PR
  • Changes adhere to coding standard
  • Consolidate commits as makes sense

… entry in ListView header/footer

When a text entry control (Entry, Editor, SearchBar, etc.) was being used in the header or
footer of a ListView on Android, a long click/press would cause a crash. This was occurring
in the HandleContextMode method because it expected to be a cell. Adding a null check and
breaking out of the method if the value from GetCellForPosition is null prevents this crash
from occurring.
@samhouts
Copy link
Member

👍 with passing UI tests

@StephaneDelcroix
Copy link
Member

👍

@samhouts samhouts merged commit ac44cf9 into master Aug 2, 2016
@samhouts samhouts deleted the fix-bugzilla40858 branch August 2, 2016 16:15
@toksdotdev
Copy link

                                                                                                                                                                                                                                                                                                                                                                                                                          Sent from my BlackBerry 10 smartphone.                                                                                                                                                                                                                From: Samantha HoutsSent: Tuesday, August 2, 2016 5:15 PMTo: xamarin/Xamarin.FormsReply To: xamarin/Xamarin.FormsSubject: Re: [xamarin/Xamarin.Forms] [Android] Add null check to prevent crashes when long clicking a text entry in ListView header/footer (#271)Merged #271.

—You are receiving this because you are subscribed to this thread.Reply to this email directly, view it on GitHub, or mute the thread.

@samhouts samhouts added this to the 2.3.2 milestone Jun 27, 2018
myroot added a commit to myroot/Xamarin.Forms that referenced this pull request Feb 24, 2019
* Tizen CollectionView implementation initial commit

 - first working version
 - only support LinearLayout(listview)

* Add more feature

 * Implement INotifyCollectionChanged
 * Implement EmptyView

* Implemnt SnapPoints, ScrollTo

* Fix MakeVisible option

* Add GridLayoutManager (xamarin#271)

* Fix GetScrollCanvasSize issue

* Enhance ItemAdaptor

 - Measure Item size with data binding
  Item size is determined with first item
 - Extract ItemDefaultTemplateAdaptor from ItemTemplateAdaptor

* Remove debug message

* Implement SelectableItemsView

* Fix ghost view issue

* Fix TV profile button effect issue

* Clean up code space and refactoring ScrollTo method
rmarinho pushed a commit that referenced this pull request Mar 14, 2019
* [Tizen] Add CollectionView Tizen Renderer (#259)

* Tizen CollectionView implementation initial commit

 - first working version
 - only support LinearLayout(listview)

* Add more feature

 * Implement INotifyCollectionChanged
 * Implement EmptyView

* Implemnt SnapPoints, ScrollTo

* Fix MakeVisible option

* Add GridLayoutManager (#271)

* Fix GetScrollCanvasSize issue

* Enhance ItemAdaptor

 - Measure Item size with data binding
  Item size is determined with first item
 - Extract ItemDefaultTemplateAdaptor from ItemTemplateAdaptor

* Remove debug message

* Implement SelectableItemsView

* Fix ghost view issue

* Fix TV profile button effect issue

* Clean up code space and refactoring ScrollTo method

* Fix collectionView emptyview (#277)
adrianknight89 pushed a commit to adrianknight89/Xamarin.Forms that referenced this pull request Mar 29, 2019
…n#3172

* [Tizen] Add CollectionView Tizen Renderer (xamarin#259)

* Tizen CollectionView implementation initial commit

 - first working version
 - only support LinearLayout(listview)

* Add more feature

 * Implement INotifyCollectionChanged
 * Implement EmptyView

* Implemnt SnapPoints, ScrollTo

* Fix MakeVisible option

* Add GridLayoutManager (xamarin#271)

* Fix GetScrollCanvasSize issue

* Enhance ItemAdaptor

 - Measure Item size with data binding
  Item size is determined with first item
 - Extract ItemDefaultTemplateAdaptor from ItemTemplateAdaptor

* Remove debug message

* Implement SelectableItemsView

* Fix ghost view issue

* Fix TV profile button effect issue

* Clean up code space and refactoring ScrollTo method

* Fix collectionView emptyview (xamarin#277)
codemillmatt pushed a commit to codemillmatt/Xamarin.Forms that referenced this pull request Apr 19, 2019
…n#3172

* [Tizen] Add CollectionView Tizen Renderer (xamarin#259)

* Tizen CollectionView implementation initial commit

 - first working version
 - only support LinearLayout(listview)

* Add more feature

 * Implement INotifyCollectionChanged
 * Implement EmptyView

* Implemnt SnapPoints, ScrollTo

* Fix MakeVisible option

* Add GridLayoutManager (xamarin#271)

* Fix GetScrollCanvasSize issue

* Enhance ItemAdaptor

 - Measure Item size with data binding
  Item size is determined with first item
 - Extract ItemDefaultTemplateAdaptor from ItemTemplateAdaptor

* Remove debug message

* Implement SelectableItemsView

* Fix ghost view issue

* Fix TV profile button effect issue

* Clean up code space and refactoring ScrollTo method

* Fix collectionView emptyview (xamarin#277)
AxelUser pushed a commit to AxelUser/Xamarin.Forms that referenced this pull request Jun 15, 2019
…n#3172

* [Tizen] Add CollectionView Tizen Renderer (xamarin#259)

* Tizen CollectionView implementation initial commit

 - first working version
 - only support LinearLayout(listview)

* Add more feature

 * Implement INotifyCollectionChanged
 * Implement EmptyView

* Implemnt SnapPoints, ScrollTo

* Fix MakeVisible option

* Add GridLayoutManager (xamarin#271)

* Fix GetScrollCanvasSize issue

* Enhance ItemAdaptor

 - Measure Item size with data binding
  Item size is determined with first item
 - Extract ItemDefaultTemplateAdaptor from ItemTemplateAdaptor

* Remove debug message

* Implement SelectableItemsView

* Fix ghost view issue

* Fix TV profile button effect issue

* Clean up code space and refactoring ScrollTo method

* Fix collectionView emptyview (xamarin#277)
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants