summaryrefslogtreecommitdiff
path: root/Xamarin.Forms.Platform.Tizen/Renderers/SearchBarRenderer.cs
diff options
context:
space:
mode:
authorKangho Hur <kangho.hur@samsung.com>2017-07-10 06:42:16 +0000
committerKangho Hur <kangho.hur@samsung.com>2017-07-10 06:42:16 +0000
commit26bf6937ff999599fcf7dbdeb08d1c9ac7605676 (patch)
treedc9e87a886dca078ab7c20aaea74113598c9c872 /Xamarin.Forms.Platform.Tizen/Renderers/SearchBarRenderer.cs
parent509e6f117c9966e5503deb8ff1c5135b41eb2a3e (diff)
downloadxamarin-forms-26bf6937ff999599fcf7dbdeb08d1c9ac7605676.tar.gz
xamarin-forms-26bf6937ff999599fcf7dbdeb08d1c9ac7605676.tar.bz2
xamarin-forms-26bf6937ff999599fcf7dbdeb08d1c9ac7605676.zip
Revert "Move registration of property handles to static constructors"
This reverts commit 509e6f117c9966e5503deb8ff1c5135b41eb2a3e. Change-Id: Icb16fdc0b1006405a92e4e5ef77f20749c2ce3e5
Diffstat (limited to 'Xamarin.Forms.Platform.Tizen/Renderers/SearchBarRenderer.cs')
-rw-r--r--Xamarin.Forms.Platform.Tizen/Renderers/SearchBarRenderer.cs25
1 files changed, 14 insertions, 11 deletions
diff --git a/Xamarin.Forms.Platform.Tizen/Renderers/SearchBarRenderer.cs b/Xamarin.Forms.Platform.Tizen/Renderers/SearchBarRenderer.cs
index 339bd00a..3e3344ff 100644
--- a/Xamarin.Forms.Platform.Tizen/Renderers/SearchBarRenderer.cs
+++ b/Xamarin.Forms.Platform.Tizen/Renderers/SearchBarRenderer.cs
@@ -13,18 +13,21 @@ namespace Xamarin.Forms.Platform.Tizen
//TODO: read default platform color
static readonly EColor s_defaultPlaceholderColor = EColor.Gray;
static readonly EColor s_defaultTextColor = EColor.Black;
-
- static SearchBarRenderer()
+ /// <summary>
+ /// Creates a new instance of the <see cref="Xamarin.Forms.Platform.Tizen.SearchBarRenderer"/> class.
+ /// Registers handlers for various properties of the SearchBar widget.
+ /// </summary>
+ public SearchBarRenderer()
{
- RegisterPropertyHandler(SearchBar.CancelButtonColorProperty, (r) => (r as SearchBarRenderer).CancelButtonColorPropertyHandler());
- RegisterPropertyHandler(SearchBar.FontAttributesProperty, (r) => (r as SearchBarRenderer).FontAttributesPropertyHandler());
- RegisterPropertyHandler(SearchBar.FontFamilyProperty, (r) => (r as SearchBarRenderer).FontFamilyPropertyHandler());
- RegisterPropertyHandler(SearchBar.FontSizeProperty, (r) => (r as SearchBarRenderer).FontSizePropertyHandler());
- RegisterPropertyHandler(SearchBar.HorizontalTextAlignmentProperty, (r) => (r as SearchBarRenderer).HorizontalTextAlignmentPropertyHandler());
- RegisterPropertyHandler(SearchBar.PlaceholderProperty, (r) => (r as SearchBarRenderer).PlaceholderPropertyHandler());
- RegisterPropertyHandler(SearchBar.PlaceholderColorProperty, (r) => (r as SearchBarRenderer).PlaceholderColorPropertyHandler());
- RegisterPropertyHandler(SearchBar.TextProperty, (r) => (r as SearchBarRenderer).TextPropertyHandler());
- RegisterPropertyHandler(SearchBar.TextColorProperty, (r) => (r as SearchBarRenderer).TextColorPropertyHandler());
+ RegisterPropertyHandler(SearchBar.CancelButtonColorProperty, CancelButtonColorPropertyHandler);
+ RegisterPropertyHandler(SearchBar.FontAttributesProperty, FontAttributesPropertyHandler);
+ RegisterPropertyHandler(SearchBar.FontFamilyProperty, FontFamilyPropertyHandler);
+ RegisterPropertyHandler(SearchBar.FontSizeProperty, FontSizePropertyHandler);
+ RegisterPropertyHandler(SearchBar.HorizontalTextAlignmentProperty, HorizontalTextAlignmentPropertyHandler);
+ RegisterPropertyHandler(SearchBar.PlaceholderProperty, PlaceholderPropertyHandler);
+ RegisterPropertyHandler(SearchBar.PlaceholderColorProperty, PlaceholderColorPropertyHandler);
+ RegisterPropertyHandler(SearchBar.TextProperty, TextPropertyHandler);
+ RegisterPropertyHandler(SearchBar.TextColorProperty, TextColorPropertyHandler);
}