OLD | NEW |
1 <div id="pageData-name" class="pageData">Browser Actions</div> | 1 <div id="pageData-name" class="pageData">Browser Actions</div> |
2 | 2 |
3 <!-- BEGIN AUTHORED CONTENT --> | 3 <!-- BEGIN AUTHORED CONTENT --> |
4 <p>Use browser actions to put icons | 4 <p>Use browser actions to put icons |
5 in the main Google Chrome toolbar, | 5 in the main Google Chrome toolbar, |
6 to the right of the address bar. | 6 to the right of the address bar. |
7 In addition to its <a href="#icon">icon</a>, | 7 In addition to its <a href="#icon">icon</a>, |
8 a browser action can also have | 8 a browser action can also have |
9 a <a href="#tooltip">tooltip</a>, | 9 a <a href="#tooltip">tooltip</a>, |
10 a <a href="#badge">badge</a>, | 10 a <a href="#badge">badge</a>, |
(...skipping 29 matching lines...) Expand all Loading... |
40 <p> | 40 <p> |
41 Register your browser action in the | 41 Register your browser action in the |
42 <a href="manifest.html">extension manifest</a> | 42 <a href="manifest.html">extension manifest</a> |
43 like this: | 43 like this: |
44 </p> | 44 </p> |
45 | 45 |
46 <pre>{ | 46 <pre>{ |
47 "name": "My extension", | 47 "name": "My extension", |
48 ... | 48 ... |
49 <b>"browser_action": { | 49 <b>"browser_action": { |
50 "default_icon": "images/icon19.png", <em>// <b>required</b></em> | 50 "default_icon": "images/icon19.png", <em>// optional</em> |
51 "default_title": "Google Mail", <em>// optional; shown in tooltip</em> | 51 "default_title": "Google Mail", <em>// optional; shown in tooltip</em> |
52 "default_popup": "popup.html" <em>// optional</em> | 52 "default_popup": "popup.html" <em>// optional</em> |
53 }</b>, | 53 }</b>, |
54 ... | 54 ... |
55 }</pre> | 55 }</pre> |
56 | 56 |
57 <h2 id="ui">Parts of the UI</h2> | 57 <h2 id="ui">Parts of the UI</h2> |
58 | 58 |
59 <p> | 59 <p> |
60 A browser action must have an <a href="#icon">icon</a>. | 60 A browser action can have an <a href="#icon">icon</a>, |
61 It can also have | |
62 a <a href="#tooltip">tooltip</a>, | 61 a <a href="#tooltip">tooltip</a>, |
63 a <a href="#badge">badge</a>, | 62 a <a href="#badge">badge</a>, |
64 and a <a href="#popups">popup</a>. | 63 and a <a href="#popups">popup</a>. |
65 </p> | 64 </p> |
66 | 65 |
67 <h3 id="icon">Icon</h3> | 66 <h3 id="icon">Icon</h3> |
68 | 67 |
69 <p>Browser action icons can be up to 19 pixels wide and high. | 68 <p>Browser action icons can be up to 19 pixels wide and high. |
70 Larger icons are resized to fit, but for best results, | 69 Larger icons are resized to fit, but for best results, |
71 use a 19-pixel square icon.</p> | 70 use a 19-pixel square icon.</p> |
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
169 | 168 |
170 <p> | 169 <p> |
171 You can find simple examples of using browser actions in the | 170 You can find simple examples of using browser actions in the |
172 <a href="http://src.chromium.org/viewvc/chrome/trunk/src/chrome/common/extension
s/docs/examples/api/browserAction/">examples/api/browserAction</a> | 171 <a href="http://src.chromium.org/viewvc/chrome/trunk/src/chrome/common/extension
s/docs/examples/api/browserAction/">examples/api/browserAction</a> |
173 directory. | 172 directory. |
174 For other examples and for help in viewing the source code, see | 173 For other examples and for help in viewing the source code, see |
175 <a href="samples.html">Samples</a>. | 174 <a href="samples.html">Samples</a>. |
176 </p> | 175 </p> |
177 | 176 |
178 <!-- END AUTHORED CONTENT --> | 177 <!-- END AUTHORED CONTENT --> |
OLD | NEW |