コード例 #1
0
        protected override void OnFormClosing(FormClosingEventArgs e)
        {
            if (e.CloseReason == CloseReason.UserClosing)
            {
                HostWindowSettings settings = new HostWindowSettings(Text)
                                                    {Location = Location, Size = Size};
                settings.Save();
            }

            base.OnFormClosing(e);
        }
コード例 #2
0
 protected override void OnLoad(EventArgs e)
 {
     HostWindowSettings settings = new HostWindowSettings(Text);
     SetLocation(settings.Location, settings.Size);
     base.OnLoad(e);
 }