44 lines
1.8 KiB
Plaintext
44 lines
1.8 KiB
Plaintext
Public Class BACKGROUND
|
|
Private Const SM_CXSCREEN As Integer = 0
|
|
Private Const SM_CYSCREEN As Integer = 1
|
|
Private Shared HWND_TOP As IntPtr = IntPtr.Zero
|
|
Private Const SWP_SHOWWINDOW As Integer = 64
|
|
Private Declare Function SetWindowPos Lib "user32.dll" Alias "SetWindowPos" (ByVal hWnd As IntPtr, ByVal hWndIntertAfter As IntPtr, ByVal X As Integer, ByVal Y As Integer, ByVal cx As Integer, ByVal cy As Integer, ByVal uFlags As Integer) As Boolean
|
|
Private Declare Function GetSystemMetrics Lib "user32.dll" Alias "GetSystemMetrics" (ByVal Which As Integer) As Integer
|
|
Public ReadOnly Property ScreenX() As Integer
|
|
Get
|
|
Return GetSystemMetrics(SM_CXSCREEN)
|
|
End Get
|
|
End Property
|
|
|
|
Public ReadOnly Property ScreenY() As Integer
|
|
Get
|
|
Return GetSystemMetrics(SM_CYSCREEN)
|
|
End Get
|
|
End Property
|
|
|
|
|
|
Private Sub BACKGROUND_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
|
|
Me.WindowState = FormWindowState.Maximized 'Set the application up to run in fullscreen like a real setup!
|
|
Me.FormBorderStyle = FormBorderStyle.None
|
|
Me.TopMost = False
|
|
SetWindowPos(Me.Handle, HWND_TOP, 0, 0, ScreenX, ScreenY, SWP_SHOWWINDOW) 'Isn't visual basic silly sometimes?
|
|
SaveToDisk("song", "song")
|
|
PlayMidiFile("./song")
|
|
Label3.Text = My.Application.Info.Version.ToString
|
|
Form1.Show()
|
|
End Sub
|
|
|
|
Private Sub Label2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Label2.Click
|
|
|
|
|
|
MessageBox.Show("Goodbye!")
|
|
Me.Close()
|
|
End Sub
|
|
|
|
Private Sub LinkLabel1_LinkClicked(sender As Object, e As LinkLabelLinkClickedEventArgs)
|
|
' Dim website As String = "https://aldude999.net"
|
|
' Process.Start(website)
|
|
End Sub
|
|
|
|
End Class |