diff options
author | Alexey Kulakov <panda75@bk.ru> | 2014-04-05 17:52:11 +0000 |
---|---|---|
committer | Alexey Kulakov <panda75@bk.ru> | 2014-04-05 17:52:11 +0000 |
commit | c4e2e2cfa438205154e7a074e46bd0fb267bb35d (patch) | |
tree | d75c11082a4d9f71a4858af52d216e3b2b907fd9 /plugins/mRadio/rframeapi.pas | |
parent | 0b9c05beba5766dfc43e127244b1c4893e9c8a5d (diff) |
mRadio "Quick Open" added
git-svn-id: http://svn.miranda-ng.org/main/trunk@8863 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/mRadio/rframeapi.pas')
-rw-r--r-- | plugins/mRadio/rframeapi.pas | 35 |
1 files changed, 24 insertions, 11 deletions
diff --git a/plugins/mRadio/rframeapi.pas b/plugins/mRadio/rframeapi.pas index dd44aaa353..84a5e25f76 100644 --- a/plugins/mRadio/rframeapi.pas +++ b/plugins/mRadio/rframeapi.pas @@ -35,6 +35,7 @@ var function QSDlgResizer(Dialog:HWND;lParam:LPARAM;urc:PUTILRESIZECONTROL):int; cdecl;
begin
case urc^.wId of
+ IDC_RADIO_OPEN: result:=RD_ANCHORX_LEFT or RD_ANCHORY_CENTRE;
IDC_RADIO_MUTE: result:=RD_ANCHORX_RIGHT or RD_ANCHORY_CENTRE;
IDC_RADIO_VOL : result:=RD_ANCHORX_WIDTH or RD_ANCHORY_CENTRE;
else
@@ -115,21 +116,30 @@ begin end;
WM_DRAWITEM: begin
- if wParam=IDC_RADIO_MUTE then
- begin
- result:=1;
- if gVolume<0 then
- tmp:=IcoBtnOff
- else
- tmp:=IcoBtnOn;
- DrawIconEx(PDRAWITEMSTRUCT(lParam)^.hDC,0,0,
- CallService(MS_SKIN2_GETICON,0,TLPARAM(tmp)),
- 16,16,0,hbr,DI_NORMAL);
+ case wParam of
+ IDC_RADIO_OPEN: begin
+ result:=1;
+ DrawIconEx(PDRAWITEMSTRUCT(lParam)^.hDC,0,0,
+ CallService(MS_SKIN2_GETICON,0,TLPARAM(IcoBtnOpen)),
+ 16,16,0,hbr,DI_NORMAL);
+ end;
+
+ IDC_RADIO_MUTE: begin
+ result:=1;
+ if gVolume<0 then
+ tmp:=IcoBtnOff
+ else
+ tmp:=IcoBtnOn;
+ DrawIconEx(PDRAWITEMSTRUCT(lParam)^.hDC,0,0,
+ CallService(MS_SKIN2_GETICON,0,TLPARAM(tmp)),
+ 16,16,0,hbr,DI_NORMAL);
+ end;
end;
end;
WM_CTLCOLORBTN: begin
- if THANDLE(lParam)=GetDlgItem(Dialog,IDC_RADIO_MUTE) then
+ if (THANDLE(lParam)=GetDlgItem(Dialog,IDC_RADIO_MUTE)) or
+ (THANDLE(lParam)=GetDlgItem(Dialog,IDC_RADIO_OPEN)) then
begin
SetBkColor(wParam, frm_bkg);
result:=hbr;
@@ -153,6 +163,9 @@ begin BN_CLICKED: begin
case loword(wParam) of
+ IDC_RADIO_OPEN: begin
+ CallService(MS_RADIO_QUICKOPEN,0,0);
+ end;
IDC_RADIO_MUTE: begin
CallService(MS_RADIO_MUTE,0,1);
end;
|