Disclosure of Invention
The embodiment of the disclosure at least provides a display content playing method and device, which are used for realizing automatic playing of different display contents in a page.
In a first aspect, an embodiment of the present disclosure provides a display content playing method, including:
in response to the end of the trigger operation, acquiring at least one piece of display content appearing in a preset detection area in a screen;
selecting target display content from the at least one piece of display content based on the area occupied by each display content in the preset detection area and the page occupied area in the screen;
and playing the target display content.
In an optional embodiment, the playing the target presentation content includes:
determining attribute information of the target display content;
determining the playing times based on the attribute information of the target display content;
and playing the target display content according to the playing times.
In an optional implementation manner, the determining the number of plays based on the attribute information of the target presentation content includes:
acquiring the playing time length of the target display content, and determining the playing times according to the playing time length; and/or the presence of a gas in the gas,
and acquiring the category characteristics of the target display content, and determining the playing times according to the category characteristics.
In an optional implementation manner, the determining the number of times of playing according to the playing duration includes:
if the playing time length is less than a set time length threshold value, determining that the playing times is 1;
and if the playing time length is greater than or equal to a set time length threshold value, determining that the repeated playing times are N, wherein N is an integer greater than or equal to 2.
In an optional implementation manner, the selecting, based on an area occupied by each piece of presentation content in the preset detection area and a page area occupied by the piece of presentation content, a target presentation content that meets an automatic playing condition from the at least one piece of presentation content includes:
for each piece of display content, determining a first ratio between the area occupied by the region corresponding to the piece of display content and the page area occupied by the region;
selecting at least one candidate display content with the corresponding first ratio larger than a set threshold value from the at least one display content;
and selecting the corresponding candidate display content with the largest area occupied by the region from the at least one candidate display content as the target display content.
In an optional implementation manner, the selecting, from the at least one candidate presentation content, a corresponding candidate presentation content with the largest area occupied by the region as the target presentation content includes:
if the determined candidate display contents with the largest area occupied by the region are multiple, determining the operation direction of the trigger operation;
and according to the determined operation direction, selecting candidate display contents matched with the operation direction from a plurality of candidate display contents with the maximum area occupied by the determined region as the target display contents.
In an optional implementation manner, the selecting, according to the determined operation direction, a candidate display content that matches the operation direction from among multiple candidate display contents that are determined to have the largest area occupied by the area as the target display content includes:
if the operation direction is an upward operation, selecting candidate display content closest to the lower edge of the screen from the plurality of candidate display contents with the largest area occupied by the determined region as the target display content;
and if the operation direction is downward operation, selecting the candidate display content closest to the upper edge of the screen from the plurality of candidate display contents with the maximum area occupied by the determined area as the target display content.
In an optional embodiment, the method further comprises:
responding to the selected operation aiming at any display content in the current page in the screen, jumping to the detail display page of any display content, and playing any display content;
responding to an exit instruction aiming at the detail display page, returning to the current page, and recording the playing progress of any display content on the detail display page;
and on the basis of the area occupied by the any display content in the preset detection area of the current page and the page area occupied by the any display content, under the condition that the any display content meets the automatic playing condition, continuing playing the any display content according to the recorded playing progress.
In an optional embodiment, the acquiring, in response to the end of the trigger operation, at least one piece of presentation content appearing in a preset detection area in the screen includes:
and responding to the end of the trigger operation, and acquiring at least one piece of display content which stays in a preset detection area in the screen for a preset time after the trigger operation is ended.
In a second aspect, an embodiment of the present disclosure further provides a playing device for displaying content, including:
the acquisition module is used for responding to the end of the trigger operation and acquiring at least one piece of display content appearing in a preset detection area in the screen;
a selection module, configured to select a target display content from the at least one piece of display content based on an area occupied by each display content in the preset detection area and a page occupied area in the screen;
and the playing module is used for playing the target display content.
In an optional implementation manner, the playing module, when playing the target presentation, is configured to:
determining attribute information of the target display content;
determining the playing times based on the attribute information of the target display content;
and playing the target display content according to the playing times.
In an optional implementation manner, when determining the number of plays based on the attribute information of the target presentation content, the play module is configured to:
acquiring the playing time length of the target display content, and determining the playing times according to the playing time length; and/or the presence of a gas in the gas,
and acquiring the category characteristics of the target display content, and determining the playing times according to the category characteristics.
In an optional implementation manner, the playing module, when determining the playing times according to the playing duration, is configured to:
if the playing time length is less than a set time length threshold value, determining that the playing times is 1;
and if the playing time length is greater than or equal to a set time length threshold value, determining that the repeated playing times are N, wherein N is an integer greater than or equal to 2.
In an optional embodiment, the selection module, when selecting a target presentation content from the at least one presentation content based on an area occupied by each of the presentation contents in the preset detection area and a page occupied area in the screen, is configured to:
for each piece of display content, determining a first ratio between the area occupied by the region corresponding to the piece of display content and the page area occupied by the region;
selecting at least one candidate display content with the corresponding first ratio larger than a set threshold value from the at least one display content;
and selecting the corresponding candidate display content with the largest area occupied by the region from the at least one candidate display content as the target display content.
In an optional embodiment, when selecting, from the at least one candidate presentation content, a corresponding candidate presentation content with a largest area occupied by the region as the target presentation content, the selecting module is configured to:
if the determined candidate display contents with the largest area occupied by the region are multiple, determining the operation direction of the trigger operation;
and according to the determined operation direction, selecting candidate display contents matched with the operation direction from a plurality of candidate display contents with the maximum area occupied by the determined region as the target display contents.
In an optional implementation manner, when, according to the determined operation direction, selecting, from the multiple candidate display contents with the largest area occupied by the determined region, a candidate display content matching with the operation direction as the target display content, the selecting module is configured to:
if the operation direction is an upward operation, selecting candidate display content closest to the lower edge of the screen from the plurality of candidate display contents with the largest area occupied by the determined region as the target display content;
and if the operation direction is downward operation, selecting the candidate display content closest to the upper edge of the screen from the plurality of candidate display contents with the maximum area occupied by the determined area as the target display content.
In an optional implementation manner, the playing module is further configured to:
responding to the selected operation aiming at any display content in the current page in the screen, jumping to the detail display page of any display content, and playing any display content;
responding to an exit instruction aiming at the detail display page, returning to the current page, and recording the playing progress of any display content on the detail display page;
and on the basis of the area occupied by the any display content in the preset detection area of the current page and the page area occupied by the any display content, under the condition that the any display content meets the automatic playing condition, continuing playing the any display content according to the recorded playing progress.
In an optional embodiment, the acquiring, in response to the end of the trigger operation, at least one piece of presentation content appearing in a preset detection area in the screen includes:
and responding to the end of the trigger operation, and acquiring at least one piece of display content which stays in a preset detection area in the screen for a preset time after the trigger operation is ended.
In a third aspect, an embodiment of the present disclosure further provides a computer device, including: a processor, a memory and a bus, the memory storing machine-readable instructions executable by the processor, the processor and the memory communicating via the bus when the computer device is running, the machine-readable instructions when executed by the processor performing the steps of the first aspect described above, or any possible implementation of the first aspect.
In a fourth aspect, this disclosed embodiment also provides a computer-readable storage medium, on which a computer program is stored, where the computer program is executed by a processor to perform the steps in the first aspect or any one of the possible implementation manners of the first aspect.
For the description of the effects of the playback apparatus, the electronic device, and the computer-readable storage medium of the above-mentioned exhibition content, reference is made to the description of the playback method of the above-mentioned exhibition content, which is not repeated herein.
According to the method, the target display content meeting the automatic playing condition can be automatically played based on the area occupied by each piece of display content in the preset detection area and the page area occupied by the piece of display content, in the process, a user does not need to continuously interact with equipment, for example, each piece of display content is continuously triggered, playing of different display contents is achieved, interactive operation of playing control is saved, automatic and reasonable playing of the display contents is achieved, and playing efficiency is improved.
In order to make the aforementioned objects, features and advantages of the present disclosure more comprehensible, preferred embodiments accompanied with figures are described in detail below.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present disclosure more clear, the technical solutions of the embodiments of the present disclosure will be described clearly and completely with reference to the drawings in the embodiments of the present disclosure, and it is obvious that the described embodiments are only a part of the embodiments of the present disclosure, not all of the embodiments. The components of the embodiments of the present disclosure, generally described and illustrated in the figures herein, can be arranged and designed in a wide variety of different configurations. Thus, the following detailed description of the embodiments of the present disclosure, presented in the figures, is not intended to limit the scope of the claimed disclosure, but is merely representative of selected embodiments of the disclosure. All other embodiments, which can be derived by a person skilled in the art from the embodiments of the disclosure without making creative efforts, shall fall within the protection scope of the disclosure.
First, an application scenario to which the present disclosure is applicable will be described. The method and the device are suitable for scenes in which a plurality of pieces of display content are displayed on a screen at the same time and the display content needs to be played. In the related art, if there are a plurality of display contents in the screen, the user and the device need to perform continuous interaction operation to realize the playing of each display content, and in this process, the playing efficiency is low because there are many interaction processes between the user and the device playing the display contents.
According to the method provided by the disclosure, the target display content meeting the automatic playing condition can be automatically played based on the area occupied by each piece of display content in the preset detection area and the page area occupied by the piece of display content, in the process, a user does not need to continuously interact with equipment, for example, each piece of display content is continuously triggered, the playing of different pieces of display content is realized, the interactive operation of playing control is saved, the automatic reasonable playing of the display content is realized, and the playing efficiency is improved.
The technical solutions in the present disclosure will be described clearly and completely with reference to the accompanying drawings in the present disclosure, and it is to be understood that the described embodiments are only a part of the embodiments of the present disclosure, and not all of the embodiments. The components of the present disclosure, as generally described and illustrated in the figures herein, may be arranged and designed in a wide variety of different configurations. Thus, the following detailed description of the embodiments of the present disclosure, presented in the figures, is not intended to limit the scope of the claimed disclosure, but is merely representative of selected embodiments of the disclosure. All other embodiments, which can be derived by a person skilled in the art from the embodiments of the disclosure without making creative efforts, shall fall within the protection scope of the disclosure.
It should be noted that: like reference numbers and letters refer to like items in the following figures, and thus, once an item is defined in one figure, it need not be further defined and explained in subsequent figures.
In order to facilitate understanding of the present embodiment, a detailed description will be given of a playing method of display content disclosed in the embodiments of the present disclosure, an execution main body of the playing method of display content provided in the embodiments of the present disclosure is generally a computer device with certain computing capability, and a touch screen is configured on the computer device, for example, the electronic device may be a mobile phone, a tablet computer, a touch screen smart television, and the like, which is not limited in the present application.
Referring to fig. 1, a flowchart of a display content playing method provided in an embodiment of the present disclosure is shown, where the method includes the following steps:
step 101, in response to the end of the trigger operation, acquiring at least one piece of display content appearing in a preset detection area in a screen.
102, selecting target display content from the at least one piece of display content based on the area occupied by each display content in the preset detection area and the page occupied area in the screen.
And 103, playing the target display content.
According to the method, the target display content meeting the automatic playing condition can be automatically played based on the area occupied by each piece of display content in the preset detection area and the page area occupied by the piece of display content, in the process, a user does not need to continuously interact with equipment, for example, each piece of display content is continuously triggered, playing of different display contents is achieved, interactive operation of playing control is saved, automatic and reasonable playing of the display contents is achieved, and playing efficiency is improved.
The following is a detailed description of the above steps 101 to 103.
For step 101:
the size of the preset detection area can be adjusted according to different screen sizes. In one possible implementation, the length N of the screen may be obtained first, and then X of the screen length may be obtained1% to X2The area between% is determined as the preset detection area.
Specifically, referring to fig. 2, the edge on the screen is determined to be X1First reference line of% N and X from the upper edge of the screen2And% N of the second reference line, and then determining a region between the first reference line and the second reference line as a preset detection region.
In another possible embodiment, the preset detection area may be the whole screen, and in this case, X1Is 0, X2The size of the specific preset detection area is 100, which may be adjusted according to the size of the displayed content, and the present application is not limited thereto.
It should be noted that the type of the display content appearing in the screen includes at least one of video, audio, text, and picture, the display content appearing in the screen may be obtained from the server when the user terminal starts up, and in the process of detecting the trigger operation in the screen, the display content may be obtained and updated from the server in real time based on the trigger operation.
The trigger operation may be a trigger operation acting on the screen, such as a sliding operation acting on the screen, or a double-click operation acting in the screen; the trigger operation may also be a voice instruction input by the user, and the application is not limited to other operation methods that can control the display content change in the screen.
In a possible implementation manner, after the trigger operation is finished, the change of the display content in the screen may not stop, and in order to save the playing resources, it may not be determined whether such display content meets the automatic playing condition, so that, in response to the end of the trigger operation acting on the screen, at least one piece of display content appearing in a preset detection area in the screen is obtained, or at least one piece of display content staying in the preset detection area in the screen for a preset duration is obtained after the self-trigger operation is finished.
With respect to step 102:
the area occupied by each piece of display content in the preset detection area refers to the area of the piece of display content in the preset detection area, and the page area occupied by the piece of display content refers to the area occupied by the piece of display content in a page. And for each piece of display content, the area occupied by the region corresponding to the display content is smaller than or equal to the page area occupied by the display content.
When target display content meeting the automatic playing condition is selected from at least one piece of display content based on the area occupied by each piece of display content in the preset detection area and the page area occupied by the piece of display content, the target display content determining method shown in fig. 3 may be referred to, and includes the following steps:
step 301, for each piece of display content, determining a first ratio between the area occupied by the region corresponding to the piece of display content and the page area occupied by the region.
Step 302, selecting at least one candidate display content from the at least one display content, wherein the corresponding first ratio is greater than a set threshold.
Step 303, selecting a corresponding candidate display content with the largest area occupied by the region from the at least one candidate display content as the target display content.
In another possible implementation manner, when the target display content is selected from the at least one candidate display content, a second ratio between an area occupied by the region corresponding to the at least one candidate display content and an area of a preset detection region may be calculated first, and the candidate display content with the largest second ratio to the preset detection area is taken as the target display content.
In a possible scenario, if a plurality of candidate display contents with the largest area of the corresponding region are selected from at least one candidate display content, the candidate display content matched with the operation direction may be selected as the target display content based on the operation direction of the trigger operation of the user.
Specifically, if the trigger operation of the user is a sliding operation acting on the screen, when the operation direction of the trigger operation of the user is determined, the start touch screen point and the end touch screen point of the trigger operation may be determined first, and then the operation direction of the trigger operation may be determined based on the position relationship between the start touch screen point and the end touch screen point.
If the trigger operation of the user is a double-click operation acting on the screen, the position point where the user clicks on the screen for the first time and the position point where the user clicks on the screen for the second time may be determined, and then the sliding distance and the sliding direction of the page (i.e., the operation direction of the trigger operation) may be determined based on the distance between the two position points.
If the triggering operation of the user is a voice operation, after receiving the voice input by the user, performing voice recognition processing on the voice, converting the voice into voice characters, recognizing keyword information in the voice characters, and determining an operation direction of the triggering operation based on the keyword information.
For example, if the voice input by the user is "turn up", after the voice text is converted into the voice text, the keyword information in the voice text may be extracted as "up", and it may be correspondingly determined that the operation direction of the trigger operation is an up operation.
If the operation direction is upward operation, determining that the display content required to be watched by the user is positioned below the current display content, and selecting the candidate display content closest to the lower edge of the screen as the target display content from the plurality of candidate display contents with the largest area occupied by the determined area;
if the operation direction is a downward operation, and it is determined that the display content that the user needs to view is located above the current display content, the candidate display content closest to the upper edge of the screen may be selected as the target display content from the plurality of candidate display contents with the largest area occupied by the determined area.
The operation direction can represent the position relation between the display content which the user wants to watch and the currently displayed display content, and the screened target display area can meet the watching requirement of the user from the multiple candidate display contents with the largest area occupied by the determined area based on the operation direction.
In the case that there are a plurality of candidate display contents with the largest second ratio to the preset detection area, the candidate display contents matched with the operation direction may also be selected as the target display contents based on the operation direction, and the specific determination method is the same as the method for determining the target display contents when the corresponding candidate display contents with the largest area are selected from the at least one candidate display contents, and will not be described herein again.
For step 103:
in step 103, the target display content selected by playing may select different display methods according to different types of the target display content. For example, if the target display content is video content, the video content may be played; if the target display content is a dynamic picture, the animation effect of the dynamic picture can be displayed; and if the target display content is a character, playing voice matched with the character, and the like.
In a possible implementation manner, the playing the selected target display content in step 103 may specifically be performed by determining attribute information of the target display content, then determining a playing time corresponding to the attribute information based on the attribute information of the target attribute, and playing the target display content according to the determined playing time.
When determining the playing times corresponding to the attribute information based on the attribute information, the playing time of the target display content may be obtained first, and then the playing times may be determined according to the playing time. Specifically, if the playing time length is less than the set time length threshold, determining that the repeated playing time is 0; and if the playing time length is greater than or equal to the set time length threshold value, determining that the repeated playing times are N, wherein N is a positive integer greater than or equal to 2.
Considering that if the playing time of the target display content is too long, the user may not be able to know the target display content through one-time watching, so that the target display content may be repeatedly played, but considering that too many repeated plays may cause waste of playing resources, so that the number of repeated plays may be determined as N; for the target display content with the playing time length smaller than the set time length threshold, the user can possibly realize the understanding of the target display content through one-time playing, so that the target display content can be played without repeating.
In a possible implementation manner, the determining attribute information of the target presentation content, and based on the attribute information of the target presentation content, playing the target presentation content may further include: and determining the playing times according to the category characteristics based on the category characteristics of the target display content, and then playing the target display content according to the playing times.
The category characteristics of the target display content may be, for example, education, entertainment, and news, and the display content with the same playing time duration may have a larger content information amount for the display content with the category characteristics being education, and the playing times for the display content may be increased to enable the user to completely know the content information in the display content.
When the playing times are determined according to the categories, different playing times can be set for the display contents of each category in advance, and after the category characteristics of the target display contents are determined, the playing times of the target display contents can be determined according to the preset playing times corresponding to the category characteristics.
In another possible implementation manner, the category feature of the target display content and the playing time length of the target display content may be determined at the same time, then the playing frequency is determined based on the category feature and the playing time length, and the target display content is played according to the playing frequency.
For the same category of the display contents, the amount of information contained in the display contents may also be different due to different playing time lengths. For the display contents of the same category, if the playing time is long, for the user, multiple times of playing may be required to completely acquire the information in the display contents. Therefore, the playing times are determined by combining the category characteristics and the playing duration, and the playing requirements of the user on different categories of displayed contents are met.
In practical application, the setting of the duration threshold and the number of repetitions may be adjusted according to practical situations, which is not limited in the present application.
In the above embodiment, the repeated playing times can be determined according to the playing time, and personalized playing of the displayed contents with different playing time and different categories can be realized.
In one possible implementation, the method provided by the present disclosure may further respond to a selection operation for any display content in the current page in the screen (where the trigger operation includes, but is not limited to, single click, double click, long press, etc.), and jump to any detailed display page of any display content to play any display content; after receiving an exit instruction for the detail display interface, responding to the exit instruction for the detail display page, returning to the current interface, and recording the playing progress of any display content on the detail display page; and determining whether any display content meets an automatic playing condition or not based on the area occupied by any display content in a preset detection area of the current page and the page area occupied by any display content, and continuously playing any display content according to the recorded playing progress under the condition that any display content meets the automatic playing condition.
The detail display page of any display content may be used to play the display content in full screen, or may display a source of the display content and/or a sharing entry of the display content while playing the display content.
It should be noted that the operation of selecting any display content in the current page in the screen may act on the target display content or may act on the non-target display content, and if the operation of selecting is acting on the target display content and the target display content is playing on the current page, when the operation of selecting the target display content in the current page is responded, the playing progress of the target display content on the current page may be recorded first, and after jumping to the detail display page of the target display content, the target display content is played on the detail display page according to the recorded playing progress.
In another possible implementation, before the selected operation acting on the screen is detected, the current page may be presented and the presentation content closest to the upper edge of the screen in the current page may be played in response to a trigger operation of opening the presentation content page (i.e., the application is opened for the first time).
In the above embodiment, the display content closest to the upper edge of the screen and the display content closest to the lower edge of the screen are not obtained by first determining the distance between each display content and the upper edge or the lower edge of the screen, and then selecting the display content closest to the upper edge or the lower edge of the screen according to the determined distance.
It will be understood by those skilled in the art that in the method of the present invention, the order of writing the steps does not imply a strict order of execution and any limitations on the implementation, and the specific order of execution of the steps should be determined by their function and possible inherent logic.
Based on the same inventive concept, a playing apparatus of the display content corresponding to the playing method of the display content is also provided in the embodiments of the present disclosure, and since the principle of the apparatus in the embodiments of the present disclosure for solving the problem is similar to the playing method of the display content described above in the embodiments of the present disclosure, the implementation of the apparatus may refer to the implementation of the method, and repeated details are not described again.
Referring to fig. 4, a schematic diagram of an architecture of a playing apparatus for displaying content provided in the embodiment of the present disclosure includes an obtaining module 401, a selecting module 402, and a playing module 403, specifically:
an obtaining module 401, configured to obtain, in response to an end of the trigger operation, at least one piece of display content appearing in a preset detection area in the screen;
a selecting module 402, configured to select a target display content from the at least one piece of display content based on an area occupied by each display content in the preset detection area and a page occupied area in the screen;
a playing module 403, configured to play the target display content.
In an optional implementation manner, the playing module 403, when playing the target presentation, is configured to:
determining attribute information of the target display content;
determining the playing times based on the attribute information of the target display content;
and playing the target display content according to the playing times.
In an optional implementation manner, the playing back module 403, when determining the number of playing back based on the attribute information of the target presentation content, is configured to:
acquiring the playing time length of the target display content, and determining the playing times according to the playing time length; and/or the presence of a gas in the gas,
and acquiring the category characteristics of the target display content, and determining the playing times according to the category characteristics.
In an optional implementation manner, when determining the number of playing times according to the playing duration, the playing module 403 is configured to:
if the playing time length is less than a set time length threshold value, determining that the playing times is 1;
and if the playing time length is greater than or equal to a set time length threshold value, determining that the repeated playing times are N, wherein N is an integer greater than or equal to 2.
In an alternative embodiment, the selecting module 402, when selecting the target presentation content from the at least one presentation content based on a region occupied area of each presentation content in the preset detection region and a page occupied area in the screen, is configured to:
for each piece of display content, determining a first ratio between the area occupied by the region corresponding to the piece of display content and the page area occupied by the region;
selecting at least one candidate display content with the corresponding first ratio larger than a set threshold value from the at least one display content;
and selecting the corresponding candidate display content with the largest area occupied by the region from the at least one candidate display content as the target display content.
In an optional implementation manner, when selecting, from the at least one candidate presentation content, a corresponding candidate presentation content with the largest area occupied by the region as the target presentation content, the selecting module 402 is configured to:
if the determined candidate display contents with the largest area occupied by the region are multiple, determining the operation direction of the trigger operation;
and according to the determined operation direction, selecting candidate display contents matched with the operation direction from a plurality of candidate display contents with the maximum area occupied by the determined region as the target display contents.
In an optional implementation manner, when, according to the determined operation direction, selecting, from the multiple candidate display contents with the largest area occupied by the determined region, a candidate display content matching with the operation direction as the target display content, the selecting module 402 is configured to:
if the operation direction is an upward operation, selecting candidate display content closest to the lower edge of the screen from the plurality of candidate display contents with the largest area occupied by the determined region as the target display content;
and if the operation direction is downward operation, selecting the candidate display content closest to the upper edge of the screen from the plurality of candidate display contents with the maximum area occupied by the determined area as the target display content.
In an optional implementation manner, the playing module 403 is further configured to:
responding to the selected operation aiming at any display content in the current page in the screen, jumping to the detail display page of any display content, and playing any display content;
responding to an exit instruction aiming at the detail display page, returning to the current page, and recording the playing progress of any display content on the detail display page;
and on the basis of the area occupied by the any display content in the preset detection area of the current page and the page area occupied by the any display content, under the condition that the any display content meets the automatic playing condition, continuing playing the any display content according to the recorded playing progress.
In an alternative embodiment, the obtaining module 401, when, in response to the end of the trigger operation, obtaining at least one piece of presentation content appearing in a preset detection area in the screen, is configured to:
and responding to the end of the trigger operation, and acquiring at least one piece of display content which stays in a preset detection area in the screen for a preset time after the trigger operation is ended.
The description of the processing flow of each module in the device and the interaction flow between the modules may refer to the related description in the above method embodiments, and will not be described in detail here.
Based on the same technical concept, the embodiment of the application also provides the electronic equipment. Referring to fig. 5, a schematic structural diagram of an electronic device 500 provided in the embodiment of the present application includes a processor 501, a memory 502, and a bus 503. The memory 502 is used for storing execution instructions and includes a memory 5021 and an external memory 5022; the memory 5021 is also referred to as an internal memory, and is used for temporarily storing operation data in the processor 501 and data exchanged with an external storage 5022 such as a hard disk, the processor 501 exchanges data with the external storage 5022 through the memory 5021, and when the electronic device 500 operates, the processor 501 communicates with the storage 502 through the bus 503, so that the processor 501 executes the following instructions:
in response to the end of the trigger operation, acquiring at least one piece of display content appearing in a preset detection area in a screen;
selecting target display content from the at least one piece of display content based on the area occupied by each display content in the preset detection area and the page occupied area in the screen;
and playing the target display content.
In one possible design, the playing the target presentation content in the instructions executed by the processor 501 includes:
determining attribute information of the target display content;
determining the playing times based on the attribute information of the target display content;
and playing the target display content according to the playing times.
In one possible design, in the instructions executed by the processor 501, the determining the number of playing times based on the attribute information of the target presentation content includes:
acquiring the playing time length of the target display content, and determining the playing times according to the playing time length; and/or the presence of a gas in the gas,
and acquiring the category characteristics of the target display content, and determining the playing times according to the category characteristics.
In one possible design, in the instructions executed by processor 501, the determining the number of playing times according to the playing time length includes:
if the playing time length is less than a set time length threshold value, determining that the playing times is 1;
and if the playing time length is greater than or equal to a set time length threshold value, determining that the repeated playing times are N, wherein N is an integer greater than or equal to 2.
In one possible design, in instructions executed by the processor 501, the selecting, from the at least one piece of display content, a target display content meeting an automatic playing condition based on an area occupied by each piece of display content in the preset detection area and a page area occupied by the piece of display content, includes:
for each piece of display content, determining a first ratio between the area occupied by the region corresponding to the piece of display content and the page area occupied by the region;
selecting at least one candidate display content with the corresponding first ratio larger than a set threshold value from the at least one display content;
and selecting the corresponding candidate display content with the largest area occupied by the region from the at least one candidate display content as the target display content.
In one possible design, in instructions executed by processor 501, the selecting, from the at least one candidate presentation content, a corresponding candidate presentation content with a largest area occupied by the area as the target presentation content includes:
if the determined candidate display contents with the largest area occupied by the region are multiple, determining the operation direction of the trigger operation;
and according to the determined operation direction, selecting candidate display contents matched with the operation direction from a plurality of candidate display contents with the maximum area occupied by the determined region as the target display contents.
In one possible design, in executing instructions by processor 501, the selecting, according to a determined operation direction, a candidate presentation content that matches the operation direction from among multiple candidate presentation contents that are determined to have the largest area occupied by the area as the target presentation content includes:
if the operation direction is an upward operation, selecting candidate display content closest to the lower edge of the screen from the plurality of candidate display contents with the largest area occupied by the determined region as the target display content;
and if the operation direction is downward operation, selecting the candidate display content closest to the upper edge of the screen from the plurality of candidate display contents with the maximum area occupied by the determined area as the target display content.
In one possible design, the instructions executed by the processor 501 further include:
responding to the selected operation aiming at any display content in the current page in the screen, jumping to the detail display page of any display content, and playing any display content;
responding to an exit instruction aiming at the detail display page, returning to the current page, and recording the playing progress of any display content on the detail display page;
and on the basis of the area occupied by the any display content in the preset detection area of the current page and the page area occupied by the any display content, under the condition that the any display content meets the automatic playing condition, continuing playing the any display content according to the recorded playing progress.
In one possible design, the instructions executed by the processor 501, which are used for acquiring at least one piece of presentation content appearing in a preset detection area in the screen in response to the end of the trigger operation, include:
and responding to the end of the trigger operation, and acquiring at least one piece of display content which stays in a preset detection area in the screen for a preset time after the trigger operation is ended.
The embodiment of the present disclosure further provides a computer-readable storage medium, where a computer program is stored on the computer-readable storage medium, and when the computer program is executed by a processor, the steps of the method for playing the display content described in the above method embodiment are executed. The storage medium may be a volatile or non-volatile computer-readable storage medium.
The computer program product of the method for playing back the display content provided in the embodiments of the present disclosure includes a computer-readable storage medium storing a program code, where instructions included in the program code may be used to execute steps of the method for playing back the display content described in the above method embodiments, which may be referred to in the above method embodiments specifically, and are not described herein again.
The embodiments of the present disclosure also provide a computer program, which when executed by a processor implements any one of the methods of the foregoing embodiments. The computer program product may be embodied in hardware, software or a combination thereof. In an alternative embodiment, the computer program product is embodied in a computer storage medium, and in another alternative embodiment, the computer program product is embodied in a Software product, such as a Software Development Kit (SDK), or the like.
It is clear to those skilled in the art that, for convenience and brevity of description, the specific working processes of the system and the apparatus described above may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again. In the several embodiments provided in the present disclosure, it should be understood that the disclosed system, apparatus, and method may be implemented in other ways. The above-described embodiments of the apparatus are merely illustrative, and for example, the division of the units is only one logical division, and there may be other divisions when actually implemented, and for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection of devices or units through some communication interfaces, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present disclosure may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit.
The functions, if implemented in the form of software functional units and sold or used as a stand-alone product, may be stored in a non-volatile computer-readable storage medium executable by a processor. Based on such understanding, the technical solution of the present disclosure may be embodied in the form of a software product, which is stored in a storage medium and includes several instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present disclosure. And the aforementioned storage medium includes: various media capable of storing program codes, such as a usb disk, a removable hard disk, a Read-only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk.
Finally, it should be noted that: the above-mentioned embodiments are merely specific embodiments of the present disclosure, which are used for illustrating the technical solutions of the present disclosure and not for limiting the same, and the scope of the present disclosure is not limited thereto, and although the present disclosure is described in detail with reference to the foregoing embodiments, those skilled in the art should understand that: any person skilled in the art can modify or easily conceive of the technical solutions described in the foregoing embodiments or equivalent technical features thereof within the technical scope of the present disclosure; such modifications, changes or substitutions do not depart from the spirit and scope of the embodiments of the present disclosure, and should be construed as being included therein. Therefore, the protection scope of the present disclosure shall be subject to the protection scope of the claims.