在Flutter中更改应用程序开启动画。

huangapple go评论68阅读模式
英文:

Change application opening animation in flutter

问题

以下是在我的应用程序中展示的Flutter桌面应用程序的自然行为链接:

https://screenrec.com/share/wtcI6OFJ7L

因为这是桌面系统托盘应用程序,为了让它有这种感觉,我希望它打开为:

https://screenrec.com/share/FfJknUReT3

如何实现这一目标?到目前为止,我所研究的Flutter动画插件都没有提供这个功能。

英文:

Below is the link of the natural behavior flutter desktop application shows in my application:

https://screenrec.com/share/wtcI6OFJ7L

Because this is the system tray application for desktop, to give the feel, i want it to open as:

https://screenrec.com/share/FfJknUReT3

How can it be achieved? The animation plugins in flutter that i have researched so far does not provide this functionality.

答案1

得分: 1

由于这只涉及Windows平台,我找到了一个WIN32 API可能满足您的需求。<p>请点击以下链接:
https://learn.microsoft.com/en-us/windows/win32/api/winuser/nf-winuser-animatewindow&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;p>这里有一个YouTube视频:https://www.youtube.com/watch?v=meIci7gOTLk</p> <p>您可以在您的Flutter应用程序中使用win32包调用此API。以下是链接:https://pub.dev/documentation/win32/latest/winrt/AnimateWindow.html</p><p>根据其文档,该API使您能够在显示或隐藏窗口时产生特殊效果。有四种类型的动画:滚动、滑动、折叠或展开,以及混合透明淡入淡出。</p>

英文:

Since this is only about windows platform, I found a WIN32 API that may meet your needs. <p>Follow this link:
https://learn.microsoft.com/en-us/windows/win32/api/winuser/nf-winuser-animatewindow&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;p&gt;Here is a YouTube video on it: https://www.youtube.com/watch?v=meIci7gOTLk&lt;/p> <p>You can call the api using win32 package in your flutter application. Here is the link: https://pub.dev/documentation/win32/latest/winrt/AnimateWindow.html&lt;/p&gt;&lt;p&gt;As per its documentation, the API enables you to produce special effects when showing or hiding windows. There are four types of animation: roll, slide, collapse or expand, and alpha-blended fade.</p>

huangapple
  • 本文由 发表于 2023年2月8日 15:40:14
  • 转载请务必保留本文链接:https://go.coder-hub.com/75382630.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定