Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[NUI] Switch camera includes current camera's Unparent() #5390

Closed
wants to merge 264 commits into from

Conversation

jmmhappy
Copy link
Contributor

Synchronizing DALi and NUI cameras' parent.

DALi's SelectCamera() includes unparenting current camera component, and NUI's SelectCamera() simply calls the function.
However, since they manage different objects on each side, NUI's camera is still attached to its parent.

This can be a problem in a situation such as:

// dummy is a View
dummy.Add(defaultCamera);
sceneView.Add(dummy);

sceneView.SelectCamera(1u);

sceneView.SelectCamera(0u);
dummy.Add(defaultCamera);

In NUI side, default camera was never detached from dummy but DALi's SceneView now has both dummy and default camera as its children. (The last line is ignored on NUI side.)

Eunki Hong and others added 30 commits January 18, 2023 16:46
After PR Samsung#4892 `HasBody()` can be false in `ReleaseSwigCPtr`.
So, some class who check double-released might not release
native memory. It might occure some leak.

This patch make them to check `Disposed` instead of `HasBody()`.

+

Clean up some codes of `ReleaseSwigCPtr`.

TODO : Also need to check `Disposable.Dispose` function

TODO : Need to check third-party library implementation who use
their custom `ReleaseSwigCPtr`

Signed-off-by: Eunki Hong <[email protected]>
GetInputMethodContext() in ReleaseSwigCPtr crashes due to current changes in BaseHandle.
Move DestroyContext() to Dispose to avoid this.

Signed-off-by: Bowon Ryu <[email protected]>
…e thread

Reorder the `ReleaseSwigCPtr` call time and `SwigCPtr` value setup.
It will be matched as `BaseHandle.cs` doing now.

Plus

Make we don't print any fatal log when we try to dispose `Disposable` class.
For example, `Vector2` or `Uint16Pair` don't need to be used only for main thread.
Only some UI releative things has some dependency issue of Main / UI thread.

Signed-off-by: Eunki, Hong <[email protected]>
- Adds descriptions
- Adds throwing an exception

Signed-off-by: Hwankyu Jhun <[email protected]>

Signed-off-by: Hwankyu Jhun <[email protected]>
Signed-off-by: Hwankyu Jhun <[email protected]>

Signed-off-by: Hwankyu Jhun <[email protected]>
To provide the screen size, NUIApplication.GetScreenSize is added.
Make recent action match with dali

Signed-off-by: Eunki Hong <[email protected]>
* [NUI] Add Tizen.NUI.Scene3D simple demo

Hello 3d world!

Signed-off-by: Eunki, Hong <[email protected]>

* Update Scene3DSample.cs

2022 -> 2023

Signed-off-by: Eunki, Hong <[email protected]>
Co-authored-by: Eunki, Hong <[email protected]>
- AppControl.GetDefaultApplicationIds()

Signed-off-by: Hwankyu Jhun <[email protected]>

Signed-off-by: Hwankyu Jhun <[email protected]>
* Implement NUIGadget

Signed-off-by: Hwankyu Jhun <[email protected]>

* Adjust project file

Signed-off-by: Hwankyu Jhun <[email protected]>

* Update csproj

Signed-off-by: Hwankyu Jhun <[email protected]>

* Update implementation

Signed-off-by: Hwankyu Jhun <[email protected]>

* Remove dll unload

Signed-off-by: Hwankyu Jhun <[email protected]>

* Remove unnecessary file

Signed-off-by: Hwankyu Jhun <[email protected]>

* Update sln file

Signed-off-by: Hwankyu Jhun <[email protected]>

* Add missing dependencies

Signed-off-by: Hwankyu Jhun <[email protected]>

* Add a missing property

The type is added.

Signed-off-by: Hwankyu Jhun <[email protected]>

* Update implementation

Signed-off-by: Hwankyu Jhun <[email protected]>

* Fix typo

Signed-off-by: Hwankyu Jhun <[email protected]>

* Check return type of Assembly.CreateInstance()

This patch uses 'as' keyword to check the instance type.
If it's not NUIGadget, the return value will be null.
In that case, the Add() method throws an exception.

Signed-off-by: Hwankyu Jhun <[email protected]>

* Add abstract keyword to NUIGadget class

Signed-off-by: Hwankyu Jhun <[email protected]>

* Modify Create() method of NUIGadget

If the Create() method returns 'false', the Add() method of NUIGadgetManager
throws an exception.

Signed-off-by: Hwankyu Jhun <[email protected]>

* Use CoreApplication.Post() instead of TizenUISynchronzationContext.Post()

Signed-off-by: Hwankyu Jhun <[email protected]>

Signed-off-by: Hwankyu Jhun <[email protected]>
This patch is to prevent the delegate garbage collected.

Signed-off-by: Hwankyu Jhun <[email protected]>
1. Collect all private values in upward of source code.
2. Formatting C#
3. MilliSeconds --> Milliseconds
4. Add some comments

Signed-off-by: Eunki Hong <[email protected]>
* [NUI] Remove build warning messages in NUI Samples

 - Replace `PreFocusChangeEventArgs` from `FocusChangingEventArgs`.
 - Use `HorizontalAlignment` or `VerticalAlignment` properties
   instead of `LinearAlignment`/
 - Use new Vector2(...) constructor instead of using `X` or `Y` setter.
 - Remove Unreachable code.

Signed-off-by: Seoyeon Kim <[email protected]>

* [NUI] Remove build warning messages

 - Remove not used variables : `axis` and `degree`.
 - Clean code according to NUI Coding style
 - Use `HorizontalAlignment` or `VerticalAlignment` properties
   instead of `LinearAlignment`.
 - Use `StyleName` property instead of `SetStyleName(string)`.
 - Use `ChildCount` property instead of `GetChildCount()`.
 - Use new Vector2(...) constructor instead of `Width` or `Height` setter.

Signed-off-by: Seoyeon Kim <[email protected]>

* [NUI] Remove build warning messages part.3

 - Remove not used variables : mClippedImagePropertyIndex,
mLogoTapDetector, FocusEffect.actor, oldPageCount, FrameUpdateCallback.text, etc.
 - Use `HorizontalAlignment` or `VerticalAlignment` properties
  instead of `LinearAlignment`.
 - Use `ChildCount` property instead of `GetChildCount()`.
 - Use new Vector2(...) constructor instead of `Width` or `Height` setter.
 - Clean code according to NUI Coding style

Signed-off-by: Seoyeon Kim <[email protected]>

Signed-off-by: Seoyeon Kim <[email protected]>
Since we create new handle at csharp binder, we should call DeleteHandle function.

Note : Extensions.GetInstanceSafely delete the getted cPtr's reference inside of
that function. So we cannot use it.

Signed-off-by: Eunki Hong <[email protected]>
Add sample to use EncodedImageBuffer.

Signed-off-by: Eunki Hong <[email protected]>
Since we update ImageView lazy, ImageUrl's lifecycle might not matched
what user think.

```
ImageUrl imageUrl = ~~~.GenerateUrl();
ImageView imageView = new ImageView(imageUrl.ToString());
imageUrl.Dispose(); ///< We should allow this situation.
```

To make scene, We allow to call UpdateImage(); synchoronously
if we use GeneratedUrl().

Signed-off-by: Eunki Hong <[email protected]>
This PR is FrontPorting of Samsung#4827

Signed-off-by: Eunki, Hong <[email protected]>
There was a flag that prevent state updating while applying style.
But the flag seemed to have a bug : when style is disabled, the state updating is never going to be done.

This patch fixes the bug and changes the flag's name to be more contextual: styleApplied -> styleApplying.

Signed-off-by: Jiyun Yang <[email protected]>
Eunki, Hong and others added 17 commits June 28, 2023 15:29
Since we don't check validation of ImageView itself during change
ImageView properties, it will not throw any exceptions.
and it will be crashend when we ProcessOnceEvent invoked.

Normal View property directly access to DALi side. But ImageView
property access to DALi side lazy.

Now this throw make app developer easy to find error codes.

Signed-off-by: Eunki, Hong <[email protected]>
Signed-off-by: seungho baek <[email protected]>
Write some comments for Matrix / Matrix3 class

Signed-off-by: Eunki, Hong <[email protected]>
 - Add ModelRoot Property to retrieve root ModelNode of the Model object.
 - Change parameter name of AddModelNode and RemoveModelNode to modelNode

Signed-off-by: seungho baek <[email protected]>
The Wheel event calls the WheelEvent callback by going back from the last child actor to the parent via hitTest.
InterceptWheelEvent checks the wheel event in the parent first.
Returning false from interceptWheelEvent allows child actors to receive WheelEvents.
If it returns true, the actor will receive a WheelEvent.

for example

   View parent = new View();
   View child = new View();
   parent.Add(child);
   child.WheelEvent += childFunctor;
   parent.WheelEvent += parentFunctor;

The callbacks are called in the order childFunctor -> parentFunctor.

If you connect InterceptWheelEvent to parentActor.

   parent.InterceptWheelEvent += interceptFunctor;

When interceptFunctor returns false, it is called in the same order childFunctor -> parentFunctor.
If intereptFunctor returns true, it means that the WheelEvent was intercepted.
So the child actor will not be able to receive wheel events.
Only the parentFunctor is called.

refer :
https://review.tizen.org/gerrit/#/c/platform/core/uifw/dali-core/+/295232/
https://review.tizen.org/gerrit/#/c/platform/core/uifw/dali-csharp-binder/+/295233/
Signed-off-by: Bowon Ryu <[email protected]>
- Except for TV and wearable profiles, FontSizeScale values are updated.

Signed-off-by: Seoyeon Kim <[email protected]>
Delete the used window so that the window can be deleted normally when deleting the widget.
this is for memory leak issue.
Because if the window is rotated, we need to resize the window by recalculating the border area.
Scrim should block all touch and gesture events.
Therefore, gesture is also not propagated from scrim.
* [MediaPlayer] Add new API to set video codec type
@github-actions github-actions bot added the API11 Platform : Tizen 8.0 / TFM: net6.0-tizen8.0 label Jul 12, 2023
@jmmhappy jmmhappy changed the base branch from master to DevelNUI July 12, 2023 09:20
@jmmhappy jmmhappy closed this Jul 12, 2023
@jmmhappy jmmhappy deleted the select_camera branch July 12, 2023 09:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
API11 Platform : Tizen 8.0 / TFM: net6.0-tizen8.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.