Граф коммитов

43 Коммитов

Автор SHA1 Сообщение Дата
Pavel Yakovlev cceee9ded6 Add TabStop/TabIndex (#2795)
* [Core, UWP, Android] support TabStop/TabIndex

* removing linq

* add iOS / MacOS implementation

* add WPF implementation
fixes UWP implementation

* - addressing comments
- improve test
- optimizations
- added previous tab direction in same tab group

* addressing comments

* [Android] support tabstop for pickers

* - moving shared code to a static class
- removed reflection

* ITabStop -> changed to internal, renamed, added in to fastRenderers

* Update ITabStop to be public
2018-09-12 21:20:46 -07:00
Stephane Delcroix 912ed626db [CSS] add more properties (#3466)
map new CSS properties:
- `color` on `IColorElement` (`ActivityIndicator`, `BoxView`),
  `ProgressBar` and `Switch`
- `row-gap` and `column-gap` on `Grid`
- `transform` and `transform-origin` on `VisualElement`
- `vertical-align` on `Label`

add new XF-specific CSS properties
- `-xf-placeholder` and `-xf-placeholder-color` on `Editor`, `Entry`,
  `SearchBar`
- `-xf-max-length` on `InputView` (`Editor` and `Entry`)
- `-xf-bar-background-color` and `-xf-bar-text-color` on
  `NavigationPage` and `TabbedPage`
- `-xf-orientation` on `ScrollView` and `StackLayout`
- `-xf-horizontal-scroll-bar-visibility` and
  `-xf-vertical-scroll-bar-visibility` on `ScrollView`
- `-xf-min-track-color`, `-xf-max-track-color` and `("-xf-thumb-color`
  on `Slider`
- `-xf-spacing` on `StackLayout`

This PR replaces and closes #3276

- fixes #2891
2018-08-31 11:35:56 -07:00
Stephane Delcroix 5e02ea603d Merge branch '3.1.0' into 3.2.0 2018-08-16 12:28:50 +02:00
Stephane Delcroix 03e14d344a
[C] VisibilityConverter Trims input (#3581)
For CSS purposes, the VisibilityConverter was added, and actually
replaced the `Boolean.Parse(str)` call for parsing Visibility.
`Boolean.Parse()` trims input, and the converter was not, so this was a
regression.
This changes Trim() the input, to be fully backward compatible.

- fixes #3554
2018-08-16 10:27:46 +00:00
Stephane Delcroix 6246b9020e
[C] abstract the Style property in an interface (#3438)
so it's ahsred between VisualElement and span, and retrieving the
property is easier.

- fixes #3314
2018-07-31 11:53:25 +02:00
Stephane Delcroix 2b74434ba0 Merge branch '3.1.0' into 3.2.0 2018-07-30 10:39:09 +02:00
Shane Neuville 72ad5cac3d Remove math on scroll view container for RTL (#3299)
* fixes #3000 remove math on scroll view container for RTL
- setup RTL scrollviews to all start scrolled all the way to the right

* * formatting and renaming fixes

* - don't move scroll if not set to RTL
2018-07-23 11:11:01 -07:00
Stephane Delcroix b79462c9e8
[All] ScaleX and ScaleY (#1280)
* [*] ScaleX and ScaleY

* Use scaleX and scaleY in sendViewBatchUpdate

* use scaleX and scaleY parameters in SendViewBatchUpdate
2018-05-07 14:22:56 +02:00
Rui Marinho 9618f158bb Merge branch '3.0.0' 2018-04-16 11:40:10 +01:00
ShaneN 729a96de90 set ChangeVisualState to internal protected 2018-04-09 15:47:16 -06:00
ShaneN 140371329a Centralizing visual state change checks and providing a method to override if users want to add/control state changes themselves 2018-04-09 15:45:19 -06:00
Rui Marinho 6d090d100f Merge branch '3.0.0' 2018-03-24 14:13:28 +00:00
P3PPP 9e6a5a8735 Fixing bug #2157 CommonState.Focused issue. 2018-03-22 12:15:07 +09:00
Adam e42bd62fb5 [All] Bindable span (#1850)
* Bindable Text Property on Span

* Style applied to Span

* Added style property

* Unit tests added

* Minor fix and cleanup

* Cleanup of code after review

* Updated docs

* Set Parent and reduce calls to Text property

* OneTime Binding

* Allow OneTime Binding as a default

* Updated docs
2018-03-08 15:50:28 -08:00
Rui Marinho 7bab9f46d9
Merge branch '3.0.0' 2018-03-08 11:19:32 +00:00
Jason Smith c17838a599 Reinstate StyleClass but keep @class as requested (#2044) 2018-03-08 10:11:45 +01:00
Jason Smith 90ca928180
Merge branch '3.0.0' 2018-03-06 11:54:19 -08:00
Stephane Delcroix e1170a9e8d [CSS] use `class` instead of `StyleClass` (#2023)
- fixes #2022
2018-03-06 09:45:11 -08:00
Daniel Cazzulino a9a7277ad8 Simplify event raising invocation pattern (#1971)
This is effectively equivalent to the original code, yet nicer to read :)

This is also how it's being done elsewhere (i.e. fast renderers,
BindableObject, etc.), probably because that code is newer?
2018-02-23 22:24:54 -08:00
Rui Marinho ff40c5b4e1
Add netstandard1.0 support (#1649)
* [Core] Add pcl Xamarin.Forms.Core

* [Core] Add Platform PCL

* [Core] Add Xamarin.Forms.Core PCL

* [Core] Use multi target

*  [Nuget,Core] Add pcl back, multi target netstandard1.0 and netstandard2.0

* [Core] Fix ImageSource for non PCL

* Fix uap

* [UWP] Fix references

* Cleaned up the solution file to remove unused platforms (#1770)

* Try don't build Appx

* [Core]Use netstandard1_0 compile directive

* Don't build UWP and WPF on macOS (#1774)

* [Xaml] Fix compile constant

* [Core] Fix Tuple usage

* [Build] Update provisioning 15.5 sr5

* [Core] Use default compile directive for netstandard1.0

* [Nuget] Add uwp dependency to nuspec

* [Nuspec] Fix speling

* [Core] Add support to FlexLayout on netstandard 1.0

* Try fix test

* cleanup

* [Core] Fix netstandard1.0 usage

* [Core] Remove tuple usage FlexLayout, cleanup
2018-02-08 18:18:56 +00:00
Stephane Delcroix 485b345049
[CSS] Apply StyleSheets through Cells (#1547)
Cells, and other Elements, are now part of the hierarchy used
for setting down stylesheets,

fixes #1472
2018-01-10 16:35:44 +01:00
E.Z. Hart 28948d7ef7 VisualStateManager phase 1 (#1405)
* Port from old VSM branch

* Add PS and notes

* Checkpoint: entry text UWP mostly working, need to check on background colors

* Remove irrelevant samples from the EntryDisabledStatesGallery
Make Background color work on UWP Entry with VSM

* Add platform specific for disabling legacy colors on Android

* Add OnPlatform example to visual state manager gallery

* Add example OnIdiom in Visual State Manager

* Add platform specific for disabling legacy color mode on iOS Entry

* Add gallery for Button disabled states
Handling legacy colors for Buttons on Android

* Split out disabled states galleries; disabled legacy handling for Picker

* TimePicker disabled states

* DatePicker color management on Android

* Color management for pre-AppCompat button

* Button legacy color handling on iOS

* Consolidate Platform Specifics;
legacy colors working for iOS Picker and DatePicker

* Fix broken search bar color management
SearchBar color management working with VSM
Add test page for SearchBar disabled color management
Consolidate legacy color management check code into extension method on Android

* Legacy color management for Editor on Android

* Fix legacy color stuff for SearchBar Cancel button on iOS

* C# 7 cleanup

* Add colors for Cancel Button

* Make sure VisualStateGroup collections set by styles are distinct objects

* Validation example

* Make common state names consts

* Make the Windows VSM and Forms VSM work together

* Update galleries for Windows

* Make new methods internal

* Split gallery classes and add more explanation to validation example

* Remove debugging statements

* Add a quick code-only example

* Make legacy color management work for fast button renderer

* Remove old TODO

* Update docs

* Move RunTimeNamePropertyAttribute to Xamarin.Forms.Xaml namespace

* Verify XF namespace when looking for VisualState

* Use nameof

* Make common states constants public

* Cast VisualElement directly so it crashes if the property is set on the wrong type

* Collection -> IList for VisualStateManager

* Setting fromStyle to true

* Remove extraneous `private set`

* Seal VSM classes

* Use constraints instead of ==

* Add teardown method; use constraints rather than ==

* Remove null checking with GetVisualStateGroups

* Don't explicitly initialize collections on elements

* Actually, turns out that fromStyle:false *was* correct

* Direct casts

* Use GetIsDefault check in GoToState

* Validate parents in FindTypeForVisualState

* Validate group and state names on Add

* Fixed check for setter collection

* Fix issues with "duplicate" names when VisualStateGroups declared directly on VisualElements

* Add gallery example for VSGs directly on VisualElements

* Update docs

* Fix bug where initial TextColor isn't set for FastRenderer Button

* Move to explicit VisualStateGroupList in Setter

* Fix return types for unit tests

* Using string.CompareOrdinal in GetState

* Update docs

* Add check for null/empty VisualState Name properties
2018-01-05 09:11:51 +00:00
Stephane Delcroix 5ea86a266b
Stylesheets (#1207)
* [*] Support for CSS StyleSheets

 Parsing, loading, and applying of StyleSheets

 see https://github.com/xamarin/Xamarin.Forms/pull/1207#issue-266464280
 for complete description.

* use initial, not none

* fix tests
2017-12-20 10:47:50 +01:00
Stephane Delcroix 1e98a0ace7
[C] Adding deconstructors for common structs (#1320)
* [C] Adding deconstructors for common structs

* [docs] update docs
2017-12-11 22:40:46 +01:00
Stephane Delcroix 4c8f901e23
Lazy creation of ResourceDictionaries (#1295)
* [C,Xaml] allow implicit ResourceDictionaries

* [XamlC] implicit ResourceDictionaries

* [C] lazy Resources creation

* fix stupid docs

* [C] no need to trigger events on initial get
2017-11-22 12:59:55 +01:00
Samantha Houts d3d59ee4f0 [All] Basic Right-To-Left Support (#1222)
* Restart RTL work

* Remove IsInherited flag as it never got used

* [Core] Unit tests

* [Core] FlowDirection

* Add FlowDirectionGallery

* Android gallery supports RTL

Need to set minSdkVersion to 17 to test

* iOS gallery supports RTL

* UWP gallery supports RTL

* [Android] Implement FlowDirection

* [iOS] Implement FlowDirection

* [macOS] Implement FlowDirection

* [UWP] Implement FlowDirection

* Update docs

* [Core] Simplify EffectiveFlowDirection enum & expose helper extensions

Also, TEST TEST TEST

* Update docs
2017-11-09 14:31:15 +00:00
E.Z. Hart b3f6d80a1b Remove VisualElement finalizer (#918)
* [Controls] Add repo for bugzilla 55365

* Remove finalizer from VisualElement

* Remove unused using directive

* Removing test for 44074

* Update docs
2017-05-16 10:27:41 -07:00
kingces95 093a4efa2d Implicit impl of controller ifaces (#807)
* Simplify ICtrl callsites

* Rebase fix
2017-04-11 19:02:06 +01:00
Samantha Houts 5f2796e160 [Internal] Normalize Obsolete attributes (#860)
* [All] Normalize Obsolete attributes.

Make sure we include the version in which the member was deprecated and
consistent instructions for working around the deprecation, if
applicable.

* Update docs
2017-04-07 09:47:33 +02:00
BradChase2011 87f0bfa2e1 Fixed a redundant check that caused a massive slowdown on UWP. (#788)
* Fixed a redundant check that caused a massive slowdown on UWP.

* Fixed formatting.

* Fixed formatting.

* UWP_UI_Speed_Fix Last time on tabbing, lets hope so!
2017-03-09 18:39:27 +00:00
kingces95 e6d5186c8a Remove InternalsVisibleTo from Core to XF.Platforms.* (#782)
* Remove InternalsVisibleTo from Core to XF.Platforms.*

* Changes per Jason's code review

* Move LockableObservableListWrapper to internals namespace

* Changes per Stephane's code review

* update docs

* Touch code to get CI to run tests

* Rebase; Update documentation
2017-03-07 14:56:24 -05:00
Stephane Delcroix faa6eae8e7
Revert "[*] ScaleX and ScaleY"
This reverts commit fc7d556848.
2017-02-06 15:18:16 +01:00
Stephane Delcroix fc7d556848
[*] ScaleX and ScaleY 2017-02-06 15:16:54 +01:00
Kevin Petit a11e4c638b Fix NullReferenceException in VisualElement finalize. (#701) 2017-01-19 10:12:51 +01:00
Stephane Delcroix 20e2e12dce [C] detach Behaviors and Triggers on VE finalization (#555)
* [C] detach Behaviors and Triggers on VE finalization

* update docs
2016-12-06 12:15:32 +00:00
E.Z. Hart c08027804e Restore incorrectly renamed InvalidateMeasure method (#251)
* Restore incorrectly renamed InvalidateMeasure method

* Update docs
2016-07-11 12:28:36 -07:00
E.Z. Hart d5be2f0144 Prep Page for removal of InternalsVisibleTo (#150) 2016-06-16 16:45:09 +01:00
E.Z. Hart 5f8f47ff7c Prep VisualElement (and descendants) for removal of InternalsVisibleTo (#141) 2016-05-02 15:19:12 -07:00
Stephane Delcroix 1a7a25fd76 Multi style classes (#134)
* [C] StyleClass is IList<string>

* fix docs

* this might be required
2016-04-25 15:03:33 -07:00
Samantha Houts 3b589b7f2a Fix margin issue (#130) 2016-04-23 15:17:21 -07:00
Jason Smith baa5e82a07 Make sure pragma warning restores only restore what they are supposed to 2016-04-12 12:51:53 -07:00
kingces95 10f6c08ceb Mop up enabling warnings as errors (#78) 2016-04-12 11:44:30 -07:00
Jason Smith 17fdde66d9 Initial import 2016-03-22 16:13:41 -07:00