-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMain.ahk
73 lines (57 loc) · 1.71 KB
/
Main.ahk
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
#NoEnv
SendMode Input
SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory.
#SingleInstance Force
;Menu TRAY, NoStandard
OnExit, ExitSub ; do cleanup things on exit to unload DLLs and hide OSDs
#include %A_ScriptDir%\includes
#include Server-head.ahk
Init_OSD() ; initializations for Text-OSD
Init_Remote() ; initializations for remote control script
Return
#include MS_RemoteControl.ahk
#include MS_TextOSD.ahk
#include Code.ahk
#include Server-functions.ahk
Test()
{
;OpenChrome("http://svtplay.se/kontroll", 1)
Reload
}
TrayDisconnect:
NormalClose()
Return
ExitSub:
TrayExit:
DllCall("Ws2_32\WSACleanup")
;Gosub HideVolumeOSD ; hide VolumeOSD before
Gosub Hide_OSD ; hide Text Based OSD
;Gosub VolumeBar_Hide ; hide Volume Bar OSD
Gosub Remote_Cleanup ; DLL-cleanup for remote control script
ExitApp, 0 ; End script
Return
; The following need to be in main file for self parsing stuff to work?
; ==========Begin Custom Labels========== (Do not delete this line.)
; Put a comment after a label to prevent it from being a command.
Standby:
Run "C:\Windows\nircmd.exe" standby
Return
YouTube:
OpenChrome("http://youtube.com/tv", 1, "YouTube TV")
Return
SvtKontroll:
OpenChrome("http://svtplay.se/kontroll", 1, "SVT Play Kontroll")
Return
SvtPlay:
OpenChrome("http://svtplay.se/", 1, "SVT Play")
Return
XBMC:
if WinExist("ahk_class XBMC") ; if XBMC is not active
{
WinActivate
WinMaximize
}
else
{
Run, "%ProgramFiles%\XBMC\XBMC.exe" ; run XBMC
}