this will activate voice if used with F10, theres 2 CUSTOM indicators for voice control, one for the mic when is on("!MIC_ENABLED") and the other for when is in listening mode, ("!ONCOMMAND"), i'm thinking in a way to add some artist albums and genres to the xml, from winamps plugin, that way if RR plays it is going to be added to the xml, and then compile it to commands. lets say something like... "Computer Play Sade" or "Computer Play Classic Rock". is doable, i got the playlist done, but still having problems with voice control.
Code:
#Include <Misc.au3>
AutoItSetOption("WinTitleMatchMode", 3)
$test = "text Mode"
If WinExists($test) Then Exit
AutoItWinSetTitle($test)
$rr=ObjCreate("RoadRunner.sdk")
if not IsObj($rr) then Exit
$oMyError = ObjEvent("AutoIt.Error","MyErrFunc")
While 1
$Status = $rr.getinfo("STATUS")
If $oMyError.windescription then ;if theres an error using RR sdk, see if RR is running.
if Not WinExists("RoadRunner") then ExitLoop ;exit if RR is not Running.
EndIf
if MouseGetCursor() = 5 And _IsPressed("01") then
;MsgBox(4096, "", " text mode")
_Activate()
EndIf
Sleep (3000) ;push and hold 3 sec for executing.
WEnd
;==============================================================================================
;Activate Voice
;==============================================================================================
Func _Activate()
if $Status = "PLAY" Then $rr.execute("PAUSE") ;in case music is playing before click, pause
$Voice = WinGetHandle("RoadRunner", "")
WinActivate($Voice, "")
Send("{F10}")
EndFunc
;==============================================================================================
;AI's error reporting Object
;==============================================================================================
Func MyErrFunc()
Local $err = $oMyError.number
If $err = 0 Then $err = -1
SetError($err)
Endfunc
Func _exit()
Exit
EndFunc
Bookmarks