From: Eunki Hong Date: Wed, 28 Sep 2022 05:16:15 +0000 (+0900) Subject: [NUI] Remove useless PostProcess callback (#4607) X-Git-Tag: submit/tizen/20221004.113029~1^2~9 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=f5f1bf8cbb165157677bf04bace8d55aabed6d19;p=platform%2Fcore%2Fcsapi%2Ftizenfx.git [NUI] Remove useless PostProcess callback (#4607) Instead of register PostProcess, We'd better invoke ProcessorOnceEvent one more time after LayoutProcessorEvent finished. Signed-off-by: Eunki, Hong Signed-off-by: Eunki, Hong Co-authored-by: Eunki, Hong --- diff --git a/src/Tizen.NUI/src/internal/Common/ProcessorController.cs b/src/Tizen.NUI/src/internal/Common/ProcessorController.cs index b6397b7d8..e4a847dbb 100755 --- a/src/Tizen.NUI/src/internal/Common/ProcessorController.cs +++ b/src/Tizen.NUI/src/internal/Common/ProcessorController.cs @@ -42,16 +42,13 @@ namespace Tizen.NUI internal ProcessorController(global::System.IntPtr cPtr, bool cMemoryOwn) : base(cPtr, cMemoryOwn) { processorCallback = new ProcessorEventHandler(Process); - processorPostCallback = new ProcessorEventHandler(PostProcess); Interop.ProcessorController.SetCallback(SwigCPtr, processorCallback); - Interop.ProcessorController.SetPostCallback(SwigCPtr, processorPostCallback); } [UnmanagedFunctionPointer(CallingConvention.StdCall)] internal delegate void ProcessorEventHandler(); private ProcessorEventHandler processorCallback = null; - private ProcessorEventHandler processorPostCallback = null; public event EventHandler ProcessorOnceEvent; public event EventHandler ProcessorEvent; @@ -75,10 +72,9 @@ namespace Tizen.NUI ProcessorOnceEvent = null; ProcessorEvent?.Invoke(this, null); LayoutProcessorEvent?.Invoke(this, null); - } - public void PostProcess() - { + // To avoid ImageView's properties mismatched problem, + // We need to invoke events now which attached during LayoutProcessor. ProcessorOnceEvent?.Invoke(this, null); ProcessorOnceEvent = null; } @@ -90,7 +86,6 @@ namespace Tizen.NUI protected override void Dispose(DisposeTypes type) { Interop.ProcessorController.RemoveCallback(SwigCPtr, processorCallback); - Interop.ProcessorController.RemovePostCallback(SwigCPtr, processorPostCallback); ProcessorOnceEvent = null; ProcessorEvent = null; LayoutProcessorEvent = null;