TWBrowse right click

TWBrowse right click

Postby Enrico Maria Giordano » Sat May 13, 2006 3:18 pm

ON RIGHT CLICK clause doesn't work.

EMG
User avatar
Enrico Maria Giordano
 
Posts: 8715
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia

Postby Antonio Linares » Sun May 14, 2006 7:14 am

Enrico,

How a Pocket PC user can right click ?
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42099
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Postby Enrico Maria Giordano » Sun May 14, 2006 8:11 am

Clicking on a spot and keep pressing the pen for a while. Try to do so on a file in Explorer.

EMG
User avatar
Enrico Maria Giordano
 
Posts: 8715
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia

Postby Antonio Linares » Sun May 14, 2006 9:51 am

Yes, you are right :)
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42099
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Postby Antonio Linares » Sun May 14, 2006 10:10 am

Enrico,

It looks as WM_RBUTTONDOWN msg is never sent to a window. We need to find which msg is sent for that event.

I have placed a LogFile( "msgs.txt", { nMsg, nWParam, nLParam } ) at Class TWindow Method HandleEvent() but I can't find it, by now.
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42099
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Postby Antonio Linares » Sun May 14, 2006 10:26 am

Enrico,

It looks as we never get such message. So a solution may be to count the ellapsed time since the left button is clicked, and on a certain amount, then fire the method.

What ellapsed time amount should we check ?
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42099
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Postby Enrico Maria Giordano » Sun May 14, 2006 11:36 am

Sorry, I don't have a real device to test it here. But your solution seems the right one.

EMG
User avatar
Enrico Maria Giordano
 
Posts: 8715
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia

Postby Maurizio » Mon May 15, 2006 6:34 am

I solve with a work around :

this is a sample for the wbrowse.prg but it is possible to use in every control :

oBrwArt:bTimer := {|| MsgInfo("Hello") }





//-------------------------------------------------------
//1 - ADD this variable
DATA oTimer
DATA nTimer
DATA bTimer
// ------------------------------------------------------
// 2 Method LButtonDown
METHOD LButtonDown( nRow, nCol, nKeyFlags ) CLASS TWBrowse

local nClickRow, nSkipped
local nColPos := 0, nColInit := ::nColPos - 1
local nAtCol

//----- my_modi
IF ::bTimer != nil
::nTimer := 1
::oTimer := TTimer():New( 1000, ;
{||(::nTimer++,;
IIF( ::nTimer > 1 , ( ::nTimer := 0 ,::oTimer:End() , eval(::bTimer) ), ) )})
::oTimer:Activate()
ENDIF
// -----------------------------------------------------
// 2 Method LButtonUp
METHOD LButtonUp( nRow, nCol, nFlags ) CLASS TWBrowse
//----- my_modi
IF ::bTimer != nil
IF ::nTimer > 0
::oTimer:End()
ENDIF
::nTimer := 0
ENDIF
User avatar
Maurizio
 
Posts: 824
Joined: Mon Oct 10, 2005 1:29 pm

Postby Antonio Linares » Mon May 15, 2006 7:10 am

Maurizio,

I thought about the same solution, to use a timer. But to create a timer everytime the mouse is clicked it seems a big overload to the application.

Whats your opinion ?
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42099
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Postby Enrico Maria Giordano » Mon May 15, 2006 7:57 am

Definitely.

EMG
User avatar
Enrico Maria Giordano
 
Posts: 8715
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia

Postby Maurizio » Mon May 15, 2006 8:39 am

Yes it is true , but I use this trick in VBE from 4 years without problem .
My application in FWPPC is still in beta , antil now it works ok .
Better if we found another solution .

Maurizio
User avatar
Maurizio
 
Posts: 824
Joined: Mon Oct 10, 2005 1:29 pm

Does this help?

Postby Bill Simmeth » Fri Jun 02, 2006 3:42 pm

Hi, I too am interested in "right click" support in WBrowse. I found this article in the MSDN knowledgebase. Perhaps this can help. Unfortaunately, I am not talented enough to understand the "SHRecognizeGesture function".
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/guide_ppc/html/ppc_programming_pocket_pc_2002_noxa.asp

My specific interest is in popping up a menu. This example on MSDN shows specifics...
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/guide_ppc/html/ppc_ht_displayshortcutexisting.asp

Thanks for any help!
Bill Simmeth
Merchant Software Corp
Marshall, Virginia USA
Bill Simmeth
 
Posts: 42
Joined: Wed Oct 26, 2005 1:20 pm
Location: Marshall, Virginia, USA

Postby Antonio Linares » Sat Jun 03, 2006 7:59 am

Bill,

Thanks for your feedback.

We have just published a new FWPPC build that includes the function SHRecognizeGesture(). Please review samples\TapHold.prg for a working sample detecting the tap and hold event.

Please notice that on such sample we are not showing a popup menu yet, just a MsgInfo(). Also we have detected that sometimes it makes crash the application, we still don't know why.
Last edited by Antonio Linares on Sat Jun 03, 2006 9:33 am, edited 1 time in total.
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42099
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Postby Antonio Linares » Sat Jun 03, 2006 9:19 am

This sample already shows a POPUP, when tap & hold, though the actions are not managed yet:

http://hyperupload.com/download/017c2df ... d.prg.html
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42099
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Postby Bill Simmeth » Mon Jun 05, 2006 2:27 pm

Antonio,
Thanks for this start. It does seem to crash often, however.

Bill
Bill Simmeth
Merchant Software Corp
Marshall, Virginia USA
Bill Simmeth
 
Posts: 42
Joined: Wed Oct 26, 2005 1:20 pm
Location: Marshall, Virginia, USA

Next

Return to FiveWin for Pocket PC

Who is online

Users browsing this forum: No registered users and 9 guests