Hi. sir
Honestly I asked about this problem a few days ago. But I could not get answer...
So I organized the questions and uploaded them again.
I'm making some automation utility in Virtuoso Layout.
Fisrt, leRoutingAssistance can automatically modify property of selected two objects (Select two objects with two mouse clicks).
Second, if there are many object to choose from, using leRouitngAssistance_Multi. It allows you to select multiple objects at once by dragging mouse.
The algorithm for the function is as follows.
-------------------------------------------------------------------------------------------------------------------------------------------------------------
leRouitngAssistance Start --> Mouse click to 1st object --> get data of 1st object
--> Mouse click to 2nd object --> get data of 2nd object
--> Compare 1st / 2nd object, 1st / 2nd click point and modify property
--> leRouitngAssistance END
leRouitngAssistance_Multi --> Mouse drag --> get data of objects
--> Compare the all selected objects and modify property
--> leRouitngAssistance_Multi END
-------------------------------------------------------------------------------------------------------------------------------------------------------------
Each function was completed through Enterfunction. But I want combine function of each to only one function like the algorithm below.
Function Start
==> if Mouse click to 1st object --> After that, proceed in the same way as operation leRouitngAssistance
==> if Mouse drag --> After that, proceed in the same way as operation leRouitngAssistance_Multi
currently i use bindkey and enterfuction bindkey like this : list("<Key>D" "leRoutingAssistance()" "cancelEnterFun() leRoutingAssistance_Multi()")
It may be greedy, but I want to reduce what I have to input the keyboard twice to one. So I want to distinguish the mouse input.
Is there any way to solve this problem?
====================================================================================================
Please understand that we only brought the core part of the code for readability.
procedure(leRoutingAssistance()
prog((layerData rtData)
unless(boundp('RoutingAssistanceForm)
RoutingAssistanceOptionForm()
); unless
enterPoints(
?prompts list("First Object" "Second Object")
?form RoutingAssistanceForm
?wantPoints 2
?initProc "initProc_setSelectMode" ;; EnterFunction select mode = dynamic highlight on
?doneProc "doneProc_RoutingAssistance" ;; Function to automatically change property of selected objects
?addPointProc "addPointProc_getSelectObj" ;; gets the information of the objects selected by the mouse click(using geGetSelSet() )
?noInfix ,window(1)->infix ;; Infix Mode T / Non Infix Mode nil
); enterPoins
) ; prog
); procedure
procedure(leRoutingAssistance_Multi()
prog((layerData rtData)
unless(boundp('RoutingAssistanceForm)
RoutingAssistanceOptionForm()
); unless
enterBox(
?doneProc "rtData = doneProc_RoutingAssistance_Multi" ;;
?noInfix ,window(1)->infix ;; Infix Mode T / Non Infix Mode nil
); enterBox
) ; prog
); procedure