platform/core/csapi/tizenfx.git
3 years ago[NUI] use discard to ignore unused return value
Yeongjong Lee [Thu, 3 Dec 2020 09:48:44 +0000 (18:48 +0900)]
[NUI] use discard to ignore unused return value

Fixes CA1806

3 years ago[NUI] Fix build warning CS0109
Sunghyun Kim [Thu, 10 Dec 2020 09:10:49 +0000 (18:10 +0900)]
[NUI] Fix build warning CS0109

https://docs.microsoft.com/ko-kr/dotnet/csharp/misc/cs0109

3 years ago[NUI] Prevent unnecessary Layout call, make independent if it has true ExcludeLayouti...
seungho [Thu, 10 Dec 2020 08:53:13 +0000 (17:53 +0900)]
[NUI] Prevent unnecessary Layout call, make independent if it has true ExcludeLayouting and root.

 - Make changed flag in Layout method true when the layout is really changed.
 - If a layout has true value of ExcludeLayouting and it also a root layout, currently it couldn't handled as independent.
 - This patch adds to check ExcludeLayouting Property when it call Layout method.

Signed-off-by: seungho <sbsh.baek@samsung.com>
3 years ago[NUI] Remove DropDown class since it is moved to fhub-nui
Jiyun Yang [Thu, 10 Dec 2020 05:59:35 +0000 (14:59 +0900)]
[NUI] Remove DropDown class since it is moved to fhub-nui

Signed-off-by: Jiyun Yang <ji.yang@samsung.com>
3 years ago[NUI] Fix CA1034 for obsolete classes
Jiyun Yang [Thu, 10 Dec 2020 05:44:31 +0000 (14:44 +0900)]
[NUI] Fix CA1034 for obsolete classes

[CA1034: Nested types should not be visible](https://docs.microsoft.com/en-us/dotnet/fundamentals/code-analysis/quality-rules/ca1034)

Suppress warning messages for obsolete classes

Signed-off-by: Jiyun Yang <ji.yang@samsung.com>
3 years ago[NUI] Change property name frome Url to Uri
seungho [Thu, 10 Dec 2020 05:21:24 +0000 (14:21 +0900)]
[NUI] Change property name frome Url to Uri

Signed-off-by: seungho <sbsh.baek@samsung.com>
3 years ago[NUI] Fix build warning CS0419
seungho [Thu, 10 Dec 2020 03:20:08 +0000 (12:20 +0900)]
[NUI] Fix build warning CS0419

 - Ambiguous reference in cref attribute: 'Method Name1'. Assuming 'Method Name2', but could have also matched other overloads including 'Method Name3'.

Signed-off-by: seungho <sbsh.baek@samsung.com>
3 years ago[NUI] Fix build warning CA2007
seungho [Thu, 10 Dec 2020 03:22:30 +0000 (12:22 +0900)]
[NUI] Fix build warning CA2007

 - CA2007: Do not directly await a Task
 - When an asynchronous method awaits a Task directly, continuation usually occurs in the same thread that created the task, depending on the async context. This behavior can be costly in terms of performance and can result in a deadlock on the UI thread. Consider calling Task.ConfigureAwait(Boolean) to signal your intention for continuation.

Signed-off-by: seungho <sbsh.baek@samsung.com>
3 years ago[NUI] Fix svace issues
zhouleonlei [Wed, 9 Dec 2020 06:01:58 +0000 (14:01 +0800)]
[NUI] Fix svace issues

3 years ago[NUI] Fix CA1052
Jiyun Yang [Wed, 9 Dec 2020 05:49:11 +0000 (14:49 +0900)]
[NUI] Fix CA1052

CA1052
Static holder types should be Static or NotInheritable.

This patch fixes classes that holds only static members to static or sealed.
If the class is obsolete, added suppress message attribute to hide warnings.

Signed-off-by: Jiyun Yang <ji.yang@samsung.com>
3 years ago[NUI] Fix CA1069
Jiyun Yang [Wed, 9 Dec 2020 04:55:55 +0000 (13:55 +0900)]
[NUI] Fix CA1069

CA1069
Enums should not have duplicate values.

This patch changed ProperRanges to struct from enum.

Signed-off-by: Jiyun Yang <ji.yang@samsung.com>
3 years ago[NUI] Fix CA2214
Jiyun Yang [Wed, 9 Dec 2020 03:55:07 +0000 (12:55 +0900)]
[NUI] Fix CA2214

CA2214
Do not call overridable methods in constructors.

* View.cs
  * In the current design, it is hard to remove virtual method call in View constructor.
  * So the patch moved method calling to the private method newly defined.
* ControlStyle.cs
* TextFieldStyle.cs
* ImageViewStyle.cs
* TextLabelStyle.cs
  * Removed unnecessary constructors.

Signed-off-by: Jiyun Yang <ji.yang@samsung.com>
3 years ago[NUI] Remove build warning - CA2241
Moonhee, Choi [Tue, 8 Dec 2020 10:24:05 +0000 (19:24 +0900)]
[NUI] Remove build warning - CA2241

3 years ago[NUI] Fix to restore setter of AnimatedImageView.ResourceUrl
Jaehyun Cho [Fri, 4 Dec 2020 04:38:27 +0000 (13:38 +0900)]
[NUI] Fix to restore setter of AnimatedImageView.ResourceUrl

The setter of AnimatedImageView.ResourceUrl was removed incorrectly by
PR #2232.
To fix the above issue, the setter of AnimatedImageView.ResourceUrl is
restored.

3 years ago[NUI] make Graphics.Backend internal
Yeongjong Lee [Thu, 3 Dec 2020 09:34:05 +0000 (18:34 +0900)]
[NUI] make Graphics.Backend internal

Fixes CA2211

3 years ago[NUI] remove "_" and refactoring naming to pascal case.
Joogab Yun [Thu, 10 Dec 2020 08:19:38 +0000 (17:19 +0900)]
[NUI] remove "_" and refactoring naming to pascal case.

3 years ago[NUI] Remove build warning - CA1825
Moonhee, Choi [Tue, 8 Dec 2020 09:27:03 +0000 (18:27 +0900)]
[NUI] Remove build warning - CA1825

3 years ago[NUI] Remove build warning - CA1041
Moonhee, Choi [Tue, 8 Dec 2020 08:57:54 +0000 (17:57 +0900)]
[NUI] Remove build warning - CA1041

3 years ago[NUI] fix exception when Theme.Resource is used in xaml file
Yeongjong Lee [Thu, 3 Dec 2020 05:50:45 +0000 (14:50 +0900)]
[NUI] fix exception when Theme.Resource is used in xaml file

Since local value `xamlFile` is set after `LoadFromXaml()`,
`xamlFile` is always null in `Reload()`.

To fix this exception, it sets `xamlFile` before `XamlLoader.Load()`.

3 years ago[NUI] Fix wrong AnimationState after VectorAnimatedImageView playing stoped
Dongsug Song [Wed, 2 Dec 2020 02:46:38 +0000 (11:46 +0900)]
[NUI] Fix wrong AnimationState after VectorAnimatedImageView playing stoped

3 years ago[NUI] separate layouting logic of the independent children
Yeongjong Lee [Thu, 19 Nov 2020 06:44:35 +0000 (15:44 +0900)]
[NUI] separate layouting logic of the independent children

This patch introduces `IterateLayoutChildren()` method that return
an enumerable collection of the child layouts that affected by parent
layout.

Independent children will be measured in `OnMeasureIndependentChildren()`.

By using `IterateLayoutChildren()`, we can remove the codes that check
whether child layout exclude from layout flow in `OnMeasure`. and api
users don't need to check `View.ExcludeLayouting` property in custom layouts.

3 years ago[NUI] fixed bug about set desired size
Joogab Yun [Wed, 18 Nov 2020 07:06:18 +0000 (16:06 +0900)]
[NUI] fixed bug about set desired size

3 years ago[NUI] Add RedrawInScalingDown in LottieAnimationView
Dongsug Song [Wed, 9 Dec 2020 04:56:31 +0000 (13:56 +0900)]
[NUI] Add RedrawInScalingDown in LottieAnimationView

3 years ago[NUI] Change clipping mode of ScrollableBase (#2354)
bshsqa [Wed, 9 Dec 2020 05:22:46 +0000 (14:22 +0900)]
[NUI] Change clipping mode of ScrollableBase (#2354)

- ClipChildren clipping mode uses stencil buffer.
 - But, scrollableBase is always pretended as rectangular shape so we can change it to ClipToBoundingBox that uses scissor.
 - Usually, Scissor is better than stencil buffer for the performance.

Signed-off-by: Seungho Baek <sbsh.baek@samsung.com>
3 years ago[NUI] Add Padding parameter for TextPageUtil (#2332)
JoogabYun [Tue, 8 Dec 2020 06:04:57 +0000 (15:04 +0900)]
[NUI] Add Padding parameter for TextPageUtil (#2332)

3 years ago[NUI] Modify NUI Seamless animation bug (#2334) (#2341)
huiyueun [Tue, 8 Dec 2020 03:35:36 +0000 (12:35 +0900)]
[NUI] Modify NUI Seamless animation bug (#2334) (#2341)

* [NUI] Modify NUI Seamless animation bug

Signed-off-by: huiyu.eun <huiyu.eun@samsung.com>
* [NUI] Modify build warning of seamless

Signed-off-by: huiyu.eun <huiyu.eun@samsung.com>
* Update DefaultFrameBroker.cs

* Update TransitionAnimations.cs

* Update DefaultFrameBroker.cs

* Update SeamlessBackward.cs

* Update SeamlessForward.cs

* Update TransitionOptions.cs

* Update NUIBrokerSample.cs

* Update DefaultFrameBroker.cs

Signed-off-by: huiyu.eun <huiyu.eun@samsung.com>
3 years ago[NUI] Use weak reference for theme changed event
Jiyun Yang [Fri, 20 Nov 2020 08:39:04 +0000 (17:39 +0900)]
[NUI] Use weak reference for theme changed event

Previous theme changed event was holding reference of the view for the theme manager's lifetime
unless the view is disposed by calling Dispose() explicitly.
Since the theme manager is a static class, so there might be a change that the view can't get free by GC.
To solve this problem, this patch apply a weak event that uses weak reference for the handler
so that the views are no longer be caught by theme manager.

Signed-off-by: Jiyun Yang <ji.yang@samsung.com>
3 years ago[NUI] Introduce CornerRadiusPolicy to View
Jiyun Yang [Mon, 9 Nov 2020 11:50:02 +0000 (20:50 +0900)]
[NUI] Introduce CornerRadiusPolicy to View

The CornerRadiusPolicy indicates whether the CornerRadius value is relative or absolute.
The default policy is absolute, which means the CornerRadius is an absolute float length.
If the policy is relative, the CornerRadius can have percentage value between 0.0f to 1.0f,
that is relative to the smaller of view's width and height.

Signed-off-by: Jiyun Yang <ji.yang@samsung.com>
3 years ago[NUI] Add Url property to convert image buffer to URL for ImageView (#2286)
bshsqa [Mon, 7 Dec 2020 06:59:19 +0000 (15:59 +0900)]
[NUI] Add Url property to convert image buffer to URL for ImageView (#2286)

Signed-off-by: Seungho Baek <sbsh.baek@samsung.com>
3 years ago[NUI] Modify popup dismiss bug (#2336)
huiyueun [Mon, 7 Dec 2020 05:50:14 +0000 (14:50 +0900)]
[NUI] Modify popup dismiss bug (#2336)

when dismiss popup, the shadow does not disappear.
-An error occurs after changing the parent to GetParent ().
-layer of converting View is null.

Signed-off-by: huiyu.eun <huiyu.eun@samsung.com>
3 years ago[NUI] Fix CA2000 warning issues of Camera / ItemView / Animatable / Animation / Anima...
guowei.wang [Wed, 18 Nov 2020 10:29:40 +0000 (18:29 +0800)]
[NUI] Fix CA2000 warning issues of Camera / ItemView / Animatable / Animation / AnimationImageView.

3 years ago[NUI] Let scroll again when displacement for OutOfBound effect become 0
seungho [Thu, 3 Dec 2020 06:59:45 +0000 (15:59 +0900)]
[NUI] Let scroll again when displacement for OutOfBound effect become 0

Signed-off-by: seungho <sbsh.baek@samsung.com>
3 years ago[NUI] Fix not to get framework path via StyleManager
Jiyun Yang [Thu, 3 Dec 2020 07:31:21 +0000 (16:31 +0900)]
[NUI] Fix not to get framework path via StyleManager

StyleManager uses dali singleton service which is not initialized in PreLoad().
Previously in Preload(), ThemeManager got framework resource path via static constant in StyleManager,
which leaded to initialize StyleManager instance that is not valid in PreLoad().

So this patch moved framework resource path constant to the constant file.

Signed-off-by: Jiyun Yang <ji.yang@samsung.com>
3 years ago[NUI] Fix a build warning CA1827 (#2314)
Seoyeon2Kim [Thu, 3 Dec 2020 05:49:53 +0000 (14:49 +0900)]
[NUI] Fix a build warning CA1827 (#2314)

- Changed to use `Count()` method once for a local variable.
 Then, we do not have to be worried about CA1827.
- To fix the build warning, it could replace `Count()` method with `Any()` method
 https://docs.microsoft.com/en-us/dotnet/fundamentals/code-analysis/quality-rules/ca1827
- But, to improve performance as a review, use `Count()` itself.

Signed-off-by: Seoyeon Kim <seoyeon2.kim@samsung.com>
3 years ago[NUI-Text] Add more scroll functinality to texteditor
ali198724 [Thu, 5 Nov 2020 18:40:21 +0000 (20:40 +0200)]
[NUI-Text] Add more scroll functinality to texteditor

1- add Horizontal_Scroll_position property (float)
2- add VerticalScrollPosition property (float)
3- add ScrollBy function (take Vector2)

3 years ago[NUI] Add Window extension method GetDefaultNavigator
Jaehyun Cho [Fri, 20 Nov 2020 02:53:16 +0000 (11:53 +0900)]
[NUI] Add Window extension method GetDefaultNavigator

To provide default navigator of window, Window extension method
GetDefaultNavigator is added.

3 years ago[NUI] fix CA1801 build warnings from auto-generated codes by SWIG
Youngbok Shin [Wed, 2 Dec 2020 08:06:19 +0000 (17:06 +0900)]
[NUI] fix CA1801 build warnings from auto-generated codes by SWIG

The 'futureUse' parameter is never being used through the whole code.
It removes 'futureUse' parameter from functions.

3 years ago[NUI] Fix build warnings related to XAML (#2287)
Seoyeon2Kim [Wed, 2 Dec 2020 04:28:06 +0000 (13:28 +0900)]
[NUI] Fix build warnings related to XAML (#2287)

- Need to avoid assigning a property to itself
 https://docs.microsoft.com/en-us/dotnet/fundamentals/code-analysis/quality-rules/ca2245
- Not to use broken cryptographic algorithm : MD5 -> SHA256
 https://docs.microsoft.com/en-us/dotnet/fundamentals/code-analysis/quality-rules/ca5351

Signed-off-by: Seoyeon Kim <seoyeon2.kim@samsung.com>
3 years ago[NUI]Revert temporary patch that fix DA build error (#2284)
YeongJong Lee [Tue, 1 Dec 2020 09:17:28 +0000 (18:17 +0900)]
[NUI]Revert temporary patch that fix DA build error (#2284)

* [NUI] Revert temporary patch that fix DA build error

This reverts commit 44c1dfe00c765eb794e5d85a19d7b2518e9e6444 and
commit ef7737bd45966655c0b557dd8d091291fdb7cb5c.

3 years ago[NUI] Refactoring FrameUpdateCallback
seungho [Wed, 4 Nov 2020 07:06:28 +0000 (16:06 +0900)]
[NUI] Refactoring FrameUpdateCallback

 - Remove FrameCallback.cs and Interop.FrameCallback.cs
 - Rename FrameCallbackInterface to FrameUpdateCallbackInterface

Signed-off-by: seungho <seungho@seungho.tn.corp.samsungelectronics.net>
3 years ago[NUI] Fix not to use setter of AnimatedImageView.URLs (#2303)
Jaehyun Cho [Fri, 27 Nov 2020 07:35:49 +0000 (16:35 +0900)]
[NUI] Fix not to use setter of AnimatedImageView.URLs (#2303)

The setter of AnimatedImageView.URLs was removed to resolve CA2227.
Therefore, the setter of AnimatedImageView.URLs in sample code is also
removed.

Co-authored-by: Jaehyun Cho <jae_hyun.cho@samsung.com>
3 years ago[NUI] Add ControlStateTypeConverter for xaml (#2185)
YeongJong Lee [Fri, 27 Nov 2020 05:09:53 +0000 (14:09 +0900)]
[NUI] Add ControlStateTypeConverter for xaml (#2185)

Custom ConstrolState is now available in xaml.

 ### Sample
XamlPage.xaml
```xaml
<View x:Class="NUIXamlTemplate1.XamlPage"
      xmlns="http://tizen.org/Tizen.NUI/2018/XAML"
      xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
      xmlns:c="clr-namespace:Tizen.NUI.Components;assembly=Tizen.NUI.Components"
      xmlns:local="clr-namespace:NUIXamlTemplate1">
    <local:MyButton x:Name="MyButton">
        <x:Arguments>
            <c:ButtonStyle Size="100, 100">
                <c:ButtonStyle.BackgroundColor>
                    <Selector x:TypeArguments="Color" Normal="1, 1, 0, 1" Pressed="0.77, 0.88, 1, 1" Disabled="0.88, 0.88, 0.88, 1">
                        <SelectorItem x:TypeArguments="Color" State="MyState" Value="0,0,1,1" />
                        <SelectorItem x:TypeArguments="Color" State="MyState,Focused" Value="0,1,1,1" />
                    </Selector>
                </c:ButtonStyle.BackgroundColor>
            </c:ButtonStyle>
        </x:Arguments>
    </local:MyButton>
</View>
```

MyButton.cs
```cs
public class MyButton : Button
{
    public MyButton(ButtonStyle buttonStyle) : base(buttonStyle) {}
    public void SetControlState(ControlState s) => ControlState = s;
}
```
Main.cs
```cs
protected override void OnCreate()
{
    base.OnCreate();
    Window.Instance.BackgroundColor = new Color(227 / 255f, 255 / 255f, 227 / 255f, 1.0f);
    Window.Instance.KeyEvent += OnKeyEvent;

    View root = new View();
    root.WidthSpecification = LayoutParamPolicies.MatchParent;
    root.HeightSpecification = LayoutParamPolicies.MatchParent;
    root.Layout = new AbsoluteLayout();
    Window.Instance.GetDefaultLayer().Add(root);

    XamlPage xamlPage = new XamlPage();
    root.Add(xamlPage);

    ControlState MyState = ControlState.Create("MyState");

    Button button = new Button() { Position2D = new Position2D(100, 100) };
    bool flag = false;
    button.Clicked += (object sender, ClickedEventArgs e) =>
    {
        if (!flag)
        {
            xamlPage.MyButton.SetControlState(MyState);
            flag = true;
        }
        else
        {
            xamlPage.MyButton.SetControlState(ControlState.Focused + MyState);
            flag = false;
        }
    };
    root.Add(button);
}
```

3 years ago[NUI] Support Blend Equaiton
seungho [Mon, 9 Nov 2020 09:09:28 +0000 (18:09 +0900)]
[NUI] Support Blend Equaiton

Signed-off-by: seungho <sbsh.baek@samsung.com>
3 years ago[NUI] Remove [Obsolete()] attribute
dongsug.song [Wed, 11 Nov 2020 06:34:11 +0000 (15:34 +0900)]
[NUI] Remove [Obsolete()] attribute

3 years agoUpdate sample of ScrollableBase OutOfBound event handler.
huayong.xu [Fri, 27 Nov 2020 02:27:55 +0000 (10:27 +0800)]
Update sample of ScrollableBase OutOfBound event handler.

3 years ago[NUI] Add direction & displacement into ScrollOutOfBound event.
huayong.xu [Thu, 26 Nov 2020 11:20:26 +0000 (19:20 +0800)]
[NUI] Add direction & displacement into ScrollOutOfBound event.

This patch is to trigger ScrollOutOfBound event as pan gesture state,
and provide more information in ScrollOutOfBound event.

3 years ago[NUI] Delete unnecessary log (#2299)
huiyueun [Fri, 27 Nov 2020 02:56:08 +0000 (11:56 +0900)]
[NUI] Delete unnecessary log (#2299)

- Delete the log commented
- Displays only one log when the value is invalid of color.
- View.Parent is deprecated, modify to use View.GetParent()

Signed-off-by: huiyu.eun <huiyu.eun@samsung.com>
3 years ago[NUI] Add AttributeUsageAttribute for ScriptableProperty(CA1018)
Yeongjong Lee [Thu, 29 Oct 2020 06:31:34 +0000 (15:31 +0900)]
[NUI] Add AttributeUsageAttribute for ScriptableProperty(CA1018)

3 years ago[NUI] Fix Svace issues
zhouleonlei [Thu, 26 Nov 2020 08:17:24 +0000 (16:17 +0800)]
[NUI] Fix Svace issues

3 years ago[NUI] Adjust ScrollingEventThreshold to cover larger sized ContentContainer. (#2249)
bshsqa [Fri, 27 Nov 2020 01:27:58 +0000 (10:27 +0900)]
[NUI] Adjust ScrollingEventThreshold to cover larger sized ContentContainer. (#2249)

- Current default value is 0.00001f and it is too small to track large scale scrolling range.
- This patch updates it to reasonable size and adds guide comment.

Signed-off-by: Seungho Baek <sbsh.baek@samsung.com>
3 years agoRevert "Modify color"
huiyu.eun [Thu, 26 Nov 2020 07:49:42 +0000 (16:49 +0900)]
Revert "Modify color"

This reverts commit 1dd79a38cfae129f7b670d80e386f95f45bbf9d0.

3 years ago[NUI] Modify comment
huiyu.eun [Thu, 26 Nov 2020 07:49:17 +0000 (16:49 +0900)]
[NUI] Modify comment

Signed-off-by: huiyu.eun <huiyu.eun@samsung.com>
3 years agoModify color
huiyu.eun [Wed, 25 Nov 2020 08:46:01 +0000 (17:46 +0900)]
Modify color

Signed-off-by: huiyu.eun <huiyu.eun@samsung.com>
3 years ago[NUI] Change setter of property
huiyu.eun [Tue, 24 Nov 2020 02:12:18 +0000 (11:12 +0900)]
[NUI] Change setter of property

- Setter is deprecated in API8.(Size/Scale/Color/Position)
- An unnecessary log comes out and causes performance degradation.

Signed-off-by: huiyu.eun <huiyu.eun@samsung.com>
3 years agoFix a security warning of FOTA script (#2302)
WonYoung Choi [Fri, 27 Nov 2020 06:47:07 +0000 (15:47 +0900)]
Fix a security warning of FOTA script (#2302)

3 years ago[NUI] Fix StyleCop warning CA2227 (#2232)
Jaehyun Cho [Thu, 26 Nov 2020 02:46:29 +0000 (11:46 +0900)]
[NUI] Fix StyleCop warning CA2227 (#2232)

To fix CA2227(Collection properties should be read only), the setters of
the collection properties are removed.

Co-authored-by: Jaehyun Cho <jae_hyun.cho@samsung.com>
Co-authored-by: YeongJong Lee <cleanlyj@naver.com>
3 years ago[NUI] Load default theme in preload
Jiyun Yang [Tue, 24 Nov 2020 03:11:31 +0000 (12:11 +0900)]
[NUI] Load default theme in preload

Signed-off-by: Jiyun Yang <ji.yang@samsung.com>
3 years ago[NUI] remove unused Xamarin style classes (#2184)
YeongJong Lee [Tue, 24 Nov 2020 08:54:49 +0000 (17:54 +0900)]
[NUI] remove unused Xamarin style classes (#2184)

NUI uses `Tizen.NUI.BaseComponents.ViewStyle` instead of
`Tizen.NUI.Binding.Style` which is copied from xamarin.

3 years ago[NUI] Fix StyleCop warning CA1823 (#2222)
Jaehyun Cho [Tue, 24 Nov 2020 07:56:48 +0000 (16:56 +0900)]
[NUI] Fix StyleCop warning CA1823 (#2222)

To fix CA1823(Avoid unused private fields), the unused private fields
are removed.

Co-authored-by: Jaehyun Cho <jae_hyun.cho@samsung.com>
Co-authored-by: YeongJong Lee <cleanlyj@naver.com>
3 years ago[NUI] respect flex child margin changes (#2271)
YeongJong Lee [Mon, 23 Nov 2020 11:20:22 +0000 (20:20 +0900)]
[NUI] respect flex child margin changes (#2271)

The flex child margin is only set when a flex child is added to flexlayout,
so margin changes after `View.Add` are ignored.

To respect child margin changes, This patch add code to set flex margin in
`OnMeasure`.

3 years agoRevert refactoring naming (#2274)
JoogabYun [Mon, 23 Nov 2020 08:10:38 +0000 (17:10 +0900)]
Revert refactoring naming (#2274)

* Revert "[NUI] remove "_" and refactoring naming to pascal case. (#2244)"

This reverts commit b0942517f09bb292216797a0a890121619384a21.

* Revert "[NUI] fixed build warning CA1707 (#2241)"

This reverts commit 88d78644dada8a24e14cdf2b5b724537e3ef9952.

* Revert "[NUI] fixed build warning CA1707 (#2239)"

This reverts commit be21b7e43c56b92fa64d4f0a4522f2369c3fb35d.

3 years ago[NUI] Fix build warning CA1062 (#2234)
Seoyeon2Kim [Mon, 23 Nov 2020 06:23:03 +0000 (15:23 +0900)]
[NUI] Fix build warning CA1062 (#2234)

* [NUI] Fix build warning CA1062

- Need to verify whether the argument is null
https://docs.microsoft.com/en-us/dotnet/fundamentals/code-analysis/quality-rules/ca1062

Signed-off-by: Seoyeon Kim <seoyeon2.kim@samsung.com>
* [NUI] Add exception handling tag

- The <exception> tag lets you specify which exceptions can be thrown.

Signed-off-by: Seoyeon Kim <seoyeon2.kim@samsung.com>
3 years ago[NUI] remove unnecessary code that flex margin is assigned to flexlayout (#2272)
YeongJong Lee [Mon, 23 Nov 2020 05:50:07 +0000 (14:50 +0900)]
[NUI] remove unnecessary code that flex margin is assigned to flexlayout (#2272)

Sicne the margin of FlexLayout will be handled by the parent layout,
we don't need to re-assign margin in `OnMeasure`.

3 years ago[NUI] fix CellPadding bugs on LinearLayout (#2269)
YeongJong Lee [Mon, 23 Nov 2020 05:30:00 +0000 (14:30 +0900)]
[NUI] fix CellPadding bugs on LinearLayout (#2269)

`childrenCount` is added to count children that have false ExcludeLayouting.
And `CellPadding` is now respected regardless of exactly mode.

This patch will fix the following bugs.
1. In some cases, when CellPadding is set, children are misaligned.
2. If CellPadding is set and last child set ExcludeLayouting to true,
CellPadding is added to the end of items.

For more information on the issues, please see the comment of this
pull request.

3 years ago[NUI] synchronize View.ExcludeLayouting and FlexLayout.PositionType (#2254)
YeongJong Lee [Fri, 20 Nov 2020 07:51:37 +0000 (16:51 +0900)]
[NUI] synchronize View.ExcludeLayouting and FlexLayout.PositionType (#2254)

Simple Test
```cs
//Default value test
bool Default_ExcludeLayouting = view.ExcludeLayouting; // False
FlexLayout.PositionType Default_FlexPositionType = FlexLayout.GetFlexPositionType(view); //Relative

// FlexPositionType test depending on ExcludeLayouting
view.ExcludeLayouting = true;
FlexLayout.PositionType FlexPositionType = FlexLayout.GetFlexPositionType(view); //Absolute

// ExcludeLayouting test depending on FlexLayout.SetFlexPositionType
FlexLayout.SetFlexPositionType(view, FlexLayout.PositionType.Relative);
bool ExcludeLayouting = view.ExcludeLayouting; // False;
```

3 years ago[NUI] fix CA1801 build warnings (#2258)
Youngbok Shin [Fri, 20 Nov 2020 06:00:08 +0000 (15:00 +0900)]
[NUI] fix CA1801 build warnings (#2258)

Fix CA1801 build warnings except auto-generated code by SWIG.

Co-authored-by: Youngbok Shin <youngb.shin@samsung.com>
Co-authored-by: woohyun <woo_hyun0705@naver.com>
3 years ago[Bluetooth][Non-ACR] Fix svace issue (#2270)
Wootak Jung [Mon, 23 Nov 2020 05:50:48 +0000 (14:50 +0900)]
[Bluetooth][Non-ACR] Fix svace issue (#2270)

Signed-off-by: Wootak Jung <wootak.jung@samsung.com>
3 years ago[NUI] Enable/Disable overshooting effect for ScrollableBase.
huayong.xu [Thu, 5 Nov 2020 09:24:04 +0000 (17:24 +0800)]
[NUI] Enable/Disable overshooting effect for ScrollableBase.

A property EnableOverShootingEffect is added. default is false.
And shadow would be raised to top when effect appears.

3 years ago[NUI] Correct the meaning of ExcludeLayouting. (#2257)
bshsqa [Thu, 19 Nov 2020 05:47:15 +0000 (14:47 +0900)]
[NUI] Correct the meaning of ExcludeLayouting. (#2257)

Signed-off-by: seungho <sbsh.baek@samsung.com>
3 years ago[NUI] change Column, Row default value from -1 to AutoColumn, AutoRow (#2180)
YeongJong Lee [Thu, 19 Nov 2020 02:41:09 +0000 (11:41 +0900)]
[NUI] change Column, Row default value from -1 to AutoColumn, AutoRow (#2180)

ArgumentException will be thrown when column,row is a negative value
other than AutoColumn/AutoRow.

3 years agoFollow formatting NUI
huiyu.eun [Wed, 18 Nov 2020 07:39:34 +0000 (16:39 +0900)]
Follow formatting NUI

Signed-off-by: huiyu.eun <huiyu.eun@samsung.com>
3 years ago[NUI] remove "_" and refactoring naming to pascal case. (#2244)
JoogabYun [Wed, 18 Nov 2020 04:31:59 +0000 (13:31 +0900)]
[NUI] remove "_" and refactoring naming to pascal case. (#2244)

Co-authored-by: dongsug-song <35130733+dongsug-song@users.noreply.github.com>
3 years ago[NUI] Add Navigator and Page classes
Jaehyun Cho [Fri, 11 Sep 2020 02:40:47 +0000 (11:40 +0900)]
[NUI] Add Navigator and Page classes

To support view navigation, Navigator and Page classes are added.
Navigator class provides stack methods to manage and navigate pages.
Page class is an element of navigation.

To add Page class, XamlBinding classes related to Page are removed
because they are not used.

3 years ago[NUI] Fix exception defect when LanguageChanged event has come
dongsug.song [Mon, 16 Nov 2020 08:04:21 +0000 (17:04 +0900)]
[NUI] Fix exception defect when LanguageChanged event has come

- LocaleLanguageChanged event should be unsubscribed when TextLabel, TextField, TextEditor are disposed.

3 years ago[NUI] Add more selection functinality into TextEditor (#2152)
Ali-Alzyoud [Wed, 18 Nov 2020 01:33:39 +0000 (03:33 +0200)]
[NUI] Add more selection functinality into TextEditor (#2152)

1- Add SelectWholeText method
2- Add SelectNone method
3- add SELECTED_TEXT property

Co-authored-by: Seoyeon2Kim <34738918+Seoyeon2Kim@users.noreply.github.com>
3 years ago[NUI] Add ExcludeLayouting to View (#2187)
bshsqa [Wed, 18 Nov 2020 01:03:52 +0000 (10:03 +0900)]
[NUI] Add ExcludeLayouting to View (#2187)

* [NUI] Formatting for layout code

Signed-off-by: seungho <sbsh.baek@samsung.com>
* [NUI] Add ExcludeLayouting to View

 - If ExcludeLayouting property is false, the view is not affected by parent layout
 - Even the property is false, the children Views are affected by layout of current View
 - This ExcludeLayouting property is changed synchronously with SetPositionByLayout of its layout
 - Children of AbsoluteLayout can freely be animated.

Signed-off-by: seungho <sbsh.baek@samsung.com>
3 years ago[NUI] fixed build warning CA1707 (#2241)
JoogabYun [Tue, 17 Nov 2020 08:11:01 +0000 (17:11 +0900)]
[NUI] fixed build warning CA1707 (#2241)

- ItemFactory

3 years ago[NUI] fixed build warning CA1707 (#2239)
JoogabYun [Tue, 17 Nov 2020 07:43:22 +0000 (16:43 +0900)]
[NUI] fixed build warning CA1707 (#2239)

- Renderer

Co-authored-by: dongsug-song <35130733+dongsug-song@users.noreply.github.com>
3 years ago[NUI] fixed build warning CA2208 (#2228)
JoogabYun [Tue, 17 Nov 2020 01:15:32 +0000 (10:15 +0900)]
[NUI] fixed build warning CA2208 (#2228)

3 years ago[NUI] fix a CA2200 warning (#2240)
Youngbok Shin [Fri, 13 Nov 2020 10:26:48 +0000 (19:26 +0900)]
[NUI] fix a CA2200 warning (#2240)

Co-authored-by: Youngbok Shin <youngb.shin@samsung.com>
3 years ago[NUI] Fill missing descriptions and fix build warnings for Theme (#2195)
Jiyun Yang [Fri, 13 Nov 2020 06:54:28 +0000 (15:54 +0900)]
[NUI] Fill missing descriptions and fix build warnings for Theme (#2195)

This patch fixes build warnings and Roslynator suggestions in Theme and ThemeManager.

CA2208 Instantiate argument exceptions correctly
CA1062 Validate arguments of public methods
IDE0044 Add readonly modifier
IDE0005 Remove unnecessary import
RCS1171 Simplify lazy initialization

Signed-off-by: Jiyun Yang <ji.yang@samsung.com>
3 years ago[NUI] fixed build warning CA1802 (#2227)
JoogabYun [Fri, 13 Nov 2020 05:25:56 +0000 (14:25 +0900)]
[NUI] fixed build warning CA1802 (#2227)

3 years ago[NUI] fix a CA1507 warning (#2233)
Youngbok Shin [Fri, 13 Nov 2020 01:26:32 +0000 (10:26 +0900)]
[NUI] fix a CA1507 warning (#2233)

Co-authored-by: Youngbok Shin <youngb.shin@samsung.com>
3 years agoFix CA2000 warning issues of GLWindow / ViewInternal.
guowei.wang [Tue, 10 Nov 2020 03:22:10 +0000 (11:22 +0800)]
Fix CA2000 warning issues of GLWindow / ViewInternal.

3 years ago[Build] Fix wrong dependency of Tizen.NET nuget package (#2235)
WonYoung Choi [Fri, 13 Nov 2020 02:26:10 +0000 (11:26 +0900)]
[Build] Fix wrong dependency of Tizen.NET nuget package (#2235)

Co-authored-by: Wonyoung Choi <wy80.choi@samsung.net>
3 years ago[Build] Add FOTA script for TizenFX (#2225)
WonYoung Choi [Thu, 12 Nov 2020 05:26:38 +0000 (14:26 +0900)]
[Build] Add FOTA script for TizenFX (#2225)

* [Build] Add FOTA script for TizenFX

* Update 500.tizenfx_upgrade.sh

3 years ago[NUI] Fixed the svace issues of Visuals
zhouleonlei [Tue, 10 Nov 2020 06:53:33 +0000 (14:53 +0800)]
[NUI] Fixed the svace issues of Visuals

3 years ago[NUI] Fixed Svace issues
zhouleonlei [Tue, 10 Nov 2020 02:52:38 +0000 (10:52 +0800)]
[NUI] Fixed Svace issues

3 years ago[NUI] Fix bulid warnings in Shadow
Jiyun Yang [Tue, 10 Nov 2020 03:24:16 +0000 (12:24 +0900)]
[NUI] Fix bulid warnings in Shadow

This patch fixes following build warnings and coding recommandations for Shadow.

* Fill missing API descriptions.
* Do not call overridable methods in constructors. (CA2214)
* Remove trailing white spaces.
* Remove unnecessary parentheses. (IDE0047)

Signed-off-by: Jiyun Yang <ji.yang@samsung.com>
3 years ago[NUI] fix ThemeResourceSample build error
Yeongjong Lee [Tue, 10 Nov 2020 11:51:44 +0000 (20:51 +0900)]
[NUI] fix ThemeResourceSample build error

This patch will fix build error caused by conflict between global::System.XXX
and Tizen.System.XXX namespace.

3 years ago[NUI] Add EnableMultiSelection to SelectGroup (#2116)
Jaehyun Cho [Tue, 10 Nov 2020 11:15:02 +0000 (20:15 +0900)]
[NUI] Add EnableMultiSelection to SelectGroup (#2116)

To support selecting multiple SelectButtons in SelectGroup,
bool EnableMultiSelection is added to SelectGroup.

By adding EnableMultiSelection in SelectGroup, RadioButtonGroup does not
need to implement its logic to prevent selecting multiple RadioButtons.

Co-authored-by: Jaehyun Cho <jae_hyun.cho@samsung.com>
Co-authored-by: Jiyun Yang <ji.yang@samsung.com>
3 years agoFix static analysis issues (#2190)
hjhun [Fri, 6 Nov 2020 05:53:54 +0000 (14:53 +0900)]
Fix static analysis issues (#2190)

Issues:
 - NO_LOCK.STAT

Signed-off-by: Hwankyu Jhun <h.jhun@samsung.com>
3 years ago[NUI] change orientation angle in GLWindow
Wonsik Jung [Mon, 9 Nov 2020 01:32:03 +0000 (10:32 +0900)]
[NUI] change orientation angle in GLWindow

Change orientation angle in GLWindow. It is same with NUI.Window.

3 years agoFix warnings about CA2000 of NUI.Components. (#2157)
guowei.wang [Mon, 9 Nov 2020 05:42:51 +0000 (13:42 +0800)]
Fix warnings about CA2000 of NUI.Components. (#2157)

Co-authored-by: Jiyun Yang <ji.yang@samsung.com>
3 years ago[NUI] Do not make error message when the profile theme file is not found (#2188)
Jiyun Yang [Fri, 6 Nov 2020 09:44:03 +0000 (18:44 +0900)]
[NUI] Do not make error message when the profile theme file is not found (#2188)

In some profile, not all 3 theme files exists.
So the patch checks file existance not to make error messages.

Signed-off-by: Jiyun Yang <ji.yang@samsung.com>
3 years ago[NUI] Introduce ThemeResource (#2176)
YeongJong Lee [Fri, 6 Nov 2020 07:42:50 +0000 (16:42 +0900)]
[NUI] Introduce ThemeResource (#2176)

You can define resources(e.g. color, image etc.) of theme in seperate files.
ThemeResource can be changed in runtime without changing theme file.

3 years ago[NUI] Fix recursion when the view sets KeyboardNavigationSupport to true (#2100)
Jiyun Yang [Fri, 6 Nov 2020 07:09:35 +0000 (16:09 +0900)]
[NUI] Fix recursion when the view sets KeyboardNavigationSupport to true (#2100)

In Dali code, the method GetNextKeyboardFocuableActor should return
an empty actor (= the base handle without a referenced object)
if there is no actor can be focused.

The corresponding method in NUI is GetNextFocusableView.
It returned new View() (that is not an empty actor) which leads to the wrong result.
So instead returning new View, this patch returns a null IntPtr.

Signed-off-by: Jiyun Yang <ji.yang@samsung.com>
3 years ago[NUI] fixed build warning CS1574 (#2191)
JoogabYun [Fri, 6 Nov 2020 06:27:02 +0000 (15:27 +0900)]
[NUI] fixed build warning CS1574 (#2191)

3 years ago[NUI] No need to do Registry.GetManagedBaseHandleFromNativePtr().
Joogab Yun [Thu, 5 Nov 2020 02:26:47 +0000 (11:26 +0900)]
[NUI] No need to do Registry.GetManagedBaseHandleFromNativePtr().

3 years agoRevert "[NUI] Add TouchArea property. (#2105)" (#2166)
JoogabYun [Tue, 3 Nov 2020 06:34:37 +0000 (15:34 +0900)]
Revert "[NUI] Add TouchArea property. (#2105)" (#2166)

This reverts commit 4a36f8f08fe9d580b35d740b8462a9a75fabd401.