SplashForm.cs 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. using System.Windows.Forms;
  2. using FastReport.Utils;
  3. namespace FastReport.Forms
  4. {
  5. /// <summary>
  6. /// Represents the Splash Screen showing during loading designer
  7. /// </summary>
  8. public partial class SplashForm : BaseForm, IMessageFilter
  9. {
  10. /// <summary>
  11. /// Initializes a new instance of the <see cref="SplashForm"/> class.
  12. /// </summary>
  13. public SplashForm()
  14. {
  15. InitializeComponent();
  16. BackgroundImage = GetImage("Images.Splash.png");
  17. #if COMMUNITY
  18. if (Utils.Config.SplashScreen != null)
  19. BackgroundImage = Utils.Config.SplashScreen;
  20. #endif
  21. }
  22. /// <summary>
  23. /// Filters mouse events.
  24. /// For internal use only.
  25. /// </summary>
  26. public bool PreFilterMessage(ref Message m)
  27. {
  28. if (m.Msg == 0x201 || m.Msg == 0x202 || m.Msg == 0x203 ||
  29. m.Msg == 0x204 || m.Msg == 0x205 || m.Msg == 0x206)
  30. return true;
  31. return false;
  32. }
  33. }
  34. }