CN103345497A - Method and device for resizing webpages on electronic equipment - Google Patents

Method and device for resizing webpages on electronic equipment Download PDF

Info

Publication number
CN103345497A
CN103345497A CN2013102681506A CN201310268150A CN103345497A CN 103345497 A CN103345497 A CN 103345497A CN 2013102681506 A CN2013102681506 A CN 2013102681506A CN 201310268150 A CN201310268150 A CN 201310268150A CN 103345497 A CN103345497 A CN 103345497A
Authority
CN
China
Prior art keywords
scaling
literal
divergent
convergent
web displaying
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.)
Granted
Application number
CN2013102681506A
Other languages
Chinese (zh)
Other versions
CN103345497B (en
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.)
Beijing 360 Zhiling Technology Co ltd
Original Assignee
Beijing Qihoo Technology Co Ltd
Qizhi Software Beijing Co Ltd
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 Beijing Qihoo Technology Co Ltd, Qizhi Software Beijing Co Ltd filed Critical Beijing Qihoo Technology Co Ltd
Priority to CN201310268150.6A priority Critical patent/CN103345497B/en
Publication of CN103345497A publication Critical patent/CN103345497A/en
Priority to PCT/CN2014/074455 priority patent/WO2014206125A1/en
Priority to US14/901,512 priority patent/US10061494B2/en
Priority to PCT/CN2014/074454 priority patent/WO2014206124A1/en
Application granted granted Critical
Publication of CN103345497B publication Critical patent/CN103345497B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Information Transfer Between Computers (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

The invention discloses a method and device for resizing webpages on electronic equipment. The method comprises the following steps of inheriting a webpage display control to establish a custom-made touch event method, judging whether the touch event method is triggered by the operation on the electronic equipment that the n-1 of the n touch points are loosened, wherein the n is an integer larger than or equal to 2, setting the scaling of webpage texts as display scaling of the webpage display control if a judging result is yes, reflecting the setting from objects of a scaling manager and starting using a scaling method to carry out calls, and executing the touch event method of the inherited webpage display control. According to the embodiment of the method and device for resizing the webpages on the electronic equipment, under the premise of not modifying a browser or the kernel components of other page display programs, the functions of recomposing the page after page resizing and enabling contents to be tiled on a whole screen are achieved.

Description

The method and apparatus of webpage convergent-divergent on a kind of electronic equipment
Technical field
The present invention relates to the web displaying technology, relate in particular to the method and apparatus of webpage convergent-divergent on a kind of electronic equipment.
Background technology
Along with the intelligentized continuous development of electronic equipment, increasing user uses browser browsing page or other content on the electronic equipment, and in the operation of browsing page, to content dwindle or to amplify the use scene of (hereinafter to be referred as " convergent-divergent ") comparatively general.
In a kind of scheme of prior art, the demonstration control that adopts electronic equipment operating system to carry is example with the Android system, opens the zoom function of its WebView control that carries, and can realize convergent-divergent.Fig. 1 schematically shows the view of shown on a electronic equipment complete Webpage, adopt this prior art scheme, the user can be embodied in by amplifying a certain zone in the page to be more clearly visible this regional particular content: the amplification that elements such as the picture in this zone, literal all can equal proportion.Yet, shown in Figure 2 as the view in a certain zone after the amplification as shown on the schematically illustrated electronic equipment, this extra-regional content, especially before also in this zone, shifted out this regional content because of amplification afterwards, can not show because exceeding the screen scope.Relative with it, pass through reduction operation, can be more clearly visible the overall picture of webpage, be embodied in: elements such as the picture in the zone, literal meeting scaled down, do not show content completely because dwindling vacant zone of coming out before then can filling, but meanwhile also can cause literal to become less, readable relatively poor.
In the scheme of another kind of prior art, by revising browser kernel component (as the WebKit assembly of Android system), it is bundled in its application program installation kit then and realizes zoom function.This prior art scheme can be accomplished when amplifying the appointed area, word content in this zone is set type again, and it is shown on the electronic equipment " tiling ", to reach the effect of similar reading novel, avoided can't the display part content because of amplification problem.Yet, this prior art scheme exists that scaling speed is slow, application program installation kit big (needing usually take 5MB to the storage space of 6MB), the defectives such as new features that can't utilize the operating system of redaction to bring more, simultaneously, revise the browser kernel component and have certain risk, strengthened exploitation and adaptive difficulty, might cause browser to collapse and be difficult to find concrete reason.
Summary of the invention
In view of the above problems, the present invention has been proposed, in order to the method and apparatus of webpage convergent-divergent on a kind of electronic equipment that overcomes the problems referred to above or address the above problem at least in part is provided.
According to one aspect of the present invention, the method for webpage convergent-divergent on a kind of electronic equipment is provided, may further comprise the steps: inherit the web displaying control, to make up customization touch event method; Whether judgement is to unclamp n the touch point of the n-1 in the touch point to trigger the touch event method to the operation of electronic equipment, and wherein n is the integer more than or equal to 2; Be under the situation that is in judged result, webpage literal scaling is set to the demonstration scaling of web displaying control; Reflection arranges and enables the scaling method to call from the convergent-divergent manager object; And the touch event method of carrying out heritable web displaying control.
Alternatively, on electronic equipment according to an embodiment of the invention in the method for webpage convergent-divergent, the step that described webpage literal scaling is set to the demonstration scaling of web displaying control comprises: be Android2.3.x or more under the situation of older version in the operating system of electronic equipment, reflection literal scaling object from described web displaying control, and give described literal scaling object with the value of the demonstration scaling of web displaying control; Perhaps the operating system at electronic equipment is Android4.0 or upgrades under the situation of version, reflection literal scaling object from described convergent-divergent manager object, and give described literal scaling object with the value of the demonstration scaling of web displaying control.
Alternatively, on electronic equipment according to an embodiment of the invention in the method for webpage convergent-divergent, whether be to unclamp n the touch point of the n-1 in the touch point to trigger in the step of touch event method in described judgement to the operation of electronic equipment, utilize ACTION_POINTER_UP object or ACTION_POINTER_n_UP object to judge whether to trigger the touch event method for unclamping n the touch point of the n-1 in the touch point.
Alternatively, the method of webpage convergent-divergent also comprises step on the electronic equipment according to an embodiment of the invention: be set at described webpage literal scaling before the step of demonstration scaling of web displaying control, judge whether the operating system of electronic equipment supports the convergent-divergent handler object, under unsupported situation, carry out described webpage literal scaling be set to the web displaying control the demonstration scaling step and described from the convergent-divergent manager object reflection arrange and enable the scaling method with the step of the touch event method of calling and carry out heritable web displaying control; Under situation about supporting, carry out the step of the touch event method of described heritable web displaying control.
Alternatively, the method of webpage convergent-divergent also comprises step on the electronic equipment according to an embodiment of the invention: be set at described webpage literal scaling before the step of demonstration scaling of web displaying control, whether enable widescreen and browse the value of object and be set to false; And described from the convergent-divergent manager object reflection arrange and enable the scaling method with the step of calling after, whether enable widescreen and browse the value of object and be set to true.
Alternatively, on electronic equipment according to an embodiment of the invention in the method for webpage convergent-divergent, described from the convergent-divergent manager object reflection arrange and enable the scaling method with the step of calling in, the parameter of transmitting when calling comprise the demonstration scaling that is set to the web displaying control webpage literal scaling, allow text composition and allow to force text composition.
Alternatively, on electronic equipment according to an embodiment of the invention in the method for webpage convergent-divergent, the WebView control that described web displaying control is the Android system, described convergent-divergent manager object is the mZoomManager object, described convergent-divergent handler object is the mListener object, described literal scaling is to liking the mTextWrapScale object, described touch event method comprises onTouchEvent method and dispatchTouchEvent method, described setting and to enable the scaling method be setZoomScale method or setNewZoomScale method, described whether enable widescreen browse to as if the setUseWideViewPort object.
According to another aspect of the present invention, the device of webpage convergent-divergent on a kind of electronic equipment is provided, comprising: customization touch event method makes up module, is suitable for inheriting the web displaying control, to make up customization touch event method; The touch point judge module is suitable for judging whether the operation to electronic equipment is to unclamp n the touch point of the n-1 in the touch point to trigger the touch event method, and wherein n is the integer more than or equal to 2; Webpage literal scaling arranges module, and being suitable in judged result is under the situation that is, webpage literal scaling is set to the demonstration scaling of web displaying control; The scaling calling module is suitable for reflecting setting and enable the scaling method to call from the convergent-divergent manager object; And touch event method execution module, be suitable for carrying out the touch event method of heritable web displaying control.
Alternatively, on electronic equipment according to an embodiment of the invention in the device of webpage convergent-divergent, be Android2.3.x or more under the situation of older version in the operating system of electronic equipment, described webpage literal scaling arranges module and is suitable for from described web displaying control reflection literal scaling object, and gives described literal scaling object with the value of the demonstration scaling of web displaying control; Perhaps the operating system at electronic equipment is Android4.0 or upgrades under the situation of version, described webpage literal scaling arranges module and is suitable for from described convergent-divergent manager object reflection literal scaling object, and gives described literal scaling object with the value of the demonstration scaling of web displaying control.
Alternatively, in the device of webpage convergent-divergent, described touch point judge module is suitable for utilizing ACTION_POINTER_UP object or ACTION_POINTER_n_UP object to judge whether to trigger the touch event method for unclamping n the touch point of the n-1 in the touch point on electronic equipment according to an embodiment of the invention.
Alternatively, the device of webpage convergent-divergent also comprises on the electronic equipment according to an embodiment of the invention: the convergent-divergent processor is supported judge module, be suitable for arranging before module webpage literal scaling is set to the demonstration scaling of web displaying control at described webpage literal scaling, judge whether the operating system of electronic equipment supports the convergent-divergent handler object, under unsupported situation, described webpage literal scaling arranges the demonstration scaling that module webpage literal scaling is set to the web displaying control, the scaling calling module reflects from the convergent-divergent manager object and arranges and enable the scaling method calling, and touch event method execution module is carried out the touch event method of heritable web displaying control; Under situation about supporting, touch event method execution module is carried out the touch event method of described heritable web displaying control.
Alternatively, the device of webpage convergent-divergent also comprises on the electronic equipment according to an embodiment of the invention: enable widescreen and browse object module is set, be suitable for arranging before module webpage literal scaling is set to the demonstration scaling of web displaying control at described webpage literal scaling, whether enabling widescreen browses the value of object and is set to false, and be suitable for reflecting from the convergent-divergent manager object at described scaling calling module and arrange and enable the scaling method with after calling, whether enable widescreen and browse the value of object and be set to true.
Alternatively, on electronic equipment according to an embodiment of the invention in the device of webpage convergent-divergent, reflect from the convergent-divergent manager object at described scaling calling module and to arrange and to enable the scaling method when calling, the parameter of transmitting when calling comprise the demonstration scaling that is set to the web displaying control webpage literal scaling, allow text composition and allow to force text composition.
Alternatively, on electronic equipment according to an embodiment of the invention in the device of webpage convergent-divergent, the WebView control that described web displaying control is the Android system, described convergent-divergent manager object is the mZoomManager object, described convergent-divergent handler object is the mListener object, described literal scaling is to liking the mTextWrapScale object, described touch event method comprises onTouchEvent method and dispatchTouchEvent method, described setting and to enable the scaling method be setZoomScale method or setNewZoomScale method, described whether enable widescreen browse to as if the setUseWideViewPort object.
The invention provides the method and apparatus of webpage convergent-divergent on a kind of electronic equipment.According to embodiments of the invention, inherit the web displaying control, to make up customization touch event method, judging that touch operation is to unclamp n the touch point of the n-1 in the touch point to trigger under the situation of touch event method, webpage literal scaling is set to the demonstration scaling of web displaying control, and reflection arranges and enables the scaling method to call from the convergent-divergent manager object, thereby under the prerequisite of the kernel component of not revising browser or other page display routine (as the WebKit assembly of Android system), realize setting type again behind the page zoom-in and zoom-out, make content tiling to the function of whole screen, solved can't the display part content because of amplification problem.And embodiments of the invention are not supported the electronic equipment of convergent-divergent handler object for operating system, can realize equally the function of setting type again behind the above-mentioned convergent-divergent so just having realized the support for nearly all electronic equipment.Simultaneously, according to embodiments of the invention, can take full advantage of the new features that the operating system of redaction is brought, for example utilize the function of hardware acceleration of Android4.0 and renewal version, scaling speed can be significantly improved, the new features such as senior web page browsing feature of Android4.0 and renewal version can also be utilized.In addition, owing to do not need to revise the kernel component of browser or other page display routine, save the storage space of electronic equipment, also avoided revising the risk that the browser kernel component is brought simultaneously.
Above-mentioned explanation only is the general introduction of technical solution of the present invention, for can clearer understanding technological means of the present invention, and can be implemented according to the content of instructions, and for above and other objects of the present invention, feature and advantage can be become apparent, below especially exemplified by the specific embodiment of the present invention.
Description of drawings
By reading hereinafter detailed description of the preferred embodiment, various other advantage and benefits will become cheer and bright for those of ordinary skills.Accompanying drawing only is used for the purpose of preferred implementation is shown, and does not think limitation of the present invention.And in whole accompanying drawing, represent identical parts with identical reference symbol.In the accompanying drawings:
Fig. 1 schematically shows the view of shown on a electronic equipment complete Webpage;
Fig. 2 schematically shows the view in a certain zone after the amplification shown on the electronic equipment;
Fig. 3 schematically shows the process flow diagram of the method for webpage convergent-divergent on the electronic equipment according to an embodiment of the invention;
Fig. 4 schematically illustrates the process flow diagram of the method for webpage convergent-divergent on the electronic equipment that comprises each optional step according to an embodiment of the invention;
Fig. 5 schematically shows the block diagram of the device of webpage convergent-divergent on the electronic equipment according to an embodiment of the invention; And
Fig. 6 schematically illustrates the block diagram of the device of webpage convergent-divergent on the electronic equipment that comprises each optional module according to an embodiment of the invention.
Embodiment
Exemplary embodiment of the present disclosure is described below with reference to accompanying drawings in more detail.Though shown exemplary embodiment of the present disclosure in the accompanying drawing, yet should be appreciated that and to realize the disclosure and the embodiment that should do not set forth limits here with various forms.On the contrary, it is in order to understand the disclosure more thoroughly that these embodiment are provided, and can with the scope of the present disclosure complete convey to those skilled in the art.
Fig. 3 schematically illustrates the process flow diagram of the method 300 of webpage convergent-divergent on the electronic equipment according to an embodiment of the invention.
Principle of the present invention is applicable to any electronic equipment that comprises display unit, including, but not limited to: based on the computing machine of desktop operating systems such as Windows, Linux, Mac OS, Unix; Based on the mobile phone of Mobile operating systems such as iOS, Android, Windows Phone, Symbian, panel computer, video player, electronic reader, digital album (digital photo frame) etc.Hereinafter, will be example with the electronic equipment based on the Android system, principle of the present invention is exemplarily described.Yet just in order to describe the present invention with concrete example, to help reader understanding's principle of the present invention, scope of the present invention is not limited thereto for this, but go for anyly comprising display unit, based on the electronic equipment of any operating system.
In the following description, " convergent-divergent " all refers to " dwindle or amplify ".
According to embodiments of the invention, web page contents not only can comprise word content, also can comprise other contents such as picture, video.
As shown in Figure 3, the method 300 of webpage convergent-divergent starts from step S301 on the electronic equipment according to an embodiment of the invention, in step S301, inherits the web displaying control, to make up customization touch event method.
According to embodiments of the invention, described web displaying control for example can be the WebView control of Android system, scope of the present invention is not limited thereto, and the web displaying control can be any control that can realize the web displaying function, for example UIWebView control of iOS system etc.
According to embodiments of the invention, the touch event method for example can be onTouchEvent method and/or the dispatchTouchEvent method of Android system, the user is to any touch operation of a certain control, the Android system all can trigger touch place director's part of this control, onTouchEvent method and parameter of dispatchTouchEvent method band, be used for describing the situation of the current touch of user, it is the MotionEvent object in the Android system, it is used for describing for example quantity of the current touch point of user, corresponding coordinate, and the state that touches, as " when moving ", " when pressing ", " when unclamping " etc.
According to embodiments of the invention, in above-mentioned steps S301, can generate an object, allow it inherit web displaying control, to make up its oneself customization touch event method, for example onTouchEvent method and dispatchTouchEvent method.
After step S301, execution in step S303 wherein, judges whether the operation to electronic equipment is to unclamp n the touch point of the n-1 in the touch point to trigger the touch event method, and wherein n is the integer more than or equal to 2.
Situation with n=2 is example,, supposes that the user with the touch screen of two finger touch electronic equipments, when a finger unclamps therein, will trigger touch place director's part method that is.
According to embodiments of the invention, in step S303, for the Android system, can utilize ACTION_POINTER_UP object or ACTION_POINTER_n_UP object to judge whether to trigger the touch event method for unclamping n the touch point of the n-1 in the touch point.
Next, execution in step S305, wherein, the judged result in step S303 is under the situation that is, webpage literal scaling is set to the demonstration scaling of web displaying control.
According to embodiments of the invention, in step S305, be Android2.3.x or more under the situation of older version in the operating system of electronic equipment, reflection literal scaling object from described web displaying control, and give described literal scaling object with the value of the demonstration scaling of web displaying control.
According to embodiments of the invention, for reflective operation, the reflex mechanism that can adopt Java language .Net language etc. to provide is operated, and method or object is become publicly-owned attribute from privately owned attribute temporarily, for directly using and revising.It will be appreciated by those skilled in the art that the programming language that can adopt other equally, in a similar manner method or object are become publicly-owned attribute from privately owned attribute temporarily, to reach the purpose of reflective operation.
In addition, for the Android system, can be by obtaining the version number that the Build.VERSION.SDK_INT object obtains the Android system.
According to embodiments of the invention, in the Android system, described literal scaling is to liking the mTextWrapScale object.Give described literal scaling object with the value of the demonstration scaling of web displaying control, that is, make the value of the literal scaling of literal scaling object equal the value of the demonstration scaling of web displaying control.Wherein, the literal scaling refers to " web width "/" textwidth ", shows that scaling refers to " web width "/" screen width ".When the value of literal scaling equaled to show the value of scaling, textwidth just equaled web width, and the text just can full screen display.For instance, if the literal scaling is 2, and the demonstration scaling of WebView control is 1, and the ratio of the shared screen of expression literal is 1/2; And if the displaying ratio of WebView control and literal scaling are 1, represent that then the shared screen proportion of literal is 1/1, also be full screen display.In addition, even the user in use shifts out screen by touch operation slip screen with word segment and (for example slides into the rightmost side, all shift out screen up to literal), because the literal scaling does not change, so when the user slides literal return by touch operation, in case when the left frame of literal alignd with the left frame of electronic equipment screen, then literal must be paved with full frame.
In step S305, operating system at electronic equipment is Android4.0 or upgrades under the situation of version, reflection literal scaling object from described convergent-divergent manager object, and give described literal scaling object with the value of the demonstration scaling of web displaying control.Wherein, for the Android system, described convergent-divergent manager object can be the mZoomManager object, this object can be called by the WebView control directly or indirectly, so just can be with zoom operations from just detaching out the complex Web View control very much originally, become comparatively independently module, and used by WebView control (even other control).Wherein, at Android2.3.x or more in the older version, this java class is exactly the WebView control class, i.e. the WebView class; And at Android3.0 and later version, this object be the WebView control the object of a java class directly using, i.e. the object of ZoomManager class.
After step S305, can execution in step S307, wherein, reflection arranges and enables the scaling method calling from the convergent-divergent manager object, and execution in step S309, wherein carries out the touch event method of heritable web displaying control.In addition, the judged result in step S303 can directly be carried out above-mentioned steps S309 under the situation not, namely carries out the touch event method of heritable web displaying control.
According to embodiments of the invention, for the Android system, described setting and to enable the scaling method can be setZoomScale method or setNewZoomScale method, and the parameter of transmitting when calling in step S307 can comprise: be set to the demonstration scaling of web displaying control webpage literal scaling, allow text composition (being set to true) and allow to force text composition (being set to true).
In step S307, called and arranged and enable after the scaling method, just can execution in step S109, namely, carry out the touch event method of heritable web displaying control, it is original touch event method, for the Android system, just call onTouchEvent method and the dispatchTouchEvent method of its parent.Like this, just can realize setting type again, making behind the page zoom-in and zoom-out content tiling to the function of whole screen.
Fig. 4 schematically illustrates the process flow diagram of the method for webpage convergent-divergent on the electronic equipment that comprises each optional step according to an embodiment of the invention.Below in conjunction with each optional step in Fig. 4 describing method 100.
As shown in Figure 4, alternatively, according to embodiments of the invention, the method 300 of webpage convergent-divergent can also comprise step S304 on the described electronic equipment: before step S305, judge whether the operating system of electronic equipment supports the convergent-divergent handler object.
For the Android system, described convergent-divergent handler object can be the mListener object, should be to liking the module of when carrying out zoom operations at a certain control, calling, the mListener of Android system is to liking the object of convergent-divergent processor class-OnScaleGestureListener class, it comprises convergent-divergent start method, convergent-divergent process approach and convergent-divergent Method Of Accomplishment, for the mListener object, they are respectively onScaleBegin method, onScale method and onScaleEnd method.The scene of utilizing two fingers to carry out convergent-divergent in the touch screen of electronic equipment with the user is example, when the user prepares twoly when referring to convergent-divergent, also namely when the user puts down two fingers and begins to drag, calls the convergent-divergent start method of convergent-divergent handler object; In the process of user's convergent-divergent, call the convergent-divergent process approach of convergent-divergent handler object; Unclamp two the finger the user, when the indication convergent-divergent is finished, call the convergent-divergent Method Of Accomplishment of convergent-divergent handler object.Each supports the control of convergent-divergent can realize one's own convergent-divergent handler object, and the WebView control namely is one.
As shown in Figure 4, in step S304, be judged as under the unsupported situation, can carry out above-mentioned steps S305, step S307 and step S309, be about to the demonstration scaling that webpage literal scaling is set to the web displaying control, and reflection arranges and enables the scaling method calling from the convergent-divergent manager object, and carries out the touch event method of heritable web displaying control.
And be judged as under the situation of support, as shown in Figure 4, the direct step of the touch event method of the described heritable web displaying control of execution among the execution in step S309.
As shown in Figure 4, alternatively, according to embodiments of the invention, the method 300 of webpage convergent-divergent can also comprise step S304 ' on the described electronic equipment: before step S305, whether enable widescreen and browse the value of object and be set to false.For the Android system, the described widescreen of whether enabling is browsed liking the setUseWideViewPort object, its value is present in the WebView control and arranges in the module (the WebSettings object in the Android system), by the operation among the step S304 ', can avoid that the user comes mobile webpage by the screen that touches electronic equipment after amplifying displaying ratio.
As shown in Figure 4, alternatively, according to embodiments of the invention, the method 300 of webpage convergent-divergent can also comprise step S308 on the described electronic equipment: the reflection from the convergent-divergent manager object in step S307 arranges also enables the scaling method with after the step of calling, and whether enables widescreen and browses the value of object and be set to true.By the operation of step S308, can after setting type again, literal recover to move by touch operation the function of webpage.
As shown in Figure 4, in addition, alternatively, the method 300 of webpage convergent-divergent is before above-mentioned steps S303 on the described electronic equipment, can also comprise that the quantity of judging current touch point is whether greater than 1 step S302-1 and judge whether webpage supports the step S302-2 of zoom function, in these two steps, if wherein the judged result of arbitrary step is for denying, just do not do further processing, directly the step of the touch event method of the described heritable web displaying control of execution among the execution in step S309.
Alternatively, judge whether webpage supports the step S302-2 of zoom function to realize in the following way: can obtain the WebView control " whether supporting convergent-divergent " variable in the module (the WebSettings object in the Android system) is set, this variable is Boolean, if true, then express support for, if false, then zoom function is not supported in expression, finishes this determining step; Reflection " the minimum zoom ratio of current web page " object and " the maximum zoom ratio of current web page " object obtain operation to finish from the convergent-divergent manager object, and they are respectively mMinZoomScale object and mMaxZoomScale object in the Android system.Generally, in the source code (invisible to the user) of webpage, understand the scaling scope that some is used for informing this webpage, this value is generally underground, so need obtain by reflection; Then, whether the value that can compare " the minimum zoom ratio of current web page " object equates with the value of " the maximum zoom ratio of current web page " object, if equate, then directly return false, represent that this webpage do not support zoom function, if unequal, then return true, the value of expression " whether supporting zoom function " variable is true, and this webpage is supported zoom function.
The invention provides the method for webpage convergent-divergent on a kind of electronic equipment.According to embodiments of the invention, inherit the web displaying control, to make up customization touch event method, judging that touch operation is to unclamp n the touch point of the n-1 in the touch point to trigger under the situation of touch event method, webpage literal scaling is set to the demonstration scaling of web displaying control, and reflection arranges and enables the scaling method to call from the convergent-divergent manager object, thereby under the prerequisite of the kernel component of not revising browser or other page display routine (as the WebKit assembly of Android system), realize setting type again behind the page zoom-in and zoom-out, make content tiling to the function of whole screen, solved can't the display part content because of amplification problem.And embodiments of the invention are not supported the electronic equipment of convergent-divergent handler object for operating system, can realize equally the function of setting type again behind the above-mentioned convergent-divergent so just having realized the support for nearly all electronic equipment.Simultaneously, according to embodiments of the invention, can take full advantage of the new features that the operating system of redaction is brought, for example utilize the function of hardware acceleration of Android4.0 and renewal version, scaling speed can be significantly improved, the new features such as senior web page browsing feature of Android4.0 and renewal version can also be utilized.In addition, owing to do not need to revise the kernel component of browser or other page display routine, save the storage space of electronic equipment, also avoided revising the risk that the browser kernel component is brought simultaneously.
Corresponding with above-mentioned method 300, the present invention also provides the device 500 of webpage convergent-divergent on a kind of electronic equipment.Fig. 5 schematically illustrates the block diagram of the device 500 of webpage convergent-divergent on the electronic equipment according to an embodiment of the invention.
Referring to Fig. 5, the device 500 of webpage convergent-divergent comprises that mainly customization touch event method structure module 501, touch point judge module 503, webpage literal scaling arrange module 505, scaling calling module 507 and touch event method execution module 509 on the described electronic equipment.
According to embodiments of the invention, customization touch event method makes up module 501 and is suitable for inheriting the web displaying control, to make up customization touch event method; Touch point judge module 503 is suitable for judging whether the operation to electronic equipment is to unclamp n the touch point of the n-1 in the touch point to trigger the touch event method, and wherein n is the integer more than or equal to 2; Webpage literal scaling arranges module 505, and to be suitable in judged result be under the situation that is, webpage literal scaling is set to the demonstration scaling of web displaying control; Scaling calling module 507 is suitable for reflecting setting and enable the scaling method to call from the convergent-divergent manager object; Touch event method execution module 509 is suitable for carrying out the touch event method of heritable web displaying control.
According to embodiments of the invention, at first, customization touch event method makes up module 501 and inherits the web displaying control, to make up customization touch event method.
According to embodiments of the invention, described web displaying control for example can be the WebView control of Android system, scope of the present invention is not limited thereto, and the web displaying control can be any control that can realize the web displaying function, for example UIWebView control of iOS system etc.
According to embodiments of the invention, the touch event method for example can be onTouchEvent method and/or the dispatchTouchEvent method of Android system, the user is to any touch operation of a certain control, the Android system all can trigger touch place director's part of this control, onTouchEvent method and parameter of dispatchTouchEvent method band, be used for describing the situation of the current touch of user, it is the MotionEvent object in the Android system, it is used for describing for example quantity of the current touch point of user, corresponding coordinate, and the state that touches, as " when moving ", " when pressing ", " when unclamping " etc.
According to embodiments of the invention, customization touch event method makes up module 501 and can generate an object, allow it inherit web displaying control, to make up its oneself customization touch event method, for example onTouchEvent method and dispatchTouchEvent method.
Subsequently, touch point judge module 503 judges whether the operation to electronic equipment is to unclamp n the touch point of the n-1 in the touch point to trigger the touch event method, and wherein n is the integer more than or equal to 2.
Situation with n=2 is example,, supposes that the user with the touch screen of two finger touch electronic equipments, when a finger unclamps therein, will trigger touch place director's part method that is.
According to embodiments of the invention, for the Android system, touch point judge module 503 can utilize ACTION_POINTER_UP object or ACTION_POINTER_n_UP object to judge whether to trigger the touch event method for unclamping n the touch point of the n-1 in the touch point.
Next, be judged as under the situation that is at touch point judge module 503, webpage literal scaling arranges the demonstration scaling that module 505 webpage literal scalings are set to the web displaying control.
According to embodiments of the invention, be Android2.3.x or more under the situation of older version in the operating system of electronic equipment, webpage literal scaling arranges module 505 and reflect literal scaling object from described web displaying control, and gives described literal scaling object with the value of the demonstration scaling of web displaying control.
According to embodiments of the invention, for reflective operation, the reflex mechanism that the module 505 that arranges webpage literal scaling can adopt Java language .Net language etc. to provide is operated, and method or object is become publicly-owned attribute from privately owned attribute temporarily, for directly using and revising.It will be appreciated by those skilled in the art that webpage literal scaling arranges module 505 and can adopt other programming language equally, in a similar manner method or object are become publicly-owned attribute from privately owned attribute, to reach the purpose of reflective operation temporarily.
In addition, for the Android system, webpage literal scaling arranges module 505 can be by obtaining the version number that the Build.VERSION.SDK_INT object obtains the Android system.
According to embodiments of the invention, in the Android system, described literal scaling is to liking the mTextWrapScale object.Webpage literal scaling arranges module 505 and gives described literal scaling object with the value of the demonstration scaling of web displaying control, that is, make the value of the literal scaling of literal scaling object equal the value of the demonstration scaling of web displaying control.Wherein, the literal scaling refers to " web width "/" textwidth ", shows that scaling refers to " web width "/" screen width ".When the value of literal scaling equaled to show the value of scaling, textwidth just equaled web width, and the text just can full screen display.For instance, if the literal scaling is 2, and the demonstration scaling of WebView control is 1, and the ratio of the shared screen of expression literal is 1/2; And if the displaying ratio of WebView control and literal scaling are 1, represent that then the shared screen proportion of literal is 1/1, also be full screen display.In addition, even the user in use shifts out screen by touch operation slip screen with word segment and (for example slides into the rightmost side, all shift out screen up to literal), because the literal scaling does not change, so when the user slides literal return by touch operation, in case when the left frame of literal alignd with the left frame of electronic equipment screen, then literal must be paved with full frame.
Operating system at electronic equipment is Android4.0 or upgrades under the situation of version, webpage literal scaling arranges module 505 and reflect literal scaling object from described convergent-divergent manager object, and gives described literal scaling object with the value of the demonstration scaling of web displaying control.Wherein, for the Android system, described convergent-divergent manager object can be the mZoomManager object, this object can be called by the WebView control directly or indirectly, so just can be with zoom operations from just detaching out the complex Web View control very much originally, become comparatively independently module, and used by WebView control (even other control).Wherein, at Android2.3.x or more in the older version, this java class is exactly the WebView control class, i.e. the WebView class; And at Android3.0 and later version, this object be the WebView control the object of a java class directly using, i.e. the object of ZoomManager class.
Afterwards, scaling calling module 507 reflects from the convergent-divergent manager object and arranges and enable the scaling method calling, and touch event method execution module 509 is carried out the touch event method of heritable web displaying control.In addition, the judged result at touch point judge module 503 is that touch event method execution module 509 can directly be carried out the touch event method of heritable web displaying control under the situation not.
According to embodiments of the invention, for the Android system, described setting and to enable the scaling method can be setZoomScale method or setNewZoomScale method can comprise and carry out the parameter of transmitting when calling at scaling calling module 507: be set to the demonstration scaling of web displaying control webpage literal scaling, allow text composition (being set to true) and allow to force text composition (being set to true).
After scaling calling module 507 has called setting and has enabled the scaling method, touch event method execution module 509 just can be carried out the touch event method of heritable web displaying control, it is original touch event method, for the Android system, just call onTouchEvent method and the dispatchTouchEvent method of its parent.Like this, just can realize setting type again, making behind the page zoom-in and zoom-out content tiling to the function of whole screen.
Fig. 6 schematically illustrates the block diagram of the device of webpage convergent-divergent on the electronic equipment that comprises each optional module according to an embodiment of the invention.Be described for each optional module of installing 200 below in conjunction with Fig. 6 and top Fig. 4.
As shown in Figure 6, alternatively, according to embodiments of the invention, the device 600 of webpage convergent-divergent can also comprise convergent-divergent processor support judge module 604 on the described electronic equipment, be suitable for arranging before module 605 webpage literal scalings are set to the demonstration scaling of web displaying control at described webpage literal scaling, judge whether the operating system of electronic equipment supports the convergent-divergent handler object.
For the Android system, described convergent-divergent handler object can be the mListener object, should be to liking the module of when carrying out zoom operations at a certain control, calling, the mListener of Android system is to liking the object of convergent-divergent processor class-OnScaleGestureListener class, it comprises convergent-divergent start method, convergent-divergent process approach and convergent-divergent Method Of Accomplishment, for the mListener object, they are respectively onScaleBegin method, onScale method and onScaleEnd method.The scene of utilizing two fingers to carry out convergent-divergent in the touch screen of electronic equipment with the user is example, when the user prepares twoly when referring to convergent-divergent, also namely when the user puts down two fingers and begins to drag, calls the convergent-divergent start method of convergent-divergent handler object; In the process of user's convergent-divergent, call the convergent-divergent process approach of convergent-divergent handler object; Unclamp two the finger the user, when the indication convergent-divergent is finished, call the convergent-divergent Method Of Accomplishment of convergent-divergent handler object.Each supports the control of convergent-divergent can realize one's own convergent-divergent handler object, and the WebView control namely is one.
Support that at the convergent-divergent processor judge module is judged as under the unsupported situation, webpage literal scaling arranges the demonstration scaling that module 605 can webpage literal scaling be set to the web displaying control, and scaling calling module 607 can reflect from the convergent-divergent manager object and arrange and enable the scaling method calling, and touch event method execution module 609 is carried out the touch event method of heritable web displaying control.
And support that at the convergent-divergent processor judge module is judged as under the situation of support, touch event method execution module 609 can directly be carried out the touch event method of described heritable web displaying control.
As shown in Figure 6, alternatively, according to embodiments of the invention, the device 600 of webpage convergent-divergent can also comprise that enabling widescreen browses object module 604 ' is set on the described electronic equipment, be suitable for arranging before module 605 webpage literal scalings are set to the demonstration scaling of web displaying control at described webpage literal scaling, whether enable widescreen and browse the value of object and be set to false.For the Android system, the described widescreen of whether enabling is browsed liking the setUseWideViewPort object, its value is present in the WebView control and arranges in the module (the WebSettings object in the Android system), browse this operation that object arranges module 604 ' by enabling widescreen, can avoid that the user comes mobile webpage by the screen that touches electronic equipment after amplifying displaying ratio.
Alternatively, according to embodiments of the invention, enable widescreen and browse object and module 604 ' is set also is suitable for reflecting from the convergent-divergent manager object at described scaling calling module 607 and arranges and enable the scaling method with after calling, whether enable widescreen and browse the value of object and be set to true.Browse this operation that object arranges module 604 ' by enabling widescreen, can after literal is set type again, recover to move by touch operation the function of webpage.
In addition, alternatively, according to embodiments of the invention, described touch point judge module 603 is judging to the operation of electronic equipment whether be to unclamp before n the touch point of the n-1 in the touch point trigger the touch event method, whether the quantity that can also judge current touch point is greater than 1 and judge whether webpage supports convergent-divergent, in this twice judgement, if wherein arbitrary time judged result is for denying, just do not do further processing, touch event method execution module 609 is just directly carried out the touch event method of described heritable web displaying control.
Alternatively, described touch point judge module 603 judges whether webpage supports zoom function to realize in the following way: described touch point judge module 603 can obtain the WebView control " whether supporting convergent-divergent " variable in the module (the WebSettings object in the Android system) is set, this variable is Boolean, if true, then express support for, if false, then zoom function is not supported in expression, finishes this judgement; Described touch point judge module 603 can reflect " the minimum zoom ratio of current web page " object from the convergent-divergent manager object and " the maximum zoom ratio of current web page " object obtains operation to finish, and they are respectively mMinZoomScale object and mMaxZoomScale object in the Android system.Generally, in the source code (invisible to the user) of webpage, understand the scaling scope that some is used for informing this webpage, this value is generally underground, so need obtain by reflection; Then, whether the value that described touch point judge module 603 can compare " the minimum zoom ratio of current web page " object equates with the value of " the maximum zoom ratio of current web page " object, if equate, then directly return false, represent that this webpage do not support zoom function, if unequal, then return true, the value of expression " whether supporting zoom function " variable is true, and this webpage is supported zoom function.
Because above-mentioned each equipment (device) embodiment is corresponding with aforementioned approaches method embodiment, therefore no longer each device embodiment is described in detail.
Intrinsic not relevant with any certain computer, virtual system or miscellaneous equipment with demonstration at this algorithm that provides.Various general-purpose systems also can be with using based on the teaching at this.According to top description, it is apparent constructing the desired structure of this type systematic.In addition, the present invention is not also at any certain programmed language.Should be understood that and to utilize various programming languages to realize content of the present invention described here, and the top description that language-specific is done is in order to disclose preferred forms of the present invention.
In the instructions that provides herein, a large amount of details have been described.Yet, can understand, embodiments of the invention can be put into practice under the situation of these details not having.In some instances, be not shown specifically known method, structure and technology, so that not fuzzy understanding of this description.
Similarly, be to be understood that, in order to simplify the disclosure and to help to understand one or more in each inventive aspect, in the description to exemplary embodiment of the present invention, each feature of the present invention is grouped together in single embodiment, figure or the description to it sometimes in the above.Yet the method for the disclosure should be construed to the following intention of reflection: namely the present invention for required protection requires the more feature of feature clearly put down in writing than institute in each claim.Or rather, as following claims reflected, inventive aspect was to be less than all features of the disclosed single embodiment in front.Therefore, follow claims of embodiment and incorporate this embodiment thus clearly into, wherein each claim itself is as independent embodiment of the present invention.
Those skilled in the art are appreciated that and can adaptively change and they are arranged in one or more devices different with this embodiment the module in the device among the embodiment.Can become the some module combinations among the embodiment module or unit or assembly, and can be divided into a plurality of submodules or subelement or sub-component to them in addition.In such feature and/or process or module at least some are mutually repelling, and can adopt any combination to disclosed all features in this instructions (comprising claim, summary and the accompanying drawing followed) and so all processes or the unit of disclosed any method or equipment make up.Unless clearly statement in addition, disclosed each feature can be by providing identical, being equal to or similar purpose alternative features replaces in this instructions (comprising claim, summary and the accompanying drawing followed).
In addition, those skilled in the art can understand, although embodiment more described herein comprise some feature rather than further feature included among other embodiment, the combination of features of different embodiment means and is within the scope of the present invention and forms different embodiment.For example, in claims, the one of any of embodiment required for protection can be used with array mode arbitrarily.
Each device embodiment of the present invention can realize with hardware, perhaps realizes with the software module of moving at one or more processor, and perhaps the combination with them realizes.It will be understood by those of skill in the art that and to use microprocessor or digital signal processor (DSP) to realize according to some or all some or repertoire of modules in the device of the embodiment of the invention in practice.The present invention can also be embodied as for part or all the device program (for example, computer program and computer program) of carrying out method as described herein.Such realization program of the present invention can be stored on the computer-readable medium, perhaps can have the form of one or more signal.Such signal can be downloaded from internet website and obtain, and perhaps provides at carrier signal, perhaps provides with any other form.
It should be noted above-described embodiment the present invention will be described rather than limit the invention, and those skilled in the art can design alternative embodiment under the situation of the scope that does not break away from claims.In the claims, any reference symbol between bracket should be configured to limitations on claims.Word " comprises " not to be got rid of existence and is not listed in element or step in the claim.Being positioned at word " " before the element or " one " does not get rid of and has a plurality of such elements.The present invention can realize by means of the hardware that includes some different elements and by means of the computing machine of suitably programming.In having enumerated the unit claim of some devices, several in these devices can be to come imbody by same hardware branch.Any order is not represented in the use of word first, second and C grade.Can be title with these word explanations.
Embodiments of the invention disclose the method for webpage convergent-divergent on A1. electronic equipment, may further comprise the steps: inherit the web displaying control, to make up customization touch event method; Whether judgement is to unclamp n the touch point of the n-1 in the touch point to trigger the touch event method to the operation of electronic equipment, and wherein n is the integer more than or equal to 2; Be under the situation that is in judged result, webpage literal scaling is set to the demonstration scaling of web displaying control; Reflection arranges and enables the scaling method to call from the convergent-divergent manager object; And the touch event method of carrying out heritable web displaying control.A2. as the described method of A1, the step that wherein said webpage literal scaling is set to the demonstration scaling of web displaying control comprises: be Android2.3.x or more under the situation of older version in the operating system of electronic equipment, reflection literal scaling object from described web displaying control, and give described literal scaling object with the value of the demonstration scaling of web displaying control; Perhaps the operating system at electronic equipment is Android4.0 or upgrades under the situation of version, reflection literal scaling object from described convergent-divergent manager object, and give described literal scaling object with the value of the demonstration scaling of web displaying control.A3. as the described method of A1, whether be to unclamp n the touch point of the n-1 in the touch point to trigger in the step of touch event method in described judgement to the operation of electronic equipment wherein, utilize ACTION_POINTER_UP object or ACTION_POINTER_n_UP object to judge whether to trigger the touch event method for unclamping n the touch point of the n-1 in the touch point.A4. as each the described method among the A1 to A3, also comprise step: be set at described webpage literal scaling before the step of demonstration scaling of web displaying control, judge whether the operating system of electronic equipment supports the convergent-divergent handler object, under unsupported situation, carry out described webpage literal scaling be set to the web displaying control the demonstration scaling step and described from the convergent-divergent manager object reflection arrange and enable the scaling method with the step of the touch event method of calling and carry out heritable web displaying control; Under situation about supporting, carry out the step of the touch event method of described heritable web displaying control.A5. as each the described method among the A1 to A3, also comprise step: be set at described webpage literal scaling before the step of demonstration scaling of web displaying control, whether enable widescreen and browse the value of object and be set to false; And described from the convergent-divergent manager object reflection arrange and enable the scaling method with the step of calling after, whether enable widescreen and browse the value of object and be set to true.A6. as each the described method among the A1 to A3, wherein described from the convergent-divergent manager object reflection arrange and enable the scaling method with the step of calling in, the parameter of transmitting when calling comprise the demonstration scaling that is set to the web displaying control webpage literal scaling, allow text composition and allow to force text composition.A7. as each the described method among the A1 to A3, the WebView control that wherein said web displaying control is the Android system, described convergent-divergent manager object is the mZoomManager object, described convergent-divergent handler object is the mListener object, described literal scaling is to liking the mTextWrapScale object, described touch event method comprises onTouchEvent method and dispatchTouchEvent method, described setting and to enable the scaling method be setZoomScale method or setNewZoomScale method, described whether enable widescreen browse to as if the setUseWideViewPort object.
Embodiments of the invention also disclose the device of webpage convergent-divergent on B8. electronic equipment, comprising: customization touch event method makes up module, is suitable for inheriting the web displaying control, to make up customization touch event method; The touch point judge module is suitable for judging whether the operation to electronic equipment is to unclamp n the touch point of the n-1 in the touch point to trigger the touch event method, and wherein n is the integer more than or equal to 2; Webpage literal scaling arranges module, and being suitable in judged result is under the situation that is, webpage literal scaling is set to the demonstration scaling of web displaying control; The scaling calling module is suitable for reflecting setting and enable the scaling method to call from the convergent-divergent manager object; And touch event method execution module, be suitable for carrying out the touch event method of heritable web displaying control.B9. as the described device of B8, be Android2.3.x or more under the situation of older version in the operating system of electronic equipment wherein, described webpage literal scaling arranges module and is suitable for from described web displaying control reflection literal scaling object, and gives described literal scaling object with the value of the demonstration scaling of web displaying control; Perhaps the operating system at electronic equipment is Android4.0 or upgrades under the situation of version, described webpage literal scaling arranges module and is suitable for from described convergent-divergent manager object reflection literal scaling object, and gives described literal scaling object with the value of the demonstration scaling of web displaying control.B10. as the described device of B8, wherein said touch point judge module is suitable for utilizing ACTION_POINTER_UP object or ACTION_POINTER_n_UP object to judge whether to trigger the touch event method for unclamping n the touch point of the n-1 in the touch point.B11. as each the described device among the B8 to B10, also comprise: the convergent-divergent processor is supported judge module, be suitable for arranging before module webpage literal scaling is set to the demonstration scaling of web displaying control at described webpage literal scaling, judge whether the operating system of electronic equipment supports the convergent-divergent handler object, under unsupported situation, described webpage literal scaling arranges the demonstration scaling that module webpage literal scaling is set to the web displaying control, and the scaling calling module reflects from the convergent-divergent manager object and arranges and enable the scaling method calling, and touch event method execution module is carried out the touch event method of heritable web displaying control; Under situation about supporting, touch event method execution module is carried out the touch event method of described heritable web displaying control.B12. as each the described device among the B8 to B10, also comprise: enable widescreen and browse object module is set, be suitable for arranging before module webpage literal scaling is set to the demonstration scaling of web displaying control at described webpage literal scaling, whether enabling widescreen browses the value of object and is set to false, and be suitable for reflecting from the convergent-divergent manager object at described scaling calling module and arrange and enable the scaling method with after calling, whether enable widescreen and browse the value of object and be set to true.B13. as each the described device among the B8 to B10, wherein reflect from the convergent-divergent manager object at described scaling calling module and arrange and enable the scaling method when calling, the parameter of transmitting when calling comprise the demonstration scaling that is set to the web displaying control webpage literal scaling, allow text composition and allow to force text composition.B14. as each the described device among the B8 to B10, the WebView control that wherein said web displaying control is the Android system, described convergent-divergent manager object is the mZoomManager object, described convergent-divergent handler object is the mListener object, described literal scaling is to liking the mTextWrapScale object, described touch event method comprises onTouchEvent method and dispatchTouchEvent method, described setting and to enable the scaling method be setZoomScale method or setNewZoomScale method, described whether enable widescreen browse to as if the setUseWideViewPort object.

Claims (10)

1. the method for webpage convergent-divergent on the electronic equipment may further comprise the steps:
Inherit the web displaying control, to make up customization touch event method;
Whether judgement is to unclamp n the touch point of the n-1 in the touch point to trigger the touch event method to the operation of electronic equipment, and wherein n is the integer more than or equal to 2;
Be under the situation that is in judged result, webpage literal scaling is set to the demonstration scaling of web displaying control;
Reflection arranges and enables the scaling method to call from the convergent-divergent manager object; And
Carry out the touch event method of heritable web displaying control.
2. the method for claim 1, the step that wherein said webpage literal scaling is set to the demonstration scaling of web displaying control comprises:
Be Android2.3.x or more under the situation of older version in the operating system of electronic equipment, reflection literal scaling object from described web displaying control, and give described literal scaling object with the value of the demonstration scaling of web displaying control; Perhaps
Be Android4.0 or upgrade under the situation of version in the operating system of electronic equipment, reflection literal scaling object from described convergent-divergent manager object, and give described literal scaling object with the value of the demonstration scaling of web displaying control.
3. the method for claim 1, whether be to unclamp n the touch point of the n-1 in the touch point to trigger in the step of touch event method in described judgement to the operation of electronic equipment wherein, utilize ACTION_POINTER_UP object or ACTION_POINTER_n_UP object to judge whether to trigger the touch event method for unclamping n the touch point of the n-1 in the touch point.
4. as each the described method in the claim 1 to 3, also comprise step: be set at described webpage literal scaling before the step of demonstration scaling of web displaying control, judge whether the operating system of electronic equipment supports the convergent-divergent handler object
Under unsupported situation, carry out described webpage literal scaling be set to the web displaying control the demonstration scaling step and described from the convergent-divergent manager object reflection arrange and enable the scaling method with the step of the touch event method of calling and carry out heritable web displaying control;
Under situation about supporting, carry out the step of the touch event method of described heritable web displaying control.
5. as each the described method in the claim 1 to 3, also comprise step:
Be set at described webpage literal scaling before the step of demonstration scaling of web displaying control, whether enable widescreen and browse the value of object and be set to false; And
Described from the convergent-divergent manager object reflection arrange and enable the scaling method with the step of calling after, whether enable widescreen and browse the value of object and be set to true.
6. as each the described method in the claim 1 to 3, wherein described from the convergent-divergent manager object reflection arrange and enable the scaling method with the step of calling in, the parameter of transmitting when calling comprise the demonstration scaling that is set to the web displaying control webpage literal scaling, allow text composition and allow to force text composition.
7. as each the described method in the claim 1 to 3, the WebView control that wherein said web displaying control is the Android system, described convergent-divergent manager object is the mZoomManager object, described convergent-divergent handler object is the mListener object, described literal scaling is to liking the mTextWrapScale object, described touch event method comprises onTouchEvent method and dispatchTouchEvent method, described setting and to enable the scaling method be setZoomScale method or setNewZoomScale method, described whether enable widescreen browse to as if the setUseWideViewPort object.
8. the device of webpage convergent-divergent on the electronic equipment comprises:
Customization touch event method makes up module, is suitable for inheriting the web displaying control, to make up customization touch event method;
The touch point judge module is suitable for judging whether the operation to electronic equipment is to unclamp n the touch point of the n-1 in the touch point to trigger the touch event method, and wherein n is the integer more than or equal to 2;
Webpage literal scaling arranges module, and being suitable in judged result is under the situation that is, webpage literal scaling is set to the demonstration scaling of web displaying control;
The scaling calling module is suitable for reflecting setting and enable the scaling method to call from the convergent-divergent manager object; And
Touch event method execution module is suitable for carrying out the touch event method of heritable web displaying control.
9. device as claimed in claim 8, be Android2.3.x or more under the situation of older version in the operating system of electronic equipment wherein, described webpage literal scaling arranges module and is suitable for from described web displaying control reflection literal scaling object, and gives described literal scaling object with the value of the demonstration scaling of web displaying control; Perhaps
Operating system at electronic equipment is Android4.0 or upgrades under the situation of version, described webpage literal scaling arranges module and is suitable for from described convergent-divergent manager object reflection literal scaling object, and gives described literal scaling object with the value of the demonstration scaling of web displaying control.
10. device as claimed in claim 8, wherein said touch point judge module is suitable for utilizing ACTION_POINTER_UP object or ACTION_POINTER_n_UP object to judge whether to trigger the touch event method for unclamping n the touch point of the n-1 in the touch point.
CN201310268150.6A 2013-06-28 2013-06-28 Method and device for resizing webpages on electronic equipment Active CN103345497B (en)

Priority Applications (4)

Application Number Priority Date Filing Date Title
CN201310268150.6A CN103345497B (en) 2013-06-28 2013-06-28 Method and device for resizing webpages on electronic equipment
PCT/CN2014/074455 WO2014206125A1 (en) 2013-06-28 2014-03-31 Method and device for aligning zoomed webpage on electronic device
US14/901,512 US10061494B2 (en) 2013-06-28 2014-03-31 Method and device for webpage zooming on electronic apparatus
PCT/CN2014/074454 WO2014206124A1 (en) 2013-06-28 2014-03-31 Method and device for performing zooming on webpage on electronic device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201310268150.6A CN103345497B (en) 2013-06-28 2013-06-28 Method and device for resizing webpages on electronic equipment

Publications (2)

Publication Number Publication Date
CN103345497A true CN103345497A (en) 2013-10-09
CN103345497B CN103345497B (en) 2017-05-03

Family

ID=49280292

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201310268150.6A Active CN103345497B (en) 2013-06-28 2013-06-28 Method and device for resizing webpages on electronic equipment

Country Status (1)

Country Link
CN (1) CN103345497B (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103955469A (en) * 2014-03-28 2014-07-30 北京奇虎科技有限公司 Method and device for page scaling in browser
WO2014206124A1 (en) * 2013-06-28 2014-12-31 北京奇虎科技有限公司 Method and device for performing zooming on webpage on electronic device
WO2016066032A1 (en) * 2014-10-31 2016-05-06 广州市动景计算机科技有限公司 Web page reformatting method and apparatus, computing device and non-transitory machine readable storage medium
CN110536005A (en) * 2019-08-16 2019-12-03 维沃移动通信有限公司 A kind of object display adjusting method and terminal

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090109243A1 (en) * 2007-10-25 2009-04-30 Nokia Corporation Apparatus and method for zooming objects on a display
CN102314502A (en) * 2011-09-01 2012-01-11 百度在线网络技术(北京)有限公司 Method and equipment for displaying webpage main content on mobile terminal
CN102637198A (en) * 2012-02-28 2012-08-15 优视科技有限公司 Realization method and device of webpage content display, browser and mobile terminal
CN102779167A (en) * 2012-06-21 2012-11-14 北京奇虎科技有限公司 Method and system for displaying webpage in mobile terminal

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090109243A1 (en) * 2007-10-25 2009-04-30 Nokia Corporation Apparatus and method for zooming objects on a display
CN102314502A (en) * 2011-09-01 2012-01-11 百度在线网络技术(北京)有限公司 Method and equipment for displaying webpage main content on mobile terminal
CN102637198A (en) * 2012-02-28 2012-08-15 优视科技有限公司 Realization method and device of webpage content display, browser and mobile terminal
CN102779167A (en) * 2012-06-21 2012-11-14 北京奇虎科技有限公司 Method and system for displaying webpage in mobile terminal

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2014206124A1 (en) * 2013-06-28 2014-12-31 北京奇虎科技有限公司 Method and device for performing zooming on webpage on electronic device
US10061494B2 (en) 2013-06-28 2018-08-28 Beijing Qihoo Technology Company Limited Method and device for webpage zooming on electronic apparatus
CN103955469A (en) * 2014-03-28 2014-07-30 北京奇虎科技有限公司 Method and device for page scaling in browser
WO2016066032A1 (en) * 2014-10-31 2016-05-06 广州市动景计算机科技有限公司 Web page reformatting method and apparatus, computing device and non-transitory machine readable storage medium
CN110536005A (en) * 2019-08-16 2019-12-03 维沃移动通信有限公司 A kind of object display adjusting method and terminal
CN110536005B (en) * 2019-08-16 2021-09-03 维沃移动通信有限公司 Object display adjustment method and terminal

Also Published As

Publication number Publication date
CN103345497B (en) 2017-05-03

Similar Documents

Publication Publication Date Title
CN103336817A (en) Method and device for webpage zoom on electronic equipment
CN103324734A (en) Method and device for webpage zooming on electronic equipment
KR102118223B1 (en) Cross window animation
CN104268251A (en) Playing method and device of video elements in web page
CN103440107A (en) Method and device for processing touch operation of electronic device
CN103246578A (en) Method and browser for processing collapse of application software
CN104268250A (en) Playing method and device of video elements in web page
CN104331474A (en) Page processing method and device
CN104063484A (en) Webpage presenting method and device and electronic device
CN103345497A (en) Method and device for resizing webpages on electronic equipment
CN105260433A (en) Webpage content collecting method and electronic device
CN103150357A (en) Browser, system and method capable of realizing compare search
CN105183724A (en) Translation method and electronic device
CN110262749B (en) Webpage operation method, device, container, equipment and medium
CN106599257B (en) Method for realizing page shortcut and electronic equipment
CN102929953A (en) Webpage picture display device and method
CN102929952A (en) Web page image display device and method
CN105279245A (en) Method for collecting contents on webpage and electronic device
CN102819556A (en) Method and device for viewing pictures
CN106598617A (en) Method for setting webpage shortcut, and electronic equipment
CN102968252A (en) Page backward/forward method and equipment
CN105243057A (en) Method for translating web page contents and electronic device.
CN105511737A (en) Method for managing menu options on web page and electronic device
CN105242848A (en) Method for translating texts on web page and electronic device
CA2868991C (en) Associating content with a graphical interface window using a fling gesture

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20220727

Address after: 300450 No. 9-3-401, No. 39, Gaoxin 6th Road, Binhai Science Park, Binhai New Area, Tianjin

Patentee after: 3600 Technology Group Co.,Ltd.

Address before: 100088 room 112, block D, 28 new street, new street, Xicheng District, Beijing (Desheng Park)

Patentee before: BEIJING QIHOO TECHNOLOGY Co.,Ltd.

Patentee before: Qizhi software (Beijing) Co.,Ltd.

TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20230711

Address after: 1765, floor 17, floor 15, building 3, No. 10 Jiuxianqiao Road, Chaoyang District, Beijing 100015

Patentee after: Beijing Hongxiang Technical Service Co.,Ltd.

Address before: 300450 No. 9-3-401, No. 39, Gaoxin 6th Road, Binhai Science Park, Binhai New Area, Tianjin

Patentee before: 3600 Technology Group Co.,Ltd.

CP03 Change of name, title or address

Address after: 1765, floor 17, floor 15, building 3, No. 10 Jiuxianqiao Road, Chaoyang District, Beijing 100015

Patentee after: Beijing 360 Zhiling Technology Co.,Ltd.

Country or region after: China

Address before: 1765, floor 17, floor 15, building 3, No. 10 Jiuxianqiao Road, Chaoyang District, Beijing 100015

Patentee before: Beijing Hongxiang Technical Service Co.,Ltd.

Country or region before: China