📄 splashform.cs
字号:
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using System.Reflection;
namespace cfWorldWind
{
public partial class SplashForm : Form
{
public SplashForm()
{
InitializeComponent();
}
private void SplashForm_Load(object sender, EventArgs e)
{
Bitmap b;
Assembly asm = Assembly.GetExecutingAssembly();
string splashFile = "splashPortrait.PNG"; //assume portrait
if (this.Width > this.Height)
{
splashFile = "splashLandscape.PNG";
}
string refPath = asm.GetName().Name;
//capitalization of file names matters (including extensions)
b = new Bitmap(asm.GetManifestResourceStream(refPath + "." + splashFile));
pictureBox1.Image = b;
}
public void KillMe(object o, EventArgs e)
{
//splashTimer.Dispose();
this.Close();
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -