CN116975485A - Lazy loading method, lazy loading device, lazy loading storage medium and lazy loading equipment for page blocks - Google Patents

Lazy loading method, lazy loading device, lazy loading storage medium and lazy loading equipment for page blocks Download PDF

Info

Publication number
CN116975485A
CN116975485A CN202310982912.2A CN202310982912A CN116975485A CN 116975485 A CN116975485 A CN 116975485A CN 202310982912 A CN202310982912 A CN 202310982912A CN 116975485 A CN116975485 A CN 116975485A
Authority
CN
China
Prior art keywords
rendered
display area
display
component
determining
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202310982912.2A
Other languages
Chinese (zh)
Inventor
张璠璠
王永恒
傅四维
巫英才
王亚鸽
李爽
杨博
施明君
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhejiang Lab
Original Assignee
Zhejiang Lab
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Zhejiang Lab filed Critical Zhejiang Lab
Priority to CN202310982912.2A priority Critical patent/CN116975485A/en
Publication of CN116975485A publication Critical patent/CN116975485A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/957Browsing optimisation, e.g. caching or content distillation
    • G06F16/9574Browsing optimisation, e.g. caching or content distillation of access to content, e.g. by caching
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0481Interaction techniques based on graphical user interfaces [GUI] based on specific properties of the displayed interaction object or a metaphor-based environment, e.g. interaction with desktop elements like windows or icons, or assisted by a cursor's changing behaviour or appearance
    • G06F3/04817Interaction techniques based on graphical user interfaces [GUI] based on specific properties of the displayed interaction object or a metaphor-based environment, e.g. interaction with desktop elements like windows or icons, or assisted by a cursor's changing behaviour or appearance using icons
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0484Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range
    • G06F3/0485Scrolling or panning
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/451Execution arrangements for user interfaces

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Human Computer Interaction (AREA)
  • Software Systems (AREA)
  • Databases & Information Systems (AREA)
  • Data Mining & Analysis (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

The application discloses a lazy loading method, a lazy loading device, a lazy loading storage medium and lazy loading equipment for a page block. And after receiving the horizontal scrolling operation of the block by the user, re-determining the display area, determining the display assembly according to the re-determined display area, rendering the re-determined display assembly, and displaying. Under the condition that the page block contains more data, only the components in the display area are rendered and displayed, the required time is short, and the rendering efficiency is improved.

Description

Lazy loading method, lazy loading device, lazy loading storage medium and lazy loading equipment for page blocks
Technical Field
The present disclosure relates to the field of computer technologies, and in particular, to a method, an apparatus, a storage medium, and a device for lazy loading of page blocks.
Background
With the development of computer technology and the deep integration of services, browsing pages to obtain information has become one of the important ways to obtain information.
At present, when information is displayed to a user, the display unit can generally acquire data to be rendered, render each element contained in the data to be rendered, and display a rendering result in a page.
However, when more elements are included in the data to be rendered, it takes a long time to render all the elements in the data to be rendered, which results in a long time for the display unit to display the rendering result to the user from receiving the data to be rendered, and lower rendering efficiency.
Based on the above, the application provides a lazy loading method of page blocks.
Disclosure of Invention
The present disclosure provides a method and apparatus for lazy loading of page blocks, a readable storage medium, and an electronic device, so as to partially solve the foregoing problems in the prior art.
The technical scheme adopted in the specification is as follows:
the present specification provides a lazy loading method for page blocks, comprising:
determining a block to be rendered and a display area in the block to be rendered, wherein the block to be rendered is a designated area in a page;
determining all components contained in the block to be rendered, and determining the components contained in the display area from all the components to serve as all display components;
rendering the data to be rendered corresponding to each display component respectively, and displaying the rendering result to a user in the display area;
and responding to the horizontal scrolling operation of the user on the display area, redefining each display component according to the redetermined display area, and displaying the rendering results of the data to be rendered, which correspond to each redetermined display component, in the redetermined display area.
Optionally, determining, from the components, the component contained in the display area as each display component specifically includes:
determining a first width corresponding to the display area and a second width corresponding to the component;
and determining each component falling into the display area according to the first width and the second width to serve as each display component.
Optionally, displaying, in the redefined display area, the rendering result of the data to be rendered corresponding to each redefined display component, where the rendering result specifically includes:
judging whether the data to be rendered corresponding to each display component is rendered or not according to each redetermined display component;
if yes, determining a rendering result of the data to be rendered corresponding to the display component to display;
if not, determining the data to be rendered of the display component, rendering the data to be rendered of the data to be rendered, and displaying the rendering result.
Optionally, the method is applied to a terminal, which is connected to a control unit;
and re-determining a display area in response to the horizontal scrolling operation of the user on the data to be rendered, wherein the method specifically comprises the following steps of:
receiving a control instruction sent by the control unit, wherein the control instruction comprises a rolling direction and a rolling distance, and the control instruction is determined by the control unit according to user operation;
and determining the position of the display area after scrolling according to the initial position of the display area and the control instruction, and re-determining the display area according to the position of the display area after scrolling.
Optionally, the method further comprises:
receiving a control instruction determined by the control unit according to the rolling operation of a user on the control unit;
or receiving a control instruction determined by the control unit according to the drag operation of the user on the progress bar corresponding to the position of the display area in the block to be rendered.
Optionally, the component is for displaying a picture.
Optionally, the method further comprises:
and rendering the component frames corresponding to the components respectively.
The present specification provides a rendering apparatus, the apparatus comprising:
the block determining module is used for determining a block to be rendered and a display area in the block to be rendered, wherein the block to be rendered is a designated area in a page;
the component determining module is used for determining all components contained in the block to be rendered, and determining the components contained in the display area from all the components to serve as all the display components;
the rendering module is used for rendering the data to be rendered corresponding to each display component respectively and displaying the rendering result to a user in the display area;
and the response module is used for responding to the horizontal scrolling operation of the user on the display area, redefining each display assembly according to the redetermined display area, and displaying the rendering results of the data to be rendered, which correspond to each redetermined display assembly, in the redetermined display area.
The present description provides a computer-readable storage medium storing a computer program which, when executed by a processor, implements the lazy loading method for page blocks described above.
The present specification provides an electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, the processor implementing the lazy loading method of page blocks described above when executing the program.
The above-mentioned at least one technical scheme that this specification adopted can reach following beneficial effect:
after receiving data to be rendered corresponding to a block to be rendered in a page, determining components contained in a display area in the block to be rendered, and displaying the display components. And after receiving the horizontal scrolling operation of the block by the user, re-determining the display area, determining the display assembly according to the re-determined display area, rendering the re-determined display assembly, and displaying.
Under the condition that the page block contains more data, only the components in the display area are rendered and displayed, the required time is short, and the rendering efficiency is improved.
Drawings
The accompanying drawings, which are included to provide a further understanding of the specification, illustrate and explain the exemplary embodiments of the present specification and their description, are not intended to limit the specification unduly. Attached at
In the figure:
fig. 1 is a flow chart of a lazy loading method for a page block provided in the present specification;
fig. 2 is a schematic structural diagram of an area to be rendered provided in the present specification;
fig. 3 is a schematic structural diagram of an area to be rendered provided in the present specification;
fig. 4 is a schematic structural diagram of a lazy loading apparatus for page blocks provided in the present specification;
fig. 5 is a schematic view of the electronic device corresponding to fig. 1 provided in the present specification.
Detailed Description
For the purposes of making the objects, technical solutions and advantages of the present specification more apparent, the technical solutions of the present specification will be clearly and completely described below with reference to specific embodiments of the present specification and corresponding drawings. It will be apparent that the described embodiments are only some, but not all, of the embodiments of the present specification. All other embodiments, which can be made by one of ordinary skill in the art without undue burden from the present disclosure, are intended to be within the scope of the present disclosure.
The following describes in detail the technical solutions provided by the embodiments of the present specification with reference to the accompanying drawings.
Generally, in the field of data processing, rendering is generally a process that a terminal visually displays data to be rendered in real time by using a line graph and a scatter image icon type after receiving the data to be rendered. And the most common rendering scene is that after receiving the data to be rendered corresponding to the webpage, the terminal renders the data to be rendered corresponding to the webpage and displays the rendered data to the user on the webpage.
At present, one common webpage rendering method is that a server sends all content contained in a webpage to a client, the client receives the content sent by the server, renders the received data to be rendered into a document object type (Document Object Model, DOM), and displays the generated DOM in the webpage.
However, when the elements included in the data to be rendered corresponding to the web page are too many, the DOM corresponding to the data to be rendered is more, and it takes a longer time to render the data to be rendered into the DOM or show the DOM to the user in the page. This results in the time currently required to present a page to a user being lengthy.
Based on this, the present specification provides a lazy loading method for page blocks.
Fig. 1 is a flow chart of a lazy loading method for a page block provided in the present specification, specifically including the following steps:
s100: determining a block to be rendered and a display area in the block to be rendered, wherein the block to be rendered is a designated area in a page.
The embodiment of the specification provides a lazy loading method of page blocks, and the execution process of the lazy loading method can be executed by electronic equipment such as a terminal for rendering and displaying data.
The method is different from the fact that at present, after the terminal receives data to be rendered, each element in the data to be rendered is directly rendered into DOM, and under the condition that the elements are more, the DOM can be displayed on a page to a user only for a long time, so that rendering efficiency is low.
The present disclosure provides a lazy loading method for a new page block, after receiving data to be rendered corresponding to a block to be rendered in a page, determining a component contained in a display area in the block as a display component, and displaying the display component. And after receiving the horizontal scrolling operation of the block by the user, re-determining the display area, determining the display assembly according to the re-determined display area, rendering the re-determined display assembly, and displaying. Under the condition that the page block contains more data, only the components in the display area are rendered and displayed, the required time is short, and the rendering efficiency is improved.
Based on the above brief description of the lazy loading method of the page block in the present application, it can be seen that the lazy loading method of the page block in the present specification can render the components contained in the display area in the block to be rendered. Based on this, the terminal may determine the tile to be rendered and the presentation area.
Specifically, the page displayed to the user by the terminal includes a block to be rendered, and the block may be a designated area in the page, where the designated area may be carried in the data to be rendered, or may be determined by the terminal in response to a setting operation of the user.
The terminal may then determine the region to be rendered in the page and determine the presentation region in the region to be rendered. The display area is a part of the area to be rendered. Alternatively, if the region to be rendered is divided into a visible portion and an invisible portion, the display region may be the visible portion of the region to be rendered.
The terminal may then determine the components in the page, as shown in FIG. 2.
Fig. 2 is a schematic structural diagram of an area to be rendered provided in the present specification. In the figure, it can be seen that the region to be rendered includes a plurality of components, and the size and shape of each component may be consistent or inconsistent. Components of uniform size are illustrated in the figures. The to-be-rendered area comprises a display area, and the total length of the to-be-rendered area formed by connecting all the components is larger than that of the display area.
Of course, the location of the display area in the drawing may be merely illustrated, and in particular, where the display area is located in the area to be rendered may be set according to needs, which is not limited in this specification.
S102: and determining all components contained in the block to be rendered, and determining the components contained in the display area from all the components to serve as all the display components.
In one or more embodiments provided herein, in general, a block to be rendered may include a plurality of components, each of which may be used to present different content. Therefore, the terminal can render different components in units of components. When a user browses a page, the user can only browse the content of the visual area, so that the terminal can determine each component contained in the display area as a display component, and then when rendering is performed, only each display component can be rendered.
Specifically, the terminal may determine each component included in the region to be rendered, and identify a component corresponding to each component allocator. Taking fig. 2 as an example, the terminal may determine that each component included in the block to be rendered is component 1, component 2, component 3, component 4, and component 5, respectively.
The component may then determine the components contained in the display area as display components.
Specifically, the terminal may determine a first width corresponding to the display area and a second width corresponding to the component.
The terminal may then determine the number of components falling within the display area based on the first width and the second width, and determine the number of components as display components based on the number, starting from an initial position of the display area. Taking fig. 2 as an example, the terminal may determine that component 1, component 2, and component 3 are presentation components.
Of course, the terminal may also construct a horizontal coordinate axis, and determine, according to the first width and the first position of the terminal, a coordinate range corresponding to the display area in the coordinate axis. Meanwhile, the terminal can also determine the coordinate range corresponding to each component in the coordinate axis according to each second width. And finally, determining each component falling into the display area as each display component according to the coordinates of the display area and the coordinates of each component.
S104: rendering the data to be rendered, which correspond to each display component, and displaying rendering results to a user in the display area.
In one or more embodiments provided herein, the terminal may render only the presentation component, as previously described.
Specifically, for each presentation component, the terminal may determine data to be rendered corresponding to the presentation component. Wherein. The data to be rendered can contain simulation results of simulation software, and can also contain colors corresponding to the components, functions, shapes and the like of all control keys in the components.
Then, the terminal can render the data to be rendered to obtain DOMs corresponding to all elements in the data to be rendered.
And finally, the terminal can display the rendered DOM in the region corresponding to each component in the display region.
S106: and responding to the horizontal scrolling operation of the user on the display area, redefining each display assembly according to the redetermined display area, and displaying the rendering results of the data to be rendered, which correspond to each redetermined display assembly, in the redetermined display area.
In one or more embodiments provided herein, a user may operate on a presentation area to update a viewable area in the block to be rendered. Therefore, the terminal can redetermine the display area according to the horizontal scrolling operation of the user, and display the redetermined display area.
Specifically, the user may perform a horizontal scrolling operation on the presentation area.
The terminal can then determine the horizontal distance of the redetermined presentation area compared to the original presentation area based on the horizontal scrolling operation performed by the user.
Then, the terminal can determine the updated position of the display area according to the horizontal distance and the original position of the display area, and re-determine the display area according to the updated position.
And then, the terminal can redetermine each component falling into the display area as each display component according to the redetermined display area and each component in the block to be rendered.
Finally, the terminal can determine the data to be rendered corresponding to the display component aiming at each redetermined display component, render the data to be rendered corresponding to the display component, and display the rendering result in the component. As shown in fig. 3.
Fig. 3 is a schematic structural diagram of an area to be rendered provided in the present specification. In the figure, the to-be-rendered area includes a plurality of components, the to-be-rendered area includes a display area, and the total length of the to-be-rendered area formed by connecting the components is greater than the total length of the display area. Taking the display area in fig. 2 as the display area determined in the previous display process as an example, the terminal can take the position of the display area in fig. 2 as the initial position corresponding to the display area, and redetermine the position of the display area according to the rolling direction and the rolling distance corresponding to the horizontal rolling operation of the user and the initial position of the display area. The location of the display area shown in fig. 3 may be the re-determined location of the display area. The terminal can then re-determine the presentation components and present based on the presentation area in fig. 3.
Based on the lazy loading method of the page block shown in fig. 1, after receiving the data to be rendered corresponding to the block to be rendered in the page, determining the components contained in the display area in the block as display components, and displaying the display components. And after receiving the horizontal scrolling operation of the block by the user, re-determining the display area, determining the display assembly according to the re-determined display area, rendering the re-determined display assembly, and displaying. Under the condition that the page block contains more data, only the components in the display area are rendered and displayed, the required time is short, and the rendering efficiency is improved.
In addition, in the present specification, if the newly determined display area includes the display component determined last time, the data to be rendered corresponding to the display component may not need to be repeatedly rendered, so as to further improve the rendering efficiency.
Specifically, the terminal may determine, for each newly determined display component, whether the data to be rendered corresponding to the display component is rendered in the history display process.
If yes, the terminal determines a rendering result of the data to be rendered corresponding to the display component to display.
If not, the terminal can determine the data to be rendered of the display component, render the data to be rendered, and display the rendering result.
Further, the operation performed by the user may be an operation performed by the user on the control unit. Then, the control unit may determine a control instruction of the user in response to a designated operation of the user. The control instruction comprises a rolling direction and a rolling distance.
Then, the terminal may receive the control command sent by the control unit, and determine the scrolling direction and the scrolling distance carried in the control command.
And then, the terminal can determine the position of the rolled display area according to the initial position of the display area and the control instruction, and the position of the rolled display area can be determined again.
Furthermore, the control unit can determine the control instruction through the scrolling operation of the user, and can also determine the control instruction through the dragging operation of the user on the progress bar corresponding to the position of the display area in the block to be rendered.
Specifically, the control unit may determine a scrolling operation of the user on the knob in the control unit, determine a control instruction including a scrolling direction and a scrolling distance corresponding to the display area according to a scrolling direction and a scrolling degree corresponding to the scrolling operation, and send the control instruction to the user.
The terminal may then receive the control command sent by the control unit.
Or the control unit can determine the click operation and the dragging operation of the keys in the control unit by a user, determine a control instruction containing the rolling direction and the rolling distance corresponding to the display area according to the click operation and the dragging operation, and send the control instruction to the user.
The terminal may then receive the control command sent by the control unit.
In addition, in this specification, each component in the to-be-displayed block may be used to display a picture.
Further, in this specification, for each component, the data to be rendered of the component may include data to be rendered corresponding to a frame of the component, and may also include data to be rendered corresponding to a page area corresponding to the component. For each component, more computing resources are required to render the page area corresponding to the component than are required to render the frame corresponding to the component. Therefore, after determining each component, the terminal can render the frame of the component for each component, and then render the page area corresponding to the display component when the component is the display component.
Based on the same thought, the present specification also provides a lazy loading apparatus for page blocks, as shown in fig. 4.
Fig. 4 is a lazy loading apparatus for page blocks provided in the present specification, wherein:
the block determining module 200 is configured to determine a block to be rendered and a display area in the block to be rendered, where the block to be rendered is a specified area in a page.
The component determining module 202 is configured to determine each component included in the block to be rendered, and determine, from the components, a component included in the display area as each display component.
And the rendering module 204 is configured to render the data to be rendered corresponding to each display component, and display the rendering result to the user in the display area.
And the response module 206 is configured to, in response to a horizontal scrolling operation of the user on the display area, redetermine each display component according to the redetermined display area, and display, in the redetermined display area, a rendering result of the data to be rendered, which corresponds to each redetermined display component.
Optionally, the component determining module 202 is configured to determine a first width corresponding to a display area and a second width corresponding to the component, and determine, as each display component, each component falling into the display area according to the first width and the second width.
Optionally, the response module 206 is configured to determine, for each redetermined display component, whether the data to be rendered corresponding to the display component is rendered, if yes, determine that a rendering result of the data to be rendered corresponding to the display component is displayed, if not, determine the data to be rendered of the display component, render the data to be rendered of the data to be rendered, and display the rendering result.
Optionally, the response module 206 is configured to receive a control instruction sent by the control unit, where the control instruction includes a rolling direction and a rolling distance, where the control instruction is determined by the control unit according to a user operation, determine a position of the rolled display area according to an initial position of the display area and the control instruction, and redetermine the display area according to the position of the rolled display area, where the method is applied to a terminal, and the terminal is connected to the control unit.
Optionally, the response module 206 is configured to receive a control instruction determined by the control unit according to a scrolling operation of the control unit by a user; or receiving a control instruction determined by the control unit according to the drag operation of the user on the progress bar corresponding to the position of the display area in the block to be rendered.
Optionally, the component is for displaying a picture.
Optionally, the rendering module 204 is configured to render the component frames corresponding to the components respectively.
The present specification also provides a computer readable storage medium storing a computer program operable to perform the lazy loading method of page blocks provided in figure 1 above.
The present specification also provides a schematic structural diagram of the electronic device shown in fig. 5. At the hardware level, the electronic device includes a processor, an internal bus, a network interface, a memory, and a non-volatile storage, as illustrated in fig. 5, although other hardware required by other services may be included. The processor reads the corresponding computer program from the non-volatile memory into the memory and then runs to implement the lazy loading method for the page block described above with respect to fig. 1. Of course, other implementations, such as logic devices or combinations of hardware and software, are not excluded from the present description, that is, the execution subject of the following processing flows is not limited to each logic unit, but may be hardware or logic devices.
In the 90 s of the 20 th century, improvements to one technology could clearly be distinguished as improvements in hardware (e.g., improvements to circuit structures such as diodes, transistors, switches, etc.) or software (improvements to the process flow). However, with the development of technology, many improvements of the current method flows can be regarded as direct improvements of hardware circuit structures. Designers almost always obtain corresponding hardware circuit structures by programming improved method flows into hardware circuits. Therefore, an improvement of a method flow cannot be said to be realized by a hardware entity module. For example, a programmable logic device (Programmable Logic Device, PLD) (e.g., field programmable gate array (Field Programmable Gate Array, FPGA)) is an integrated circuit whose logic function is determined by the programming of the device by a user. A designer programs to "integrate" a digital system onto a PLD without requiring the chip manufacturer to design and fabricate application-specific integrated circuit chips. Moreover, nowadays, instead of manually manufacturing integrated circuit chips, such programming is mostly implemented by using "logic compiler" software, which is similar to the software compiler used in program development and writing, and the original code before the compiling is also written in a specific programming language, which is called hardware description language (Hardware Description Language, HDL), but not just one of the hdds, but a plurality of kinds, such as ABEL (Advanced Boolean Expression Language), AHDL (Altera Hardware Description Language), confluence, CUPL (Cornell University Programming Language), HDCal, JHDL (Java Hardware Description Language), lava, lola, myHDL, PALASM, RHDL (Ruby Hardware Description Language), etc., VHDL (Very-High-Speed Integrated Circuit Hardware Description Language) and Verilog are currently most commonly used. It will also be apparent to those skilled in the art that a hardware circuit implementing the logic method flow can be readily obtained by merely slightly programming the method flow into an integrated circuit using several of the hardware description languages described above.
The controller may be implemented in any suitable manner, for example, the controller may take the form of, for example, a microprocessor or processor and a computer readable medium storing computer readable program code (e.g., software or firmware) executable by the (micro) processor, logic gates, switches, application specific integrated circuits (Application Specific Integrated Circuit, ASIC), programmable logic controllers, and embedded microcontrollers, examples of which include, but are not limited to, the following microcontrollers: ARC 625D, atmel AT91SAM, microchip PIC18F26K20, and Silicone Labs C8051F320, the memory controller may also be implemented as part of the control logic of the memory. Those skilled in the art will also appreciate that, in addition to implementing the controller in a pure computer readable program code, it is well possible to implement the same functionality by logically programming the method steps such that the controller is in the form of logic gates, switches, application specific integrated circuits, programmable logic controllers, embedded microcontrollers, etc. Such a controller may thus be regarded as a kind of hardware component, and means for performing various functions included therein may also be regarded as structures within the hardware component. Or even means for achieving the various functions may be regarded as either software modules implementing the methods or structures within hardware components.
The system, apparatus, module or unit set forth in the above embodiments may be implemented in particular by a computer chip or entity, or by a product having a certain function. One typical implementation is a computer. In particular, the computer may be, for example, a personal computer, a laptop computer, a cellular telephone, a camera phone, a smart phone, a personal digital assistant, a media player, a navigation device, an email device, a game console, a tablet computer, a wearable device, or a combination of any of these devices.
For convenience of description, the above devices are described as being functionally divided into various units, respectively. Of course, the functions of each element may be implemented in one or more software and/or hardware elements when implemented in the present specification.
It will be appreciated by those skilled in the art that embodiments of the present description may be provided as a method, system, or computer program product. Accordingly, the present specification may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present description can take the form of a computer program product on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) having computer-usable program code embodied therein.
The present description is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems) and computer program products according to embodiments of the specification. It will be understood that each flow and/or block of the flowchart illustrations and/or block diagrams, and combinations of flows and/or blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable lesion detection device to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable lesion detection device, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable lesion detection device to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
In one typical configuration, a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory.
The memory may include volatile memory in a computer-readable medium, random Access Memory (RAM) and/or nonvolatile memory, such as Read Only Memory (ROM) or flash memory (flash RAM). Memory is an example of computer-readable media.
Computer readable media, including both non-transitory and non-transitory, removable and non-removable media, may implement information storage by any method or technology. The information may be computer readable instructions, data structures, modules of a program, or other data. Examples of storage media for a computer include, but are not limited to, phase change memory (PRAM), static Random Access Memory (SRAM), dynamic Random Access Memory (DRAM), other types of Random Access Memory (RAM), read Only Memory (ROM), electrically Erasable Programmable Read Only Memory (EEPROM), flash memory or other memory technology, compact disc read only memory (CD-ROM), digital Versatile Discs (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices, or any other non-transmission medium, which can be used to store information that can be accessed by a computing device. Computer-readable media, as defined herein, does not include transitory computer-readable media (transmission media), such as modulated data signals and carrier waves.
It should also be noted that the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one … …" does not exclude the presence of other like elements in a process, method, article or apparatus that comprises the element.
It will be appreciated by those skilled in the art that embodiments of the present description may be provided as a method, system, or computer program product. Accordingly, the present specification may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present description can take the form of a computer program product on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) having computer-usable program code embodied therein.
The description may be described in the general context of computer-executable instructions, such as program modules, being executed by a computer. Generally, program modules include routines, programs, objects, components, data structures, etc. that perform particular tasks or implement particular abstract data types. The specification may also be practiced in distributed computing environments where tasks are performed by remote processing devices that are linked through a communications network. In a distributed computing environment, program modules may be located in both local and remote computer storage media including memory storage devices.
In this specification, each embodiment is described in a progressive manner, and identical and similar parts of each embodiment are all referred to each other, and each embodiment mainly describes differences from other embodiments. In particular, for system embodiments, since they are substantially similar to method embodiments, the description is relatively simple, as relevant to see a section of the description of method embodiments.
The foregoing is merely exemplary of the present disclosure and is not intended to limit the disclosure. Various modifications and alterations to this specification will become apparent to those skilled in the art. Any modifications, equivalent substitutions, improvements, or the like, which are within the spirit and principles of the present description, are intended to be included within the scope of the claims of the present description.

Claims (10)

1. A method for lazy loading of a page block, the method comprising:
determining a block to be rendered and a display area in the block to be rendered, wherein the block to be rendered is a designated area in a page;
determining all components contained in the block to be rendered, and determining the components contained in the display area from all the components to serve as all display components;
rendering the data to be rendered corresponding to each display component respectively, and displaying the rendering result to a user in the display area;
and responding to the horizontal scrolling operation of the user on the display area, redefining each display component according to the redetermined display area, and displaying the rendering results of the data to be rendered, which correspond to each redetermined display component, in the redetermined display area.
2. The method according to claim 1, wherein determining the components contained in the display area from the components, as each display component, specifically comprises:
determining a first width corresponding to the display area and a second width corresponding to the component;
and determining each component falling into the display area according to the first width and the second width to serve as each display component.
3. The method of claim 1, wherein displaying the rendering result of the data to be rendered corresponding to each newly determined display component in the newly determined display area specifically comprises:
judging whether the data to be rendered corresponding to each display component is rendered or not according to each redetermined display component;
if yes, determining a rendering result of the data to be rendered corresponding to the display component to display;
if not, determining the data to be rendered of the display component, rendering the data to be rendered of the data to be rendered, and displaying the rendering result.
4. The method according to claim 1, characterized in that the method is applied to a terminal, which is connected to a control unit;
and re-determining a display area in response to the horizontal scrolling operation of the user on the data to be rendered, wherein the method specifically comprises the following steps of:
receiving a control instruction sent by the control unit, wherein the control instruction comprises a rolling direction and a rolling distance, and the control instruction is determined by the control unit according to user operation;
and determining the position of the display area after scrolling according to the initial position of the display area and the control instruction, and re-determining the display area according to the position of the display area after scrolling.
5. The method of claim 4, wherein the method further comprises:
receiving a control instruction determined by the control unit according to the rolling operation of a user on the control unit;
or receiving a control instruction determined by the control unit according to the drag operation of the user on the progress bar corresponding to the position of the display area in the block to be rendered.
6. The method of claim 1, wherein the component is for displaying a picture.
7. The method of claim 4, wherein the method further comprises:
and rendering the component frames corresponding to the components respectively.
8. A rendering apparatus, the apparatus comprising:
the block determining module is used for determining a block to be rendered and a display area in the block to be rendered, wherein the block to be rendered is a designated area in a page;
the component determining module is used for determining all components contained in the block to be rendered, and determining the components contained in the display area from all the components to serve as all the display components;
the rendering module is used for rendering the data to be rendered corresponding to each display component respectively and displaying the rendering result to a user in the display area;
and the response module is used for responding to the horizontal scrolling operation of the user on the display area, redefining each display assembly according to the redetermined display area, and displaying the rendering results of the data to be rendered, which correspond to each redetermined display assembly, in the redetermined display area.
9. A computer readable storage medium storing a computer program, characterized in that the computer program, when executed by a processor, implements the method of any of the preceding claims 1-7.
10. An electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, characterized in that the processor implements the method of any of the preceding claims 1-7 when executing the program.
CN202310982912.2A 2023-08-04 2023-08-04 Lazy loading method, lazy loading device, lazy loading storage medium and lazy loading equipment for page blocks Pending CN116975485A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310982912.2A CN116975485A (en) 2023-08-04 2023-08-04 Lazy loading method, lazy loading device, lazy loading storage medium and lazy loading equipment for page blocks

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310982912.2A CN116975485A (en) 2023-08-04 2023-08-04 Lazy loading method, lazy loading device, lazy loading storage medium and lazy loading equipment for page blocks

Publications (1)

Publication Number Publication Date
CN116975485A true CN116975485A (en) 2023-10-31

Family

ID=88474807

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310982912.2A Pending CN116975485A (en) 2023-08-04 2023-08-04 Lazy loading method, lazy loading device, lazy loading storage medium and lazy loading equipment for page blocks

Country Status (1)

Country Link
CN (1) CN116975485A (en)

Similar Documents

Publication Publication Date Title
CN111639289B (en) Webpage loading method and device
CN109101157B (en) Sidebar icon setting method and device, terminal and storage medium
EP3835931A1 (en) Icon display method and apparatus, and terminal and storage medium
CN108228050B (en) Picture scaling method and device and electronic equipment
CN110244949B (en) Page information display method and device
CN110941784A (en) Page generation method and device
JP2012038336A (en) System and method for viewing digital visual content on a device
CN112364277B (en) Webpage loading method and device
WO2019085580A1 (en) View scrolling method and apparatus, and electronic device
CN110496395B (en) Component operation method, system and equipment for illusion engine
CN111796821A (en) Page updating method and device
CN114115643A (en) Component display method and device, electronic equipment and readable medium
CN110806847A (en) Distributed multi-screen display method, device, equipment and system
CN113672323A (en) Page display method and device
CN110647704B (en) Page updating method, device and equipment
CN110262749B (en) Webpage operation method, device, container, equipment and medium
CN111898056A (en) Webpage display method and device, storage medium and electronic equipment
CN107368236B (en) Method and device for displaying titles in information directory
CN112528614A (en) Table editing method and device and electronic equipment
CN116245051A (en) Simulation software rendering method and device, storage medium and electronic equipment
CN116975485A (en) Lazy loading method, lazy loading device, lazy loading storage medium and lazy loading equipment for page blocks
CN112861042B (en) Information display method, device, equipment and readable medium
CN112000329B (en) Data display method, device, equipment and medium
CN116302230A (en) Page display method, device and equipment
CN115061618A (en) Method and device for displaying list data in sliding mode and electronic equipment

Legal Events

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