OLD | NEW |
---|---|
1 <!-- BEGIN AUTHORED CONTENT --> | 1 <!-- BEGIN AUTHORED CONTENT --> |
2 <p id="classSummary"> | 2 <p id="classSummary"> |
3 Use the <code>chrome.permissions</code> module to implement | 3 Use the <code>chrome.permissions</code> module to implement |
4 optional permissions. You can request optional permissions during your | 4 optional permissions. You can request optional permissions during your |
5 extension's regular application flow rather than at install time, so users | 5 extension's regular application flow rather than at install time, so users |
6 understand why the permissions are needed and use only those that are | 6 understand why the permissions are needed and use only those that are |
7 necessary. | 7 necessary. |
8 </p> | 8 </p> |
9 <p> | 9 <p> |
10 For general information about permissions and details about each permission, | 10 For general information about permissions and details about each permission, |
11 see the <a href="manifest.html#permissions">permissions</a> section of the | 11 see the <a href="manifest.html#permissions">permissions</a> section of the |
12 manifest documentation. | 12 manifest documentation. |
13 </p> | 13 </p> |
14 <h2 id="howto"> Implementing optional permissions </h2> | 14 <h2 id="howto"> Implementing optional permissions </h2> |
15 | 15 |
16 <h3 id="types"> | 16 <h3 id="types"> Step 1: Decide which permissions are optional and required </h3> |
not at google - send to devlin
2012/07/20 02:04:54
maybe we should fix the parser rather than fix the
| |
17 Step 1: Decide which permissions are optional and required | |
18 </h3> | |
19 <p> | 17 <p> |
20 Extensions should generally require permissions when they are needed for the | 18 Extensions should generally require permissions when they are needed for the |
21 extension's basic functionality and employ optional permissions for optional | 19 extension's basic functionality and employ optional permissions for optional |
22 features. | 20 features. |
23 </p> | 21 </p> |
24 <p> | 22 <p> |
25 Advantages of optional permissions: | 23 Advantages of optional permissions: |
26 <ul> | 24 <ul> |
27 <li> | 25 <li> |
28 Users run with less permissions since they enable only what is needed. | 26 Users run with less permissions since they enable only what is needed. |
(...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
155 }, function(removed) { | 153 }, function(removed) { |
156 if (removed) { | 154 if (removed) { |
157 // The permissions have been removed. | 155 // The permissions have been removed. |
158 } else { | 156 } else { |
159 // The permissions have not been removed (e.g., you tried to remove | 157 // The permissions have not been removed (e.g., you tried to remove |
160 // required permissions). | 158 // required permissions). |
161 } | 159 } |
162 }); | 160 }); |
163 </pre> | 161 </pre> |
164 <!-- END AUTHORED CONTENT --> | 162 <!-- END AUTHORED CONTENT --> |
OLD | NEW |