Página 1 de 1

OnDblClick in TMonthCalendar

Publicado: Vie Abr 20, 2007 1:23 pm
por Oleg
Dear developers!
I assigned OnDblClick event in TMonthCalendar control (placed on the form),
but it does not fired.
I need it to enter some date value into TEdit control (placed on another
form). I cannot do it with OnClick event because it is fired when I change
the month
(buttons on the top of TMonthCalendar).
Can you look at this?
Thank you. Oleg.

OnDblClick in TMonthCalendar

Publicado: Vie Abr 20, 2007 1:55 pm
por ignacio
Oleg,
I am afraid this API control does not send any WM_LButtonDblClk messages.
Sorry. We will eliminate the event on next revision.
Regards,
--
Ignacio Ortiz de Zúñiga
http://www.xailer.com
"Oleg" <info@cluster.samara.ru> escribió en el mensaje
news:[email=4628a2dd@ozsrv2.ozlan.local...]4628a2dd@ozsrv2.ozlan.local...[/email]
> Dear developers!
>
> I assigned OnDblClick event in TMonthCalendar control (placed on the
> form),
> but it does not fired.
> I need it to enter some date value into TEdit control (placed on another
> form). I cannot do it with OnClick event because it is fired when I change
> the month
> (buttons on the top of TMonthCalendar).
>
> Can you look at this?
>
> Thank you. Oleg.
>
>
>
>

OnDblClick in TMonthCalendar

Publicado: Vie Abr 20, 2007 1:55 pm
por NoName
Oleg,
I am afraid this API control does not send any WM_LButtonDblClk messages.
Sorry. We will eliminate the event on next revision.
Regards,
--
Ignacio Ortiz de Zúñiga
http://www.xailer.com
"Oleg" <info@cluster.samara.ru> escribió en el mensaje
news:[email=4628a2dd@ozsrv2.ozlan.local...]4628a2dd@ozsrv2.ozlan.local...[/email]
> Dear developers!
>
> I assigned OnDblClick event in TMonthCalendar control (placed on the
> form),
> but it does not fired.
> I need it to enter some date value into TEdit control (placed on another
> form). I cannot do it with OnClick event because it is fired when I change
> the month
> (buttons on the top of TMonthCalendar).
>
> Can you look at this?
>
> Thank you. Oleg.
>
>
>
>

OnDblClick in TMonthCalendar

Publicado: Vie Abr 20, 2007 2:21 pm
por Oleg
Ignacio!
> I am afraid this API control does not send any WM_LButtonDblClk messages.
> Sorry. We will eliminate the event on next revision.
Maybe. I do not know Xailer's and Delphi's internals, but the same event in
Delphi is fired.
Thank you. Oleg.

OnDblClick in TMonthCalendar

Publicado: Vie Abr 20, 2007 2:21 pm
por Oleg
Ignacio!
> I am afraid this API control does not send any WM_LButtonDblClk messages.
> Sorry. We will eliminate the event on next revision.
Maybe. I do not know Xailer's and Delphi's internals, but the same event in
Delphi is fired.
Thank you. Oleg.

OnDblClick in TMonthCalendar

Publicado: Vie Abr 20, 2007 4:26 pm
por ignacio
Oleg,
It has nothing to do with Xailer, is the control behaviour. You can check it
your self with the Microsoft tool SPY.
Regards,
--
Ignacio Ortiz de Zúñiga
http://www.xailer.com
"Oleg" <info@cluster.samara.ru> escribió en el mensaje
news:[email=4628b053@ozsrv2.ozlan.local...]4628b053@ozsrv2.ozlan.local...[/email]
> Ignacio!
>
>> I am afraid this API control does not send any WM_LButtonDblClk messages.
>> Sorry. We will eliminate the event on next revision.
>
> Maybe. I do not know Xailer's and Delphi's internals, but the same event
> in Delphi is fired.
>
> Thank you. Oleg.
>
>

OnDblClick in TMonthCalendar

Publicado: Vie Abr 20, 2007 4:26 pm
por NoName
Oleg,
It has nothing to do with Xailer, is the control behaviour. You can check it
your self with the Microsoft tool SPY.
Regards,
--
Ignacio Ortiz de Zúñiga
http://www.xailer.com
"Oleg" <info@cluster.samara.ru> escribió en el mensaje
news:[email=4628b053@ozsrv2.ozlan.local...]4628b053@ozsrv2.ozlan.local...[/email]
> Ignacio!
>
>> I am afraid this API control does not send any WM_LButtonDblClk messages.
>> Sorry. We will eliminate the event on next revision.
>
> Maybe. I do not know Xailer's and Delphi's internals, but the same event
> in Delphi is fired.
>
> Thank you. Oleg.
>
>

OnDblClick in TMonthCalendar

Publicado: Vie Abr 20, 2007 8:48 pm
por ignacio
Oleg,
I confirm the event is fired in Delphi, but I also confirm that the message
is not generated by the control.
Surely Delphi has its own mechanism to generate double click events when the
control does not. We also have a similar mechanism for click events, but not
for double-click events, sorry. For example, the OnClick event generated on
TMonthCalendar is generated and triggered enterely by Xailer
Maybe in the future we will include the Double-click mechanism but I can
not give you a time frame for it. BTW, with the OnClick event it will be
quite easy for you to simulate a double click event, just save on a static
var the Seconds() value inside the OnClick event and check the difference of
time on next events, if is less than a really small number trigger the
OnDoubleClick() event. That's all.
Regards,
"Ignacio Ortiz de Zúñiga" <NoName@xailer.com> escribió en el mensaje
news:4628cd86$[email=1@ozsrv2.ozlan.local...]1@ozsrv2.ozlan.local...[/email]
> Oleg,
>
> It has nothing to do with Xailer, is the control behaviour. You can check
> it your self with the Microsoft tool SPY.
>
> Regards,
>
> --
> Ignacio Ortiz de Zúñiga
> http://www.xailer.com
>
>
> "Oleg" <info@cluster.samara.ru> escribió en el mensaje
> news:[email=4628b053@ozsrv2.ozlan.local...]4628b053@ozsrv2.ozlan.local...[/email]
>> Ignacio!
>>
>>> I am afraid this API control does not send any WM_LButtonDblClk
>>> messages. Sorry. We will eliminate the event on next revision.
>>
>> Maybe. I do not know Xailer's and Delphi's internals, but the same event
>> in Delphi is fired.
>>
>> Thank you. Oleg.
>>
>>
>
>

OnDblClick in TMonthCalendar

Publicado: Vie Abr 20, 2007 8:48 pm
por NoName
Oleg,
I confirm the event is fired in Delphi, but I also confirm that the message
is not generated by the control.
Surely Delphi has its own mechanism to generate double click events when the
control does not. We also have a similar mechanism for click events, but not
for double-click events, sorry. For example, the OnClick event generated on
TMonthCalendar is generated and triggered enterely by Xailer
Maybe in the future we will include the Double-click mechanism but I can
not give you a time frame for it. BTW, with the OnClick event it will be
quite easy for you to simulate a double click event, just save on a static
var the Seconds() value inside the OnClick event and check the difference of
time on next events, if is less than a really small number trigger the
OnDoubleClick() event. That's all.
Regards,
"Ignacio Ortiz de Zúñiga" <NoName@xailer.com> escribió en el mensaje
news:4628cd86$[email=1@ozsrv2.ozlan.local...]1@ozsrv2.ozlan.local...[/email]
> Oleg,
>
> It has nothing to do with Xailer, is the control behaviour. You can check
> it your self with the Microsoft tool SPY.
>
> Regards,
>
> --
> Ignacio Ortiz de Zúñiga
> http://www.xailer.com
>
>
> "Oleg" <info@cluster.samara.ru> escribió en el mensaje
> news:[email=4628b053@ozsrv2.ozlan.local...]4628b053@ozsrv2.ozlan.local...[/email]
>> Ignacio!
>>
>>> I am afraid this API control does not send any WM_LButtonDblClk
>>> messages. Sorry. We will eliminate the event on next revision.
>>
>> Maybe. I do not know Xailer's and Delphi's internals, but the same event
>> in Delphi is fired.
>>
>> Thank you. Oleg.
>>
>>
>
>

OnDblClick in TMonthCalendar

Publicado: Lun Abr 23, 2007 2:34 pm
por Oleg
Ignacio!
I have found how it is done in Delphi and how to overcome this in Xailer.
First, description from MSDN:
"Only windows that have the CS_DBLCLKS style can receive WM_LBUTTONDBLCLK
messages,
which Windows generates whenever the user presses, releases,
and again presses the left mouse button within the system's double-click
time limit. "
I create a function:
XA_FUNC( WNDDBLCLK )
{
HWND hWnd = ( HWND ) hb_parnl( 1 );
LONG st;
st=GetClassLong(hWnd, GCL_STYLE);
SetClassLong(hWnd, GCL_STYLE, st | CS_DBLCLKS);
hb_ret();
}
and call this in my form in OnCreate event of TMonthCalendar control:
METHOD MonthCalendarCreate( oSender ) CLASS TFormCalendar
WNDDBLCLK(oSender:Handle)
RETURN Nil
After this, OnDblClick event is fired in TMonthCalendar control.
Maybe you could include this into Xailer core for TMonthCalendar (in the
near releases)?
Thank you. Oleg.

OnDblClick in TMonthCalendar

Publicado: Lun Abr 23, 2007 2:34 pm
por Oleg
Ignacio!
I have found how it is done in Delphi and how to overcome this in Xailer.
First, description from MSDN:
"Only windows that have the CS_DBLCLKS style can receive WM_LBUTTONDBLCLK
messages,
which Windows generates whenever the user presses, releases,
and again presses the left mouse button within the system's double-click
time limit. "
I create a function:
XA_FUNC( WNDDBLCLK )
{
HWND hWnd = ( HWND ) hb_parnl( 1 );
LONG st;
st=GetClassLong(hWnd, GCL_STYLE);
SetClassLong(hWnd, GCL_STYLE, st | CS_DBLCLKS);
hb_ret();
}
and call this in my form in OnCreate event of TMonthCalendar control:
METHOD MonthCalendarCreate( oSender ) CLASS TFormCalendar
WNDDBLCLK(oSender:Handle)
RETURN Nil
After this, OnDblClick event is fired in TMonthCalendar control.
Maybe you could include this into Xailer core for TMonthCalendar (in the
near releases)?
Thank you. Oleg.

OnDblClick in TMonthCalendar

Publicado: Lun Abr 23, 2007 5:18 pm
por ignacio
Oleg,
Really strange, that style is already present on its acenstor TStdControl.
Maybe the control is resetting that style upon creation. I will have a
closer look at it. Thank you for the tip.
Regards
--
Ignacio Ortiz de Zúñiga
http://www.xailer.com
"Oleg" <info@cluster.samara.ru> escribió en el mensaje
news:[email=462ca7cf@ozsrv2.ozlan.local...]462ca7cf@ozsrv2.ozlan.local...[/email]
> Ignacio!
>
> I have found how it is done in Delphi and how to overcome this in Xailer.
>
> First, description from MSDN:
> "Only windows that have the CS_DBLCLKS style can receive WM_LBUTTONDBLCLK
> messages,
> which Windows generates whenever the user presses, releases,
> and again presses the left mouse button within the system's double-click
> time limit. "
>
> I create a function:
>
> XA_FUNC( WNDDBLCLK )
> {
> HWND hWnd = ( HWND ) hb_parnl( 1 );
> LONG st;
> st=GetClassLong(hWnd, GCL_STYLE);
> SetClassLong(hWnd, GCL_STYLE, st | CS_DBLCLKS);
>
> hb_ret();
> }
>
> and call this in my form in OnCreate event of TMonthCalendar control:
>
> METHOD MonthCalendarCreate( oSender ) CLASS TFormCalendar
> WNDDBLCLK(oSender:Handle)
> RETURN Nil
>
> After this, OnDblClick event is fired in TMonthCalendar control.
>
> Maybe you could include this into Xailer core for TMonthCalendar (in the
> near releases)?
>
> Thank you. Oleg.
>
>

OnDblClick in TMonthCalendar

Publicado: Lun Abr 23, 2007 5:18 pm
por NoName
Oleg,
Really strange, that style is already present on its acenstor TStdControl.
Maybe the control is resetting that style upon creation. I will have a
closer look at it. Thank you for the tip.
Regards
--
Ignacio Ortiz de Zúñiga
http://www.xailer.com
"Oleg" <info@cluster.samara.ru> escribió en el mensaje
news:[email=462ca7cf@ozsrv2.ozlan.local...]462ca7cf@ozsrv2.ozlan.local...[/email]
> Ignacio!
>
> I have found how it is done in Delphi and how to overcome this in Xailer.
>
> First, description from MSDN:
> "Only windows that have the CS_DBLCLKS style can receive WM_LBUTTONDBLCLK
> messages,
> which Windows generates whenever the user presses, releases,
> and again presses the left mouse button within the system's double-click
> time limit. "
>
> I create a function:
>
> XA_FUNC( WNDDBLCLK )
> {
> HWND hWnd = ( HWND ) hb_parnl( 1 );
> LONG st;
> st=GetClassLong(hWnd, GCL_STYLE);
> SetClassLong(hWnd, GCL_STYLE, st | CS_DBLCLKS);
>
> hb_ret();
> }
>
> and call this in my form in OnCreate event of TMonthCalendar control:
>
> METHOD MonthCalendarCreate( oSender ) CLASS TFormCalendar
> WNDDBLCLK(oSender:Handle)
> RETURN Nil
>
> After this, OnDblClick event is fired in TMonthCalendar control.
>
> Maybe you could include this into Xailer core for TMonthCalendar (in the
> near releases)?
>
> Thank you. Oleg.
>
>

OnDblClick in TMonthCalendar

Publicado: Lun Abr 23, 2007 5:32 pm
por ignacio
Oleg,
If I set or reset the style before the window creation, nothing happens,
BTW, you proposal works perfectly, and I have just included in the class so
it will be available on next release. Thank very much for your feedback.
Regards,
--
Ignacio Ortiz de Zúñiga
http://www.xailer.com
"Ignacio Ortiz de Zúñiga" <NoName@xailer.com> escribió en el mensaje
news:462cce49$[email=1@ozsrv2.ozlan.local...]1@ozsrv2.ozlan.local...[/email]
> Oleg,
>
> Really strange, that style is already present on its acenstor TStdControl.
> Maybe the control is resetting that style upon creation. I will have a
> closer look at it. Thank you for the tip.
>
> Regards
>
> --
> Ignacio Ortiz de Zúñiga
> http://www.xailer.com
>
>
> "Oleg" <info@cluster.samara.ru> escribió en el mensaje
> news:[email=462ca7cf@ozsrv2.ozlan.local...]462ca7cf@ozsrv2.ozlan.local...[/email]
>> Ignacio!
>>
>> I have found how it is done in Delphi and how to overcome this in Xailer.
>>
>> First, description from MSDN:
>> "Only windows that have the CS_DBLCLKS style can receive WM_LBUTTONDBLCLK
>> messages,
>> which Windows generates whenever the user presses, releases,
>> and again presses the left mouse button within the system's double-click
>> time limit. "
>>
>> I create a function:
>>
>> XA_FUNC( WNDDBLCLK )
>> {
>> HWND hWnd = ( HWND ) hb_parnl( 1 );
>> LONG st;
>> st=GetClassLong(hWnd, GCL_STYLE);
>> SetClassLong(hWnd, GCL_STYLE, st | CS_DBLCLKS);
>>
>> hb_ret();
>> }
>>
>> and call this in my form in OnCreate event of TMonthCalendar control:
>>
>> METHOD MonthCalendarCreate( oSender ) CLASS TFormCalendar
>> WNDDBLCLK(oSender:Handle)
>> RETURN Nil
>>
>> After this, OnDblClick event is fired in TMonthCalendar control.
>>
>> Maybe you could include this into Xailer core for TMonthCalendar (in the
>> near releases)?
>>
>> Thank you. Oleg.
>>
>>
>
>

OnDblClick in TMonthCalendar

Publicado: Lun Abr 23, 2007 5:32 pm
por NoName
Oleg,
If I set or reset the style before the window creation, nothing happens,
BTW, you proposal works perfectly, and I have just included in the class so
it will be available on next release. Thank very much for your feedback.
Regards,
--
Ignacio Ortiz de Zúñiga
http://www.xailer.com
"Ignacio Ortiz de Zúñiga" <NoName@xailer.com> escribió en el mensaje
news:462cce49$[email=1@ozsrv2.ozlan.local...]1@ozsrv2.ozlan.local...[/email]
> Oleg,
>
> Really strange, that style is already present on its acenstor TStdControl.
> Maybe the control is resetting that style upon creation. I will have a
> closer look at it. Thank you for the tip.
>
> Regards
>
> --
> Ignacio Ortiz de Zúñiga
> http://www.xailer.com
>
>
> "Oleg" <info@cluster.samara.ru> escribió en el mensaje
> news:[email=462ca7cf@ozsrv2.ozlan.local...]462ca7cf@ozsrv2.ozlan.local...[/email]
>> Ignacio!
>>
>> I have found how it is done in Delphi and how to overcome this in Xailer.
>>
>> First, description from MSDN:
>> "Only windows that have the CS_DBLCLKS style can receive WM_LBUTTONDBLCLK
>> messages,
>> which Windows generates whenever the user presses, releases,
>> and again presses the left mouse button within the system's double-click
>> time limit. "
>>
>> I create a function:
>>
>> XA_FUNC( WNDDBLCLK )
>> {
>> HWND hWnd = ( HWND ) hb_parnl( 1 );
>> LONG st;
>> st=GetClassLong(hWnd, GCL_STYLE);
>> SetClassLong(hWnd, GCL_STYLE, st | CS_DBLCLKS);
>>
>> hb_ret();
>> }
>>
>> and call this in my form in OnCreate event of TMonthCalendar control:
>>
>> METHOD MonthCalendarCreate( oSender ) CLASS TFormCalendar
>> WNDDBLCLK(oSender:Handle)
>> RETURN Nil
>>
>> After this, OnDblClick event is fired in TMonthCalendar control.
>>
>> Maybe you could include this into Xailer core for TMonthCalendar (in the
>> near releases)?
>>
>> Thank you. Oleg.
>>
>>
>
>