CN106202217A - Webpage link access method and device and mobile terminal - Google Patents
Webpage link access method and device and mobile terminal Download PDFInfo
- Publication number
- CN106202217A CN106202217A CN201610490574.0A CN201610490574A CN106202217A CN 106202217 A CN106202217 A CN 106202217A CN 201610490574 A CN201610490574 A CN 201610490574A CN 106202217 A CN106202217 A CN 106202217A
- Authority
- CN
- China
- Prior art keywords
- content
- link
- desktop
- character string
- pasteboard
- 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
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/90—Details of database functions independent of the retrieved data types
- G06F16/95—Retrieval from the web
- G06F16/955—Retrieval from the web using information identifiers, e.g. uniform resource locators [URL]
- G06F16/9558—Details of hyperlinks; Management of linked annotations
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Databases & Information Systems (AREA)
- Data Mining & Analysis (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Information Transfer Between Computers (AREA)
Abstract
本发明实施例提供一种网页链接访问方法,包括:通过隐藏于系统桌面的窗口小部件监听系统发出的返回桌面广播;当监听到系统发出的返回桌面广播时,读取系统粘贴板中的内容,并判断所述粘贴板的内容中是否包含字符串;当所述粘贴板的内容中包含字符串时,判断所述字符串中是否包含网页链接;当所述字符串中包含网页链接时,从所述字符串中提取所述网页链接,并调用系统浏览器打开所述网页链接。另,本发明实施例还提供一种网页链接访问装置及移动终端。所述网页链接访问方法及装置可以实现粘贴板中的网页链接的自动识别和访问。
An embodiment of the present invention provides a webpage link access method, including: monitoring the return to desktop broadcast sent by the system through a widget hidden on the system desktop; when listening to the return to desktop broadcast sent by the system, reading the content in the system pasteboard , and judge whether the content of the pasteboard contains a character string; when the content of the pasteboard contains a character string, judge whether the character string contains a web page link; when the character string contains a web page link, The web page link is extracted from the character string, and the system browser is invoked to open the web page link. In addition, the embodiment of the present invention also provides a web page link access device and a mobile terminal. The method and device for accessing webpage links can realize automatic identification and access of webpage links in the pasteboard.
Description
技术领域technical field
本发明涉及计算机软件领域,尤其涉及一种网页链接访问方法、装置及移动终端。The invention relates to the field of computer software, in particular to a web page link access method, device and mobile terminal.
背景技术Background technique
目前,在手机、平板电脑等终端的系统中,没有托盘程序去识别网页链接而打开网页。因此,当用户打开一个网页时,需要进行先复制网页链接,然后返回桌面打开浏览器,点击浏览器地址栏,再粘贴网页链接,最后通过点击访问,在浏览器显示界面中打开网页链。也就是说,在访问网页链接映射的网页时,需要执行包括复制、返回桌面、打开浏览器、点击地址栏、粘贴以及点击访问等多个操作流程,使得访问网页链接的流程较为繁琐、访问所需的时间较长,降低了终端的用户体验。At present, in the systems of terminals such as mobile phones and tablet computers, there is no tray program to identify webpage links and open webpages. Therefore, when a user opens a webpage, he needs to first copy the webpage link, then return to the desktop to open the browser, click on the address bar of the browser, paste the webpage link, and finally open the webpage link in the browser display interface by clicking Access. That is to say, when accessing the webpage mapped by the webpage link, it is necessary to perform multiple operation procedures including copying, returning to the desktop, opening the browser, clicking the address bar, pasting, and clicking to access, which makes the process of accessing the webpage link more cumbersome, and accessing all It takes a long time, which reduces the user experience of the terminal.
发明内容Contents of the invention
为解决现有技术中所存在的上述问题,本发明提供一种网页链接访问方法、装置及移动终端,通过监听终端系统发出的返回桌面广播,自动读取系统粘贴板中的内容,并在判断所述内容中存在网页链接时,调用系统浏览器打开所述网页链接,从而简化网页链接访问时的操作,提升终端的用户体验。In order to solve the above-mentioned problems existing in the prior art, the present invention provides a web page link access method, device and mobile terminal, by listening to the return desktop broadcast sent by the terminal system, automatically reading the content in the system pasteboard, and judging When there is a webpage link in the content, the system browser is invoked to open the webpage link, thereby simplifying the operation when accessing the webpage link and improving the user experience of the terminal.
一种网页链接访问方法,包括:A method for accessing a webpage link, comprising:
通过隐藏于系统桌面的窗口小部件监听系统发出的返回桌面广播;Monitor the return to desktop broadcast sent by the system through a widget hidden on the system desktop;
当监听到系统发出的返回桌面广播时,读取系统粘贴板中的内容,并判断所述粘贴板的内容中是否包含字符串;When listening to the return desktop broadcast sent by the system, read the content in the system pasteboard, and judge whether the content of the pasteboard contains a character string;
当所述粘贴板的内容中包含字符串时,判断所述字符串中是否包含网页链接;When the content of the pasteboard contains a character string, determine whether the character string contains a web page link;
当所述字符串中包含网页链接时,从所述字符串中提取所述网页链接,并调用系统浏览器打开所述网页链接。When the string contains a webpage link, the webpage link is extracted from the string, and a system browser is invoked to open the webpage link.
可选地,所述通过隐藏于系统桌面的窗口小部件监听系统发出的返回桌面广播之前,所述方法还包括:Optionally, before listening to the return-to-desktop broadcast sent by the system through a widget hidden on the system desktop, the method further includes:
建立窗口小部件,并将所述窗口小部件隐藏于系统桌面;Create a widget, and hide the widget on the system desktop;
其中,所述窗口小部件中包含用于接收系统发出的返回桌面广播的广播接收函数和用于读取系统粘贴板的内容读取函数。Wherein, the widget includes a broadcast receiving function for receiving the return-to-desktop broadcast sent by the system and a content reading function for reading the system clipboard.
可选地,所述当监听到系统发出的返回桌面广播时,读取系统粘贴板中的内容,包括:Optionally, when listening to the return to desktop broadcast sent by the system, reading the content in the system clipboard includes:
当所述广播接收函数接收到系统发出的返回桌面广播时,调用所述内容读取函数,并通过所述内容读取函数读取系统粘贴板中的内容。When the broadcast receiving function receives the return-to-desktop broadcast sent by the system, it calls the content reading function, and reads the content in the system clipboard through the content reading function.
可选地,所述判断所述字符串中是否包含网页链接,包括:Optionally, the judging whether the character string contains a webpage link includes:
从所述粘贴板的内容中包含的字符串中提取英文字符串;extracting English character strings from the character strings contained in the contents of the pasteboard;
判断所述英文字符串的格式是否与网页链接格式匹配;Judging whether the format of the English character string matches the format of the web page link;
若所述英文字符串的格式与网页链接格式匹配,则判断所述字符串中包含网页链接。If the format of the English character string matches the format of the web page link, it is determined that the character string contains a web page link.
可选地,所述从所述字符串中提取所述网页链接之后,调用系统浏览器打开所述网页链接之前,所述方法还包括:Optionally, after extracting the webpage link from the character string, before calling the system browser to open the webpage link, the method further includes:
通过提示窗口提示用户是否需要打开所述网页链接;Prompting the user through a prompt window whether to open the webpage link;
通过所述提示窗口接收用户同意打开所述网页链接的指令。An instruction that the user agrees to open the web page link is received through the prompt window.
一种网页链接访问装置,包括:A webpage link access device, comprising:
广播监听模块,用于通过隐藏于系统桌面的窗口小部件监听系统发出的返回桌面广播;The broadcast monitoring module is used to monitor the return desktop broadcast sent by the system through the widget hidden on the system desktop;
内容读取模块,用于在监听到系统发出的返回桌面广播时,读取系统粘贴板中的内容,并判断所述粘贴板的内容中是否包含字符串;The content reading module is used to read the content in the system pasteboard when listening to the return desktop broadcast sent by the system, and determine whether the content of the pasteboard contains a character string;
链接识别模块,用于在所述粘贴板的内容中包含字符串时,判断所述字符串中是否包含网页链接;A link identification module, configured to determine whether the string contains a webpage link when the content of the pasteboard contains a string;
链接提取模块,用于在所述字符串中包含网页链接时,从所述字符串中提取所述网页链接,并调用系统浏览器打开所述网页链接。The link extracting module is used to extract the webpage link from the string when the webpage link is contained in the string, and invoke the system browser to open the webpage link.
可选地,所述装置还包括:Optionally, the device also includes:
部件建立模块,用于建立窗口小部件,并将所述窗口小部件隐藏于系统桌面;A component creation module, configured to create a widget and hide the widget on the system desktop;
其中,所述窗口小部件中包含用于接收系统发出的返回桌面广播的广播接收函数和用于读取系统粘贴板的内容读取函数。Wherein, the widget includes a broadcast receiving function for receiving the return-to-desktop broadcast sent by the system and a content reading function for reading the system clipboard.
可选地,所述内容读取模块,还用于在所述广播接收函数接收到系统发出的返回桌面广播时,调用所述内容读取函数,并通过所述内容读取函数读取系统粘贴板中的内容。Optionally, the content reading module is further configured to call the content reading function when the broadcast receiving function receives the return-to-desktop broadcast sent by the system, and read the pasted content of the system through the content reading function. content in the board.
可选地,所述链接识别模块包括:Optionally, the link identification module includes:
字符串提取子模块,用于从所述粘贴板的内容中包含的字符串中提取英文字符串;A string extraction submodule is used to extract an English string from the string contained in the content of the pasteboard;
网页链接匹配子模块,用于判断所述英文字符串的格式是否与网页链接格式匹配;并在所述英文字符串的格式与网页链接格式匹配时,判断所述字符串中包含网页链接。The webpage link matching sub-module is used to judge whether the format of the English character string matches the format of the webpage link; and when the format of the English character string matches the format of the webpage link, determine whether the character string contains a webpage link.
可选地,所述装置还包括:Optionally, the device also includes:
用户提示模块,用于通过提示窗口提示用户是否需要打开所述网页链接;并通过所述提示窗口接收用户同意打开所述网页链接的指令。The user prompting module is used to prompt the user through the prompt window whether to open the web page link; and receive an instruction from the user agreeing to open the web page link through the prompt window.
一种移动终端,包括:壳体、处理器、存储器、电路板和电源电路,其中,所述电路板安置在所述壳体围成的空间内部,所述处理器和所述存储器设置在所述电路板上;所述电源电路,用于为所述移动终端的各个电路或器件供电;所述存储器用于存储可执行程序代码;所述处理器通过读取所述存储器中存储的可执行程序代码来运行与所述可执行程序代码对应的程序,以用于执行以下步骤:A mobile terminal, comprising: a housing, a processor, a memory, a circuit board, and a power supply circuit, wherein the circuit board is placed inside the space enclosed by the housing, and the processor and the memory are arranged in the on the circuit board; the power supply circuit is used to supply power to each circuit or device of the mobile terminal; the memory is used to store executable program code; the processor reads the executable program code stored in the memory program code to run a program corresponding to the executable program code for performing the following steps:
通过隐藏于系统桌面的窗口小部件监听系统发出的返回桌面广播;Monitor the return to desktop broadcast sent by the system through a widget hidden on the system desktop;
当监听到系统发出的返回桌面广播时,读取系统粘贴板中的内容,并判断所述粘贴板的内容中是否包含字符串;When listening to the return desktop broadcast sent by the system, read the content in the system pasteboard, and judge whether the content of the pasteboard contains a character string;
当所述粘贴板的内容中包含字符串时,判断所述字符串中是否包含网页链接;When the content of the pasteboard contains a character string, determine whether the character string contains a web page link;
当所述字符串中包含网页链接时,从所述字符串中提取所述网页链接,并调用系统浏览器打开所述网页链接。When the string contains a webpage link, the webpage link is extracted from the string, and a system browser is invoked to open the webpage link.
所述网页链接访问方法、装置及移动终端通过在系统桌面设置隐藏的窗口小部件,并通过所述窗口小部件监听终端系统发出的返回桌面广播,在监听到所述返回桌面广播时,自动读取粘贴板中的内容,并在判断所述内容中存在网页链接时,提取所述网页链接,并调用系统浏览器打开所述网页链接,从而可以有效简化网页链接访问时的操作步骤,提升所述移动终端的用户体验。The web page link access method, device and mobile terminal set hidden widgets on the system desktop, and monitor the return desktop broadcast sent by the terminal system through the widgets, and automatically read the return desktop broadcast when listening to the return desktop broadcast. Get the content in the pasteboard, and when it is judged that there is a webpage link in the content, extract the webpage link, and call the system browser to open the webpage link, thereby effectively simplifying the operation steps when accessing the webpage link, and improving all Describe the user experience of mobile terminals.
附图说明Description of drawings
为了更清楚地说明本发明实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the following will briefly introduce the drawings that need to be used in the description of the embodiments or the prior art. Obviously, the accompanying drawings in the following description are only These are some embodiments of the present invention. Those skilled in the art can also obtain other drawings based on these drawings without creative work.
图1是本发明实施例提供的网页链接访问方法的第一流程示意图;FIG. 1 is a schematic flow chart of a first method for accessing a webpage link provided by an embodiment of the present invention;
图2是本发明实施例提供的网页链接访问方法的第二流程示意图;FIG. 2 is a second schematic flowchart of a method for accessing a webpage link provided by an embodiment of the present invention;
图3是本发明实施例提供的网页链接访问方法的第三流程示意图;Fig. 3 is a third schematic flowchart of a method for accessing a webpage link provided by an embodiment of the present invention;
图4是本发明实施例提供的网页链接访问装置的第一结构示意图;FIG. 4 is a schematic diagram of a first structure of a device for accessing a webpage link provided by an embodiment of the present invention;
图5是本发明实施例提供的网页链接访问装置的第二结构示意图;Fig. 5 is a second structural schematic diagram of a device for accessing a webpage link provided by an embodiment of the present invention;
图6是本发明实施例提供的移动终端的结构示意图。Fig. 6 is a schematic structural diagram of a mobile terminal provided by an embodiment of the present invention.
具体实施方式detailed description
下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。The following will clearly and completely describe the technical solutions in the embodiments of the present invention with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only some, not all, embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by persons of ordinary skill in the art without making creative efforts belong to the protection scope of the present invention.
请参阅图1,本发明第一实施例提供一种网页链接访问方法,包括:Referring to Fig. 1, the first embodiment of the present invention provides a method for accessing webpage links, including:
步骤S12:通过隐藏于系统桌面的窗口小部件监听系统发出的返回桌面广播;Step S12: monitor the return-to-desktop broadcast sent by the system through a widget hidden on the system desktop;
步骤S14:当监听到系统发出的返回桌面广播时,读取系统粘贴板中的内容,并判断所述粘贴板的内容中是否包含字符串;Step S14: When listening to the return to desktop broadcast sent by the system, read the content in the system pasteboard, and judge whether the content in the pasteboard contains a character string;
步骤S16:当所述粘贴板的内容中包含字符串时,判断所述字符串中是否包含网页链接;Step S16: When the content of the pasteboard contains a character string, determine whether the character string contains a webpage link;
步骤S18:当所述字符串中包含网页链接时,从所述字符串中提取所述网页链接,并调用系统浏览器打开所述网页链接。Step S18: When the string contains a webpage link, extract the webpage link from the string, and call a system browser to open the webpage link.
本实施例中,所述窗口小部件可以对系统发出的返回桌面广播进行实时监听。当系统执行返回桌面操作后,系统会发出返回桌面广播。所述窗口小部件在接收到系统发出的所述返回桌面广播后,从系统的粘贴板中读取当前复制的内容,并判断所述粘贴板的内容中是否包含字符串。当所述粘贴板的内容中包含字符串时,判断所述字符串中是否包含网页链接。若所述字符串中包含网页链接,则从所述字符串中提取所述网页链接,并调用系统浏览器打开所述网页链接,从而实现粘贴板中的网页链接的自动识别和访问,简化网页链接访问时的操作步骤。In this embodiment, the widget can monitor the return to desktop broadcast sent by the system in real time. When the system executes the return to desktop operation, the system will send a return to desktop broadcast. After receiving the return-to-desktop broadcast sent by the system, the widget reads the currently copied content from the system's pasteboard, and judges whether the content of the pasteboard contains a character string. When the content of the clipboard contains a character string, it is judged whether the character string contains a web page link. If the webpage link is included in the character string, then extract the webpage link from the character string, and call the system browser to open the webpage link, thereby realizing automatic identification and access of the webpage link in the pasteboard, simplifying the webpage Operation steps when accessing the link.
请参阅图2,结合第一实施例,所述通过隐藏于系统桌面的窗口小部件监听系统发出的返回桌面广播之前,所述方法还包括:Please refer to Fig. 2, in conjunction with the first embodiment, before the widget hidden on the system desktop monitors the return to desktop broadcast sent by the system, the method further includes:
步骤S11:建立窗口小部件,并将所述窗口小部件隐藏于系统桌面。Step S11: Create a widget, and hide the widget on the system desktop.
在本实施例中,所述窗口小部件为widget小部件。所述widget小部件在系统桌面上不进行布局绘制,即系统桌面上不显示所述widget小部件的图形界面,只是活动于系统进程中,从而达到隐藏于系统桌面的效果。其中,所述widget小部件中包含用于接收系统发出的返回桌面广播的广播接收函数和用于读取系统粘贴板的内容读取函数。所述广播接收函数始终活动与系统进程中,并实时监听系统是否发出返回桌面广播。In this embodiment, the widget is a widget widget. The widget does not perform layout drawing on the system desktop, that is, the graphical interface of the widget is not displayed on the system desktop, but is only active in the system process, thereby achieving the effect of being hidden on the system desktop. Wherein, the widget includes a broadcast receiving function for receiving the broadcast sent by the system to return to the desktop and a content reading function for reading the system pasteboard. The broadcast receiving function is always active in the system process, and monitors in real time whether the system sends out a return to desktop broadcast.
在一种实施方式中,所述当监听到系统发出的返回桌面广播时,读取系统粘贴板中的内容,包括:In one embodiment, when listening to the return to desktop broadcast sent by the system, reading the content in the system clipboard includes:
当所述广播接收函数接收到系统发出的返回桌面广播时,调用所述内容读取函数,并通过所述内容读取函数读取系统粘贴板中的内容。When the broadcast receiving function receives the return-to-desktop broadcast sent by the system, it calls the content reading function, and reads the content in the system clipboard through the content reading function.
可以理解,若所述内容读取函数读取系统粘贴板中的内容为空,则结束当前监听流程,并重新启动下一轮的返回桌面广播监听。若所述内容读取函数读取系统粘贴板中的内容不为空,则判断所述粘贴板的内容中是否包含字符串,若所述粘贴板的内容中不包含字符串,则结束当前监听流程,并重新启动下一轮的返回桌面广播监听;若所述粘贴板的内容中包含字符串,则从所述粘贴板的内容中提取出所述字符串,以便进一步判断所述字符串中是否包含网页链接。It can be understood that if the content reading function reads that the content in the system clipboard is empty, the current monitoring process is ended, and the next round of returning to the desktop broadcast monitoring is restarted. If the content reading function reads that the content in the system pasteboard is not empty, then judge whether the content of the pasteboard contains a string, if the content of the pasteboard does not contain a string, then end the current monitoring process, and restart the next round of returning to the desktop broadcast monitoring; if the content of the pasteboard contains a character string, then extract the character string from the content of the pasteboard, so as to further judge the character string in the character string Whether to include web links.
可以理解,所述系统粘贴板中的内容可以只包括网页链接,也可以同时包括非网页链接的文字内容和网页链接。对于仅包含网页链接的内容,包含的网页链接即为读取粘贴板中的内容得到的网页链接,对于同时包含网页链接以及非网页链接的文字的内容,则需要进一步从中提取出网页链接。这样,用户在复制网页链接时,可以无需绝对精确地选取网页链接后进行复制,只需在选取的复制内容中包含有网页链接即可,从而可以有效节约选取网页链接所需的时间。It can be understood that the content in the system pasteboard may only include webpage links, or may include non-webpage link text content and webpage links at the same time. For the content containing only webpage links, the contained webpage links are the webpage links obtained by reading the content in the pasteboard. For the content containing both webpage links and non-webpage link texts, it is necessary to further extract the webpage links therefrom. In this way, when copying a webpage link, the user does not need to select the webpage link absolutely accurately and then copy it, and only needs to include the webpage link in the selected copied content, thereby effectively saving the time required for selecting the webpage link.
请参阅图3,在一种实施方式中,所述判断所述字符串中是否包含网页链接,包括:Please refer to Fig. 3, in an implementation manner, said judging whether the string contains a webpage link includes:
步骤S161:从所述粘贴板的内容中包含的字符串中提取英文字符串;Step S161: extracting English character strings from the character strings contained in the contents of the pasteboard;
步骤S163:判断所述英文字符串的格式是否与网页链接格式匹配;Step S163: judging whether the format of the English character string matches the format of the web page link;
步骤S165:若所述英文字符串的格式与网页链接格式匹配,则判断所述字符串中包含网页链接。Step S165: If the format of the English character string matches the format of the web page link, then determine that the character string contains a web page link.
具体地,由于所述粘贴板的内容可能包含中文、英文、特殊符号等,需要进行分析以确定其中是否包含网页链接。由于网页链接通常为由英文数字和特殊符号组成的字符串,因此,首先通过从所述粘贴板的内容中包含的字符串中提取英文字符串,进而通过判断所述英文字符串的格式是否与网页链接格式匹配来判断所述粘贴板的内容中是否包含网页链接。可以理解,从所述粘贴板的内容中包含的字符串中提取英文字符串可以包含连续的英文、数字和特殊字符中的一种或多种的组合。其中,所述判断所述英文字符串的格式是否与网页链接格式匹配可以时通过正则表达式来判断。Specifically, because the content of the pasteboard may contain Chinese, English, special symbols, etc., it needs to be analyzed to determine whether it contains webpage links. Since webpage links are usually strings composed of English numbers and special symbols, firstly, by extracting the English strings from the strings contained in the content of the pasteboard, and then by judging whether the format of the English strings is consistent with Matching the format of the webpage link to determine whether the content of the pasteboard contains the webpage link. It can be understood that the extraction of English character strings from the character strings contained in the contents of the clipboard may include one or more combinations of continuous English characters, numbers and special characters. Wherein, the judging whether the format of the English character string matches the webpage link format can be judged by regular expressions.
在一种实施方式中,所述从所述字符串中提取所述网页链接之后,调用系统浏览器打开所述网页链接之前,所述方法还包括:In one embodiment, after extracting the webpage link from the character string, before invoking a system browser to open the webpage link, the method further includes:
通过提示窗口提示用户是否需要打开所述网页链接;Prompting the user through a prompt window whether to open the webpage link;
通过所述提示窗口接收用户同意打开所述网页链接的指令。An instruction that the user agrees to open the web page link is received through the prompt window.
可以理解,当用户从一个应用中复制包含网页链接的内容并返回桌面后,可能并不一定是要去浏览器中访问所述网页链接,也可能是要将所述复制的内容通过即时通信软件分享出去。因此,在从所述字符串中提取到所述网页链接之后,调用系统浏览器打开所述网页链接之前,还可以通过提示窗口提示用户是否需要打开所述网页链接。其中,所述提示窗口可以包括供用户选择是否要打开所述网页链接的选项。当接收到用户通过所述提示窗口输入的同意打开所述网页链接的指令时,进而调用系统浏览器打开所述网页链接;当接收到用户通过所述提示窗口输入的拒绝打开所述网页链接的指令时,则结束当前监听流程,并重新启动下一轮的返回桌面广播监听。It can be understood that when the user copies the content containing the web page link from an application and returns to the desktop, it may not necessarily be to visit the web page link in the browser, but it may also be to pass the copied content through the instant messaging software Share it out. Therefore, after the webpage link is extracted from the character string, before calling the system browser to open the webpage link, a prompt window may also be used to prompt the user whether to open the webpage link. Wherein, the prompt window may include an option for the user to choose whether to open the webpage link. When receiving the instruction that the user agrees to open the webpage link by the input of the prompt window, the system browser is called to open the webpage link; command, the current monitoring process is ended, and the next round of return to desktop broadcast monitoring is restarted.
请参阅图4,本发明第二实施例提供一种网页链接访问装置20,包括:Referring to Fig. 4, the second embodiment of the present invention provides a web page link access device 20, including:
广播监听模块22,用于通过隐藏于系统桌面的窗口小部件监听系统发出的返回桌面广播;The broadcast monitoring module 22 is used for returning to the desktop broadcast sent by the monitoring system through widgets hidden in the system desktop;
内容读取模块24,用于在监听到系统发出的返回桌面广播时,读取系统粘贴板中的内容,并判断所述粘贴板的内容中是否包含字符串;The content reading module 24 is used for reading the content in the system pasteboard when listening to the return desktop broadcast sent by the system, and judging whether the content of the pasteboard contains a character string;
链接识别模块26,用于在所述粘贴板的内容中包含字符串时,判断所述字符串中是否包含网页链接;The link identification module 26 is used to determine whether the character string contains a web page link when the content of the pasteboard contains a character string;
链接提取模块28,用于在所述字符串中包含网页链接时,从所述字符串中提取所述网页链接,并调用系统浏览器打开所述网页链接。The link extraction module 28 is configured to extract the web page link from the character string when the web page link is included in the character string, and call a system browser to open the web page link.
请参阅图5,在一种实施方式中,提供一种网页链接访问装置20’,其相对于所述网页链接访问装置20,还包括:Please refer to Fig. 5, in one embodiment, provide a kind of web page link access device 20 ', it also includes with respect to described web page link access device 20:
部件建立模块21,用于建立窗口小部件,并将所述窗口小部件隐藏于系统桌面;Component building module 21, used to set up widgets, and hide said widgets on the system desktop;
其中,所述窗口小部件中包含用于接收系统发出的返回桌面广播的广播接收函数和用于读取系统粘贴板的内容读取函数。Wherein, the widget includes a broadcast receiving function for receiving the return-to-desktop broadcast sent by the system and a content reading function for reading the system clipboard.
在一种实施方式中,所述内容读取模块24,还用于在所述广播接收函数接收到系统发出的返回桌面广播时,调用所述内容读取函数,并通过所述内容读取函数读取系统粘贴板中的内容。In one embodiment, the content reading module 24 is also configured to call the content reading function when the broadcast receiving function receives the return-to-desktop broadcast sent by the system, and use the content reading function to Read the contents of the system pasteboard.
请参阅图5,在一种实施方式中,所述链接识别模块26包括:Referring to FIG. 5, in one implementation manner, the link identification module 26 includes:
字符串提取子模块261,用于从所述粘贴板的内容中包含的字符串中提取英文字符串;String extraction submodule 261, used to extract English character strings from the character strings contained in the content of the pasteboard;
网页链接匹配子模块263,用于判断所述英文字符串的格式是否与网页链接格式匹配;并在所述英文字符串的格式与网页链接格式匹配时,判断所述字符串中包含网页链接。The webpage link matching sub-module 263 is used to determine whether the format of the English character string matches the format of the webpage link; and when the format of the English character string matches the format of the webpage link, determine whether the character string contains a webpage link.
请参阅图5,在一种实施方式中,所述网页链接访问装置20’还包括:Please refer to Fig. 5, in one embodiment, described web page link access device 20' also includes:
用户提示模块29,用于通过提示窗口提示用户是否需要打开所述网页链接;并通过所述提示窗口接收用户同意打开所述网页链接的指令。The user prompting module 29 is configured to prompt the user through a prompt window whether to open the webpage link; and receive an instruction from the user agreeing to open the webpage link through the prompt window.
可以理解,本实施例中所述的网页链接访问装置20、20’的各个模块的功能及其具体实现还可以参照图1-图3所示方法实施例中的相关描述,此处不再赘述。It can be understood that the functions and specific implementations of the various modules of the web page link access devices 20, 20' described in this embodiment can also refer to the relevant descriptions in the method embodiments shown in FIGS. 1-3 , and will not be repeated here. .
请参阅图6,本发明第三实施例提供一种移动终端30,包括:壳体(图未示)、处理器31、存储器33、电路板(图未示)和电源电路35,其中,所述电路板安置在所述壳体围成的空间内部,所述处理器31和所述存储器33设置在所述电路板上,并相互电性连接;所述电源电路35,用于为所述移动终端30的各个电路或器件供电;所述存储器33用于存储可执行程序代码;所述处理器31通过读取所述存储器33中存储的可执行程序代码来运行与所述可执行程序代码对应的程序,以用于执行以下操作:Referring to FIG. 6, the third embodiment of the present invention provides a mobile terminal 30, including: a housing (not shown), a processor 31, a memory 33, a circuit board (not shown) and a power circuit 35, wherein the The circuit board is placed inside the space surrounded by the housing, the processor 31 and the memory 33 are arranged on the circuit board, and are electrically connected to each other; the power supply circuit 35 is used for the The various circuits or devices of the mobile terminal 30 are powered; the memory 33 is used to store executable program codes; the processor 31 runs and the executable program codes by reading the executable program codes stored in the memory 33 Corresponding programs to perform the following actions:
通过隐藏于系统桌面的窗口小部件监听系统发出的返回桌面广播;Monitor the return to desktop broadcast sent by the system through a widget hidden on the system desktop;
当监听到系统发出的返回桌面广播时,读取系统粘贴板中的内容,并判断所述粘贴板的内容中是否包含字符串;When listening to the return desktop broadcast sent by the system, read the content in the system pasteboard, and judge whether the content of the pasteboard contains a character string;
当所述粘贴板的内容中包含字符串时,判断所述字符串中是否包含网页链接;When the content of the pasteboard contains a character string, determine whether the character string contains a web page link;
当所述字符串中包含网页链接时,从所述字符串中提取所述网页链接,并调用系统浏览器打开所述网页链接。When the string contains a webpage link, the webpage link is extracted from the string, and a system browser is invoked to open the webpage link.
在一种实施方式中,所述通过隐藏于系统桌面的窗口小部件监听系统发出的返回桌面广播之前,所述操作还包括:In one embodiment, before listening to the return-to-desktop broadcast sent by the system through a widget hidden on the system desktop, the operation further includes:
建立窗口小部件,并将所述窗口小部件隐藏于系统桌面;Create a widget, and hide the widget on the system desktop;
其中,所述窗口小部件中包含用于接收系统发出的返回桌面广播的广播接收函数和用于读取系统粘贴板的内容读取函数。Wherein, the widget includes a broadcast receiving function for receiving the return-to-desktop broadcast sent by the system and a content reading function for reading the system clipboard.
在一种实施方式中,所述当监听到系统发出的返回桌面广播时,读取系统粘贴板中的内容,包括:In one embodiment, when listening to the return to desktop broadcast sent by the system, reading the content in the system clipboard includes:
当所述广播接收函数接收到系统发出的返回桌面广播时,调用所述内容读取函数,并通过所述内容读取函数读取系统粘贴板中的内容。When the broadcast receiving function receives the return-to-desktop broadcast sent by the system, it calls the content reading function, and reads the content in the system clipboard through the content reading function.
在一种实施方式中,所述判断所述字符串中是否包含网页链接,包括:In one embodiment, the judging whether the character string contains a webpage link includes:
从所述粘贴板的内容中包含的字符串中提取英文字符串;extracting English character strings from the character strings contained in the contents of the pasteboard;
判断所述英文字符串的格式是否与网页链接格式匹配;Judging whether the format of the English character string matches the format of the web page link;
若所述英文字符串的格式与网页链接格式匹配,则判断所述字符串中包含网页链接。If the format of the English character string matches the format of the web page link, it is determined that the character string contains a web page link.
在一种实施方式中,所述从所述字符串中提取所述网页链接之后,调用系统浏览器打开所述网页链接之前,所述操作还包括:In one embodiment, after extracting the webpage link from the character string, before invoking the system browser to open the webpage link, the operation further includes:
通过提示窗口提示用户是否需要打开所述网页链接;Prompting the user through a prompt window whether to open the webpage link;
通过所述提示窗口接收用户同意打开所述网页链接的指令。An instruction that the user agrees to open the web page link is received through the prompt window.
可以理解,所述处理器31执行的上述操作的每个步骤及其具体实现还可以参照图1-图3所示方法实施例中的相关描述,此处不再赘述。It can be understood that, for each step of the above operation performed by the processor 31 and its specific implementation, reference may also be made to the relevant descriptions in the method embodiments shown in FIGS. 1-3 , and details are not repeated here.
所述网页链接访问方法、装置及移动终端通过在监听到终端系统发出的返回桌面广播时,自动读取粘贴板中的内容,并在判断所述内容中存在网页链接时,提取所述网页链接,并调用系统浏览器打开所述网页链接,从而可以有效简化网页链接访问时的操作步骤,提升终端的用户体验。The web page link access method, device and mobile terminal automatically read the content in the pasteboard when listening to the return to desktop broadcast sent by the terminal system, and extract the web page link when judging that there is a web page link in the content , and invoke the system browser to open the webpage link, thereby effectively simplifying the operation steps when accessing the webpage link and improving the user experience of the terminal.
以上所揭露的仅为本发明的较佳实施例而已,当然不能以此来限定本发明的权利范围,本领域普通技术人员可以理解实现上述实施例的全部或部分流程,并依本发明权利要求所作的等同变化,仍属于发明所涵盖的范围。What is disclosed above is only a preferred embodiment of the present invention, which certainly cannot limit the scope of rights of the present invention. Those of ordinary skill in the art can understand all or part of the process for realizing the above embodiments, and according to the claims of the present invention The equivalent changes made still belong to the scope covered by the invention.
Claims (10)
Priority Applications (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610490574.0A CN106202217B (en) | 2016-06-28 | 2016-06-28 | Webpage link access method and device and mobile terminal |
PCT/CN2017/087631 WO2018001068A1 (en) | 2016-06-28 | 2017-06-08 | Web page link access method and device, and mobile terminal |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610490574.0A CN106202217B (en) | 2016-06-28 | 2016-06-28 | Webpage link access method and device and mobile terminal |
Publications (2)
Publication Number | Publication Date |
---|---|
CN106202217A true CN106202217A (en) | 2016-12-07 |
CN106202217B CN106202217B (en) | 2019-12-03 |
Family
ID=57460999
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201610490574.0A Expired - Fee Related CN106202217B (en) | 2016-06-28 | 2016-06-28 | Webpage link access method and device and mobile terminal |
Country Status (2)
Country | Link |
---|---|
CN (1) | CN106202217B (en) |
WO (1) | WO2018001068A1 (en) |
Cited By (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2018001068A1 (en) * | 2016-06-28 | 2018-01-04 | 北京金山安全软件有限公司 | Web page link access method and device, and mobile terminal |
CN108509454A (en) * | 2017-02-27 | 2018-09-07 | 阿里巴巴集团控股有限公司 | A kind of operating method and relevant apparatus of character string |
CN110413169A (en) * | 2019-07-24 | 2019-11-05 | 北京小米移动软件有限公司 | A kind of information displaying method, device and medium |
CN111897469A (en) * | 2020-07-06 | 2020-11-06 | 上海泛微网络科技股份有限公司 | Real-time data processing method, device, equipment and storage medium |
CN114168031A (en) * | 2022-02-11 | 2022-03-11 | 荣耀终端有限公司 | Display optimization method, device and storage medium for hole-digging screen |
CN116012058A (en) * | 2023-02-05 | 2023-04-25 | 李志军 | Advertisement method and system for paid users |
CN117078310A (en) * | 2023-04-04 | 2023-11-17 | 李志军 | Electronic information propaganda method and system |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111221614A (en) * | 2020-01-03 | 2020-06-02 | 北京小米移动软件有限公司 | Information processing method and device, electronic equipment and storage medium |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20050137873A1 (en) * | 2003-12-18 | 2005-06-23 | Tsung-Chun Liu | Method and system for multi-language web homepage selection process |
JP2009171049A (en) * | 2008-01-11 | 2009-07-30 | Ict Solutions:Kk | Internet television apparatus |
CN104035986A (en) * | 2014-05-30 | 2014-09-10 | 北京金山网络科技有限公司 | Method and device for opening URL and method and device for searching for keywords |
CN104346027A (en) * | 2013-07-31 | 2015-02-11 | 腾讯科技(深圳)有限公司 | Website address input method and device |
CN104899269A (en) * | 2015-05-26 | 2015-09-09 | 北京金山安全软件有限公司 | Method and device for accessing website link |
Family Cites Families (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20150324853A1 (en) * | 2014-05-06 | 2015-11-12 | Derek Damiano | Release Date Notification System |
CN104036019B (en) * | 2014-06-25 | 2017-07-04 | 北京奇虎科技有限公司 | The open method and device of web page interlinkage |
CN105159787B (en) * | 2015-08-17 | 2018-08-14 | 北京京东尚科信息技术有限公司 | A kind of webpage action processing method and device |
CN106202217B (en) * | 2016-06-28 | 2019-12-03 | 北京金山安全软件有限公司 | Webpage link access method and device and mobile terminal |
-
2016
- 2016-06-28 CN CN201610490574.0A patent/CN106202217B/en not_active Expired - Fee Related
-
2017
- 2017-06-08 WO PCT/CN2017/087631 patent/WO2018001068A1/en active Application Filing
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20050137873A1 (en) * | 2003-12-18 | 2005-06-23 | Tsung-Chun Liu | Method and system for multi-language web homepage selection process |
JP2009171049A (en) * | 2008-01-11 | 2009-07-30 | Ict Solutions:Kk | Internet television apparatus |
CN104346027A (en) * | 2013-07-31 | 2015-02-11 | 腾讯科技(深圳)有限公司 | Website address input method and device |
CN104035986A (en) * | 2014-05-30 | 2014-09-10 | 北京金山网络科技有限公司 | Method and device for opening URL and method and device for searching for keywords |
CN104899269A (en) * | 2015-05-26 | 2015-09-09 | 北京金山安全软件有限公司 | Method and device for accessing website link |
Cited By (10)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2018001068A1 (en) * | 2016-06-28 | 2018-01-04 | 北京金山安全软件有限公司 | Web page link access method and device, and mobile terminal |
CN108509454A (en) * | 2017-02-27 | 2018-09-07 | 阿里巴巴集团控股有限公司 | A kind of operating method and relevant apparatus of character string |
CN108509454B (en) * | 2017-02-27 | 2022-03-08 | 阿里巴巴集团控股有限公司 | Operation method of character string and related device |
CN110413169A (en) * | 2019-07-24 | 2019-11-05 | 北京小米移动软件有限公司 | A kind of information displaying method, device and medium |
US11099916B2 (en) | 2019-07-24 | 2021-08-24 | Beijing Xiaomi Mobile Software Co., Ltd. | Method and device for presenting information on terminal |
CN110413169B (en) * | 2019-07-24 | 2021-11-23 | 北京小米移动软件有限公司 | Information display method, device and medium |
CN111897469A (en) * | 2020-07-06 | 2020-11-06 | 上海泛微网络科技股份有限公司 | Real-time data processing method, device, equipment and storage medium |
CN114168031A (en) * | 2022-02-11 | 2022-03-11 | 荣耀终端有限公司 | Display optimization method, device and storage medium for hole-digging screen |
CN116012058A (en) * | 2023-02-05 | 2023-04-25 | 李志军 | Advertisement method and system for paid users |
CN117078310A (en) * | 2023-04-04 | 2023-11-17 | 李志军 | Electronic information propaganda method and system |
Also Published As
Publication number | Publication date |
---|---|
WO2018001068A1 (en) | 2018-01-04 |
CN106202217B (en) | 2019-12-03 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN106202217B (en) | Webpage link access method and device and mobile terminal | |
CN108595445A (en) | Interpretation method, device and terminal | |
WO2018077085A1 (en) | Application processing method, device and storage medium | |
CN110221968A (en) | Method for testing software and Related product | |
US9934206B2 (en) | Method and apparatus for extracting web page content | |
US9400633B2 (en) | Methods and apparatus for voiced-enabling a web application | |
US9292253B2 (en) | Methods and apparatus for voiced-enabling a web application | |
US9781262B2 (en) | Methods and apparatus for voice-enabling a web application | |
US10157612B2 (en) | Methods and apparatus for voice-enabling a web application | |
US9195653B2 (en) | Identification of in-context resources that are not fully localized | |
CN112988255B (en) | Data processing method, device and computer readable storage medium | |
CN113392660B (en) | Page translation method and device, electronic equipment and storage medium | |
CN108647032A (en) | Using loading method and device, computer installation and computer readable storage medium | |
US9292252B2 (en) | Methods and apparatus for voiced-enabling a web application | |
CN112163432A (en) | Translation method, translation device and electronic equipment | |
CN109753644B (en) | Rich text editing method and device, mobile terminal and storage medium | |
CN102982217A (en) | Processing method and device of screen print | |
CN105677800B (en) | A kind of processing method and device for error when accessing webpage | |
CN113268221B (en) | File matching method, device, storage medium and computer equipment | |
CN107918552B (en) | Light application calling method and device, client device and electronic equipment | |
CN111966433B (en) | Method, device, storage medium and electronic device for changing language in page | |
CN112099791B (en) | Method, device, equipment and storage medium for setting page style in browser | |
CN114090118A (en) | Method, device and equipment for starting small program and storage medium | |
CN107589954A (en) | Application program updating method, device, terminal and computer-readable storage medium | |
CN108268298B (en) | Desktop icon generation method and device, storage medium and electronic equipment |
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 | ||
CF01 | Termination of patent right due to non-payment of annual fee | ||
CF01 | Termination of patent right due to non-payment of annual fee |
Granted publication date: 20191203 |