CN116400846A - Realization method, equipment and medium for simulating touch operation 3D application - Google Patents

Realization method, equipment and medium for simulating touch operation 3D application Download PDF

Info

Publication number
CN116400846A
CN116400846A CN202310531481.8A CN202310531481A CN116400846A CN 116400846 A CN116400846 A CN 116400846A CN 202310531481 A CN202310531481 A CN 202310531481A CN 116400846 A CN116400846 A CN 116400846A
Authority
CN
China
Prior art keywords
touch
message
function
application
application program
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202310531481.8A
Other languages
Chinese (zh)
Inventor
晏仁科
罗俊华
刘坤朋
周双全
邹琼
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen Ruiyun Technology Co ltd
Original Assignee
Shenzhen Ruiyun Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen Ruiyun Technology Co ltd filed Critical Shenzhen Ruiyun Technology Co ltd
Priority to CN202310531481.8A priority Critical patent/CN116400846A/en
Publication of CN116400846A publication Critical patent/CN116400846A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0487Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser
    • G06F3/0488Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser using a touch-screen or digitiser, e.g. input of commands through traced gestures
    • G06F3/04883Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser using a touch-screen or digitiser, e.g. input of commands through traced gestures for inputting data by handwriting, e.g. gesture or text
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/54Interprogram communication
    • G06F9/542Event management; Broadcasting; Multicasting; Notifications
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/54Interprogram communication
    • G06F9/546Message passing systems or structures, e.g. queues
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/54Interprogram communication
    • G06F9/547Remote procedure calls [RPC]; Web services
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2209/00Indexing scheme relating to G06F9/00
    • G06F2209/54Indexing scheme relating to G06F9/54
    • G06F2209/544Remote
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2209/00Indexing scheme relating to G06F9/00
    • G06F2209/54Indexing scheme relating to G06F9/54
    • G06F2209/547Messaging middleware
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Software Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Human Computer Interaction (AREA)
  • Multimedia (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

The invention relates to a realization method, equipment and a medium for simulating TOUCH operation 3D application, wherein the method comprises the steps of simulating a TOUCH program to create a shared memory, constructing a structure object, controlling an application DLL file to replace an original window message processing method TrueWndProc () with a MineWndProc (), sending a system message to the application program by a PostMessage () function, generating a WM_TOUCH message each time the PostMessage () function sends the simulation message and the system message to the application program, taking an htouchut parameter as an address value when the control application DLL file realizes the acquisition function MineGetTouchInputInfo (), judging whether the address value is in the shared memory, if so, determining that the message processed by the MineGetTouchInputInfo is the address of the structure object of the simulation TOUCH event, assigning the value to the relevant parameters of the function, and making a corresponding response after the application program acquires the simulation message. The method provided by the invention can not influence other applications in the system, and can support a plurality of identical or different applications on the same machine to be operated simultaneously.

Description

Realization method, equipment and medium for simulating touch operation 3D application
Technical Field
The invention belongs to the technical field of touch control, and particularly relates to a method, equipment and medium for realizing 3D application of simulated touch control operation.
Background
With the development of the mobile internet, application (APP) is becoming an important component of the intelligent terminal. Before an application is pushed to the application market, a test for touch operation test is required for the application to detect whether there is an operation problem with the application program. At present, manual test, virtual test, automatic test and other modes are mainly adopted for detection. The manual test is to manually operate the touch terminal to obtain test data; the virtual test is to implant a software test tool in the touch terminal in advance, and acquire real-time data related to screen resources from an internal interface of the system to perform test analysis; the automatic test is to set a touch pen at the free end of the manipulator, and then control the manipulator to drive the touch pen to perform touch operations such as clicking, sliding and the like on a screen of the touch terminal.
In the related art, in the field of touch control, only one control system can control another control system to realize the control of touch. For example, when the computer A remotely controls the computer B, corresponding operation is performed on the computer A, and corresponding response operation is performed when the computer B touches the computer A, and the control process is the control of the system level. The above process cannot realize control of a single application program and cannot realize control of operation of multiple application programs at the same time, for example, two computers A, B simultaneously remotely control a computer C, but the computer C can only operate corresponding to a computer alone or operate corresponding to B computer alone, and cannot realize simultaneous control of multiple application programs.
Disclosure of Invention
In view of the above, the present invention aims to overcome the shortcomings of the prior art, and provide a method, a device and a medium for implementing 3D application of simulated touch operation, so as to solve the problem that a touch control system in the prior art cannot implement control over a single application program and cannot implement control over operations of multiple application programs at the same time.
In order to achieve the above purpose, the invention adopts the following technical scheme: an implementation method for simulating touch operation 3D application comprises the following steps:
creating a shared memory by a simulated TOUCH program, constructing a corresponding TOUCH event simulated TOUCH object touch_input in the shared memory according to the operation event requirement, and calling a PostMessage () function to send the address of the touch_input of the structure object to an application program through a preset WM_USER_TOUCH message;
injecting a control application DLL file into the application program to replace an original window message processing method TrueWndProc () with MineWndProc (), and replacing all custom message types WM_USER_TOUCH with system TOUCH message types WM_TOUCH, and continuously calling the original message processing method TrueWndProc ();
the control application DLL file searches the original acquisition function TrueGetTouchInputInfo (), and replaces the original acquisition function TrueGetTouchInputInfo ();
the PostMessage () function is further used for sending the system message to the application program, and the PostMessage () function generates a WM_TOUCH message each time the simulation message and the system message are sent to the application program;
the acquisition function MineGetTouchInputInfo () is used to process all WM_TOUCH messages;
when the control application DLL file realizes obtaining the function MineGetTouchInputInfo (), taking the htouchinput parameter as an address value, judging whether the address value is in a shared memory, if so, determining that the message processed by the MineGetTouchInputInfo is the address of a structural object simulating a touch event, assigning the value to the related parameter of the function, and making a corresponding response by the application program after obtaining the simulation message.
Further, the injecting the control application DLL file into the application program to replace the original window message processing method TrueWndProc () with MineWndProc (), and replace all the custom message types wm_user_touch with system TOUCH message types wm_touch, includes:
injecting a control application DLL file into the application program by
GetClassInfoEx (& windowClass) acquires window type information, wherein windowClass.lpnWndProc in the acquired window type information is a window message processing method, and is marked as TrueWndProc (), and is replaced by MineWndProc ();
the MineWndProc () is used for replacing all the custom message types WM_USER_TOUCH with the system TOUCH message types WM_TOUCH, and continuously calling the original message processing method TrueWndProc ().
Further, the control application DLL file searches the original acquisition function GetTouchInputInfo address in the system, records the address as TrueGetTouchInputInfo (), and replaces the address with a new acquisition function MineGetTouchInputInfo () through the HOOKWin 32 API.
Further, the original acquisition function TrueGetTouchInputInfo () is an acquisition TOUCHINPUT message function of an original DLL file of the system; the acquisition function MineGetTouchInputInfo () is an acquisition TOUCHINPUT message function for controlling an application DLL file.
Further, the applied message handling function needs to make at least one GetTouchInputInfo call to handle the wm_touch message when it is received.
Further, when judging whether the value of the htouchinput parameter of the MineGetTouchInputInfo is in the shared memory, if the judging result is negative, the message corresponding to the GetTouchInputInfo is a system message, the application program calls the original acquisition function TrueGetTouchInputInfo () to acquire the system message, and the application program responds according to the system message.
Further, the application program obtains the response of TOUCHINPUT according to the requirement through MineGetTouchInputInfo ().
An embodiment of the present application provides a computer device, including: the device comprises a memory and a processor, wherein the memory stores a computer program, and the computer program is executed by the processor to enable the processor to execute the steps of the method for realizing the 3D application of any simulation touch operation.
The embodiment of the application also provides a computer storage medium, which stores a computer program, wherein the computer program, when executed by a processor, causes the processor to execute the steps of the implementation method of any one of the simulated touch operation 3D applications.
By adopting the technical scheme, the invention has the following beneficial effects:
(1) According to the technical scheme provided by the application, a structural body touch_input of a simulated TOUCH event can be constructed on a shared memory according to the operation event requirement of a USER, the structural body touch_input of the simulated TOUCH event is sent to an application program through a PostMessage function, then the WM_USER_TOUCH message is converted into a TOUCH message WM_TOUCH of a system at a window message processing position, the TOUCH message WM_TOUCH is issued to a real message processing flow, system information is acquired through controlling an acquisition function MineGetTouchInfo () on an application DLL file, getToutInfo data corresponding to the structural body touch_input are acquired, getToutInfo in the acquisition function MineGetToutInfo () is realized through controlling the application DLL file, whether the HToutToutInfo parameter value of the GetToutInfo is in the shared memory is the value of the TOUCH message WM_TOUCH of the system or not is judged, and accordingly the information corresponding to the information of the structural body of the information is acquired, and the structure of the TOUCH input Input is further judged according to the operation structure of the application DLL file; meanwhile, the distinguishing and judging of the system message and the touch simulation message corresponding to the structure touch_input can be realized, so that the application program can respond differently according to different message types, different operations are realized, and the experience of a user is effectively improved;
(2) The connection between the simulated touch program and the application program is established, so that each application program in the same system can be connected with the simulated touch programs of other systems, and simultaneous control and touch operation of a plurality of application programs of the other systems by different systems are realized.
Drawings
In order to more clearly illustrate the embodiments of the invention or the technical solutions in the prior art, the drawings that are required in the embodiments or the description of the prior art will be briefly described, it being obvious that the drawings in the following description are only some embodiments of the invention, and that other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
FIG. 1 is a schematic diagram illustrating steps of an implementation method of a 3D application for simulating touch operation according to the present invention;
fig. 2 is a schematic structural diagram of a computer device related to an implementation method of the 3D application for simulating touch operation according to the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the technical solutions of the present invention will be described in detail below. It will be apparent that the described embodiments are only some, but not all, embodiments of the invention. All other embodiments, based on the examples herein, which are within the scope of the invention as defined by the claims, will be within the scope of the invention as defined by the claims.
The following describes a specific implementation method of the 3D application for simulating touch operation according to the embodiments of the present application with reference to the accompanying drawings.
As shown in fig. 1, the implementation method for the 3D application for simulating touch operation provided in the embodiment of the present application includes:
s101, a TOUCH simulation program creates a shared memory, constructs a corresponding TOUCH event simulation structure object touch_input in the shared memory according to the operation event requirement, and calls a PostMessage () function to send the address of the structure object touch_input to an application program through a preset WM_USER_TOUCH message;
because the system prohibits the analog transmission of the TOUCH message type wm_touch, a custom message type wm_user_touch is defined, which needs to be transmitted instead whenever the analog transmission of wm_touch is required.
S102, injecting a control application DLL file into the application program to replace an original window message processing method TrueWndProc () with MineWndProc (), and replacing all custom message types WM_USER_TOUCH with system TOUCH message types WM_TOUCH, and continuously calling the original message processing method TrueWndProc ();
s103, controlling and applying the original acquisition function in the DLL file searching system
trueGetTouchInputInfo (), and replace it with a new acquisition function
MineGetTouchInputInfo();
S104, the PostMessage () function is further used for sending the system message to the application program, and the PostMessage () function generates a WM_TOUCH message each time the simulation message and the system message are sent to the application program;
s105, the acquisition function MineGetTouchInputInfo () is used for processing all WM_TOUCH messages;
s106, when the control application DLL file realizes obtaining the function MineGetTouchInputInfo (), taking the htouchinput parameter as an address value, judging whether the address value is in the shared memory, if so, determining that the message processed by the MineGetTouchInputInfo is the address of the structural object simulating the touch event, assigning the value to the related parameter of the function, and making a corresponding response after the application program obtains the simulation message.
It should be noted that, the control application DLL file may open the shared memory; injecting a control application DLL file into the application program, and replacing the original acquisition function TrueGetTouchInputInfo () in the control application DLL file search system with a new acquisition function
MineGetTouchInputInfo (); specifically, the original acquisition function TrueGetTouchInputInfo () is the acquisition function GetTouchInputInfo ()' of the original DLL file of the system; the acquisition function MineGetTouchInputInfo () is an acquisition function for controlling application of DLL files
GetTouchInputInfo (). The function names of trueGetTouchInputInfo (), mineGetTouchInputInfo () are the addresses of the trueGetTouchInputInfo (), the trueGetTouchInputInfo () is positioned in the system and is a function pointer which can point to the GetTouchInputInfo function in user32.DLL, the MineGetTouchInputInfo () is a function defined and realized by a user and can also be used as a function pointer which can point to the GetTouchInputInfo function in a control application DLL file.
The working principle of the realization method for simulating the touch operation 3D application is as follows: the simulated touch program creates a shared memory, constructs a corresponding structure body touch_input of the simulated touch event in the shared memory according to the operation event requirement, and calls a PostMessage function to send the structure body touch_input to the application program. The operation event requirement is the touch operation which the user wants to perform, and the user can directly construct a corresponding structure body touch_input simulating the touch event in the shared memory according to the operation event requirement. It should be noted that, when the PostMessage function is called, the first address of the struct touch_input needs to be used as the HTOUCHINPUT type, so that the struct touch_input is sent to the application program through the PostMessage function.
In some embodiments, the injecting the control application DLL file into the application program to replace the original window message processing method TrueWndProc () with MineWndProc (), and replace all custom message types wm_user_touch with system TOUCH message types wm_touch includes:
injecting a control application DLL file into the application program by
GetClassInfoEx (& windowClass) acquires window type information, wherein windowClass.lpnWndProc in the acquired window type information is a window message processing method, and is marked as TrueWndProc (), and is replaced by MineWndProc ();
the MineWndProc () is used for replacing all the custom message types WM_USER_TOUCH with the system TOUCH message types WM_TOUCH, and continuously calling the original message processing method TrueWndProc ().
In some embodiments, the control application DLL file looks up the original acquisition function GetTouchInputInfo address within the system, records it as TrueGetTouchInputInfo (), and replaces it with the new acquisition function MineGetTouchInputInfo (), via the HOOK Win32 API.
In some embodiments, the original acquisition function trueGetTouchInputInfo () is an acquisition TOUCHINPUT message function of an original DLL file of the system; the acquisition function
MineGetTouchInputInfo () is the get TOUCHINPUT message function that controls the application DLL file.
In some embodiments, the applied message handling function needs to make at least one GetTouchInputInfo call to handle the wm_touch message when it is received.
When judging whether the value of the htouchinput parameter of the MineGetTouchInputInfo is in the shared memory or not, if the judging result is negative, the message corresponding to the GetTouchInputInfo is a system message, the application program calls the original acquisition function TrueGetTouchInputInfo () to acquire the system message, and the application program responds according to the system message. That is, the present invention is not limited to the above-described embodiments; when the program calls MineCloteTouchInputHandle, the htouchinput parameter is used as an address value to judge whether the htouchinput parameter is in the shared memory or not, if yes, the instruction is a simulated message, no cleaning operation is needed, otherwise, the instruction is a system message, and the instruction is needed to call TrueCloseTouchInfoHandle for response.
The application program in the application obtains the response of TOUCHINPUT according to the requirement through MineGetTouchInputInfo (). That is, the PostMessage function is also used to send a system message to the application, and the PostMessage function generates a corresponding GetTouchInputInfo each time a structure touchinput, a system message, is sent to the application.
The get function MineGetTouchInputInfo () in this application is used to record all GetTouchInputInfo. Thus, the get function MineGetTouchInputInfo () may simultaneously receive the GetTouchInputInfo generated by the PostMessage function when sending the fabric touch_input, system message to the application, rather than just the GetTouchInputInfo corresponding to the system message.
When the control application DLL file realizes the GetTouchInputInfo in the acquisition function MineGetTouchInputInfo (), judging whether the value of the HtouchInput parameter of the GetTouchInputInfo is in the shared memory, if so, the message corresponding to the GetTouchInputInfo is the structural body touch_input of the simulated touch event, and the application program acquires the structural body touch_input of the simulated touch event from the shared memory through the acquisition function MineGetTouchInputInfo (), and responds according to the structural body touch_input of the simulated touch event. After the simulated touch program calls the PostMessage function to send the structure body touch_input to the application program, the application program does not receive the structure body touch_input, and after the judging, if the message corresponding to the judged gettouchInputinfo is the structure body touch_input of the simulated touch event, the application program can receive the structure body touch_input through obtaining a function MineGetTouchInputInfo ().
The invention provides a realization method of a 3D application of simulated touch operation, which constructs a structural body touch_input of a simulated touch event on a shared memory according to the operation event requirement of a user, and sends the structural body touch_input to an application program through a PostMessage function, when each structural body touch_input is sent, the PostMessage function can generate a GetTouchInputInfo data, an original acquisition function TrueGetTouchInputInfo () in a system can only realize the acquisition of GetTouchInputInfo data of a system message, but can not realize the GetTouchInputInfo data of a corresponding message outside the system message, and after the GetTouchInputInfo () is replaced by a new acquisition function MineGetTouchInputInfo () which is a pointing function for controlling an application file, therefore, the acquisition of GetTouchInputInfo corresponding to the system message and the structural body touch_Input can be realized simultaneously, after the gettouchInputInfo data is acquired, the GetTouchInputInfo in the acquisition function MineGetTouchInputInfo () is realized by controlling an application DLL file, whether the message corresponding to the GetTouchInputInfo data is a system message or a structure touchInput can be judged by judging whether the value of the HtouchInput parameter of the GetTouchInputInfo is in a shared memory or not, namely whether the storage address of the HtouchInput parameter belongs to the shared memory or not, and because the structure touchInput is created in the shared memory, when the judgment result is yes, the message corresponding to the GetTouchInputInfo data is the structure touchInput, namely the simulated touch message, and the application program needs to further acquire the structure touchInput according to the structure touchInput to make a corresponding response, so that the corresponding touch operation function is realized, and the single application can be realized; on the other hand, the invention can also realize the simultaneous control of a plurality of application programs of the same system, such as: when the computer A and the computer B remotely control the computer C at the same time, a user of the computer A needs to control an application program H1 on the computer C to perform corresponding operation, and a user of the computer B needs to control an application program H2 on the computer C to perform corresponding operation, at the moment, the simulated touch program A on the computer A and the application program H1 on the computer C can establish a connection through the implementation method of the simulated touch operation 3D application in the invention, the user on the computer A can perform related operation according to the operation event requirement of the user, the corresponding touch operation function is realized in the application program H1, and simultaneously, the simulated touch program B on the computer B and the application program H2 on the computer C can establish a connection through the implementation method of the simulated touch operation 3D application in the invention so as to realize various touch operation functions, and therefore, simultaneous control and touch operation of a plurality of application programs of the same system can be realized.
Specifically, in this embodiment, the control application DLL file looks up the original acquisition function TrueGetTouchInputInfo () within the system and converts it to the acquisition function MineGetTouchInputInfo () by the HOOK Win32 API GetTouchInputInfo () function. Specifically, the function of the HOOK Win32 API GetTouchInputInfo () function can be achieved by a windows self-contained detours tool.
Specifically, in this embodiment, when determining whether the value of the htuchinput parameter of GetTouchInputInfo is in the shared memory, if the determination result is no, it is indicated that the message corresponding to GetTouchInputInfo is a system message, and the application program calls the original acquisition function TrueGetTouchInputInfo () to acquire the system message, and responds according to the system message. Therefore, the invention can also realize the distinction and judgment of the system message and the touch simulation message corresponding to the structural body touch_input, so that the application program can make different responses according to different message types, realize different operations and effectively improve the experience of the user.
In summary, the invention provides a method for implementing 3D application of simulated touch operation, which has the following beneficial effects:
1. the method comprises the steps that a structural body touch_input simulating a TOUCH event can be constructed on a shared memory according to operation event requirements of a USER, the structural body touch_input simulating the TOUCH event is sent to an application program through a PostMessaging function, the WM_USER_TOUCH message is converted into a TOUCH message WM_TOUCH of a system at a window message processing position, the TOUCH message WM_TOUCH is issued to a real message processing flow, system information is acquired through an acquisition function MineGetToutInfo () on an application DLL file, getToutInfo data corresponding to the structural body touch_input are acquired through the control application DLL file, getToutInfo in the acquisition function MineGetToutToutInfo () is realized through the control application DLL file, whether HTouch Touch Info parameter values of the GetTouchInfo are in the shared memory or not is judged, and accordingly whether the information corresponding to the GetToutToutInfo data is the structural body of the system information or the GetToutInfo is the structural body of the system information or the system information is judged to be the structural body, and the corresponding to the structural body TOUCH information is further corresponding to the operation information, and the operation structure is further realized according to the operation requirements; meanwhile, the distinguishing and judging of the system message and the touch simulation message corresponding to the structure touch_input can be realized, so that the application program can respond differently according to different message types, different operations are realized, and the experience of a user is effectively improved;
2. the connection between the simulated touch program and the application program is established, so that each application program in the same system can be connected with the simulated touch programs of other systems, and simultaneous control and touch operation of a plurality of application programs of the other systems by different systems are realized.
The application provides a computer device comprising: the memory and processor may also include a network interface, the memory storing a computer program, the memory may include volatile memory in a computer readable medium, random Access Memory (RAM) and/or nonvolatile memory, etc., such as Read Only Memory (ROM) or flash memory (flash RAM). The computer device stores an operating system, with memory being an example of a computer-readable medium. The computer program, when executed by the processor, causes the processor to perform the method of implementing a 3D application of simulated touch operation, the structure shown in fig. 2 is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation of the computer device to which the present application is applied, and a specific computer device may include more or fewer components than those shown in the drawings, or may combine some components, or have a different arrangement of components.
In one embodiment, the implementation method of the 3D application for simulating touch operation provided in the present application may be implemented as a computer program, and the computer program may be executed on a computer device as shown in fig. 2.
In some embodiments, the computer program, when executed by the processor, causes the processor to perform the steps of: creating a shared memory by a simulated TOUCH program, constructing a corresponding TOUCH event simulated TOUCH object touch_input in the shared memory according to the operation event requirement, and calling a PostMessage () function to send the address of the touch_input of the structure object to an application program through a preset WM_USER_TOUCH message; injecting a control application DLL file into the application program to replace an original window message processing method TrueWndProc () with MineWndProc (), and replacing all custom message types WM_USER_TOUCH with system TOUCH message types WM_TOUCH, and continuously calling the original message processing method TrueWndProc (); the control application DLL file searches the original acquisition function TrueGetTouchInputInfo (), and replaces it with a new acquisition function
MineGetTouchInputInfo (); the PostMessage () function is further used for sending the system message to the application program, and the PostMessage () function generates a WM_TOUCH message each time the simulation message and the system message are sent to the application program; the acquisition function
MineGetTouchInputInfo () is used to process all WM_TOUCH messages; when the control application DLL file realizes obtaining the function MineGetTouchInputInfo (), taking the htouchinput parameter as an address value, judging whether the address value is in a shared memory, if so, determining that the message processed by the MineGetTouchInputInfo is the address of a structural object simulating a touch event, assigning the value to the related parameter of the function, and making a corresponding response by the application program after obtaining the simulation message.
The present application also provides a computer storage medium, examples of which include, but are not limited to, phase change memory (PRAM), static Random Access Memory (SRAM), dynamic Random Access Memory (DRAM), other types of Random Access Memory (RAM), read Only Memory (ROM), electrically Erasable Programmable Read Only Memory (EEPROM), flash memory or other memory technology, compact disc read only memory (CD-ROM), digital Versatile Discs (DVD) or other optical storage, magnetic cassette storage or other magnetic storage devices, or any other non-transmission medium, that can be used to store information that can be accessed by a computing device.
In some embodiments, the present invention further provides a computer readable storage medium, where a computer program is stored, where when the computer program is executed by a processor, the TOUCH simulation program creates a shared memory, constructs a touch_input object of a corresponding TOUCH event simulation structure in the shared memory according to an operation event requirement, and calls a PostMessage () function to send an address of the structure object touch_input to an application program through a preset wm_user_touch message; injecting a control application DLL file into the application program to replace an original window message processing method TrueWndProc () with MineWndProc (), and replacing all custom message types WM_USER_TOUCH with system TOUCH message types WM_TOUCH, and continuously calling the original message processing method TrueWndProc (); the control application DLL file searches the original acquisition function TrueGetTouchInputInfo (), and replaces it with a new acquisition function
MineGetTouchInputInfo (); the PostMessage () function is further used for sending the system message to the application program, and the PostMessage () function generates a WM_TOUCH message each time the simulation message and the system message are sent to the application program; the acquisition function
MineGetTouchInputInfo () is used to process all WM_TOUCH messages; when the control application DLL file realizes obtaining the function MineGetTouchInputInfo (), taking the htouchinput parameter as an address value, judging whether the address value is in a shared memory, if so, determining that the message processed by the MineGetTouchInputInfo is the address of a structural object simulating a touch event, assigning the value to the related parameter of the function, and making a corresponding response by the application program after obtaining the simulation message.
It can be understood that the above-provided method embodiments correspond to the above-described apparatus embodiments, and corresponding specific details may be referred to each other and will not be described herein.
It will be appreciated by those skilled in the art that embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, magnetic disk storage, optical storage, and the like) having computer-usable program code embodied therein.
The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems) and computer program products according to embodiments of the application. It will be understood that each flow and/or block of the flowchart illustrations and/or block diagrams, and combinations of flows and/or blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
The foregoing is merely illustrative of the present invention, and the present invention is not limited thereto, and any person skilled in the art will readily recognize that variations or substitutions are within the scope of the present invention. Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.

Claims (9)

1. The realization method for simulating the touch operation of the 3D application is characterized by comprising the following steps of:
creating a shared memory by a simulated TOUCH program, constructing a corresponding TOUCH event simulated TOUCH object touch_input in the shared memory according to the operation event requirement, and calling a PostMessage () function to send the address of the touch_input of the structure object to an application program through a preset WM_USER_TOUCH message;
injecting a control application DLL file into the application program to replace an original window message processing method TrueWndProc () with MineWndProc (), and replacing all custom message types WM_USER_TOUCH with system TOUCH message types WM_TOUCH, and continuously calling the original message processing method TrueWndProc ();
the control application DLL file searches the original acquisition function TrueGetTouchInputInfo (), and replaces the original acquisition function TrueGetTouchInputInfo (); and searching an original cleaning function CloseTouchInputHandle in the system, which is marked as TrueCloseTouchInputHandle, and replacing the original cleaning function CloseTouchInputHandle with MineLoseTouchInputHandle by using the HooK API;
the PostMessage () function is further used for sending the system message to the application program, and the PostMessage () function generates a WM_TOUCH message each time the simulation message and the system message are sent to the application program;
the acquisition function MineGetTouchInputInfo () is used to process all WM_TOUCH messages;
when the control application DLL file realizes obtaining the function MineGetTouchInputInfo (), taking the htouchinput parameter as an address value, judging whether the address value is in a shared memory, if so, determining that the message processed by the MineGetTouchInputInfo is the address of a structural object simulating a touch event, assigning the value to the related parameter of the function, and making a corresponding response by the application program after obtaining the simulation message.
2. The method of claim 1, wherein the injecting the control application DLL file into the application program to replace an original window message processing method TrueWndProc () with MineWndProc (), and to replace all custom message types wm_user_touch with system TOUCH message types wm_touch, comprises:
injecting a control application DLL file into the application program, and acquiring window type information through GetClassInfoEx (& windows class), wherein windows class. LpfwndProc in the acquired window type information is a window message processing method, and is marked as TrueWndProc (), and is replaced by MineWndProc ();
the MineWndProc () is used for replacing all the custom message types WM_USER_TOUCH with the system TOUCH message types WM_TOUCH, and continuously calling the original message processing method TrueWndProc ().
3. The method of claim 2, wherein the control application DLL file lookup system records the original get function GetTouchInputInfo address as TrueGetTouchInputInfo (), and replaces it with the new get function MineGetTouchInputInfo () via the HOOK Win32 API.
4. A method according to claim 3, wherein the original acquisition function TrueGetTouchInputInfo () is an acquisition TOUCHINPUT message function of an original DLL file of the system; the acquisition function MineGetTouchInputInfo () is an acquisition TOUCHINPUT message function for controlling an application DLL file.
5. The method of claim 1, wherein the step of determining the position of the substrate comprises,
the applied message handling function needs to make at least one GetTouchInputInfo call to handle the wm_touch message when it is received.
6. The method of claim 1, wherein the step of determining the position of the substrate comprises,
when judging whether the value of the htouchinput parameter of the MineGetTouchInputInfo is in the shared memory or not, if the judging result is negative, the message corresponding to the GetTouchInputInfo is a system message, the application program calls the original acquisition function TrueGetTouchInputInfo () to acquire the system message, and the application program responds according to the system message.
7. The method of claim 1, wherein the step of determining the position of the substrate comprises,
the application program obtains the response of the TOUCHINPUT according to the requirement through MineGetTouchInputInfo ().
8. A computer device, comprising: a memory and a processor, the memory storing a computer program that, when executed by the processor, causes the processor to perform the method of implementing a simulated touch operated 3D application as claimed in any one of claims 1 to 7.
9. A computer storage medium, characterized in that a computer program is stored, which, when being executed by a processor, causes the processor to perform the method of implementing a simulated touch operation 3D application according to any of claims 1 to 7.
CN202310531481.8A 2023-05-11 2023-05-11 Realization method, equipment and medium for simulating touch operation 3D application Pending CN116400846A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310531481.8A CN116400846A (en) 2023-05-11 2023-05-11 Realization method, equipment and medium for simulating touch operation 3D application

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310531481.8A CN116400846A (en) 2023-05-11 2023-05-11 Realization method, equipment and medium for simulating touch operation 3D application

Publications (1)

Publication Number Publication Date
CN116400846A true CN116400846A (en) 2023-07-07

Family

ID=87010647

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310531481.8A Pending CN116400846A (en) 2023-05-11 2023-05-11 Realization method, equipment and medium for simulating touch operation 3D application

Country Status (1)

Country Link
CN (1) CN116400846A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117971108A (en) * 2024-03-29 2024-05-03 中科方德软件有限公司 Touch control method, device, equipment and medium of WPF application

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117971108A (en) * 2024-03-29 2024-05-03 中科方德软件有限公司 Touch control method, device, equipment and medium of WPF application
CN117971108B (en) * 2024-03-29 2024-06-04 中科方德软件有限公司 Touch control method, device, equipment and medium of WPF application

Similar Documents

Publication Publication Date Title
CN110971655B (en) Offline client playback and synchronization
WO2015081841A1 (en) Devices and methods for test scenario reproduction
WO2017083207A1 (en) Digital assistant setting up device
EP3142005B1 (en) Method for creating context-aware application and user terminal
CN106126424B (en) A kind of visual automated testing method of script, device and mobile terminal
CN106844181B (en) Method, system and mobile terminal for recording user behavior
US20140129620A1 (en) Indicating coverage of web application testing
KR102323693B1 (en) Motion object processing method and device
CN105740144A (en) Automated testing method and system for Android mobile Terminal
CN107608609B (en) Event object sending method and device
Wang et al. Automatic Android GUI traversal with high coverage
CN104731500B (en) A kind of information processing method and electronic equipment
WO2019075994A1 (en) Method, device and system for mock data at ios end, and storage medium
CN116400846A (en) Realization method, equipment and medium for simulating touch operation 3D application
CN108038373B (en) Data scanning method and system for cloud terminal
WO2016133534A1 (en) An automatically invoked unified visualization interface
CN107506104A (en) Desktop icon sorting method and device, mobile terminal and storage medium
CN110413161B (en) Component configuration method and device and electronic equipment
CN111459818B (en) Visual test method and device
CN108549537A (en) The method and system of user data acquisition based on Android terminal
CN107102937B (en) User interface testing method and device
CN110858175A (en) Test control method, master control equipment, controlled equipment and test system
CN104915244B (en) The method and device of key mouse script playback
CN112346946B (en) User software operation behavior monitoring method and system based on control positioning
CN106484604B (en) Application test control method and device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination