Revert "[NUI] Fix CA2000 issue in DefaultTheme(Dispose object before losing scope...
authorJiyun Yang <ji.yang@samsung.com>
Thu, 24 Dec 2020 08:47:35 +0000 (17:47 +0900)
committerhuiyueun <35286162+huiyueun@users.noreply.github.com>
Mon, 11 Jan 2021 05:49:43 +0000 (14:49 +0900)
commitd6fe274d9e46ec3c5efc197e735712a4013a11a8
tree159263ba000a64d047fb43c64e4d9a55e492e9c3
parent054278304da901e7410121a2ea18580a14a7c454
Revert "[NUI] Fix CA2000 issue in DefaultTheme(Dispose object before losing scope)" (#2463)

This reverts commit cff3fd4d9fd6fd461263e742e296a5397e9563a0.

This causes segfault to dispose styles after passing them through `AddStyleWithoutClone` method.
Because the theme object holds the passed style objects.
Which means the responsibility to dispose the object is transferred to the theme object.

In this case, we can suppress this warning.
https://docs.microsoft.com/en-us/dotnet/fundamentals/code-analysis/quality-rules/ca2000

Instead revert the patch, it suppressed CA2000 warning.
src/Tizen.NUI.Components/Theme/DefaultTheme.cs [changed mode: 0755->0644]