summaryrefslogtreecommitdiff
path: root/Xamarin.Forms.Core.UnitTests
AgeCommit message (Collapse)AuthorFilesLines
2017-03-24Clean sync with 2.3.4-2Kangho Hur5-327/+24
Change-Id: I6a7423d2690a1c30f46e0c128d9504a2464f8f0b
2017-03-24Update RelativeLayout to make it respond to constraint changes (#425)Philippe Leybaert1-0/+41
* Update RelativeLayout to make it respond to constraint changes Constraints of a RelativeLayout are bindable properties but the layout does not update when the constraints are updated. This change will invalidate the layout whenever XConstraint, YConstraint, WidthConstraint or HeightConstraint is changed (either in code or through a change in the bound property) * Specified changed handler as named property * Adding attached property accessors for layout properties Since the constraint attached properties can now be updated at runtime, setters are required for those properties. Also, when adding a child view at runtime using the Add() method with x/y/w/h constraints, generating the bounds constraints is deferred to the layout phase. * Unit tests for runtime constraints updates in RelativeLayout * Rename unit test method Rename LayoutChangesAtRuntim() to LayoutIsUpdatedWhenConstraintsChange() * Wrap RelativeLayout update setters in BatchBegin/Commit * Update documentation of RelativeLayout Added SetXConstraint(), SetYConstraint(), SetWidthConstraint() and SetHeightConstraint()
2017-03-24Add pressed and released events to Button (#446)Kangho1-1/+27
* Add pressed and released events to Button * Update ButtonRenderer.cs * Apply safely casting to android button renderer * Use safety casting for Android buttin renderer * [Windows] Fix modal pages being laid out below soft buttons (#395) * Add sample HanselForms and TwitterDemo to ControlGallery (#651) * [Controls] Add Hanselforms sample * Remove extra twitter sample * [Controls]Add TwitterDemo sample * [Controls] Fix build * Slider should show user-set value on initial load (#378) * [UWP] Use toolbar foreground color on primary items (#640) * Avoid duplicating code in OmPlatform (#591) * [iOS] Entry should not pass a newline to the next responder (#397) * UITextField should not return so that the next field does not get passed a newline * Added code sample * [XamlC] import members on x:Static and factories (#642) * [Xaml] support short Properties for PropertyCondition (#645) * Xamlc compile data triggers (#648) * [Xaml] DataTrigger and PropertyCondition no longer use a ServiceProvider * [XamlC] avoid generating ServiceProvider for unused ProvideValue * fix tests * Fix comment typo * [UWP] Fix TextBox style for foreground focus color (#618) * Adding image to use for CellsGalleryImageUrlCellList UI test * Update ImageCellListPage to use an image we control; Update CellsGalleryImageUrlCellList test to wait longer than 1s for images to load if necessary * fix nre when changing content in datepickerselected (#494) * Make CellsGalleryImageUrlCellList test finish early if possible * [iOS] Change keyboard type while keyboard is visible (#443) * Change keyboard while changing text * add sample code * [Android] Fix NavigationPage dispose crash when it parents a MasterDetailPage (#577) * fix navigation page dispose crash * changes after review * [XamlC] detect duplicate x:Name at compile time (#655) * [XamlC] detect duplicate x:Name at compile time * invoking methods with the right arguments produces better results * Make UWP toolbar display rules consistent with other platforms (#638) * Allow subscriber to be collected if MessagingCenter is the only reference to it (#617) * Repro * Make messaging center callbacks weak references * Preserve attribute * Fix test method name * Watch for collection of actual delegate target instead of wrapper delegate * Preserve the original platform instance when changing main page * Better tests for lambda situations * Update tests, make callback target a weakreference if it's the subscriber * Ensure old Platform MessagingCenter subs are gone before creating new Platform * [iOS] Prevent multiple ListView cells from being swiped simultaneously (#578) * disable multiple cell swipe * add sample code * refactored * convert to weakreference * remove null setting * change weakreference setting place * remove if * revert isopen changes * add instructions * [WinRT/UWP] Apply BackgroundColor to Stepper buttons (#581) * [WinRT/UWP] Apply BackgroundColor to Stepper buttons * Add explanatory text; use nameof * Move explanatory text to a label * Return group instead of internal class (#461) * [iOS/Android] Move Map camera to correct region on layout change (#548) * Move to region on layout change * remove visibility check * [iOS] Platform specifics for controlling Picker SelectedIndex change behavior (#540) * picker selected index could change when picker view is dismissed * use enum * [iOS] Ignore intermittent failing test on XTC (#666) * [UITest] Update to UITest 2.0.5 (#665) * Rebase the current branch onto upstream latest
2017-03-24[Core] Added RootPage to NavigationPage (#464)adrianknight891-6/+97
* d * removed whitespace * Using ArgumentNullException * changes
2017-03-24[C] throw meaningful exception on duplicate RD key (#716)Stephane Delcroix1-0/+14
2017-03-24Make MessagingCenter testable (#723)E.Z. Hart1-5/+70
* Make MessagingCenter testable * Eagerly create MessagingCenter instancef * More succinct version
2017-03-24Add default parameter value of zero to INavigationPageController.Peek() (#708)E.Z. Hart1-0/+1
2017-03-24Reduce overhead of pushing existing navigation stack (#672)E.Z. Hart1-12/+77
* Make StackCopy less awkward * Clean up comment * Update docs * Update docs * Replace SecondToLast with an arbitrarily deep Peek method * Update docs * Handle negative depths in Peek()
2017-03-02Backport #793 (#796)Stephane Delcroix1-1/+21
* [Xaml] Fallback to App.Current for DynResources (Previewer) (#793) * [Xaml] Fallback to App.Current for DynResources (Previewer) * [C] avoid NRE and ensure setting the style * remove files committed by accident
2017-01-30Fix overeager subscription cleanup (#712)E.Z. Hart1-0/+18
2017-01-12Fix test failures in Release modebeta-2.3.4-pre1.1E.Z. Hart1-6/+8
2017-01-12[C] new OnPlatform mechanism (#658)Stephane Delcroix4-26/+42
* [C] Obsolete TargetPlatform * [Xaml] support and test the new syntax * blind fix windows platforms
2017-01-10iOS and Android timers should be runnable from any thread and execute… (#374)adrianknight891-51/+0
* iOS and Android timers should be runnable from any thread and executed on the main thread * removing unused Timer class declarations with minor refactoring efforts * iOS and Android timers should be runnable from any thread and executed on the main thread * removing bak file * switch to v7 * add test code
2017-01-03Allow subscriber to be collected if MessagingCenter is the only reference to ↵E.Z. Hart1-1/+166
it (#617) * Repro * Make messaging center callbacks weak references * Preserve attribute * Fix test method name * Watch for collection of actual delegate target instead of wrapper delegate * Preserve the original platform instance when changing main page * Better tests for lambda situations * Update tests, make callback target a weakreference if it's the subscriber * Ensure old Platform MessagingCenter subs are gone before creating new Platform
2016-12-23Xamlc compile data triggers (#648)Stephane Delcroix2-0/+28
* [Xaml] DataTrigger and PropertyCondition no longer use a ServiceProvider * [XamlC] avoid generating ServiceProvider for unused ProvideValue * fix tests
2016-12-07remove the noise while running nunit from consoleStephane Delcroix1-2/+0
2016-12-06[C] detach Behaviors and Triggers on VE finalization (#555)Stephane Delcroix1-1/+41
* [C] detach Behaviors and Triggers on VE finalization * update docs
2016-12-06[Android] ScrollView should send correct ScrollX and ScrollY (#394)adrianknight891-0/+31
* Android should show correct ScrollX and ScrollY when scrolling in both directions * Adding sample code to demonstrate scrolling * Orientation fix * ScrollTo should work for horizontal + vertical scrolling * Get correct scroll x and y values for ScrollOrientation.Both * Convert positions to pixels * Adding unit test to watch out for incorrect animation positioning * automated test * improvements * fixed texts
2016-12-06ResourceDictionary fixes (#536)Stephane Delcroix1-9/+40
* [C] avoid leaking RDs, remove reflection call, validate arguments * [C,Xaml] The only way to get merged values are internal
2016-12-01Don't run Command CanExecute on incorrect inherited binding context type (#572)E.Z. Hart1-1/+99
* Allow Command CanExecute to recover when run on inherited bindingcontext * Make exception handler more generic * Checking types in Command delegates to avoid exception in the first place * Adding type chekc to other Command constructor * Use nameof for ArgumentNullExceptions * Add unit tests for null parameters, handle value types and Nullable<T>
2016-11-16[W] Support 0 as valid BorderWidth (#537)Stephane Delcroix1-1/+1
2016-11-16[C] Use a Binding for ItemsSource object selectionStephane Delcroix1-96/+68
2016-11-16Squashed commit of the following:Joakim Carselind1-20/+468
commit 8d784ec7459335ca33003844a793c3dd266c5861 Author: Joakim Carselind <joakim.carselind@cub.se> Date: Tue Aug 23 00:30:25 2016 +0200 Added DisplayConverter property of type IValueConverter to perform conversion from object to string commit afb606f05c16b14e24785fad017540dd83dbf373 Author: Joakim Carselind <joakim.carselind@cub.se> Date: Tue Aug 23 00:07:55 2016 +0200 Use IsValueType commit 4742c22ed33309f40a55c536b161292eb5db40f8 Author: Joakim Carselind <joakim.carselind@cub.se> Date: Fri Aug 19 18:58:40 2016 +0200 Fixed bug with nested property expression commit 70a121e6172a61dbcf8835137bf58bd972cf2065 Author: Joakim Carselind <joakim.carselind@cub.se> Date: Fri Aug 19 18:43:14 2016 +0200 Added more tests commit 49c7876bda4185c699f5fd9b3a66763efca9623c Author: Joakim Carselind <joakim.carselind@cub.se> Date: Thu Aug 18 13:28:36 2016 +0200 Siimplified setting SelectedItem. Added property to provide full control over how to display the objects by DisplayFunc. Added tests commit 5c1d5e149dc21c58cebf7cdbc6677d1ccec04ed4 Author: Joakim Carselind <joakim.carselind@cub.se> Date: Thu Aug 11 17:15:36 2016 +0200 Trying to fix formatting with tabs instead of spaces commit d64663ce3ef6b223a04d477274e93ec87bd38ff4 Author: Joakim Carselind <joakim.carselind@cub.se> Date: Thu Aug 11 17:10:39 2016 +0200 Formatting. Handle Reset,Move,Replace collection changed action equal by re binding Items collection commit 8d4641810cb3b11fb6b47f8215bb5950a9641ba2 Author: Joakim Carselind <joakim.carselind@cub.se> Date: Thu Aug 11 16:33:03 2016 +0200 Removed inline documentation. Fixed formatting commit 28010a1b31da02879fd2d549d5b02458766544d5 Author: Joakim Carselind <joakim.carselind@cub.se> Date: Thu Aug 11 16:29:37 2016 +0200 Removed SelectedValue since SelectedIndex and SelectedItem make it redundant commit ac9d65816fe6db7b467c304e6dc3168a84d3166b Author: Joakim Carselind <joakim.carselind@cub.se> Date: Thu Aug 11 14:51:20 2016 +0200 Initial attempt on bindable picker
2016-11-16BindingContext changes are called multiple times on app start (#470)adrianknight891-0/+84
* inherited binding context fix * add check for child binding context * Revert "add check for child binding context" This reverts commit 71952f39129cfedc2358a32100deb07bd32a3080. * unit tests
2016-11-15[XamlC] TypedBindings, some tests, a compiler, ... (#489)Stephane Delcroix5-651/+2145
2016-10-25ScrollView should account for Content margin (#392)adrianknight891-0/+54
* ScrollView should account for Content margin * Unit tests for content margin
2016-09-26[C] specify type and default value for native bindings (#376)Stephane Delcroix1-11/+21
2016-09-26[XamlC] Compiled converters (#358)Stephane Delcroix1-1/+1
2016-09-18[Controls] Update Insights and UITest packages and fix warnings (#361)Rui Marinho3-9/+8
* [Controls] Update Insights and UITest packages * Update Xamarin.Forms.Platform.Android (Forwarders).csproj
2016-09-08[Xaml] support native views and native bindings (#266)Stephane Delcroix1-1/+0
Allows including Native views directly in xaml. Support for ios, android, UWP
2016-09-08Native Bindings (#278)Stephane Delcroix2-0/+488
* [C, I, A, W] Support Native Bindings * fix tabs
2016-08-30Fix for ListView BindingContext for Header/Footer (#312)Jonathan Peppers1-0/+37
* ListView - unit test showing BindingContext issue Apparently the BC doesn't pass to Header and Footer * ListView - support for passing BC to header and footer * ListView - test checking BindingContext is set Checking that it works to set the BindingContext first and the Header/Footer after
2016-08-30Platform Specifics (#301)Samantha Houts2-0/+228
* Playing around with how the platform specifics interfaces etc. might work * Sample implementation of iOS navigation translucency * Very slightly reduced code * Better vendor stuff * Drop single-implemenation interfaces * Generics on NavigationPage * On-demand vendor stuff * Remove functionally duplicate classes and make ControlGallery work again * Namespace all the things. XAML test. * Can use Effect to attach platform specific * Attach Effect on PropertyChanging for XAML support! * Rename IConfigPlatform interfaces for readability * Some renaming to match the documents * Split class files * Clear out test-only code * Re-namespace * Added On method to rendered Elements * Allow for removal of platform suffix, convenience methods on specific platforms * Creating a gallery page for specifics * Add rudimentary Platform Specifics gallery; make CollapseStyle work on UWP; Add CollapsedPaneWidth specific property * Toolbar now working with both collapse styles * MDP now displaying Content title; toolbar routing around title * Add a gallery for the iOS NavigationPage stuff * Add Navigation Page as detail page to verify it works with new Toolbar options * Make titlebar/toolbar background colors consistent * ToolbarPlacement now working on NavigationPage * Toolbar Placement working for tabbed and nav pages * Fix bug where phone doesn't get default toolbar placement on start * [Core] Add PS WindowSoftInputModeAdjust [Core] Make Application extendable * Toolbar placement now working on Nav, Tabbed, and Master pages on desktop/phone Remove unnecessary style indirection Fix build errors * [A] Add PlatformConfigurationExtensions * SetSoftInputMode test page * [A] SetSoftInputMode Known issue: Status bar color does not work in AdjustResize mode * [Core] Add PS Blur * [iOS] Configure renderer for blur * Add test page * Move to blur VisualElement for broader support * Move test pages to gallery * Update docs * Use lazy initializer for PlatformConfigurationRegistry
2016-08-16Fix for BindingExpression memory leak (#279)Jonathan Peppers1-0/+27
* Unit test proving a memory leak with Binding What we were seeing in our app was that Binding objects stay around when bound to long-lived ViewModels, even when the View is long gone * BindingExpression - INotifyPropertyChanged should use WeakReference I had to make a WeakPropertyChangedProxy class for this, I could not think of a way to get around creating a new object for this
2016-08-16Invalidate measure of Label when FormattedText changes (#303)Akihiko Odaki1-0/+26
2016-08-10Unit tests for the PCL WeakEventManager (#280)E.Z. Hart2-0/+190
2016-08-09Add the key in the message on throwing a KeyNotFoundException (#282)Rogier van der Hee1-1/+10
* Add the key in the message on throwing a KeyNotFoundException for trying to access an invalid key in the ResourceDictionary. This helps a lot in tracking down what resource is actually missing. * Fix test build, use C# 6 string interpolation
2016-07-11Added PoppedToRootEventArgs to track popped pages when calling PopToRoot (#229)Johan Karlsson1-0/+25
2016-06-17Prep Cell & friends for removal of InternalsVisibleTo (#142)Samantha Houts4-7/+9
* Prep Cell & friends for removal of InternalsVisibleTo Includes: - Cell - EntryCell - ListView - MenuItem - TableView - ViewCell - Toolbar Moved extensions to Internal & removed TPH * Update docs * [Controls] Ignore Issue2411 on iOS <9 * [Controls] Formatting for Issue2411
2016-06-16Prep Page for removal of InternalsVisibleTo (#150)E.Z. Hart9-45/+58
2016-05-25[Android] Implement the AppIndexProvider on non-AppCompact, fix KeyValues ↵Rui Marinho2-0/+43
on AppLinkEntry (#166) * [Android] Set AppIndexingProvider on non AppCompact activity * [Core] Fix AppLinkEntry KeyValues
2016-05-04Add IMasterDetailPageController and update renderers (#146)E.Z. Hart1-10/+10
2016-05-04Add INavigationPageController (#149)E.Z. Hart1-2/+2
2016-05-02Prep VisualElement (and descendants) for removal of InternalsVisibleTo (#141)E.Z. Hart1-1/+2
2016-05-02Prep Image for removal of InternalsVisibleTo (#140)E.Z. Hart1-2/+2
2016-05-02Prep SearchBar for removal of InternalsVisibleTo (#137)E.Z. Hart1-2/+2
2016-04-25Multi style classes (#134)Stephane Delcroix1-9/+46
* [C] StyleClass is IList<string> * fix docs * this might be required
2016-04-25Make core Ticker abstract and public (#116)E.Z. Hart4-4/+34
* Make core Ticker abstract and public Make the core Ticker abstract and public so it can be inherited by platform implementations; remove now-unused parts of original Ticker; add CreateTicker to IPlatformServices; remove unused CreateTimer methods from IPlatformServices * Add docs for Ticker * Remove unnecessary Ticker.Default set * Move Ticker into Internals * Update Ticker docs * Remove old Ticker docs * Remove commented code
2016-04-25Remove ToolBar from Core; Remove ToolBar renderers and unit tests (#124)E.Z. Hart2-145/+0
2016-04-24Enable Warnings as Errors on all plat|cfg of XF.Core.UnitTests (#95)kingces953-5/+13
* Enable Warnings as Errors on all plat|cfg of XF.Core.UnitTests * Fix build errors