AutoHotkey Community

It is currently May 27th, 2012, 11:59 am

All times are UTC [ DST ]




Post new topic Reply to topic  [ 27 posts ]  Go to page Previous  1, 2
Author Message
 Post subject:
PostPosted: August 17th, 2011, 10:25 am 
Offline

Joined: May 11th, 2011, 11:51 pm
Posts: 31
This is excellent! Exactly what I needed.

I just have one peeve... (well two really, but the second is a glitch I think)

The OSD minimizes some fullscreen apps like games, it'd be great if it was possible for the OSD to show up as an overlay, barring that, if the script could be modified to simply not take focus with fullscreen apps running.

The second, it's kinda weird, but if I have the "Edit Script" window open (I use notepad) for the "Volume Control.ahk" file (and only this specific AHK file) the mousewheel gesture doesn't wait for the 0.5 seconds, in fact, you don't need to press it at all (meaning you can use the mousewheel to scroll through this file)

Anyway, this is the definitely by far the best looking, quickest, and most functional Volume OSD I've seen, even including non-AHK types, so thank you! :D


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: August 22nd, 2011, 6:36 pm 
Offline

Joined: November 12th, 2009, 4:39 pm
Posts: 17
Very nice script. Last time I had a script like this it was very oldschool just coloured bars. The integration with Win 7 seems pretty cool now.


Report this post
Top
 Profile  
Reply with quote  
 Post subject: Just a quick thanks
PostPosted: October 26th, 2011, 3:07 pm 
Offline

Joined: October 5th, 2009, 6:02 pm
Posts: 66
Location: southampton UK
:lol: :lol: :lol: Thanks for this great script , Good work

_________________
All`s well that ends well :-)
I will not appreciate sarcastic or personal insults in reply s to my posts . Those are the acts of cowards being brave from afar .If you cant be productive don't be destructive .


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 24th, 2011, 9:34 pm 
Offline

Joined: March 7th, 2009, 6:36 pm
Posts: 17
Thanks for this script

I added this lines,seems to be more fast and usable with the combo right+wheel

Code:
RButton & wheeldown::
PostMessage("Volume Control - message receiver",02)
return

RButton & wheelup::
PostMessage("Volume Control - message receiver",01)
return

RButton::Send, {RButton}


Report this post
Top
 Profile  
Reply with quote  
 Post subject: Thanks
PostPosted: February 11th, 2012, 1:12 am 
Offline

Joined: September 20th, 2011, 3:41 pm
Posts: 1
Nice job. Appreciate your effort.


Report this post
Top
 Profile  
Reply with quote  
 Post subject: Reply
PostPosted: February 17th, 2012, 11:00 am 
Can the volume be controlled by increasing/decreasing by 1% only?

(It changes by 4% for me)

Thanks :D


Report this post
Top
  
Reply with quote  
 Post subject: volume control OSD
PostPosted: February 21st, 2012, 12:05 am 
Hi,

Well, your script works like a charm!

I kindly installed it for volume control purpose and since it was running on my machine, I kept having trouble within Microsoft Internet Explorer 9 - the latest release, up-to-date.

I gently bawled at the Microsoft Team on the telephon about this pretty nice recurrent trouble I have been running through! : the "SHIFT" key holding untimely and gently while navigating within the Microsoft Internet Explorer 9 - up-to-date, should I recall!

So...

After the nice response I got from the hotline, I broke gently my nice pretty 100 bucks keyboard in pieces!

So...

You know what ?

I am gonna look for your father and smash his nuts to prevent him from polluting again the earth with such dumbass-geeked gays of yours!

And you know what ?

I won't be finished with you!

Just wait and see...

U son of a gun!

I will teach you how-to script the right way!

Upon this, I wish you I niece day - u loose nothing to wait...

U looser...

Bye, bye.

;)


Report this post
Top
  
Reply with quote  
 Post subject:
PostPosted: February 21st, 2012, 1:19 am 
Offline

Joined: October 13th, 2009, 10:09 pm
Posts: 1389
Didn't you post nearly the same crap on another thread? :P
You don't really expect anyone to take your serious, do you? ;)


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: February 22nd, 2012, 12:37 pm 
lol
I do not indeed
this is just for fun lol
:wink:


Report this post
Top
  
Reply with quote  
 Post subject: volume control OSD
PostPosted: February 26th, 2012, 11:34 pm 
Hi,

I just want to make it clear

Each time your script
*******

;Volume Control v1.10 for Windows7
;by Filipe Novais

;====================================================================================================================
;Options ============================================================================================================
;====================================================================================================================
Volume_Increments_general = 2 ;Volume increments for keyboard default "Vol+" "Vol-" keys
Volume_Increments_mouse = 3 ;Volume increments for mouse wheel gestures "up" "down"
Visible_Duration = 1800 ;Duration of Volume Control display (milliseconds)



;====================================================================================================================
;Startup ============================================================================================================
;====================================================================================================================
#Include *i VA.ahk
Volume_Increments = %Volume_Increments_general%
OnMessage(0x1001,"VC_ReceiveMessage")
Gui 29: show, hide, Volume Control - message receiver
Menu, Tray, Icon, Shell32.dll, 169 ; Square Speaker Icon
;Menu, Tray, Icon, %SystemRoot%\system32\Mmsys.cpl,1 ; Standard Speaker Icon



;====================================================================================================================
;Volume OSD Background ==============================================================================================
;====================================================================================================================
Gui, 27: +AlwaysOnTop +ToolWindow -caption +LastFound
WinSet, Region, 0-0 W602 H59
Gui, 27: Color, FFFF00
Gui, 27: Add, Picture, w602 h59 x0 y0, %A_ScriptDir%\Pictures\Background.png
WinSet, TransColor, FFFF00 255



;====================================================================================================================
;Volume OSD Bars and Speakers =======================================================================================
;====================================================================================================================
Gui, 28: +AlwaysOnTop +ToolWindow -caption +LastFound
WinSet, Region, 0-0 W602 H59
Gui, 28: Color, FFFF00
WinSet, TransColor, FFFF00 255
Gui, 28: Add, Picture, w81 h59 x0 y0 gMute_On_Off vMuteOff, %A_ScriptDir%\Pictures\SpeakerSound.png
Gui, 28: Add, Picture, w81 h59 x0 y0 gMute_On_Off vMuteOn, %A_ScriptDir%\Pictures\SpeakerMute.png
startp = 83
Loop 100
{
Gui, 28: Add, Picture, vBF%A_Index% w5 h29 x%startp% y15 gVolume_Bar_Click, %A_ScriptDir%\Pictures\Full.png
Gui, 28: Add, Picture, vBE%A_Index% w5 h29 x%startp% y15 gVolume_Bar_Click, %A_ScriptDir%\Pictures\Empty.png
startp += 5
}
return


;====================================================================================================================
;Hotkeys ============================================================================================================
;====================================================================================================================


$Volume_Up:: ;Keyboard default "Vol+" key
Gosub, Up_Volume
return

$Volume_down:: ;Keyboard default "Vol-" key
Gosub, Down_Volume
return

$Volume_Mute:: ;Keyboard default Mute/Unmute key
Gosub, Mute_On_Off
return


;====================================================================================================================
;Labels =============================================================================================================
;====================================================================================================================


Up_Volume:
volume_level := VA_GetMasterVolume()
volume_level += %Volume_Increments%
VA_SetMasterVolume(volume_level)
Gosub, Volume_Bar_Update
return


Down_Volume:
volume_level := VA_GetMasterVolume()
volume_level -= %Volume_Increments%
VA_SetMasterVolume(volume_level)
Gosub, Volume_Bar_Update
return


Volume_Bar_Update:
If WinActive("FullScreenBottomLayout")
fullscreen=1
volume_level := VA_GetMasterVolume()
SetTimer, Volume_Bar_Hide, off
Loop %volume_level%
{
GuiControl,28: Hide, BE%A_Index%
GuiCOntrol,28: Show, BF%A_Index%
}
volume_level2 := 100 - volume_level
Loop %volume_level2%
{
index := 101 - A_Index
GuiCOntrol,28: Hide, BF%index%
GuiControl,28: Show, BE%index%
}
Volume_Bar_Update2:
if VA_GetMasterMute()
{
GuiControl,28: Show, MuteOn
GuiCOntrol,28: Hide, MuteOff
}
else
{
GuiControl,28: Show, MuteOff
GuiCOntrol,28: Hide, MuteOn
}
gosub, Show_Background
Gui, 28: +AlwaysOnTop
Gui, 28: Show, xCenter yCenter w602 h95 NoActivate
SetTimer, Volume_Bar_Hide, %Visible_Duration%
return


Volume_Bar_Hide:
SetTimer, Volume_Bar_Hide, off
Gui, 28: Hide
Gui, 27: Hide
Background_Vis=0
if fullscreen=1
{
sleep 300
fullscreen=0
;WinActivate, Windows Media Player
;send, !{ENTER}
}
return


Show_Background:
If %Background_Vis%
return
Gui, 27: +AlwaysOnTop
Gui, 27: Show, xCenter yCenter w602 h95 NoActivate
Background_Vis=1
return


Volume_Bar_Click:
Gui_Bar_To_Volume=% A_GuiControl
StringTrimLeft, volume_level, Gui_Bar_To_Volume, 2
VA_SetMasterVolume(volume_level)
Gosub, Volume_Bar_Update
return


Mute_On_Off:
if VA_GetMasterMute()
{
VA_SetMasterMute(false)
Gosub, Volume_Bar_Update2
}
else
{
VA_SetMasterMute(true)
Gosub, Volume_Bar_Update2
}
return


Volume_Mouse_on:
Volume_Increments = %Volume_Increments_mouse%
return


Volume_Mouse_off:
Volume_Increments = %Volume_Increments_general%
return


;====================================================================================================================
;Messages ===========================================================================================================
;====================================================================================================================


VC_ReceiveMessage(Message)
{
if Message = 01 ; Volume increase with mouse wheel gesture
{
Gosub, Volume_Mouse_on
Gosub, Up_Volume
Gosub, Volume_Mouse_off
return
}

else if Message = 02 ; Volume decrease with mouse wheel gesture
{
Gosub, Volume_Mouse_on
Gosub, Down_Volume
Gosub, Volume_Mouse_off
return
}

else if Message = 03 ; Mute/Unmute
Gosub, Mute_On_Off

else if Message = 04 ; show Volume Control
Gosub, Volume_Bar_Update

else if Message = 05 ; Volume Control Reload script
Reload
}
return


;====================================================================================================================
;====================================================================================================================
;================================================== Control Example =================================================
;====================================================================================================================
;====================================================================================================================


MButton::
If WinActive("Volume Control.ahk")
{
PostMessage("Volume Control - message receiver",03)
return
}
StartTime := A_TickCount
KeyWait, MButton
if (A_TickCount - StartTime < 500)
{
MouseGetPos, xpos, ypos
MouseClick, Middle, xpos, ypos
return
}
else
{
PostMessage("Volume Control - message receiver",04)
return
}
return


wheelup::
If WinActive("Volume Control.ahk")
{
PostMessage("Volume Control - message receiver",01)
return
}
send {wheelup}
return


wheeldown::
If WinActive("Volume Control.ahk")
{
PostMessage("Volume Control - message receiver",02)
return
}
send {wheelDown}
return


PostMessage(Receiver,Message) {
oldTMM := A_TitleMatchMode
oldDHW := A_DetectHiddenWindows
SetTitleMatchMode, 3
DetectHiddenWindows, on
PostMessage, 0x1001,%Message%,,,%Receiver% ahk_class AutoHotkeyGUI
SetTitleMatchMode, %oldTMM%
DetectHiddenWindows, %oldDHW%
}
return
***********
runs on my machine, I get unexpected and unauthorized "shift" keyboard key access from this script of the hell!

will you please review your script, and correct this ?...

thank you sir.

bye bye.

:?


Report this post
Top
  
Reply with quote  
 Post subject:
PostPosted: February 28th, 2012, 3:52 am 
Offline

Joined: April 17th, 2011, 2:15 am
Posts: 12
[SOLVED]
After further experimentation I figured out I needed to copy the whole function PostMessage(Receiver,Message) into my script and call that (à la PostMessage("Volume Control - message receiver",04) on line 241).
For some reason just copying contents of the PostMessage() function (lines 270-272) directly didn't work.
Go figure. Probably a quotation mark issue.
Thanks

[ORIGINAL POST]

Very nice program.

I have a question, since I am new to passing messages back & forth between programs.

In my script (Vol_Headphones.ahk), what lines of code do I need in order to get your script to display the OSD volume update?
I assume both my script (Vol_Headphones.ahk) & your script (Volume Control.ahk) are simultaneously running. My script will handle the VA_SetMasterVolume() and just use yours to show the GUI.

I guess I need a PostMessage <something something>, but I have never used that line before.
My simple guesses for writing the correct line of code have failed.


Thanks for the help.


Report this post
Top
 Profile  
Reply with quote  
 Post subject: lol
PostPosted: March 3rd, 2012, 3:35 pm 
Please do not play comedy... making as if nothing was going on...
You are quite ridiculous, just like geeks do...
lol
:lol:


Report this post
Top
  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 27 posts ]  Go to page Previous  1, 2

All times are UTC [ DST ]


Who is online

Users browsing this forum: notsoobvious, rrhuffy and 18 guests


You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Powered by phpBB® Forum Software © phpBB Group