-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathFastSearch.ahk
66 lines (61 loc) · 1.55 KB
/
FastSearch.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
I_Icon = fs-logo-mod-new-ico.ico
IfExist, %I_Icon%
Menu, Tray, Icon, %I_Icon%
Gui, Add, Text,, Enter your search:
Gui, Add, Edit, w400 h100 vtext,
Gui, Add, Text,, Where?
Gui, Add, DropdownList,w400 h100 vList,DuckDuckGo||Google|Yahoo|Odysee|Youtube|Link
Gui, Add,Button,gOk wp,Search
Gui, Font, s12,Courier New
Gui, Add, Text,cRed +Right w400, by ZETALVX
goto, GUIC
GUIC:
Gui, Show,AutoSize,FastSearch
return
Ok:
Gui,Submit,Nohide
StringLen, textl, text
if(List="Google")
{
parameter = https://www.google.com/search?q=%text%
StringReplace, parameter, parameter, %A_Space%, +, All
Run %parameter%
}
if(List="DuckDuckGo")
{
parameter = https://duckduckgo.com/?q=%text%
StringReplace, parameter, parameter, %A_Space%, +, All
Run %parameter%
}
if(List="Odysee")
{
parameter = https://odysee.com/$/discover?t=%text%
StringReplace, parameter, parameter, %A_Space%, +, All
Run %parameter%
}
if(List="Youtube")
{
parameter = https://www.youtube.com/results?search_query=%text%
StringReplace, parameter, parameter, %A_Space%, +, All
Run %parameter%
}
if(List="Yahoo")
{
parameter = https://search.yahoo.com/search?p=%text%
StringReplace, parameter, parameter, %A_Space%, +, All
Run %parameter%
}
if(List ="Link")
{
parameter = %text%
StringReplace, parameter, parameter, https://, , All
StringReplace, parameter, parameter, http://, , All
Run https://%parameter%
}
;if you want to close the program after the search add this line --> While WinExist("ahk_exe " "FastSearch")
return
GuiClose:
ExitApp
!s::
Goto, GUIC
return