Strage figure behavior with compiled .NET library
1 次查看(过去 30 天)
显示 更早的评论
I have a .NET library that I compiled using the deploy tool. I after it does some calculations, it displays a two figures. Whenever I perform an action on the figure, the respone is delayed until a perform a second action.
With these figures, I replaced the OnClosingRequest function to hide them instead of deleting them so that the user can click a button to open the figure up again. If I use MATLAB natively or if I use the COM capability with C# then this works fine. But when I compile the code, I run into that delayed response issue. In this case, when the users clicks the X on the window, it doesn't hide until they perform a second action such as clicking the menu or something. Then as soon as they click the menu, it hides the figure.
Also, when I run the command from C# to re-display the figure that's hidden, it won't display unless I click a menu on the other figure.
The way my MATLAB code works is that I have a function called "prevent_display_closing(name)". Inside of this, it finds the figure with that name and calls a private static function called "override_CloseRequestFcn(fig)". Inside of this, it uses set(hObject, 'CloseRequestFcn', function) where function is a static public function that just sets hObject.Visible = 'Off'.
Is there something specific that could be causing this?
I am using MATLAB 2017b.
0 个评论
回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 MATLAB Compiler SDK 的更多信息
产品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!