* Remove Bindable.
Fix Observable & ObservableArray tests
Fix formattedString text
Change implementation of Span, FormattedString & TextBase
properties valueChange called before native setter

* revetred formattedString tests asserts - formattedText update text property again
properties - when getting value we now use always property name instead of key (using key could return undefined for property that is set to its default value)
updated fontSize & fontInternal properties on all controls
fix font properties so that fontInternal is reset if the new font is the same as Font.default

* fix tslint errors
This commit is contained in:
Hristo Hristov
2017-01-20 16:42:20 +02:00
committed by GitHub
parent 8382e98d80
commit e34b0f622c
32 changed files with 786 additions and 1474 deletions

View File

@@ -5,13 +5,7 @@ declare module "ui/core/dependency-observable" {
import { Observable, EventData } from "data/observable";
/**
* Value specifing that Property value should be reset. Used when bindingContext on bound property is creared/null.
*/
export const unsetValue: any;
/**
* Interface used by Propery 'defaultValueGetter' function to specify if the default value returned by the native instance can be cached or not.
* One example is - android.widget.Button background. It is state drawable so it cannot be reused/cached.
* @deprecated
*/
export interface NativeValueResult {
result: any;
@@ -19,7 +13,7 @@ declare module "ui/core/dependency-observable" {
}
/**
* Represents a special Property which supports changed callback, metadata and value validation.
* @deprecated use 'ui/core/properties' module instead.
*/
export class Property {
@@ -68,7 +62,7 @@ declare module "ui/core/dependency-observable" {
}
/**
* Represents an Object that describes a Property instance.
* @deprecated use 'ui/core/properties' module instead.
*/
export class PropertyMetadata {
/**
@@ -121,7 +115,7 @@ declare module "ui/core/dependency-observable" {
}
/**
* The data for the event raised when a value of a Property changes for a DependencyObservable instance.
* @deprecated use 'ui/core/properties' module instead.
*/
export interface PropertyChangeData extends EventData {
/**
@@ -139,28 +133,28 @@ declare module "ui/core/dependency-observable" {
}
/**
* Defines the signature of the function that handles the propertyChanged event.
* @deprecated use 'ui/core/properties' module instead.
*/
export interface PropertyChangedCallback {
(data: PropertyChangeData): void;
}
/**
* Defines the signature of the function that handles the validateValue event.
* @deprecated use 'ui/core/properties' module instead.
*/
export interface PropertyValidationCallback {
(value: any): boolean;
}
/**
* Defines the signature of the function that compares if two property values are equal.
* @deprecated use 'ui/core/properties' module instead.
*/
export interface PropertyEqualityComparer {
(x: any, y: any): boolean;
}
/**
* Represents an Object that is used to back a value for a Property in a DependencyObservable Object instance.
* @deprecated
*/
export class PropertyEntry {
/**
@@ -201,8 +195,7 @@ declare module "ui/core/dependency-observable" {
}
/**
* Represents an extended Observable Object that uses Property instances for value backing mechanism.
* This routine allows for various value modifiers per Property, which is used for inheritance, data-binding and styling purposes.
* @deprecated use 'ui/core/view' as base class.
*/
export class DependencyObservable extends Observable {
// TODO: Do we want to expose the get/setValue methods as public?
@@ -251,7 +244,7 @@ declare module "ui/core/dependency-observable" {
}
/**
* Lists the possible values for the PropertyMetadata.options property. Each actual numeric value is a power of two allowing for bitwise operations.
* @deprecated use 'ui/core/properties' module instead.
*/
export module PropertyMetadataSettings {
/**
@@ -273,7 +266,7 @@ declare module "ui/core/dependency-observable" {
}
/**
* Lists the possible values for the PropertyEntry.valueSource property.
* @deprecated
*/
export module ValueSource {
/**