Detailed Description
Embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. While certain embodiments of the present disclosure are shown in the drawings, it is to be understood that the present disclosure may be embodied in various forms and should not be construed as limited to the embodiments set forth herein, but rather are provided for a more thorough and complete understanding of the present disclosure. It should be understood that the drawings and embodiments of the disclosure are for illustration purposes only and are not intended to limit the scope of the disclosure.
It should be understood that the various steps recited in the method embodiments of the present disclosure may be performed in a different order, and/or performed in parallel. Moreover, method embodiments may include additional steps and/or omit performing the illustrated steps. The scope of the present disclosure is not limited in this respect.
The term "include" and variations thereof as used herein are open-ended, i.e., "including but not limited to". The term "based on" is "based, at least in part, on". The term "one embodiment" means "at least one embodiment"; the term "another embodiment" means "at least one additional embodiment"; the term "some embodiments" means "at least some embodiments". Relevant definitions for other terms will be given in the following description.
It should be noted that the terms "first", "second", and the like in the present disclosure are only used for distinguishing the devices, modules or units, and are not used for limiting the devices, modules or units to be different devices, modules or units, and also for limiting the sequence or interdependence relationship of the functions executed by the devices, modules or units.
It is noted that references to "a", "an", and "the" modifications in this disclosure are intended to be illustrative rather than limiting, and that those skilled in the art will recognize that "one or more" may be used unless the context clearly dictates otherwise.
The names of messages or information exchanged between devices in the embodiments of the present disclosure are for illustrative purposes only, and are not intended to limit the scope of the messages or information.
In the embodiment of the disclosure, a first connection number and a first window number are determined, where the first connection number is the number of first target screen projection sources connected with a screen projection device before disconnection is performed, and the first window number is the number of target windows already opened on the screen projection device.
In the embodiment of the disclosure, the target window is used for displaying screen projection information projected to the screen projection device by the screen projection source.
In the embodiment of the disclosure, the first connection number is greater than or equal to 2, the first window number is greater than or equal to 1, and the first connection number is the number of the first target screen projection sources connected with the screen projection device before disconnection is performed.
In the embodiment of the present disclosure, as shown in fig. 1, the first connection number is 2, and the first window number is 1. The labels of the three screen projection sources displayed on the toolbar 102 of the only opened window 101 of the screen projection device are device 103, device 104 and device 105, respectively, each screen projection source connected with the screen projection device is defined as a first target screen projection source, and each opened window is defined as a target window. The tab of the screen projection source may indicate different states between the screen projection device and the screen projection source with different display patterns. The tag of the screen projection source can comprise three states, namely, turning off, turning on and selecting; if the label of the screen projection source displays gray, the screen projection source is turned off, that is, the screen projection device and the screen projection source are in a disconnected state, for example, the device 103; if the label of the screen projection source displays blue or white, the label indicates that the screen projection device is turned on, that is, the screen projection device and the screen projection source are in a connected state, for example, the device 104 and the device 105; and selecting a label representing that the user clicks the screen projection source, namely selecting the screen projection source to project screen projection information to the screen projection equipment.
The embodiment of the present disclosure provides a screen projection method, a flow diagram of the method is shown in fig. 2, and the method includes:
s101, acquiring a disconnection instruction.
In the embodiment of the disclosure, the disconnection instruction is used for instructing to disconnect the connection between the at least one first target screen projection source and the screen projection device. In an embodiment, the disconnection instruction may be triggered by a screen projection source, and the screen projection source sends the disconnection instruction to the screen projection device.
S102, according to the connection disconnection command, disconnecting at least one first target screen projection source from the screen projection equipment, and determining a second connection number, wherein the second connection number is the number of the first target screen projection sources which are not disconnected.
In the embodiment of the disclosure, in an optional mode, the screen projection device is in a connection state with N first target screen projection sources, and when it is detected that M first target screen projection sources are disconnected from the screen projection device, it is determined that the number of the first target screen projection sources which are not disconnected is N-M, that is, a difference is obtained between N and M; wherein N and M are positive integers, N is greater than M, the first connection number is N, and the second connection number is N-M.
For example, the screen projection device is in a connection state with 3 first target screen projection sources, and when it is detected that 1 first target screen projection source is disconnected from the screen projection device, it is determined that the number of the first target screen projection sources which are not disconnected is 2, that is, a difference is obtained between 3 and 2; wherein the first number of connections is 3 and the second number of connections is 2.
In the embodiment of the present disclosure, in another optional manner, the screen projection device disconnects S first target screen projection sources from the screen projection device according to the disconnection instruction, and if the screen projection device detects K first target screen projection sources that are not disconnected, it determines that the second connection number is K; wherein S and K are both positive integers.
And S103, displaying screen projection information projected to the screen projection equipment by each first target screen projection source which is not disconnected according to the second connection number and the first window number, wherein the first window number is the number of the opened target windows on the screen projection equipment.
In the embodiment of the present disclosure, the screen projection information includes various media information, a real-time operation screen, and the like.
In the embodiment of the present disclosure, displaying, according to the second connection number and the first window number, screen projection information projected to the screen projection device by each first target screen projection source that is not disconnected includes:
when the second connection number is smaller than the first window number, closing the target windows with the second window number, wherein the second window number is smaller than the first window number; displaying screen projection information projected to the screen projection equipment by each first target screen projection source which is not disconnected by utilizing each target window which is not closed;
or when the second connection number is greater than or equal to the first window number, keeping the target window of the first window number in an open state; and displaying screen projection information projected to the screen projection equipment by each first target screen projection source which is not disconnected by utilizing the target windows with the first window number.
In the embodiment of the disclosure, the number of the first windows may be equal to or greater than the number of the first connections, and when the number of the second connections is less than the number of the first windows, the number of the target windows that are left open may be made to be the same as the number of the first target screen projection sources that are not disconnected by closing all or part of the redundant target windows, or the number of the target windows that are left open may be made to be greater than the number of the first target screen projection sources that are not disconnected, so that it is ensured that a proper number of target windows are used to display screen projection information of the first target screen projection sources that are not disconnected.
In the embodiment of the present disclosure, if the second connection number is smaller than the first window number, the target windows of the second window number may be closed, and the second window number is smaller than the first window number. If the second connection number is N-M and the first window number is N, that is, the first window number is equal to the first connection number, it may be determined that the number N-M of the first target screen projection sources that are not disconnected is less than the number N of target windows that have been opened on the screen projection device, and the number of redundant target windows is M, that is, the second window number is M; closing M redundant target windows and reserving N-M opened target windows, so that the number of the reserved opened target windows is the same as that of the first target screen projection sources which are not disconnected, namely, the reserved opened target windows are all N-M; or closing part of the redundant target windows, namely closing F redundant target windows, and reserving N-F opened target windows, wherein the number of the unclosed redundant target windows is M-F; wherein N, M and F are both positive integers, N is greater than M, and M is greater than F.
In the embodiment of the present disclosure, if the second connection number is smaller than the first window number, the target windows of the second window number may be closed, and the second window number is smaller than the first window number. If the second connection number is N-M and the first window number is H, when the first window number H is greater than the first connection number N, the number N-M of the first target screen projection sources which are not disconnected is smaller than the number H of target windows which are opened on the screen projection equipment, and the number of redundant target windows is H-N + M, namely the second window number is H-N + M; and closing H-N + M redundant target windows and reserving N-M opened target windows, so that the number of the reserved opened target windows is the same as that of the first target screen projection sources which are not disconnected, namely, the reserved opened target windows are all N-M. Or closing part of the redundant target windows, namely closing F redundant target windows, and reserving H-F opened target windows, wherein the number of the unclosed redundant target windows is H-N + M-F; wherein H, N, M and F are both positive integers, N is greater than M, and M is greater than F.
In the embodiment of the disclosure, when the connection between the at least one first target screen projection source and the screen projection device is disconnected, if the number of the first target screen projection sources which are not disconnected is less than the number of the target windows which are opened on the screen projection device, one or more target windows can be correspondingly closed, so that window resources are saved, and user experience is improved.
In an embodiment of the present disclosure, disconnecting at least one first target screen projection source from a screen projection device includes:
disconnecting a first target screen projection source from screen projection equipment, wherein before disconnection of the first target screen projection source, screen projection information projected to the screen projection equipment by the first target screen projection source is displayed on a target window with a first connection number, and the first connection number is the number of the first target screen projection sources connected with the screen projection equipment before disconnection;
correspondingly, screen projection information projected to the screen projection equipment by each first target screen projection source which is not disconnected is displayed, and the screen projection information comprises the following steps: and displaying screen projection information projected to the screen projection equipment by each first target screen projection source which is not disconnected through switching display.
In the embodiment of the present disclosure, after disconnecting the connection between the first target screen projection source and the screen projection device, the method further includes:
and closing the at least one target window which is opened last.
In the embodiment of the present disclosure, for example, the first target screen projection source disconnected from the screen projection device is an a screen projection source, the first target screen projection source not disconnected from the screen projection device is a B screen projection source, each opened window on the screen projection device is defined as a target window, the first connection number is 2, the first window number is 2 or 3, and the second connection number is 1. Based on this, if two screen projection sources A and B are connected with the screen projection equipment, 2 or 3 windows are opened to display the picture projected by the screen projection source A to the screen projection equipment, at the moment, the screen projection source A is actively or passively disconnected, 1 or 2 last opened windows are respectively closed, only 1 window is reserved, the screen projection source B is automatically switched to project the picture projected by the screen projection equipment, namely, the reserved 1 window displays the picture of the screen projection source B.
In the embodiment of the present disclosure, for example, the first target screen projection source disconnected from the screen projection device is a screen projection source a, the first target screen projection sources not disconnected from the screen projection device are B and C screen projection sources, each opened window on the screen projection device is defined as a target window, the first connection number is 3, the first window number is 3, the second connection number is 2, and the second window number is 1. Based on this, if A, B and C three throw the screen source and throw the screen equipment and be in being connected, the picture that A throws the screen source and throw the screen equipment is all shown to 3 windows that open, and A throws the screen source initiative or the passive disconnection at this moment, closes 1 window that opens last, reserves 2 windows, and automatic switch over to B and C throw the screen source and throw the picture that the screen equipment was thrown to, 2 windows that promptly remain show B and C respectively throw the screen information that the screen source throwed to throwing the screen equipment.
In the embodiment of the disclosure, if the second connection number is greater than or equal to the first window number, the target window of the first window number is kept in an open state; and displaying screen projection information projected to the screen projection equipment by each first target screen projection source which is not disconnected by utilizing the target windows with the first window number.
In the embodiment of the present disclosure, for example, the first target screen projection source disconnected from the screen projection device is a screen projection source a, the first target screen projection sources not disconnected from the screen projection device are screen projection sources B and C, each window opened on the screen projection device is defined as a target window, the first connection number is 3, the first window number is 1, and the second connection number is 2. Based on this, if A, B and C three screen projection sources are connected with the screen projection device, only 1 window is opened to display the picture projected by the A screen projection source to the screen projection device, at this time, the A device is actively disconnected, no window is closed, the current window is automatically switched to the B or C screen projection source to project the picture of the screen projection device, and the switched screen projection source can be either one of the B and C screen projection sources or the last screen projection source connected with the screen projection device in the B and C screen projection sources.
In the embodiment of the present disclosure, displaying, by using the target windows with the number of the first windows, screen projection information projected to the screen projection device by each first target screen projection source that is not disconnected, includes:
displaying screen projection information projected to the screen projection equipment by the first target screen projection source which is not disconnected and has the third connection number by using the target windows with the first window number;
and the third connection number is less than or equal to the first window number, and the first target screen projection sources of the third connection number are determined based on the time sequence of connection establishment between the first target screen projection sources and the screen projection equipment.
In the embodiment of the present disclosure, displaying, by using the target windows with the first window number, screen projection information projected to the screen projection device by the first target screen projection source with the third connection number that is not disconnected includes:
and displaying screen projection information projected to the screen projection equipment by the first target screen projection source which is not disconnected and is different or the same in the third connection number by using the target windows with the first window number.
In the embodiment of the present disclosure, for example, the first target screen projection source disconnected from the screen projection device is a screen projection source a, the first target screen projection sources not disconnected from the screen projection device are screen projection sources B and C, each window opened on the screen projection device is defined as a target window, the first connection number is 3, the first window number is 2, and the third connection number is 2. Based on this, if A, B and C three screen projection sources are in connection with the screen projection equipment, only 2 windows are opened to display the pictures projected by the A screen projection source to the screen projection equipment, at the moment, the A screen projection source is actively or passively disconnected, no window is closed, the 2 windows are automatically switched to the B and C screen projection sources to project the pictures of the screen projection equipment, and the B and C screen projection sources are the last two screen projection sources connected with the screen projection equipment. Or, the 2 windows are automatically switched to a screen projection source B to project the screen to the screen projection equipment, and the screen projection source B is the screen projection source which is finally connected with the screen projection equipment. Or the 2 windows are automatically switched to a C screen projection source to project the pictures of the screen projection equipment, and the C screen projection source is the screen projection source which is finally connected with the screen projection equipment.
In the embodiment of the disclosure, when it is detected that all the target windows are in a disconnected state, the connection between all the first target screen projection sources in a connected state of the screen projection equipment is disconnected.
In the embodiment of the disclosure, if all windows on the screen projection device are closed, the connection between all the first target screen projection sources and the screen projection device is disconnected. For example, 2-3 first target screen projection sources are connected with the screen projection device, the screen projection device only opens 1 window, the user clicks a close key at this time to close the window, and a dialog box pops up before the window is closed: closing the application will disconnect all connections, if the current connection needs to be disconnected, please click the return key. Is all connections broken? Determine/return ".
Another screen projection method is provided in the embodiment of the present disclosure, a flow chart of the method is shown in fig. 3, and the method includes:
s201, a first connection opening instruction and a window opening instruction are obtained, the first connection opening instruction is used for indicating the screen projection equipment to be connected with a screen projection source, and the window opening instruction is used for indicating the opening of a window on the screen projection equipment.
In the embodiment of the disclosure, the window is used for displaying screen projection information projected to the screen projection device by the screen projection source.
In the embodiment of the present disclosure, as shown in fig. 4, the windowing instruction may be triggered by the user terminal 202, and the user terminal 202 sends the windowing instruction to the screen projection device 201, where the user terminal 202 may be an APP client of the screen projection device 201; the connection opening instruction can be triggered by the screen projection source 203, and the screen projection source 203 can send the connection opening instruction to the screen projection device 201 through the wireless local area network Wi-Fi. In an embodiment, the screen projecting service of the screen projecting device is started by sending a window opening instruction by the user terminal, so that the screen projecting source cannot misoperate and project a screen onto the screen projecting device, in other words, if the screen projecting device 201 does not start the screen projecting service, the screen projecting source 203 cannot force to project the screen, and the screen projecting source 203 cannot project the screen, for example, if the user terminal 202 sends the window opening instruction to instruct the screen projecting device 201 to start at least one window, the screen projecting device 201 starts the screen projecting service after receiving the window opening instruction, and thereafter, the screen projecting source can project the screen on the screen projecting device 201.
S202, receiving a window display instruction, and displaying screen projection information projected to screen projection equipment by each first target screen projection source by using each target window; each target window comprises a window which is displayed in the window and is indicated by the windowing instruction, and each first target screen projection source comprises a screen projection source which is connected with the windowing instruction and is indicated by the windowing instruction.
In the embodiment of the disclosure, the window display instruction is used for indicating the target window to display screen projection information projected to the screen projection device by the screen projection source. For example, the screen projection device is simultaneously connected with three first target screen projection sources, three windows on the screen projection device are simultaneously opened, and the window display instruction indicates that screen projection information projected to the screen projection device by the three first target screen projection sources is respectively displayed on the three windows.
In the embodiment of the disclosure, a first connection number and a first window number are determined, wherein the first connection number is the number of first target screen projection sources connected with screen projection equipment, and the first window number is the number of target windows opened on the screen projection equipment; acquiring a second connection opening instruction, wherein the second connection opening instruction is used for indicating the screen projection equipment to be connected with a second target screen projection source; displaying screen projection information projected to the screen projection equipment by the second target screen projection source according to the first connection number and the first window number; and the second target screen projection sources are screen projection sources except for the first target screen projection sources.
In the embodiment of the present disclosure, displaying screen projection information projected from a second target screen projection source to a screen projection device according to a first connection number and a first window number includes:
when the first connection number is smaller than a first preset threshold value and the first window number is equal to a second preset threshold value, screen projection information projected to screen projection equipment by a second target screen projection source is displayed in at least one of two target windows displaying screen projection information projected by the same first target screen projection source;
or when the first connection number is equal to a first preset threshold value, screen projection information projected to the screen projection equipment by the second target screen projection source is displayed in at least one target window in each target window according to the acquired connection disconnection instruction, wherein the connection disconnection instruction is used for indicating disconnection of at least one first target screen projection source in each first target screen projection source.
In the embodiment of the disclosure, when the first connection number is smaller than a first preset threshold and the number of first windows is equal to a second preset threshold, screen projection information projected to the screen projection device by a second target screen projection source is displayed in at least one of two target windows displaying screen projection information projected by the same first target screen projection source. For example, the first connection number is 2, the first window number is 3, the first preset threshold value is 3, the second preset threshold value is 3, and each window opened on the screen projection device is defined as a target window. The window 1 displays a picture projected to the screen projection equipment by the screen projection source No. 1, the window 2 displays a picture projected to the screen projection equipment by the screen projection source No. 1, and the window 3 displays a picture projected to the screen projection equipment by the screen projection source No. 2; if the No. 3 screen projection source is to be connected with the screen projection device, one window may be selected from window 1 or window 2 to display the picture projected by the No. 3 screen projection source to the screen projection device, for example, window 1 is selected to display the picture projected by the No. 3 screen projection source to the screen projection device.
In the embodiment of the present disclosure, according to the obtained disconnection instruction, in at least one target window of the target windows, displaying screen projection information projected by the second target screen projection source to the screen projection device, where the screen projection information includes:
and according to the acquired disconnection instruction, taking the target window as a display window of a newly connected second target screen projection source, and displaying screen projection information projected to the screen projection equipment by the second target screen projection source through the display window, wherein the disconnection instruction instructs to disconnect the connection between the first target screen projection source and the screen projection equipment, and the screen projection information projected to the screen projection equipment by the first target screen projection source is displayed on the display window.
For example, the first connection number is 3, the first window number is 3, the first preset threshold value is 3 and the second preset threshold value is 3, and each window opened on the screen projection device is defined as a target window. Based on the method, the screen projection source No. 1, the screen projection source No. 2 and the screen projection source No. 3 are first target screen projection sources, and the screen projection source No. 4 is a second target screen projection source. The picture projected to the screen projection equipment by the screen projection source No. 1 is displayed on the window 1, the picture projected to the screen projection equipment by the screen projection source No. 2 is displayed on the window 2, and the picture projected to the screen projection equipment by the screen projection source No. 3 is displayed on the window 3. And the acquired disconnection instruction indicates that the connection between the screen projection source No. 1 and the screen projection equipment is disconnected, the window 1 is used as a display window of the newly connected screen projection source No. 4, and screen projection information projected to the screen projection equipment by the screen projection source No. 4 is displayed through the window 1.
In the embodiment of the present disclosure, according to the obtained disconnection instruction, in at least one target window of the target windows, displaying screen projection information projected by the second target screen projection source to the screen projection device, where the screen projection information includes:
determining at least one target window according to the acquired disconnection instruction and at least one of the target window with a focus in each target window, a prompt of each target window and a preset selection frame;
and displaying screen projection information projected to the screen projection equipment by the second target screen projection source in at least one target window.
For example, the first connection number is 3, the first window number is 3, the first preset threshold value is 3 and the second preset threshold value is 3, and each window opened on the screen projection device is defined as a target window. Based on the method, the screen projection source No. 1, the screen projection source No. 2 and the screen projection source No. 3 are first target screen projection sources, and the screen projection source No. 4 is a second target screen projection source. Displaying a picture projected to the screen projection equipment by the screen projection source No. 1 on the window 1, and if the screen projection equipment has the screen projection source No. 2 newly connected with the screen projection equipment, opening the window 2; and if a No. 3 screen projection source newly connected with the screen projection equipment exists, opening a window 3. When the No. 4 screen projection source is connected with the screen projection equipment, a window with a focus at present pops up to prompt a user, for example, if the window 2 is the window with the focus at present, the No. 2 screen projection source is disconnected or not, and the No. 4 screen projection source is connected; or popping up a selection frame, and inquiring which one of the No. 1 screen projection source, the No. 2 screen projection source and the No. 3 screen projection source is disconnected so as to connect the No. 4 screen projection source; or whether the window with the focus has the prompt of popping up, and prompting the user to click and disconnect any one of the screen projection source No. 1, the screen projection source No. 2 and the screen projection source No. 3 so as to connect the screen projection source No. 4.
In the embodiment of the disclosure, the first preset threshold is used for representing the maximum number of screen projection sources which can be connected to the screen projection device, and the second preset threshold is used for representing the maximum number of windows which can be opened on the screen projection device. The first preset threshold and the second preset threshold are integers greater than or equal to 1.
In the embodiment of the present disclosure, for example, the first preset threshold is 3, and the maximum number of screen projection sources that the screen projection device can connect to is 3; the second preset threshold value is 3, and the maximum number of windows which can be opened on the screen projection equipment is 3.
In the embodiment of the disclosure, when the screen projection equipment does not start the screen projection service, the screen projection source cannot forcibly project the screen, and the screen projection source cannot project the screen, so that the screen is prevented from being projected by mistake; therefore, window resources are saved, and user experience is improved.
Based on the same inventive concept, the embodiment of the present disclosure further provides a screen projection apparatus, a schematic structural diagram of the apparatus is shown in fig. 5, and the screen projection apparatus 60 includes a first processing module 601, a second processing module 602, and a third processing module 603.
A first processing module 601, configured to obtain a disconnection instruction;
the second processing module 602 is configured to disconnect, according to the disconnection instruction, the connection between the at least one first target screen projection source and the screen projection device, and determine a second connection number, where the second connection number is the number of the first target screen projection sources that are not disconnected;
and a third processing module 603, configured to display, according to the second connection number and the first window number, screen projection information that is projected to the screen projection device by each first target screen projection source that is not disconnected, where the first window number is the number of target windows already opened on the screen projection device.
In the embodiment of the present disclosure, the third processing module 603 is specifically configured to close the target windows with the second number of windows when the second connection number is smaller than the first number of windows, where the second number of windows is smaller than the first number of windows; displaying screen projection information projected to the screen projection equipment by each first target screen projection source which is not disconnected by utilizing each target window which is not closed; or when the second connection number is greater than or equal to the first window number, keeping the target window of the first window number in an open state; and displaying screen projection information projected to the screen projection equipment by each first target screen projection source which is not disconnected by utilizing the target windows with the first window number.
In the embodiment of the present disclosure, the third processing module 603 is specifically configured to display, by using the target windows of the first window number, screen projection information projected to the screen projection device by the first target screen projection source, which is not disconnected, of the third connection number; and the third connection number is less than or equal to the first window number, and the first target screen projection sources of the third connection number are determined based on the time sequence of connection establishment between the first target screen projection sources and the screen projection equipment.
In this embodiment of the disclosure, the third processing module 603 is specifically configured to display, by using the target windows with the first number of windows, screen projection information that is projected to the screen projection device by the first target screen projection source that is not disconnected and is different or the same in the third number of connections.
In this embodiment of the disclosure, the second processing module 602 is specifically configured to disconnect a first target screen projection source from the screen projection device, where before the first target screen projection source is disconnected, screen projection information projected by the first target screen projection source to the screen projection device is displayed on a target window with a first connection number, where the first connection number is the number of the first target screen projection sources connected to the screen projection device before disconnection is performed; correspondingly, the second processing module 602 is specifically configured to display, by switching display, screen projection information projected to the screen projection device by each first target screen projection source that is not disconnected.
In the embodiment of the present disclosure, after the second processing module 602 disconnects the first target screen projection source from the screen projection device, the second processing module 602 is further configured to close the last opened at least one target window.
In this embodiment of the present disclosure, the third processing module 603 is further configured to disconnect all first target screen projection sources that are in a connected state with the screen projection device when it is detected that all target windows are in a disconnected state.
In the embodiment of the disclosure, the first connection number is greater than or equal to 2, the first window number is greater than or equal to 1, and the first connection number is the number of the first target screen projection sources connected with the screen projection device before disconnection is performed.
The application of the embodiment of the disclosure has at least the following beneficial effects:
the method comprises the steps that connection of at least one first target screen projection source and screen projection equipment is disconnected, and a second connection number is determined, wherein the second connection number is the number of the first target screen projection sources which are not disconnected; displaying screen projection information projected to the screen projection equipment by each first target screen projection source which is not disconnected according to the second connection number and the first window number, wherein the first window number is the number of target windows opened on the screen projection equipment; therefore, a proper number of target windows can be ensured to be used for displaying screen projection information of the first target screen projection source which is not disconnected; the window resource is saved, and the user experience is improved.
Based on the same inventive concept, the disclosed embodiment further provides another screen projection device, which is shown in fig. 6, and the screen projection device 70 includes a fourth processing module 701 and a fifth processing module 702.
The fourth processing module 701 is configured to obtain a first connection opening instruction and a windowing instruction, where the first connection opening instruction is used to instruct the screen projection device to connect with the screen projection source, and the windowing instruction is used to instruct the screen projection device to open a window;
a fifth processing module 702, configured to receive a window display instruction, and display, by using each target window, screen projection information that is projected to the screen projection device by each first target screen projection source; each target window comprises a window which is displayed in the window and is indicated by the windowing instruction, and each first target screen projection source comprises a screen projection source which is connected with the first windowing instruction.
In this embodiment of the present disclosure, the fifth processing module 702 is further configured to determine a first connection number and a first window number, where the first connection number is the number of first target screen projection sources connected to the screen projection device, and the first window number is the number of target windows already opened on the screen projection device; acquiring a second connection opening instruction, wherein the second connection opening instruction is used for indicating the screen projection equipment to be connected with a second target screen projection source; displaying screen projection information projected to the screen projection equipment by the second target screen projection source according to the first connection number and the first window number; and the second target screen projection sources are screen projection sources except for the first target screen projection sources.
In this disclosure, the fifth processing module 702 is specifically configured to, when the first connection number is smaller than a first preset threshold and the first window number is equal to a second preset threshold, display screen projection information projected by a second target screen projection source to the screen projection device in at least one of two target windows displaying screen projection information projected by the same first target screen projection source; or when the first connection number is equal to the first preset threshold, displaying screen projection information projected to the screen projection equipment by the second target screen projection source in any one of the at least one target window according to the acquired disconnection instruction, wherein the disconnection instruction is used for indicating to disconnect at least one first target screen projection source in each first target screen projection source; the first preset threshold value is used for representing the maximum number of screen projection sources which can be connected with the screen projection equipment, and the second preset threshold value is used for representing the maximum number of windows which can be opened on the screen projection equipment.
The fifth processing module 702 is specifically configured to, according to the obtained disconnection instruction, use the target window as a display window of a newly connected second target screen projection source, and display screen projection information projected by the second target screen projection source to the screen projection device through the display window, where the disconnection instruction indicates to disconnect the connection between the first target screen projection source and the screen projection device, and the screen projection information projected by the first target screen projection source to the screen projection device is displayed on the display window.
A fifth processing module 702, configured to determine, according to the obtained disconnection instruction, at least one target window through at least one of a target window with a focus in each target window, a prompt of each target window, and a preset selection frame;
and displaying screen projection information projected to the screen projection equipment by the second target screen projection source in at least one target window.
The application of the embodiment of the disclosure has at least the following beneficial effects:
when the screen projection equipment does not start the screen projection service, the screen projection source cannot be forced to project the screen, and the screen projection source cannot be projected upwards, so that the screen is prevented from being projected by mistake; therefore, window resources are saved, and user experience is improved.
The content that is not described in detail in the screen projection device provided by the embodiment of the present disclosure may refer to the screen projection method provided by the above embodiment, and the beneficial effects that the screen projection device provided by the embodiment of the present disclosure can achieve are the same as the screen projection method provided by the above embodiment, and are not described again here.
Referring now to FIG. 7, a block diagram of an electronic device 800 suitable for use in implementing embodiments of the present disclosure is shown. The terminal device in the embodiments of the present disclosure may include, but is not limited to, a mobile terminal such as a mobile phone, a notebook computer, a digital broadcast receiver, a PDA (personal digital assistant), a PAD (tablet computer), a PMP (portable multimedia player), a vehicle terminal (e.g., a car navigation terminal), and the like, and a stationary terminal such as a digital TV, a desktop computer, and the like. The electronic device shown in fig. 7 is only an example, and should not bring any limitation to the functions and the scope of use of the embodiments of the present disclosure.
The electronic device includes: a memory and a processor, wherein the processor may be referred to as the processing device 801 described below, and the memory may include at least one of a Read Only Memory (ROM)802, a Random Access Memory (RAM)803, and a storage device 808, as shown in fig. 7:
the electronic device 800 may include a processing means (e.g., a central processing unit, a graphics processor, etc.) 801 that may perform various appropriate actions and processes in accordance with a program stored in a Read Only Memory (ROM)802 or a program loaded from a storage means 808 into a Random Access Memory (RAM) 803. In the RAM 803, various programs and data necessary for the operation of the electronic apparatus 800 are also stored. The processing apparatus 801, the ROM 802, and the RAM 803 are connected to each other by a bus 804. An input/output (I/O) interface 805 is also connected to bus 804.
Generally, the following devices may be connected to the I/O interface 805: input devices 806 including, for example, a touch screen, touch pad, keyboard, mouse, camera, microphone, accelerometer, gyroscope, etc.; output devices 807 including, for example, a Liquid Crystal Display (LCD), speakers, vibrators, and the like; storage 808 including, for example, magnetic tape, hard disk, etc.; and a communication device 809. The communication means 809 may allow the electronic device 800 to communicate wirelessly or by wire with other devices to exchange data. While fig. 7 illustrates an electronic device 800 having various means, it is to be understood that not all illustrated means are required to be implemented or provided. More or fewer devices may alternatively be implemented or provided.
In particular, according to an embodiment of the present disclosure, the processes described above with reference to the flowcharts may be implemented as computer software programs. For example, embodiments of the present disclosure include a computer program product comprising a computer program carried on a non-transitory computer readable medium, the computer program containing program code for performing the method illustrated by the flow chart. In such an embodiment, the computer program may be downloaded and installed from a network through the communication means 809, or installed from the storage means 808, or installed from the ROM 802. The computer program, when executed by the processing apparatus 801, performs the above-described functions defined in the methods of the embodiments of the present disclosure.
It should be noted that the computer readable medium in the present disclosure can be a computer readable signal medium or a computer readable storage medium or any combination of the two. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples of the computer readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the present disclosure, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In contrast, in the present disclosure, a computer readable signal medium may comprise a propagated data signal with computer readable program code embodied therein, either in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: electrical wires, optical cables, RF (radio frequency), etc., or any suitable combination of the foregoing.
In some embodiments, the clients, servers may communicate using any currently known or future developed network Protocol, such as HTTP (HyperText Transfer Protocol), and may interconnect with any form or medium of digital data communication (e.g., a communications network). Examples of communication networks include a local area network ("LAN"), a wide area network ("WAN"), the Internet (e.g., the Internet), and peer-to-peer networks (e.g., ad hoc peer-to-peer networks), as well as any currently known or future developed network.
The computer readable medium may be embodied in the electronic device; or may exist separately without being assembled into the electronic device.
The computer readable medium carries one or more programs which, when executed by the electronic device, cause the electronic device to: acquiring a connection breaking instruction; according to the connection disconnection instruction, disconnecting at least one first target screen projection source from screen projection equipment, and determining a second connection number, wherein the second connection number is the number of the first target screen projection sources which are not disconnected; and displaying screen projection information projected to the screen projection equipment by each first target screen projection source which is not disconnected according to the second connection number and the first window number, wherein the first window number is the number of target windows opened on the screen projection equipment.
The computer readable medium carries one or more programs which, when executed by the electronic device, cause the electronic device to: acquiring a first connection opening instruction and a window opening instruction, wherein the first connection opening instruction is used for indicating the screen projection equipment to be connected with a screen projection source, and the window opening instruction is used for indicating the opening of a window on the screen projection equipment; receiving window display instructions, and displaying screen projection information projected to the screen projection equipment by each first target screen projection source by using each target window; each target window comprises a window which is displayed in the window and is indicated by the windowing instruction, and each first target screen projection source comprises a screen projection source which is connected with the first windowing instruction.
Computer program code for carrying out operations for the present disclosure may be written in any combination of one or more programming languages, including but not limited to an object oriented programming language such as Java, Smalltalk, C + +, and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any type of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or the connection may be made to an external computer (for example, through the Internet using an Internet service provider).
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present disclosure. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The modules or units described in the embodiments of the present disclosure may be implemented by software or hardware. Wherein the designation of a module or unit does not in some cases constitute a limitation of the unit itself.
The functions described herein above may be performed, at least in part, by one or more hardware logic components. For example, without limitation, exemplary types of hardware logic components that may be used include: field Programmable Gate Arrays (FPGAs), Application Specific Integrated Circuits (ASICs), Application Specific Standard Products (ASSPs), systems on a chip (SOCs), Complex Programmable Logic Devices (CPLDs), and the like.
In the context of this disclosure, a machine-readable medium may be a tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. The machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples of a machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
According to one or more embodiments of the present disclosure, an embodiment provides a screen projection method, including:
acquiring a connection breaking instruction;
according to the connection disconnection instruction, disconnecting at least one first target screen projection source from screen projection equipment, and determining a second connection number, wherein the second connection number is the number of the first target screen projection sources which are not disconnected;
and displaying screen projection information projected to the screen projection equipment by each first target screen projection source which is not disconnected according to the second connection number and the first window number, wherein the first window number is the number of target windows opened on the screen projection equipment.
In the embodiment of the present disclosure, displaying, according to the second connection number and the first window number, screen projection information projected to the screen projection device by each first target screen projection source that is not disconnected includes:
when the second connection number is smaller than the first window number, closing the target windows with the second window number, wherein the second window number is smaller than the first window number; displaying screen projection information projected to the screen projection equipment by each first target screen projection source which is not disconnected by utilizing each target window which is not closed;
or when the second connection number is greater than or equal to the first window number, keeping the target window of the first window number in an open state; and displaying screen projection information projected to the screen projection equipment by each first target screen projection source which is not disconnected by utilizing the target windows with the first window number.
In the embodiment of the present disclosure, displaying, by using the target windows with the number of the first windows, screen projection information projected to the screen projection device by each first target screen projection source that is not disconnected, includes:
displaying screen projection information projected to the screen projection equipment by the first target screen projection source which is not disconnected and has the third connection number by using the target windows with the first window number;
and the third connection number is less than or equal to the first window number, and the first target screen projection sources of the third connection number are determined based on the time sequence of connection establishment between the first target screen projection sources and the screen projection equipment.
In the embodiment of the present disclosure, displaying, by using the target windows with the first window number, screen projection information projected to the screen projection device by the first target screen projection source with the third connection number that is not disconnected includes:
and displaying screen projection information projected to the screen projection equipment by the first target screen projection source which is not disconnected and is different or the same in the third connection number by using the target windows with the first window number.
In an embodiment of the present disclosure, disconnecting at least one first target screen projection source from a screen projection device includes:
disconnecting a first target screen projection source from the screen projection equipment, wherein before disconnection of the first target screen projection source, screen projection information projected to the screen projection equipment by the first target screen projection source is displayed on a target window with a first connection number, and the first connection number is the number of the first target screen projection sources connected with the screen projection equipment before disconnection;
correspondingly, screen projection information projected to the screen projection equipment by each first target screen projection source which is not disconnected is displayed, and the screen projection information comprises the following steps:
and displaying screen projection information projected to the screen projection equipment by each first target screen projection source which is not disconnected through switching display.
In the embodiment of the present disclosure, after disconnecting the connection between the first target screen projection source and the screen projection device, the method further includes:
and closing the at least one target window which is opened last.
In the embodiment of the disclosure, when it is detected that all the target windows are in a disconnected state, the connection between all the first target screen projection sources in a connected state of the screen projection equipment is disconnected.
In the embodiment of the disclosure, the first connection number is greater than or equal to 2, the first window number is greater than or equal to 1, and the first connection number is the number of the first target screen projection sources connected with the screen projection device before disconnection is performed.
According to one or more embodiments of the present disclosure, there is provided another screen projection method, including:
acquiring a first connection opening instruction and a window opening instruction, wherein the first connection opening instruction is used for indicating the screen projection equipment to be connected with a screen projection source, and the window opening instruction is used for indicating the opening of a window on the screen projection equipment;
receiving window display instructions, and displaying screen projection information projected to the screen projection equipment by each first target screen projection source by using each target window;
each target window comprises a window which is displayed in the window and is indicated by the windowing instruction, and each first target screen projection source comprises a screen projection source which is connected with the first windowing instruction.
In the embodiment of the disclosure, a first connection number and a first window number are determined, wherein the first connection number is the number of first target screen projection sources connected with screen projection equipment, and the first window number is the number of target windows opened on the screen projection equipment;
acquiring a second connection opening instruction, wherein the second connection opening instruction is used for indicating the screen projection equipment to be connected with a second target screen projection source;
displaying screen projection information projected to the screen projection equipment by the second target screen projection source according to the first connection number and the first window number;
and the second target screen projection sources are screen projection sources except for the first target screen projection sources.
In the embodiment of the present disclosure, displaying screen projection information projected from a second target screen projection source to a screen projection device according to a first connection number and a first window number includes:
when the first connection number is smaller than a first preset threshold value and the first window number is equal to a second preset threshold value, screen projection information projected to screen projection equipment by a second target screen projection source is displayed in at least one of two target windows displaying screen projection information projected by the same first target screen projection source;
or when the first connection number is equal to a first preset threshold value, displaying screen projection information projected to the screen projection equipment by a second target screen projection source in at least one target window of each target window according to the acquired connection disconnection instruction, wherein the connection disconnection instruction is used for indicating to disconnect at least one first target screen projection source in each first target screen projection source; the first preset threshold value is used for representing the maximum number of screen projection sources which can be connected with the screen projection equipment, and the second preset threshold value is used for representing the maximum number of windows which can be opened on the screen projection equipment.
In the embodiment of the present disclosure, according to the obtained disconnection instruction, in at least one target window of the target windows, displaying screen projection information projected to the screen projection device by a second target screen projection source, where the screen projection information includes:
and according to the acquired disconnection instruction, taking the target window as a display window of a newly connected second target screen projection source, and displaying screen projection information projected to the screen projection equipment by the second target screen projection source through the display window, wherein the disconnection instruction instructs to disconnect the connection between the first target screen projection source and the screen projection equipment, and the screen projection information projected to the screen projection equipment by the first target screen projection source is displayed on the display window. In the embodiment of the present disclosure, according to the obtained disconnection instruction, in at least one target window of the target windows, displaying screen projection information projected by the second target screen projection source to the screen projection device, where the screen projection information includes:
determining at least one target window according to the acquired disconnection instruction and at least one of the target window with a focus in each target window, a prompt of each target window and a preset selection frame;
and displaying screen projection information projected to the screen projection equipment by the second target screen projection source in at least one target window.
According to one or more embodiments of the present disclosure, there is provided a screen projection apparatus including:
the first processing module is used for acquiring a disconnection instruction;
the second processing module is used for disconnecting the connection between the at least one first target screen projection source and the screen projection equipment according to the connection disconnection instruction and determining a second connection number, wherein the second connection number is the number of the first target screen projection sources which are not disconnected;
and the third processing module is used for displaying screen projection information projected to the screen projection equipment by each first target screen projection source which is not disconnected according to the second connection number and the first window number, wherein the first window number is the number of the opened target windows on the screen projection equipment.
In an embodiment of the present disclosure, the third processing module is specifically configured to close the target windows of the second window number when the second connection number is smaller than the first window number, where the second window number is smaller than the first window number; displaying screen projection information projected to the screen projection equipment by each first target screen projection source which is not disconnected by utilizing each target window which is not closed; or when the second connection number is greater than or equal to the first window number, keeping the target window of the first window number in an open state; and displaying screen projection information projected to the screen projection equipment by each first target screen projection source which is not disconnected by utilizing the target windows with the first window number.
In the embodiment of the disclosure, the third processing module is specifically configured to display, by using the target windows of the first window number, screen projection information projected to the screen projection device by the first target screen projection source, which is not disconnected, of the third connection number; and the third connection number is less than or equal to the first window number, and the first target screen projection sources of the third connection number are determined based on the time sequence of connection establishment between the first target screen projection sources and the screen projection equipment.
In an embodiment of the present disclosure, the third processing module is specifically configured to display, by using the target windows with the first number of windows, screen projection information that is projected to the screen projection device by the same or different first target screen projection sources that are not disconnected and have the third number of connections.
In an embodiment of the present disclosure, the second processing module is specifically configured to disconnect a first target screen projection source from the screen projection device, where before the first target screen projection source is disconnected, screen projection information projected by the first target screen projection source to the screen projection device is displayed on a target window with a first connection number, where the first connection number is the number of the first target screen projection sources connected to the screen projection device before disconnection is performed; correspondingly, the third processing module is specifically configured to display, by switching display, screen projection information projected to the screen projection device by each of the first target screen projection sources that are not disconnected.
In the embodiment of the present disclosure, after the second processing module disconnects the connection between the first target screen projection source and the screen projection device, the second processing module is further configured to close at least one target window that is opened last.
In the embodiment of the present disclosure, the second processing module is further configured to disconnect all first target screen projection sources that are in a connected state with the screen projection device when it is detected that all target windows are in a disconnected state.
In the embodiment of the disclosure, the first connection number is greater than or equal to 2, the first window number is greater than or equal to 1, and the first connection number is the number of the first target screen projection sources connected with the screen projection device before disconnection is performed.
According to one or more embodiments of the present disclosure, there is provided another screen projection apparatus including:
the fourth processing module is used for acquiring a first connection opening instruction and a windowing instruction, the first connection opening instruction is used for indicating the screen projection equipment to be connected with the screen projection source, and the windowing instruction is used for indicating the opening of a window on the screen projection equipment;
the fifth processing module is used for receiving the window display instruction and displaying screen projection information projected to the screen projection equipment by each first target screen projection source by using each target window; each target window comprises a window which is displayed in the window and is indicated by the windowing instruction, and each first target screen projection source comprises a screen projection source which is connected with the first windowing instruction.
In this embodiment of the disclosure, the fifth processing module is further configured to determine a first connection number and a first window number, where the first connection number is the number of first target screen projection sources connected to the screen projection device, and the first window number is the number of target windows already opened on the screen projection device; acquiring a second connection opening instruction, wherein the second connection opening instruction is used for indicating the screen projection equipment to be connected with a second target screen projection source; displaying screen projection information projected to the screen projection equipment by the second target screen projection source according to the first connection number and the first window number; and the second target screen projection sources are screen projection sources except for the first target screen projection sources.
In an embodiment of the disclosure, the fifth processing module is specifically configured to, when the first connection number is smaller than a first preset threshold and the number of first windows is equal to a second preset threshold, display screen projection information projected by a second target screen projection source to the screen projection device in at least one of two target windows displaying screen projection information projected by the same first target screen projection source; or when the first connection number is equal to the first preset threshold value, displaying screen projection information projected to the screen projection equipment by the second target screen projection source in at least one target window in each target window, wherein the disconnection instruction is used for indicating to disconnect at least one first target screen projection source in each first target screen projection source; the first preset threshold value is used for representing the maximum number of screen projection sources which can be connected with the screen projection equipment, and the second preset threshold value is used for representing the maximum number of windows which can be opened on the screen projection equipment.
And the fifth processing module is specifically configured to, according to the acquired disconnection instruction, use the target window as a display window of a newly connected second target screen projection source, and display screen projection information projected to the screen projection device by the second target screen projection source through the display window, where the disconnection instruction indicates disconnection of connection between the first target screen projection source and the screen projection device, and the screen projection information projected to the screen projection device by the first target screen projection source is displayed on the display window.
The fifth processing module is specifically used for determining at least one target window according to the acquired disconnection instruction and at least one of the target windows with focuses in each target window, prompts of each target window and a preset selection frame;
and displaying screen projection information projected to the screen projection equipment by the second target screen projection source in at least one target window.
The foregoing description is only exemplary of the preferred embodiments of the disclosure and is illustrative of the principles of the technology employed. It will be appreciated by those skilled in the art that the scope of the disclosure herein is not limited to the particular combination of features described above, but also encompasses other embodiments in which any combination of the features described above or their equivalents does not depart from the spirit of the disclosure. For example, the above features and (but not limited to) the features disclosed in this disclosure having similar functions are replaced with each other to form the technical solution.
Further, while operations are depicted in a particular order, this should not be understood as requiring that such operations be performed in the particular order shown or in sequential order. Under certain circumstances, multitasking and parallel processing may be advantageous. Likewise, while several specific implementation details are included in the above discussion, these should not be construed as limitations on the scope of the disclosure. Certain features that are described in the context of separate embodiments can also be implemented in combination in a single embodiment. Conversely, various features that are described in the context of a single embodiment can also be implemented in multiple embodiments separately or in any suitable subcombination.
Although the subject matter has been described in language specific to structural features and/or methodological acts, it is to be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or acts described above. Rather, the specific features and acts described above are disclosed as example forms of implementing the claims.