Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(343)

Side by Side Diff: chrome/common/extensions/docs/static/history.html

Issue 1530002: Move history API out of experimental. Allow extensions to override history page. (Closed)
Patch Set: Rebase for commit. Created 10 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 <!-- BEGIN AUTHORED CONTENT --> 1 <!-- BEGIN AUTHORED CONTENT -->
2 <p id="classSummary"> 2 <p id="classSummary">
3 For information on how to use experimental APIs, 3 Use the <code>chrome.history</code> module to interact with the
4 see the <a href="experimental.html">chrome.experimental.* APIs</a> page. 4 browser's record of visited pages. You can add, remove, and query
5 for URLs in the browser's history.
6
7 To override the history page with your own version, see
8 <a href="override.html">Override Pages</a>.
9
5 </p> 10 </p>
6 11
7 <h2 id="transition_types">Transition types</h2> 12 <h2 id="transition_types">Transition types</h2>
8 13
9 <p> 14 <p>
10 The history API uses a <em>transition type</em> to describe 15 The history API uses a <em>transition type</em> to describe
11 how the browser navigated to a particular URL 16 how the browser navigated to a particular URL
12 on a particular visit. 17 on a particular visit.
13 For example, if a user visits a page 18 For example, if a user visits a page
14 by clicking a link on another page, 19 by clicking a link on another page,
15 the transition type is LINK. 20 the transition type is "link".
16 To be precise,
17 the type is
18 <a href="#LINK"><code>chrome.experimental.history.transitionType.LINK</code></a> ,
19 which has an integer value of 0.
20 </p>
21
22 <p class="note">
23 <b>Note:</b>
24 The spelling of
25 <code>transitionType</code> changed in
26 <a href="http://src.chromium.org/viewvc/chrome?view=rev&revision=38850">revision 38850</a>.
27 Previously, it was <code>transistionType</code>.
28 </p> 21 </p>
29 22
30 <p> 23 <p>
31 The following table describes each transition type defined by 24 The following table describes each transition type.
32 <code>chrome.experimental.history.transitionType</code>.
33 </p> 25 </p>
34 26
35 <table> 27 <table>
36 <tr> 28 <tr>
37 <th> Transition type </th> <th> Value </th> <th> Description </th> 29 <th> Transition type </th> <th> Description </th>
38 </tr> 30 </tr>
39 <tr id="LINK"> 31 <tr id="tt_link">
40 <td>LINK</td> <td>0</td> 32 <td>"link"</td>
41 <td> 33 <td>
42 The user got to this page by clicking a link on another page. 34 The user got to this page by clicking a link on another page.
43 </td> 35 </td>
44 </tr> 36 </tr>
45 <tr id="TYPED"> 37 <tr id="tt_typed">
46 <td>TYPED</td> <td>1</td> 38 <td>"typed"</td>
47 <td> 39 <td>
48 The user got this page by typing the URL in the address bar. 40 The user got this page by typing the URL in the address bar.
49 Also used for other explicit navigation actions. 41 Also used for other explicit navigation actions.
50 See also <a href="#GENERATED">GENERATED</a>, 42 See also <a href="#tt_generated">generated</a>,
51 which is used for cases where the user selected a choice 43 which is used for cases where the user selected a choice
52 that didn't look at all like a URL. 44 that didn't look at all like a URL.
53 </td> 45 </td>
54 </tr> 46 </tr>
55 <tr id="AUTO_BOOKMARK"> 47 <tr id="tt_auto_bookmark">
56 <td>AUTO_BOOKMARK</td><td>2</td> 48 <td>"auto_bookmark"</td>
57 <td> 49 <td>
58 The user got to this page through a suggestion in the UI &mdash; 50 The user got to this page through a suggestion in the UI &mdash;
59 for example, through a menu item. 51 for example, through a menu item.
60 </td> 52 </td>
61 </tr> 53 </tr>
62 <tr id="AUTO_SUBFRAME"> 54 <tr id="tt_auto_subframe">
63 <td>AUTO_SUBFRAME</td><td>3</td> 55 <td>"auto_subframe"</td>
64 <td> 56 <td>
65 Subframe navigation. 57 Subframe navigation.
66 This is any content that is automatically 58 This is any content that is automatically
67 loaded in a non-top-level frame. 59 loaded in a non-top-level frame.
68 For example, if a page consists of 60 For example, if a page consists of
69 several frames containing ads, 61 several frames containing ads,
70 those ad URLs have this transition type. 62 those ad URLs have this transition type.
71 The user may not even realize the content in these pages 63 The user may not even realize the content in these pages
72 is a separate frame, and so may not care about the URL 64 is a separate frame, and so may not care about the URL
73 (see also <a href="#MANUAL_SUBFRAME">MANUAL_SUBFRAME</a>). 65 (see also <a href="#tt_manual_subframe">manual_subframe</a>).
74 </td> 66 </td>
75 </tr> 67 </tr>
76 <tr id="MANUAL_SUBFRAME"> 68 <tr id="tt_manual_subframe">
77 <td>MANUAL_SUBFRAME</td><td>4</td> 69 <td>"manual_subframe"</td>
78 <td> 70 <td>
79 For subframe navigations that are explicitly requested by the user 71 For subframe navigations that are explicitly requested by the user
80 and generate new navigation entries in the back/forward list. 72 and generate new navigation entries in the back/forward list.
81 An explicitly requested frame is probably more important than 73 An explicitly requested frame is probably more important than
82 an automatically loaded frame 74 an automatically loaded frame
83 because the user probably cares about the fact that 75 because the user probably cares about the fact that
84 the requested frame was loaded. 76 the requested frame was loaded.
85 </td> 77 </td>
86 </tr> 78 </tr>
87 <tr id="GENERATED"> 79 <tr id="tt_generated">
88 <td>GENERATED</td><td>5</td> 80 <td>"generated"</td>
89 <td> 81 <td>
90 The user got to this page by typing in the address bar 82 The user got to this page by typing in the address bar
91 and selecting an entry that did not look like a URL. 83 and selecting an entry that did not look like a URL.
92 For example, a match might have the URL of a Google search result page, 84 For example, a match might have the URL of a Google search result page,
93 but it might appear to the user as "Search Google for ...". 85 but it might appear to the user as "Search Google for ...".
94 These are not quite the same as <a href="#TYPED">TYPED</a> navigations 86 These are not quite the same as <a href="#tt_typed">typed</a> navigations
95 because the user didn't type or see the destination URL. 87 because the user didn't type or see the destination URL.
96 See also <a href="#KEYWORD">KEYWORD</a>. 88 See also <a href="#tt_keyword">keyword</a>.
97 </td> 89 </td>
98 </tr> 90 </tr>
99 <tr id="START_PAGE"> 91 <tr id="tt_start_page">
100 <td>START_PAGE</td><td>6</td> 92 <td>"start_page"</td>
101 <td> 93 <td>
102 The page was specified in the command line or is the start page. 94 The page was specified in the command line or is the start page.
103 </td> 95 </td>
104 </tr> 96 </tr>
105 <tr id="FORM_SUBMIT"> 97 <tr id="tt_form_submit">
106 <td>FORM_SUBMIT</td><td>7</td> 98 <td>"form_submit"</td>
107 <td> 99 <td>
108 The user filled out values in a form and submitted it. 100 The user filled out values in a form and submitted it.
109 Note that in some situations &mdash; 101 Note that in some situations &mdash;
110 such as when a form uses script to submit contents &mdash; 102 such as when a form uses script to submit contents &mdash;
111 submitting a form does not result in this transition type. 103 submitting a form does not result in this transition type.
112 </td> 104 </td>
113 </tr> 105 </tr>
114 <tr id="RELOAD"> 106 <tr id="tt_reload">
115 <td>RELOAD</td><td>8</td> 107 <td>"reload"</td>
116 <td> 108 <td>
117 The user reloaded the page, 109 The user reloaded the page,
118 either by clicking the reload button 110 either by clicking the reload button
119 or by pressing Enter in the address bar. 111 or by pressing Enter in the address bar.
120 Session restore and Reopen closed tab use this transition type, too. 112 Session restore and Reopen closed tab use this transition type, too.
121 </td> 113 </td>
122 </tr> 114 </tr>
123 <tr id="KEYWORD"> 115 <tr id="tt_keyword">
124 <td>KEYWORD</td><td>9</td> 116 <td>"keyword"</td>
125 <td> 117 <td>
126 The URL was generated from a replaceable keyword 118 The URL was generated from a replaceable keyword
127 other than the default search provider. 119 other than the default search provider.
128 See also 120 See also
129 <a href="#KEYWORD_GENERATED">KEYWORD_GENERATED</a>. 121 <a href="#tt_keyword_generated">keyword_generated</a>.
130 </td> 122 </td>
131 </tr> 123 </tr>
132 <tr id="KEYWORD_GENERATED"> 124 <tr id="tt_keyword_generated">
133 <td>KEYWORD_GENERATED</td><td>10</td> 125 <td>"keyword_generated"</td>
134 <td> 126 <td>
135 Corresponds to a visit generated for a keyword. 127 Corresponds to a visit generated for a keyword.
136 See also <a href="#KEYWORD">KEYWORD</a>. 128 See also <a href="#tt_keyword">keyword</a>.
137 </td> 129 </td>
138 </tr> 130 </tr>
139 </table> 131 </table>
140 132
141 <h2 id="examples">Examples</h2> 133 <h2 id="examples">Examples</h2>
142 134
143 <p> 135 <p>
144 For an example of using this API, see the 136 For an example of using this API, see the
145 <a href="http://src.chromium.org/viewvc/chrome/trunk/src/chrome/test/data/extens ions/api_test/history/">history API test directory</a>. 137 <a href="http://src.chromium.org/viewvc/chrome/trunk/src/chrome/test/data/extens ions/api_test/history/">history API test directory</a>.
146 </p> 138 </p>
147 139
148 <!-- END AUTHORED CONTENT --> 140 <!-- END AUTHORED CONTENT -->
OLDNEW
« no previous file with comments | « chrome/common/extensions/docs/static/experimental.html ('k') | chrome/common/extensions/docs/static/override.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698