Unlock instant, AI-driven research and patent intelligence for your innovation.

Long data displaying method and system based on Android terminal

A technology for displaying systems and long data, applied in digital data processing, input/output process of data processing, instruments, etc., can solve the problem of easily misleading users and achieve the reduction of operation steps and good user experience , the effect of reducing the difficulty of operation

Active Publication Date: 2018-10-16
成都天翼空间科技有限公司
View PDF4 Cites 3 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0007] The purpose of the present invention is to overcome the deficiencies of the prior art and provide a method and system for displaying long data based on an Android terminal. This method solves the problem of easily misleading users into the illusion that the end has reached the end when displaying long data, and reduces the difficulty of operation. , which enhances the user experience

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Long data displaying method and system based on Android terminal
  • Long data displaying method and system based on Android terminal

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0039] Based on the above method, if the parent View is ScrollView, and the direction is to slide left and right, then define a method smoothScrollToMid that slides to the middle, and pass in parameters: the focusable child View, bind the focus monitoring event to the child View, when the child View is focused time, call this method.

[0040] The smoothScrollToMid method is: first obtain the visible width width in the left and right directions of the ScrollView, then obtain the distance left (getLeft) from the child View to the visible left part of the parent View, and then calculate the width vWidth (getWidth) of the child View, and calculate the left at this time The value of +vWidth / 2-width / 2 (the difference between the center of the sub-Viw and the center of the screen), this value is the distance that the sub-View needs to move (smoothScrollBy) on the X-axis of fatherView, that is, the middle position of the screen, so the visible area It will always be the center positio...

Embodiment 2

[0042] Based on the above method, if the parent View is ScrollView, and the direction is sliding up and down, then define a method smoothScrollToMid that slides to the middle, and pass in the parameters: the focusable sub-View, bind the focus monitoring event to the sub-View, when the sub-View is focused time, call this method.

[0043]The smoothScrollToMid method is as follows: first obtain the height of the visible area in the upper and lower directions of the ScrollView, and then obtain the upper margin of the visible area from the child View to the parent View and the height vheight (getheight) of the child View. At this time, calculate upper+vheight / 2 -height / 2 (the width difference between the center of the sub-Viw and the center of the screen), this value is the distance that the sub-View needs to move (smoothScrollBy) on the Y-axis of fatherView, that is, the middle position of the screen, so that the visible area is always the sub-View The center position of the View....

Embodiment 3

[0045] Based on the above method, if the parent View is a list View such as RecyclerView, take RecyclerView as an example to illustrate the implementation method of the invention: first define a method to move through the coordinate position of the item, and also take left and right movement as an example smoothScrollToMid, and maintain the child View as Under the premise of the middle position, the calculation is performed in the focus change event of the item. The calculation method is similar to that of the ScrollView. First, calculate the distance left between the item and the leftmost part of the RecyclerView, and then obtain the width vwidth of the item, and the width of the left and right directions of the RecyclerView displayable area. Width, finally calculate the distance that the item needs to move distance=left+vwidth / 2-Width / 2, then you can call the movement method (smoothScrollBy) to move the item on the X axis. In this way, the target View is always located in the...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The invention discloses a long data displaying method and system based on an Android terminal. The method comprises the steps that (1), a focus is obtained by a sub View, and when the focus is not ata head part or a tail part, step (2) is executed; (2), the position of a current focused sub View is obtained, whether or not the current position of the sub View is located in the middle of the visible region of a parent View is judged, and if not step (3) is executed; (3), the distance needed to be moved of the parent View is calculated; (4), the parent View is moved according to the distance tomake the sub View to be in the middle of the visible region of the parent View. By means of the method, the problem that a user is easily misled to think that the tail part is reached when long datais displayed is solved, the operation difficulty is reduced, and user experience is improved.

Description

technical field [0001] The invention belongs to the technical field of terminal application display, and more specifically, relates to a long data display method and system based on an Android terminal. Background technique [0002] There are two main methods for displaying long data on existing Android terminals: [0003] 1. Use ListView, GridView, RecyclerView and other reusable sub-item list Views to divide the data into pieces and put them into corresponding items, so that the sub-items can get the focus and scroll the data by continuously moving the focus. Generally speaking, the use of this type of View is usually data in a similar format. The data is displayed in a list, and the number of items is adaptive according to the amount of data. Because the width and height of the item have been specified in advance, it is easy to make some table types. style, and then parse the formatted beans, and place them in each position of the item according to the corresponding rela...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
Patent Type & Authority Applications(China)
IPC IPC(8): G06F9/451G06F3/0481
CPCG06F3/0481G06F9/451
Inventor 唐选勇吴江秦贤徐剑谭功强廖勇军
Owner 成都天翼空间科技有限公司