sdkpage.cs revision 55d99832fd2631bc9453141ae3a23e2eb074ede0
1<?cs include:"doctype.cs" ?> 2<?cs include:"macros.cs" ?> 3<html> 4<?cs if:sdk.redirect ?> 5 <head> 6 <title>Redirecting...</title> 7 <meta http-equiv="refresh" content="0;url=<?cs var:toroot ?>sdk/<?cs 8 if:sdk.redirect.path ?><?cs var:sdk.redirect.path ?><?cs 9 else ?>index.html<?cs /if ?>"> 10 <link href="<?cs var:toroot ?>assets/android-developer-docs.css" rel="stylesheet" type="text/css" /> 11 </head> 12<?cs else ?> 13 <?cs include:"head_tag.cs" ?> 14<?cs /if ?> 15<body class="gc-documentation 16 <?cs if:(guide||develop||training||reference||tools||sdk) ?>develop<?cs 17 elif:design ?>design<?cs 18 elif:distribute ?>distribute<?cs 19 /if ?>" itemscope itemtype="http://schema.org/CreativeWork"> 20 <a name="top"></a> 21<?cs include:"header.cs" ?> 22 23 24<div <?cs if:fullpage 25?><?cs else 26?>class="col-13" id="doc-col"<?cs /if ?> > 27 28<?cs if:sdk.redirect ?> 29 30<div class="g-unit"> 31 <div id="jd-content"> 32 <p>Redirecting to 33 <a href="<?cs var:toroot ?>sdk/<?cs 34 if:sdk.redirect.path ?><?cs var:sdk.redirect.path ?><?cs 35 else ?>index.html<?cs /if ?>"><?cs 36 if:sdk.redirect.path ?><?cs var:sdk.redirect.path ?><?cs 37 else ?>Download the SDK<?cs /if ?> 38 </a> ...</p> 39 40<?cs else ?> 41<?cs # else, if NOT redirect ... 42# 43# 44# The following is for SDK/NDK pages 45# 46# 47?> 48 49<?cs if:header.hide ?><?cs else ?> 50<h1 itemprop="name"><?cs var:page.title ?></h1> 51<?cs /if ?> 52 <div id="jd-content" itemprop="description"> 53 54<?cs if:sdk.not_latest_version ?> 55 <div class="special"> 56 <p><strong>This is NOT the current Android SDK release.</strong></p> 57 <p><a href="/sdk/index.html">Download the current Android SDK</a></p> 58 </div> 59<?cs /if ?> 60 61 62<?cs if:ndk ?> 63<?cs # 64# 65# 66# 67# 68# 69# 70# the following is for the NDK 71# 72# (nested in if/else redirect) 73# 74# 75# 76# 77?> 78 79 <table class="download" id="download-table"> 80 <tr> 81 <th>Platform</th> 82 <th>Package</th> 83 <th>Size</th> 84 <th>MD5 Checksum</th> 85 </tr> 86 <tr> 87 <td>Windows</td> 88 <td> 89 <a onClick="_gaq.push(['_trackEvent', 'Tools', 'Download NDK', 'Link <' + <?cs var:ndk.win_download ?> + '>']);" 90 href="http://dl.google.com/android/ndk/<?cs var:ndk.win_download ?>"><?cs var:ndk.win_download ?></a> 91 </td> 92 <td><?cs var:ndk.win_bytes ?> bytes</td> 93 <td><?cs var:ndk.win_checksum ?></td> 94 </tr> 95 <tr class="alt-color"> 96 <td>Mac OS X (intel)</td> 97 <td> 98 <a onClick="_gaq.push(['_trackEvent', 'Tools', 'Download NDK', 'Link <' + <?cs var:ndk.mac_download ?> + '>']);" 99 href="http://dl.google.com/android/ndk/<?cs var:ndk.mac_download ?>"><?cs var:ndk.mac_download ?></a> 100 </td> 101 <td><?cs var:ndk.mac_bytes ?> bytes</td> 102 <td><?cs var:ndk.mac_checksum ?></td> 103 </tr> 104 <tr> 105 <td>Linux 32/64-bit (x86)</td> 106 <td> 107 <a onClick="_gaq.push(['_trackEvent', 'Tools', 'Download NDK', 'Link <' + <?cs var:ndk.linux_download ?> + '>']);" 108 href="http://dl.google.com/android/ndk/<?cs var:ndk.linux_download ?>"><?cs var:ndk.linux_download ?></a> 109 </td> 110 <td><?cs var:ndk.linux_bytes ?> bytes</td> 111 <td><?cs var:ndk.linux_checksum ?></td> 112 </tr> 113 </table> 114 115 <?cs ######## HERE IS THE JD DOC CONTENT ######### ?> 116 <?cs call:tag_list(root.descr) ?> 117 118 <?cs else ?> 119<?cs # end if NDK ... 120# 121# 122# 123# 124# 125# 126# the following is for the SDK 127# 128# (nested in if/else redirect and if/else NDK) 129# 130# 131# 132# 133?> 134 <?cs if:android.whichdoc == "online" ?> 135 136 137<?cs ######## HERE IS THE JD DOC CONTENT FOR ONLINE ######### ?> 138<?cs call:tag_list(root.descr) ?> 139 140 141 142 143<h4><a href='' class="expandable" 144 onclick="toggleExpandable(this,'.pax');hideExpandable('.myide,.reqs');return false;" 145 >DOWNLOAD FOR OTHER PLATFORMS</a></h4> 146 147 148<div class="pax col-13 online" style="display:none;margin:0;"> 149 150 151<p class="table-caption"><strong>ADT Bundle</strong></p> 152 <table class="download"> 153 <tr> 154 <th>Platform</th> 155 <th>Package</th> 156 <th>Size</th> 157 <th>MD5 Checksum</th> 158 </tr> 159 <tr> 160 <td>Windows</td> 161 <td> 162 <a onClick="return onDownload(this)" id="win-bundle" 163 href="http://dl.google.com/android/sdk/<?cs var:sdk.win_bundle_download ?>"><?cs var:sdk.win_bundle_download ?></a> 164 </td> 165 <td><?cs var:sdk.win_bundle_bytes ?> bytes</td> 166 <td><?cs var:sdk.win_bundle_checksum ?></td> 167 </tr> 168 <tr class="alt-color"> 169 <td>Mac OS X (intel)</td> 170 <td> 171 <a onClick="return onDownload(this)" id="mac-bundle" 172 href="http://dl.google.com/android/sdk/<?cs var:ndk.mac_bundle_download ?>"><?cs var:sdk.mac_bundle_download ?></a> 173 </td> 174 <td><?cs var:sdk.mac_bundle_bytes ?> bytes</td> 175 <td><?cs var:sdk.mac_bundle_checksum ?></td> 176 </tr> 177 <tr> 178 <td>Linux 32/64-bit (x86)</td> 179 <td> 180 <a onClick="return onDownload(this)" id="linux-bundle" 181 href="http://dl.google.com/android/sdk/<?cs var:sdk.linux_bundle_download ?>"><?cs var:sdk.linux_bundle_download ?></a> 182 </td> 183 <td><?cs var:sdk.linux_bundle_bytes ?> bytes</td> 184 <td><?cs var:sdk.linux_bundle_checksum ?></td> 185 </tr> 186 </table> 187 188 189<p class="table-caption"><strong>SDK Tools Only</strong></p> 190 <table class="download"> 191 <tr> 192 <th>Platform</th> 193 <th>Package</th> 194 <th>Size</th> 195 <th>MD5 Checksum</th> 196 </tr> 197 <tr> 198 <td rowspan="2">Windows</td> 199 <td> 200 <a onclick="return onDownload(this)" href="http://dl.google.com/android/<?cs var:sdk.win_download 201?>"><?cs var:sdk.win_download ?></a> 202 </td> 203 <td><?cs var:sdk.win_bytes ?> bytes</td> 204 <td><?cs var:sdk.win_checksum ?></td> 205 </tr> 206 <tr> 207 <!-- blank TD from Windows rowspan --> 208 <td> 209 <a onclick="return onDownload(this)" id="win-tools" href="http://dl.google.com/android/<?cs 210var:sdk.win_installer 211?>"><?cs var:sdk.win_installer ?></a> (Recommended) 212 </td> 213 <td><?cs var:sdk.win_installer_bytes ?> bytes</td> 214 <td><?cs var:sdk.win_installer_checksum ?></td> 215 </tr> 216 <tr class="alt-color"> 217 <td>Mac OS X (intel)</td> 218 <td> 219 <a onclick="return onDownload(this)" id="mac-tools" href="http://dl.google.com/android/<?cs 220var:sdk.mac_download 221?>"><?cs var:sdk.mac_download ?></a> 222 </td> 223 <td><?cs var:sdk.mac_bytes ?> bytes</td> 224 <td><?cs var:sdk.mac_checksum ?></td> 225 </tr> 226 <tr> 227 <td>Linux (i386)</td> 228 <td> 229 <a onclick="return onDownload(this)" id="linux-tools" href="http://dl.google.com/android/<?cs 230var:sdk.linux_download 231?>"><?cs var:sdk.linux_download ?></a> 232 </td> 233 <td><?cs var:sdk.linux_bytes ?> bytes</td> 234 <td><?cs var:sdk.linux_checksum ?></td> 235 </tr> 236 </table> 237 238</div><!-- end pax --> 239 240 241 242</div><!-- end col-13 for lower-half content --> 243 244 245 246 247<script> 248 if (location.hash == "#Requirements") { 249 $('.reqs').show(); 250 } else if (location.hash == "#ExistingIDE") { 251 $('.ide').show(); 252 } 253 254 var os; 255 var $bundlelink; 256 var $toolslink; 257 258 if (navigator.appVersion.indexOf("Win")!=-1) { 259 os = "Windows"; 260 $bundlelink = $('#win-bundle'); 261 $toolslink = $('#win-tools'); 262 } else if (navigator.appVersion.indexOf("Mac")!=-1) { 263 os = "Mac"; 264 $bundlelink = $('#mac-bundle'); 265 $toolslink = $('#mac-tools'); 266 } else if (navigator.appVersion.indexOf("Linux")!=-1) { 267 os = "Linux"; 268 $bundlelink = $('#linux-bundle'); 269 $toolslink = $('#linux-tools'); 270 } 271 272 if (os) { 273 $('#not-supported').hide(); 274 275 /* set up primary adt download button */ 276 $('#download-bundle-button').show(); 277 $('#download-bundle-button').append("Download the SDK <br/><span class='small'>ADT Bundle for " + os + "</span>"); 278 $('#download-bundle-button').click(function() {return onDownload(this,true);}).attr('href', $bundlelink.attr('href')); 279 280 /* set up sdk tools only button */ 281 $('#download-tools-button').show(); 282 $('#download-tools-button').append("Download the SDK Tools for " + os); 283 $('#download-tools-button').click(function() {return onDownload(this,true);}).attr('href', $toolslink.attr('href')); 284 } else { 285 $('.pax').show(); 286 } 287 288 function onDownload(link, button) { 289 290 if (button) { 291 $("#downloadForRealz").html($(link).text()); 292 } else { 293 $("#downloadForRealz").html("Download " + $(link).text()); 294 $("a#next-link").html("Setting Up an Existing IDE").attr('href',toRoot + 'sdk/installing/index.html'); 295 } 296 $("#downloadForRealz").attr('href',$(link).attr('href')); 297 298 $("#tos").fadeIn('fast'); 299 $("#landing").fadeOut('fast'); 300 301 location.hash = "download"; 302 return false; 303 } 304 305 306 function onAgreeChecked() { 307 if ($("input#agree").is(":checked")) { 308 $("a#downloadForRealz").removeClass('disabled'); 309 } else { 310 $("a#downloadForRealz").addClass('disabled'); 311 } 312 } 313 314 function onDownloadForRealz(link) { 315 if ($("input#agree").is(':checked')) { 316 $("div.sdk-terms").slideUp(); 317 $("#sdk-terms-form,.sdk-terms-intro").fadeOut('slow'); 318 $("#next-steps").fadeIn('slow'); 319 $("h1#tos-header").text('Get Ready to Code!'); 320 return true; 321 } else { 322 $("label#agreeLabel").parent().stop().animate({color: "#258AAF"}, 200, 323 function() {$("label#agreeLabel").parent().stop().animate({color: "#222"}, 200)} 324 ); 325 return false; 326 } 327 } 328 329 $(window).hashchange( function(){ 330 console.log('hash: '+location.hash); 331 if (location.hash == "") { 332 location.reload(); 333 } 334 }); 335 336</script> 337 338 339 340</div><!-- end the wrapper used for relative/absolute positions --> 341<?cs # THIS DIV WAS OPENED IN INDEX.JD ?> 342 343 344 345 346 <?cs else ?> <?cs # end if online ?> 347 348 <?cs if:sdk.preview ?><?cs # it's preview offline docs ?> 349 <p>Welcome developers! We are pleased to provide you with a preview SDK for the upcoming 350 Android 3.0 release, to give you a head-start on developing applications for it. 351 </p> 352 353 <p>See the <a 354 href="<?cs var:toroot ?>sdk/preview/start.html">Getting Started</a> document for more information 355 about how to set up the preview SDK and get started.</p> 356 <style type="text/css"> 357 .non-preview { display:none; } 358 </style> 359 360 <?cs else ?><?cs # it's normal offline docs ?> 361 362 <?cs ######## HERE IS THE JD DOC CONTENT FOR OFFLINE ######### ?> 363 <?cs call:tag_list(root.descr) ?> 364 <style type="text/css"> 365 body .offline { display:block; } 366 body .online { display:none; } 367 </style> 368 <script> 369 $('.reqs').show(); 370 </script> 371 <?cs /if ?> 372 373 <?cs /if ?> <?cs # end if/else online ?> 374 375<?cs /if ?> <?cs # end if/else NDK ?> 376 377<?cs /if ?> <?cs # end if/else redirect ?> 378 379 380</div><!-- end jd-content --> 381 382<?cs if:!sdk.redirect ?> 383<?cs include:"footer.cs" ?> 384<?cs /if ?> 385 386</div><!-- end g-unit --> 387 388<?cs include:"trailer.cs" ?> 389 390</body> 391</html> 392 393 394 395