Files
c-sharp/MozogForm/Form1.cs

33 lines
833 B
C#
Raw Normal View History

2022-05-31 08:46:10 +02:00
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace MozogForm {
public partial class Form1 : Form {
2022-06-07 13:52:04 +02:00
private const int MOVE_SIZE = 10;
2022-05-31 08:46:10 +02:00
public Form1() {
InitializeComponent();
}
2022-06-07 13:52:04 +02:00
private void buttonFSZ_Click(object sender, EventArgs e) {
Top = 0;
}
private void buttonF_Click(object sender, EventArgs e) {
Top -= MOVE_SIZE;
if (Top < 0) {
Top = 0;
} else if (Top > Screen.PrimaryScreen.WorkingArea.Height - Height) {
Top = Screen.PrimaryScreen.WorkingArea.Height - Height;
}
}
2022-05-31 08:46:10 +02:00
}
}