Conversation message sending method, device, electronic device and storage medium
Dragging and dropping conversation messages on the terminal device through the virtual window solves the problem of users needing to manually click the send button, realizing convenient and flexible conversation message sending, and is suitable for all applications.
Patent Information
- Application Number
- CN202210806122.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-07-08
- Publication Date
- 2024-08-30
- Estimated Expiration
- 2042-07-08
AI Technical Summary
When users use social software on terminal devices, they need to manually click the send button during the conversation message sending process, which is not convenient enough.
Drag and drop session messages into the information display area of the target session interface through the virtual window, enabling message sending without clicking the send button, which improves the flexibility and convenience of session message sending.
It implements system-level session message sending based on virtual windows, simplifies user operations, improves the efficiency and convenience of session message sending, and is suitable for message sending in all applications.
Smart Images

Figure CN115309294B
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of electronic devices, and in particular to a method and device for sending a session message, an electronic device, and a storage medium. Background Art
[0002] In practice, it is found that when a user uses social software on a terminal device (such as a tablet, mobile phone, etc.) to have a conversation with other users, after entering the conversation message, the user usually needs to manually click the send button in the social software to complete the sending of the conversation message, which is often not convenient enough. Summary of the invention
[0003] The embodiments of the present application provide a method, device, electronic device and storage medium for sending a conversation message, which can improve the flexibility and convenience of sending a conversation message.
[0004] A first aspect of an embodiment of the present application provides a method for sending a session message, including:
[0005] In response to the message sending operation, obtaining a target conversation message input in the message editing area of the target conversation interface;
[0006] Associating the target conversation message with the virtual window;
[0007] The target conversation message is dragged and dropped to the information display area of the target conversation interface by using the virtual window, so as to send the target conversation message to the receiving account corresponding to the target conversation interface.
[0008] A second aspect of an embodiment of the present application provides a session message sending device, including:
[0009] A message acquisition unit, configured to acquire a target conversation message input in the information editing area of the target conversation interface in response to a message sending operation;
[0010] A message associating unit, used to associate the target conversation message with the virtual window;
[0011] The message sending unit is used to use the virtual window to drag and drop the target conversation message to the information display area of the target conversation interface to send the target conversation message to the receiving account corresponding to the target conversation interface.
[0012] A third aspect of the embodiments of the present application provides an electronic device, including:
[0013] A memory storing executable program code;
[0014] and a processor coupled to the memory;
[0015] The processor calls the executable program code stored in the memory, and when the executable program code is executed by the processor, the processor implements the method described in the first aspect of the embodiment of the present application.
[0016] A fourth aspect of an embodiment of the present application provides a computer-readable storage medium having executable program code stored thereon. When the executable program code is executed by a processor, the method described in the first aspect of the embodiment of the present application is implemented.
[0017] A fifth aspect of the embodiments of the present application discloses a computer program product. When the computer program product runs on a computer, the computer executes any one of the methods disclosed in the first aspect of the embodiments of the present application.
[0018] The sixth aspect of the embodiments of the present application discloses an application publishing platform, which is used to publish a computer program product. When the computer program product runs on a computer, the computer executes any one of the methods disclosed in the first aspect of the embodiments of the present application.
[0019] It can be seen from the above technical solutions that the embodiments of the present application have the following advantages:
[0020] In an embodiment of the present application, in response to a message sending operation, a target conversation message input into an information editing area of a target conversation interface is obtained; the target conversation message is associated with a virtual window; and using the virtual window, the target conversation message is dragged and dropped into an information display area of the target conversation interface to send the target conversation message to a receiving account corresponding to the target conversation interface.
[0021] By implementing the above method, the conversation message can be dragged and dropped to the information display area of the corresponding conversation interface based on the virtual window, thereby achieving the purpose of sending the conversation message to the receiving account, further improving the flexibility and convenience of conversation message sending. BRIEF DESCRIPTION OF THE DRAWINGS
[0022] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings required for use in the embodiments and the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application, and other drawings can be obtained based on these drawings.
[0023] Figure 1 It is a diagram of the method for sending a session message disclosed in an embodiment of the present application;
[0024] Figure 2 It is a flow chart of a method for sending a session message disclosed in an embodiment of the present application;
[0025] Figure 3It is another flowchart of the method for sending a session message disclosed in an embodiment of the present application;
[0026] Figure 4A It is a diagram of using a single thread to respond to drag events and release events disclosed in the embodiment of the present application;
[0027] Figure 4B It is a diagram of using dual threads to respond to drag events and release events disclosed in the embodiment of the present application;
[0028] Figure 5 It is a structural block diagram of a session message sending device disclosed in an embodiment of the present application;
[0029] Figure 6 It is a structural block diagram of an electronic device disclosed in an embodiment of the present application. DETAILED DESCRIPTION
[0030] The embodiments of the present application provide a method, device, electronic device and storage medium for sending a conversation message, which can improve the flexibility and convenience of sending a conversation message.
[0031] In order to make the technical personnel in the technical field better understand the scheme of the present application, the technical scheme in the embodiment of the present application will be described below in conjunction with the drawings in the embodiment of the present application. Obviously, the described embodiment is only a part of the embodiment of the present application, not all of the embodiments. Based on the embodiments in the present application, they should all fall within the scope of protection of the present application.
[0032] It can be understood that the electronic devices involved in the embodiments of the present application may include general handheld screen electronic user terminals, such as mobile phones, smart phones, portable terminals, terminals, personal digital assistants (PDA), portable multimedia players (Personal Media Player, PMP) devices, laptop computers, notebooks (Note Pad), wireless broadband (Wireless Broadband, Wibro) terminals, tablet computers (Personal Computer, PC), smart PCs, sales terminals (Point of Sales, POS) and car computers, etc.
[0033] Electronic devices may also include wearable devices. Wearable devices are portable electronic devices that can be worn directly on the user or integrated into the user's clothes or accessories. Wearable devices are not just hardware devices, but can also achieve powerful intelligent functions through software support, data interaction, and cloud server interaction, such as: computing function, positioning function, and alarm function. They can also be connected to mobile phones and various terminals. Wearable devices may include but are not limited to watches supported by the wrist (such as watches, wrists, etc.), shoes supported by the feet (such as shoes, socks, or other products worn on the legs), Glass supported by the head (such as glasses, helmets, headbands, etc.), and various non-mainstream product forms such as smart clothing, school bags, crutches, accessories, etc.
[0034] The following is a description of the specific terms involved in the embodiments of the present application:
[0035] Conversational interface: A hybrid user interface that can interact with users in multiple ways, such as text, voice, and other ways.
[0036] Virtual window: A window that is not displayed on the display screen of an electronic device.
[0037] Drag and drop framework: includes a drag event class, a drag listener, and some auxiliary methods and classes; supports users to transfer data from one view in the current layout to another view through a graphical drag and drop action.
[0038] Input method framework: contains the system-level window of the virtual keyboard, which can handle the click events of virtual keys and pass characters to the edit box.
[0039] The technical solution of this application is further described below by way of embodiments:
[0040] See also Figure 1 , Figure 1 Schematic diagram of a scenario of the method for sending a session message disclosed in the embodiment of the present application. Figure 1The scene schematic diagram shown may be an electronic device 10 and an external keyboard 20. The target conversation interface 11 may be displayed in the electronic device 10. The target conversation interface 11 includes an information editing area 111 and an information display area 112. The user inputs a conversation message in the information editing area using the external keyboard 20. The electronic device 10 may create a virtual window 12. When the electronic device 10 detects a message sending operation, the electronic device 10 may respond to the message sending operation by obtaining the target conversation message input by the user in the information editing area 111 of the target conversation interface 11, and associating the target conversation message with the virtual window 12. The target conversation message may be dragged and dropped to the information display area 112 of the target conversation interface 11 using the virtual window 12, so as to send the target conversation message to the receiving account corresponding to the target conversation interface 11.
[0041] By implementing this method, the electronic device 101 can drag and drop the conversation message to the information display area of the corresponding conversation interface through the virtual window 12, thereby achieving the purpose of sending the conversation message to the receiving account. The user does not need to click the message sending button every time after entering the conversation message, which improves the flexibility and convenience of sending the conversation message.
[0042] See also Figure 2 , Figure 2 Schematic diagram of a flow chart of a method for sending a session message disclosed in an embodiment of the present application. Figure 2 The session message sending method shown may include the following steps:
[0043] 201. In response to a message sending operation, a target conversation message input in a message editing area of a target conversation interface is obtained.
[0044] In an embodiment of the present application, the sending of session messages of any application running on the electronic device can be triggered by the above-mentioned message sending operation. The message sending operation can be pre-defined by the operating system of the electronic device and is not bound to a specific application.
[0045] In some embodiments, the message sending operation may include, but is not limited to, any one of the following: pressing a first designated key on a keyboard of the electronic device, a target gesture operation, and a target voice operation.
[0046] Optionally, the keyboard of the electronic device may refer to an external keyboard of the electronic device, or a virtual keyboard of a third-party input method on the electronic device, which is not limited in the embodiments of the present application. The external keyboard of the electronic device may be connected to the electronic device wirelessly or by wire, which is not limited in the embodiments of the present application.
[0047] When the electronic device is wirelessly connected to the external keyboard, the connection method between the electronic device and the external keyboard may include any of the following: WiFi (Wireless-Fidelity), Bluetooth, and NFC (
[0048] Near Field Communication).
[0049] The first designated key may be any key on the keyboard, which is not limited in the embodiment of the present application. Optionally, the first designated key may include an Enter key.
[0050] Among them, users are accustomed to using the Enter key to trigger the sending of conversation messages, but in practice, it is found that when social software is directly run on an electronic device, or any user terminal is projected to an electronic device and the electronic device runs social software in a mirrored window, the Enter key on the keyboard of the electronic device mostly triggers a line break instead of sending a conversation message. The sending of a conversation message often requires the user to manually click the send button in the social software after editing the conversation message, which is not convenient enough. By implementing the above method, the sending of a conversation message can be triggered based on the Enter key, making the sending of a conversation message more in line with user habits and improving the convenience of operation.
[0051] In some embodiments, the target gesture operation may be a contact or non-contact gesture operation, which is not limited in the embodiments of the present application.
[0052] In some embodiments, the target gesture operation may include a sliding gesture toward a first direction, wherein the first direction may be based on the center of the electronic device as a reference point, and the first direction may refer to the left, right, top or bottom of the center of the electronic device, which is not limited in the embodiments of the present application.
[0053] Optionally, the above sliding gesture does not limit the number of fingers involved in the sliding. Exemplarily, the number of fingers involved in the sliding is 3.
[0054] In some embodiments, the target voice operation may refer to a voice input containing a keyword indicating message sending, for example, voice input "send this conversation message", "send", etc.
[0055] The target conversation interface refers to the conversation interface where the input method cursor is located on the display screen of the electronic device.
[0056] In some embodiments, obtaining the target conversation message input in the information editing area of the target conversation interface includes: obtaining the content before the input method cursor through the input method framework to obtain the target conversation message input in the information editing area of the target conversation interface.
[0057] 202. Associate the target session message with the virtual window.
[0058] In some embodiments, the virtual window may be an invisible window, so that the process of the electronic device responding to the message sending operation is completely imperceptible to the user, further improving the user experience.
[0059] In some embodiments, before associating the target conversation message with the virtual window, a virtual window may be generated according to pre-set window information; wherein the window information may include window size, window position, and the like.
[0060] In some embodiments, associating the target conversation message with the virtual window may refer to placing the target conversation message in the virtual window.
[0061] 203. Using the virtual window, drag and drop the target conversation message to the information display area of the target conversation interface to send the target conversation message to the receiving account corresponding to the target conversation interface.
[0062] In some embodiments, a target conversation message is dragged and dropped to an information display area of a target conversation interface using a virtual window, including: determining a drag and drop event for the virtual window based on position information of the information display area of the target conversation interface and the position of the virtual window, and moving the virtual window to the information display area of the target conversation interface based on the drag and drop event, so as to send the target conversation message to a receiving account corresponding to the target conversation interface through the virtual window.
[0063] The above drag and drop event may include a drag event and a release event, wherein the drag event indicates that a simulated drag operation is performed on the virtual window to move the virtual window to the information display area of the target session interface, and the release event indicates that a simulated release operation is performed on the virtual window.
[0064] By implementing the above method, based on the virtual window, the conversation message can be dragged and dropped to the information display area of the corresponding conversation interface, thereby achieving the purpose of sending the conversation message to the receiving account, and further improving the flexibility and convenience of conversation message sending. In addition, this conversation message sending method based on the virtual window is a system-level conversation message sending method, and the sending of conversation messages in all applications running on the electronic device can be triggered by the same triggering method, making the sending of conversation messages more efficient and convenient.
[0065] See also Figure 3 , Figure 3 FIG. 1 is another flow chart of the method for sending a session message disclosed in the embodiment of the present application. Figure 3 The session message sending method shown may include the following steps:
[0066] 301. In response to a message sending operation, obtain a target conversation message input in an information editing area of a target conversation interface.
[0067] In some embodiments, the message sending operation includes pressing a first designated key, and the duration of pressing the first designated key is less than or equal to a first duration threshold.
[0068] In some embodiments, the electronic device may also generate a line break event when a line break operation is detected; wherein the line break operation includes pressing a first designated key in the keyboard, and the duration of pressing the first designated key is greater than or equal to a first duration threshold; or, pressing the first designated key and a second designated key in the keyboard at the same time; and, when the input method framework monitors the line break event, an output line break operation is performed on the dialog box of the target session interface.
[0069] The second designated key is any key on the keyboard that is different from the first designated key. Exemplarily, the second designated key is the control key (Ctrl key).
[0070] It should be noted that the input method framework may register a line break listener. When the input method framework listens to a line break event, it performs an output line break operation on the dialog box of the target session interface.
[0071] In some embodiments, if the keyboard of the electronic device is an external keyboard of the electronic device, the message sending operation is pressing a first designated key, and the line break operation is pressing the first designated key and a second designated key on the keyboard at the same time.
[0072] In some embodiments, if the keyboard of the electronic device is a virtual keyboard of a third-party input method, the message sending operation is pressing the first designated key, and the duration of pressing the first designated key is less than the first duration threshold; the line break operation is pressing the first designated key in the keyboard, and the duration of pressing the first designated key is greater than or equal to the first duration threshold. That is, if the keyboard of the electronic device is a virtual keyboard of a third-party input method, a short press of the first designated key is a message sending operation, and a long press of the first designated key is a line break operation.
[0073] In some embodiments, the first designated key is an enter key.
[0074] In the prior art, although some software running on electronic devices supports sending conversation messages by using the Enter key, this function mostly requires manual setting by the user, which is cumbersome. After completing the setting of sending conversation messages by using the Enter key, the line break function is usually not available when using the software. By implementing the above, the keyboard can be compatible with line break and conversation message sending, solving the problem that the existing keyboard can only send a single line break or a single conversation message.
[0075] 302. Associate the target session message with the virtual window.
[0076] For detailed description of steps 301-302, please refer to Figure 2 The description of step 201-step 202 shown is not repeated here.
[0077] In some embodiments, after step 302, a drag event and a release event for the virtual window may be injected into the system of the electronic device, so that the electronic device performs a simulated drag operation on the virtual window according to the drag event, and performs a simulated release operation on the virtual window according to the release event. For the response to the drag event and the release event, please refer to the following embodiment for details.
[0078] 303. Perform a simulated drag operation on the virtual window, so that the virtual window sends the target session message to the drag-and-drop framework; wherein the simulated drag operation indicates dragging the virtual window to the information display area of the target session interface.
[0079] In some embodiments, simulating a drag operation on the virtual window may include: performing a simulated drag operation on the virtual window in response to a drag event on the virtual window.
[0080] In some embodiments, the drag event may include a press event and a move event, and the corresponding simulated drag operation includes a simulated press operation and a simulated move operation. Further, performing a simulated drag operation on the virtual window includes: performing a simulated press operation and a simulated move operation on the virtual window in sequence.
[0081] 304. Perform a simulated release operation on the virtual window, so that the drag-and-drop framework sends the target session message to a receiving account corresponding to the target session interface.
[0082] In some embodiments, simulating a release operation on the virtual window includes: performing a simulated release operation on the virtual window in response to a release event for the virtual window.
[0083] The above-mentioned drag event and release event are automatically injected into the operating system of the electronic device by the electronic device.
[0084] In some embodiments, when the electronic device executes step 303-step 304, it can be executed in a single thread or in multiple threads, which is not limited in the embodiment of the present application.
[0085] The electronic device uses a single thread to execute step 303-step 304 as follows:
[0086] Performing a simulated drag operation on the virtual window so that the virtual window sends the target session message to the drag and drop framework may include: performing a simulated drag operation on the virtual window; and sending the target session message to the drag and drop framework through the virtual window when the virtual window monitors the simulated drag operation.
[0087] Furthermore, a simulated release operation is performed on the virtual window so that the drag and drop framework sends the target session message to the receiving account corresponding to the target session interface, including: performing a simulated release operation on the virtual window; when the virtual window monitors the simulated release operation, sending the target session message to the receiving account corresponding to the target session interface through the drag and drop framework.
[0088] When executing step 303-step 304 using a single thread, a drag monitor and a release monitor may be set on the virtual window. The drag monitor is used for the virtual window to monitor the simulated drag operation, and the release monitor is used for the virtual window to monitor the simulated release operation.
[0089] In summary, when the electronic device executes step 303-step 304 in a single thread, the virtual window sends the target session message to the drag and drop framework after the virtual window monitors the simulated drag operation.
[0090] The electronic device uses two threads (a first thread and a second thread) to perform steps 303 to 304 as follows:
[0091] Performing a simulated drag operation on the virtual window so that the virtual window sends a target session message to the drag and drop framework may include: using a first thread to perform a simulated drag operation on the virtual window, and sending a message sending instruction to a second thread, so that when the second thread receives the message sending instruction, it controls the virtual window to send the target session message to the drag and drop framework.
[0092] In some embodiments, using the first thread to simulate the drag operation on the virtual window and sending a message sending instruction to the second thread may include: using the first thread to respond to the drag event for the virtual window to simulate the drag operation on the virtual window and sending a message sending instruction to the second thread. By implementing this method, the first thread performs the simulated drag operation on the virtual window and the second thread controls the virtual window to send the target session message to the drag and drop framework simultaneously, and the target session message can be quickly sent to the drag and drop framework.
[0093] Furthermore, a simulated release operation is performed on the virtual window so that the drag and drop framework sends the target session message to a receiving account corresponding to the target session interface, including: using a first thread to perform a simulated release operation on the virtual window; when the virtual window monitors the simulated release operation, using the first thread to control the drag and drop framework to send the target session message to the receiving account corresponding to the target session interface.
[0094] Furthermore, since the first thread performs a simulated drag operation on the virtual window and the second thread controls the virtual window to send the target session message to the drag and drop framework synchronously, the time interval between responding to the drag event and responding to the release event can be greatly shortened, further improving the efficiency of sending session messages.
[0095] It should be noted that when using dual threads to execute step 303-step 304, it is not necessary to set a drag monitor on the virtual window. Compared with using a single thread to send a session message, using multiple threads to send a session message can reduce the total time consumption by 90% (for example, it takes 1000 milliseconds (ms) to send a session message using a single thread, and it takes 100ms to send a session message using multiple threads), further improving the sending efficiency of the session message.
[0096] See also Figure 4A , Figure 4A This is a flowchart of the embodiment of the present application disclosed in which a single thread is used to execute step 303-step 304. Figure 4A include:
[0097] 401. In response to a drag event for a virtual window, simulate a drag operation on the virtual window.
[0098] 402. When the virtual window monitors the simulated drag operation, the target session message is sent to the drag and drop framework through the virtual window.
[0099] 403. In response to a release event for the virtual window, perform a simulated release operation on the virtual window.
[0100] 404. When the virtual window monitors the simulated release operation, a target session message is sent to a receiving account corresponding to the target session interface through a drag-and-drop framework.
[0101] See also Figure 4B , Figure 4B 303-304 is a flowchart of the embodiment of the present application using dual threads to execute step 303-step 304. Figure 4B include:
[0102] 410. In response to a drag event for a virtual window, the first thread simulates a drag operation on the virtual window and sends a message sending instruction to the second thread.
[0103] 420. When receiving the message sending instruction, the second thread controls the virtual window to send the target session message to the drag and drop frame.
[0104] 430. The first thread performs a simulated release operation on the virtual window in response to a release event for the virtual window.
[0105] 440. When the virtual window monitors the simulated release operation, the first thread is used to control the drag and drop framework to send a target session message to a receiving account corresponding to the target session interface.
[0106] By implementing the above method, a simulated drag operation is performed on the virtual window so that the virtual window sends the target session message to the drag and drop frame. Then, when the virtual window is simulated to be released, the target session message is sent to the receiving account corresponding to the target session interface through the drag and drop frame, so as to achieve the purpose of sending the session message to the receiving account. This system-level session message sending method using the drag and drop frame further improves the sending efficiency of the session message.
[0107] See also Figure 5 , Figure 5 This is a structural block diagram of the session message sending device disclosed in the embodiment of this application. Figure 5 The message sending device shown includes a message acquisition unit 501, a message association unit 502 and a message sending unit 503; wherein:
[0108] A message acquisition unit 501 is used to acquire a target conversation message input in the information editing area of the target conversation interface in response to a message sending operation;
[0109] A message associating unit 502, used to associate a target conversation message with a virtual window;
[0110] The message sending unit 503 is used to use the virtual window to drag and drop the target conversation message to the information display area of the target conversation interface, so as to send the target conversation message to the receiving account corresponding to the target conversation interface.
[0111] In some embodiments, the message sending unit 503 is used to use a virtual window to drag and drop the target session message to the information display area of the target session interface, so as to send the target session message to the receiving account corresponding to the target session interface. Specifically, the message sending unit 503 is used to simulate a drag operation on the virtual window, so that the virtual window sends the target session message to the drag and drop framework; wherein the virtual window is an invisible window, and the simulated drag operation indicates dragging the virtual window to the information display area of the target session interface; and simulate a release operation on the virtual window, so that the drag and drop framework sends the target session message to the receiving account corresponding to the target session interface.
[0112] In some embodiments, the message sending unit 503 is used to simulate the drag operation on the virtual window so that the virtual window sends the target session message to the drag and drop framework. Specifically, the message sending unit 503 is used to simulate the drag operation on the virtual window; when the virtual window monitors the simulated drag operation, the target session message is sent to the drag and drop framework through the virtual window;
[0113] Furthermore, the message sending unit 503 is used to simulate a release operation on the virtual window so that the drag and drop framework sends the target session message to the receiving account corresponding to the target session interface. Specifically, the message sending unit 503 is used to simulate a release operation on the virtual window; when the virtual window monitors the simulated release operation, the target session message is sent to the receiving account corresponding to the target session interface through the drag and drop framework.
[0114] In some embodiments, the message sending unit 503 is used to simulate the drag operation on the virtual window so that the virtual window sends the target session message to the drag and drop framework. Specifically, the message sending unit 503 is used to use the first thread to simulate the drag operation on the virtual window, and send a message sending instruction to the second thread, so that when the second thread receives the message sending instruction, it controls the virtual window to send the target session message to the drag and drop framework;
[0115] Furthermore, the message sending unit 503 is used to simulate a release operation on the virtual window so that the drag and drop framework sends the target session message to the receiving account corresponding to the target session interface. Specifically, the message sending unit 503 is used to use the first thread to simulate a release operation on the virtual window; when the virtual window monitors the simulated release operation, the first thread is used to control the drag and drop framework to send the target session message to the receiving account corresponding to the target session interface.
[0116] In some embodiments, the message sending operation includes any one of the following: pressing a first designated key on a keyboard of the electronic device, a target gesture operation, and a target voice operation.
[0117] In some embodiments, the keyboard of the electronic device includes an external keyboard or a virtual keyboard of a third-party input method, and the first designated key includes an enter key.
[0118] In some embodiments, the message sending operation includes pressing a first designated key, and the duration of pressing the first designated key is less than or equal to a first duration threshold.
[0119] In some embodiments, Figure 5 The conversation message sending device shown may also include a message line break unit, which is used to generate a line break event when a line break operation is detected. The line break operation includes pressing a first designated key in the keyboard, and the duration of pressing the first designated key is greater than or equal to a first duration threshold; or, pressing the first designated key and the second designated key in the keyboard at the same time; when the input method framework monitors the line break event, an output line break operation is performed on the dialog box of the target conversation interface.
[0120] See also Figure 6 , Figure 6 is a structural block diagram of an electronic device disclosed in an embodiment of the present application. Figure 6 The electronic device shown may include a processor 601 and a processor 602 coupled to the processor 601 , wherein the processor 602 may store one or more computer programs.
[0121] The processor 601 may include one or more processing cores. The processor 601 uses various interfaces and lines to connect the various parts of the entire electronic device, and executes various functions of the electronic device and processes data by running or executing instructions, programs, code sets or instruction sets stored in the processor 602, and calling data stored in the processor 602. Optionally, the processor 601 can be implemented in at least one hardware form of digital signal processing (Digital Signal Processing, DSP), field programmable gate array (Field-Programmable Gate Array, FPGA), and programmable logic array (Programmable Logic Array, PLA). The processor 601 can integrate one or a combination of a central processing unit (Central Processing Unit, CPU), a graphics processing unit (Graphics Processing Unit, GPU) and a modem. Among them, the CPU mainly processes the operating system, user interface and application programs; the GPU is responsible for rendering and drawing display content; and the modem is used to process wireless communications. It can be understood that the above-mentioned modem may not be integrated into the processor 601, and may be implemented separately through a communication chip.
[0122] The processor 602 may include a random access memory (RAM) or a read-only memory (ROM). The processor 602 may be used to store instructions, programs, codes, code sets or instruction sets. The processor 602 may include a program storage area and a data storage area, wherein the program storage area may store instructions for implementing an operating system, instructions for implementing at least one function (such as a touch function, a sound playback function, an image playback function, etc.), instructions for implementing the above-mentioned various method embodiments, etc. The data storage area may also store data created by the electronic device during use, etc.
[0123] In the embodiment of the present application, the processor 601 also has the following functions:
[0124] In response to the message sending operation, obtaining a target conversation message input in the message editing area of the target conversation interface;
[0125] Associating the target session message with the virtual window;
[0126] By using the virtual window, the target conversation message is dragged and dropped to the information display area of the target conversation interface to send the target conversation message to the receiving account corresponding to the target conversation interface.
[0127] In the embodiment of the present application, the processor 601 also has the following functions:
[0128] Performing a simulated drag operation on the virtual window so that the virtual window sends a target session message to the drag-and-drop framework; wherein the virtual window is an invisible window, and the simulated drag operation indicates dragging the virtual window to an information display area of a target session interface;
[0129] A simulated release operation is performed on the virtual window so that the drag-and-drop framework sends the target session message to a receiving account corresponding to the target session interface.
[0130] In the embodiment of the present application, the processor 601 also has the following functions:
[0131] Simulate dragging operations on virtual windows;
[0132] When the virtual window monitors the simulated drag operation, the target session message is sent to the drag and drop framework through the virtual window.
[0133] Perform a simulated release operation on the virtual window;
[0134] When the virtual window monitors the simulated release operation, a target session message is sent to a receiving account corresponding to the target session interface through the drag-and-drop framework.
[0135] In the embodiment of the present application, the processor 601 also has the following functions:
[0136] Using the first thread to simulate the drag operation on the virtual window, and sending a message sending instruction to the second thread, so that the second thread controls the virtual window to send the target session message to the drag and drop framework when receiving the message sending instruction;
[0137] Using the first thread to simulate the release operation on the virtual window;
[0138] When the virtual window monitors the simulated release operation, the first thread is used to control the drag and drop framework to send a target session message to a receiving account corresponding to the target session interface.
[0139] In an embodiment of the present application, the message sending operation includes any one of the following: pressing a first designated key on a keyboard of the electronic device, a target gesture operation, and a target voice operation.
[0140] In an embodiment of the present application, the keyboard of the electronic device includes an external keyboard or a virtual keyboard of a third-party input method, and the first designated key includes an enter key.
[0141] In an embodiment of the present application, the message sending operation includes pressing a first designated button, and the duration of pressing the first designated button is less than or equal to a first duration threshold.
[0142] In the embodiment of the present application, the processor 601 also has the following functions:
[0143] When a line break operation is detected, a line break event is generated, where the line break operation includes pressing a first designated key in the keyboard, and the duration of pressing the first designated key is greater than or equal to a first duration threshold; or, pressing the first designated key and a second designated key in the keyboard at the same time;
[0144] When the input method framework listens to the line break event, an output line break operation is performed on the dialog box of the target session interface.
[0145] An embodiment of the present application discloses a computer-readable storage medium storing a computer program, wherein when the computer program is executed by a processor, the processor implements part or all of the steps executed by the electronic device in the above embodiment.
[0146] The embodiment of the present application discloses a computer program product. When the computer program product is run on a computer, the computer executes part or all of the steps executed by the electronic device in the above embodiment.
[0147] An embodiment of the present application discloses an application publishing platform, which is used to publish a computer program product. When the computer program product runs on a computer, the computer executes part or all of the steps executed by the electronic device in the above embodiment.
[0148] In the above embodiments, all or part of the embodiments may be implemented by software, hardware, firmware or any combination thereof. When implemented by software, all or part of the embodiments may be implemented in the form of a computer program product.
[0149] The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on the computer, the process or function according to the embodiment of the present application is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable devices. The computer instructions can be stored in a computer-readable storage medium, or transmitted from a computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions can be transmitted from a website site, a computer, a server, or a data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) mode to another website site, computer, server, or data center. The computer-readable storage medium can be any available medium that a computer can store or a data storage device such as a server, a data center, etc. that includes one or more available media integration. Available media can be magnetic media, (e.g., floppy disk, disk, tape), optical media (e.g., DVD), or semiconductor media (e.g., solid-state disk Solid State Disk (SSD)), etc.
[0150] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0151] In the several embodiments provided in the present application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of units is only a logical function division. There may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interfaces, devices or units, which can be electrical, mechanical or other forms.
[0152] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0153] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0154] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions to enable a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the various embodiments of the present application. The aforementioned storage medium includes: U disk, mobile disk, read-only memory (ROM), random access memory (RAM), disk or optical disk, etc. Various media that can store program codes.
[0155] The above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or replace some of the technical features therein by equivalents. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present application.
Claims
1. A method for sending a session message, characterized in that: include: In response to a message sending operation, a target conversation message inputted in an information editing area of a target conversation interface is obtained; wherein the target conversation interface refers to a conversation interface where an input method cursor is located on a display screen of the electronic device, and the message sending operation includes any one of the following: pressing a first designated key on a keyboard of the electronic device, a target gesture operation, and a target voice operation; Associating the target session message with a virtual window, where the virtual window is an invisible window; The target conversation message is dragged and dropped to the information display area of the target conversation interface by using the virtual window, so as to send the target conversation message to the receiving account corresponding to the target conversation interface.
2. The method according to claim 1, characterized in that: The step of utilizing the virtual window to drag and drop the target conversation message to the information display area of the target conversation interface to send the target conversation message to a receiving account corresponding to the target conversation interface includes: Performing a simulated drag operation on the virtual window so that the virtual window sends the target session message to the drag-and-drop framework; wherein the simulated drag operation indicates dragging the virtual window to the information display area of the target session interface; A simulated release operation is performed on the virtual window, so that the drag-and-drop framework sends the target session message to a receiving account corresponding to the target session interface.
3. The method according to claim 2, characterized in that The simulating a drag operation on the virtual window so that the virtual window sends the target session message to the drag-and-drop framework includes: Performing a simulated drag operation on the virtual window; When the virtual window monitors the simulated drag operation, sending the target session message to the drag-and-drop framework through the virtual window; The simulating release operation on the virtual window so that the drag-and-drop framework sends the target session message to a receiving account corresponding to the target session interface includes: Performing a simulated release operation on the virtual window; When the virtual window monitors the simulated release operation, the target session message is sent to a receiving account corresponding to the target session interface through the drag-and-drop framework.
4. The method according to claim 2, characterized in that: The simulating a drag operation on the virtual window so that the virtual window sends the target session message to the drag-and-drop framework includes: Using the first thread to simulate the drag operation on the virtual window, and sending a message sending instruction to the second thread, so that the second thread controls the virtual window to send the target session message to the drag and drop framework when receiving the message sending instruction; The simulating release operation on the virtual window so that the drag-and-drop framework sends the target session message to a receiving account corresponding to the target session interface includes: Using the first thread to perform a simulated release operation on the virtual window; When the virtual window monitors the simulated release operation, the first thread is used to control the drag and drop framework to send the target session message to a receiving account corresponding to the target session interface.
5. The method according to claim 1, characterized in that The keyboard of the electronic device includes an external keyboard or a virtual keyboard of a third-party input method, and the first designated key includes an enter key.
6. The method according to claim 1, characterized in that The message sending operation includes pressing the first designated button, and the duration of pressing the first designated button is less than or equal to a first duration threshold.
7. The method according to claim 1, characterized in that The method further comprises: When a line break operation is detected, a line break event is generated, wherein the line break operation includes pressing a first designated key in the keyboard, and the duration of pressing the first designated key is greater than or equal to a first duration threshold; or, simultaneously pressing the first designated key and a second designated key in the keyboard; When the input method framework monitors the line break event, an output line break operation is performed on the dialog box of the target conversation interface.
8. A conversation message sending device, characterized in that: include: a message acquisition unit, configured to acquire a target conversation message inputted in an information editing area of a target conversation interface in response to a message sending operation; wherein the target conversation interface refers to a conversation interface where an input method cursor is located on a display screen of an electronic device, and the message sending operation includes any one of the following: pressing a first designated key on a keyboard of the electronic device, a target gesture operation, and a target voice operation; A message associating unit, configured to associate the target conversation message with a virtual window, wherein the virtual window is an invisible window; The message sending unit is used to use the virtual window to drag and drop the target conversation message to the information display area of the target conversation interface to send the target conversation message to the receiving account corresponding to the target conversation interface.
9. An electronic device, characterized in that: include: A memory storing executable program code; and a processor coupled to the memory; The processor calls the executable program code stored in the memory, and when the executable program code is executed by the processor, the processor implements the method according to any one of claims 1 to 7.
10. A computer-readable storage medium having executable program code stored thereon, characterized in that: When the executable program code is executed by a processor, the method according to any one of claims 1 to 7 is implemented.
Citation Information
Patent Citations
Media file processing method and device and storage medium
CN111628977A
Message sending method and device and electronic equipment
CN111984115A
