Skip to content

Commit

Permalink
[NUI] update imageUrl to resourceUrl
Browse files Browse the repository at this point in the history
  • Loading branch information
everLEEst committed Dec 16, 2022
1 parent c57bf41 commit 5d7e499
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -165,20 +165,20 @@ private View InternalBadge
}

/// <summary>
/// Image image's resource url in DefaultGridItem.
/// Image resource url in DefaultGridItem.
/// </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public string ImageUrl
public string ResourceUrl
{
get => GetValue(ImageUrlProperty) as string;
get => GetValue(ResourceUrlProperty) as string;
set
{
SetValue(ImageUrlProperty, value);
SetValue(ResourceUrlProperty, value);
NotifyPropertyChanged();
}
}

internal string InternalImageUrl
internal string InternalResourceUrl
{
get
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,21 +44,21 @@ public partial class DefaultGridItem


/// <summary>
/// ImageUrlProperty
/// ResourceUrlProperty
/// </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public static readonly BindableProperty ImageUrlProperty = BindableProperty.Create(nameof(ImageUrl), typeof(string), typeof(DefaultGridItem), default(string), propertyChanged: (bindable, oldValue, newValue) =>
public static readonly BindableProperty ResourceUrlProperty = BindableProperty.Create(nameof(ResourceUrl), typeof(string), typeof(DefaultGridItem), default(string), propertyChanged: (bindable, oldValue, newValue) =>
{
var instance = (DefaultGridItem)bindable;
if (newValue != null)
{
instance.InternalImageUrl = newValue as string;
instance.InternalResourceUrl = newValue as string;
}
},
defaultValueCreator: (bindable) =>
{
var instance = (DefaultGridItem)bindable;
return instance.InternalImageUrl;
return instance.InternalResourceUrl;
});

/// <summary>
Expand Down

0 comments on commit 5d7e499

Please sign in to comment.