/// DefaultGridItem may contain text or an icon.
/// </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
- public class DefaultGridItem : RecyclerViewItem
+ public partial class DefaultGridItem : RecyclerViewItem
{
private TextLabel itemLabel;
private ImageView itemImage;
}
internal set
{
+ if (itemImage != null) Remove(itemImage);
itemImage = value;
+ if (itemImage != null)
+ {
+ //FIXME: User applied image's style can be overwritten!
+ if (ItemStyle != null) itemImage.ApplyStyle(ItemStyle.Image);
+ Add(itemImage);
+ itemImage.Relayout += OnImageRelayout;
+ }
layoutChanged = true;
}
}
{
get
{
+ return GetValue(BadgeProperty) as View;
+ }
+ set
+ {
+ SetValue(BadgeProperty, value);
+ NotifyPropertyChanged();
+ }
+ }
+ private View InternalBadge
+ {
+ get
+ {
return itemBadge;
}
set
{
- if (value == null)
- {
- Remove(itemBadge);
- }
+ if (itemBadge != null) Remove(itemBadge);
itemBadge = value;
if (itemBadge != null)
{
- itemBadge.ApplyStyle(ItemStyle.Badge);
+ //FIXME: User applied badge's style can be overwritten!
+ if (ItemStyle != null) itemBadge.ApplyStyle(ItemStyle.Badge);
Add(itemBadge);
}
layoutChanged = true;
{
get
{
+ return GetValue(TextProperty) as string;
+ }
+ set
+ {
+ SetValue(TextProperty, value);
+ NotifyPropertyChanged();
+ }
+ }
+ private string InternalText
+ {
+ get
+ {
return Label.Text;
}
set
{
get
{
+ return (Tizen.NUI.Components.DefaultGridItem.LabelOrientation)GetValue(LabelOrientationTypeProperty);
+ }
+ set
+ {
+ SetValue(LabelOrientationTypeProperty, value);
+ NotifyPropertyChanged();
+ }
+ }
+ private Tizen.NUI.Components.DefaultGridItem.LabelOrientation InternalLabelOrientationType
+ {
+ get
+ {
return labelOrientation;
}
set