Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 2953f0b0 authored by Scott Main's avatar Scott Main Committed by Android Git Automerger
Browse files

am fef18c61: am db3678bc: add ADT Bundle to the download page

* commit 'fef18c61':
  add ADT Bundle to the download page
parents 0900e42e fef18c61
Loading
Loading
Loading
Loading
+92 −17
Original line number Diff line number Diff line
@@ -129,11 +129,14 @@ strong {
em {
  font-style: italic; }

acronym {
acronym,
.tooltip-link {
  border-bottom: 1px dotted #555555;
  cursor: help; }

acronym:hover {
acronym:hover,
.tooltip-link:hover {
  color: #7aa1b0;
  border-bottom-color: #7aa1b0; }

img.with-shadow,
@@ -938,9 +941,12 @@ dd {
dd p {
  margin:10px 0 0;
}
ul p,
ol p {
  margin:5px 0 0;
li p,
li pre,
li ul,
li ol {
  margin-top:5px;
  margin-bottom:5px;
}
pre strong, pre b, a strong, a b, a code {
    color: inherit;
@@ -1418,8 +1424,6 @@ Buttons
    color: #444;
}
a.button, a.button:visited, a.button-secondary, a.button-secondary:visited {
    height: 28px;
    line-height: 28px;
    margin-right: 16px;
	 font-weight: 400;
    min-width: 54px;
@@ -1428,8 +1432,6 @@ a.button, a.button:visited, a.button-secondary, a.button-secondary:visited {
    text-align: center;
}
.button, .button-secondary {
    height: 34px;
    line-height: 34px;
    margin-right: 16px;
	font-weight: 400;
    min-width: 54px;
@@ -1455,6 +1457,9 @@ EndColorStr='#4cadcb',GradientType=0);
    background-image: none;
    border-color: #30b7e6;
}
a.button.big.subtitle {
  line-height:18px;
}
.button-secondary:hover, a.button-secondary:hover {
    border-color: #dbdbdb;
    background-color: #f3f3f3;
@@ -1510,12 +1515,20 @@ endColorstr='#ffffff',GradientType=0 ); /* IE6-8 */
  font-size:20px;
  display:inline-block;
}
.button.big span.small {
  font-size:14px;
}
.button-caption {
  margin-top:10px;
  font-size:12px;
  font-style:italic;
}

.button.disabled,
.button.disabled:hover,
.button.disabled:active {
  background:#ebebeb;
  color:#999;
  color:#999 !important;
  border-color:#999;
  cursor:default;
}
@@ -1832,6 +1845,45 @@ form .form-error input[type='text'], form .form-error textarea {
    border-color: #eff2f9;
}
*/

/* SDK TOS styles */

div.sdk-terms {
  white-space: pre-wrap;
  word-wrap: break-word;
  font-family: inherit;
  font-size: inherit;
  padding: 10px;
  height: 370px;
  width: 738px;
  border: 1px solid #444;
  background: transparent;
  overflow:auto;
  margin:0 0 10px;
}

div.sdk-terms.fullsize {
  padding: 0;
  height: auto;
  width: auto;
  border:none;
}

div.sdk-terms h3,
div.sdk-terms h2 {
  margin:0;
}

div#sdk-terms-form {
  padding:0 0 0 10px;
}

div#sdk-terms-form input#agree {
  display:inline;
  margin:4px 4px 4px 0;
}


/* --------------------------------------------------------------------------
Code Style
*/
@@ -2332,6 +2384,29 @@ div.design-announce p {
  line-height:30px;
}

.expandable {
  height:34px;
  padding-left:20px;
  position:relative;
}
.expandable:before {
  content: '';
  background-image: url(../images/styles/disclosure_down.png);
  background-repeat:no-repeat;
  background-position: -12px -9px;
  width: 20px;
  height: 20px;
  display: inline-block;
  position: absolute;
  top: 0;
  left: 0; }
}
.expandable.expanded:before {
  background-image: url(../images/styles/disclosure_up.png);
}



/* -----------------------------------------------
Dialog box for popup messages 
*/
+18 −3
Original line number Diff line number Diff line
@@ -28,7 +28,7 @@ $(document).ready(function() {
  $('.scroll-pane').jScrollPane( {verticalGutter:0} );
  
  // add HRs below all H2s (except for a few other h2 variants)
  $('h2').not('#qv h2').not('#tb h2').not('.sidebox h2').not('#devdoc-nav h2').css({marginBottom:0}).after('<hr/>');
  $('h2').not('#qv h2').not('#tb h2').not('.sidebox h2').not('#devdoc-nav h2').not('h2.norule').css({marginBottom:0}).after('<hr/>');
  
  // set search's onkeyup handler here so we can show suggestions 
  // even while search results are visible
@@ -384,11 +384,11 @@ false; // navigate across topic boundaries only in design docs

  // Set up tooltips
  var TOOLTIP_MARGIN = 10;
  $('acronym').each(function() {
  $('acronym,.tooltip-link').each(function() {
    var $target = $(this);
    var $tooltip = $('<div>')
        .addClass('tooltip-box')
        .text($target.attr('title'))
        .append($target.attr('title'))
        .hide()
        .appendTo('body');
    $target.removeAttr('title');
@@ -1052,6 +1052,21 @@ function toggleContent(obj) {
}


/* New version of expandable content */
function toggleExpandable(link,id) {
  if($(id).is(':visible')) {
    $(id).slideUp();
    $(link).removeClass('expanded');
  } else {
    $(id).slideDown();
    $(link).addClass('expanded');
  }
}

function hideExpandable(ids) {
  $(ids).slideUp();
}




+126 −26
Original line number Diff line number Diff line
@@ -76,7 +76,6 @@
#
?>


  <table class="download" id="download-table">
    <tr>
      <th>Platform</th>
@@ -140,6 +139,49 @@

<div class="wrap">
<div class="pax col-13 online" style="display:none">




<p class="table-caption"><strong>ADT Bundle</strong></p>
  <table class="download">
    <tr>
      <th>Platform</th>
      <th>Package</th>
      <th>Size</th>
      <th>MD5 Checksum</th>
  </tr>
  <tr>
    <td>Windows</td>
    <td>
  <a onClick="return onDownload(this)" id="win-bundle"
     href="http://dl.google.com/android/sdk/<?cs var:sdk.win_bundle_download ?>"><?cs var:sdk.win_bundle_download ?></a>
    </td>
    <td><?cs var:sdk.win_bundle_bytes ?> bytes</td>
    <td><?cs var:sdk.win_bundle_checksum ?></td>
  </tr>
  <tr class="alt-color">
    <td>Mac OS X (intel)</td>
    <td>
  <a onClick="return onDownload(this)" id="mac-bundle"
     href="http://dl.google.com/android/sdk/<?cs var:ndk.mac_bundle_download ?>"><?cs var:sdk.mac_bundle_download ?></a>
    </td>
    <td><?cs var:sdk.mac_bundle_bytes ?> bytes</td>
    <td><?cs var:sdk.mac_bundle_checksum ?></td>
  </tr>
  <tr>
    <td>Linux 32/64-bit (x86)</td>
    <td>
  <a onClick="return onDownload(this)" id="linux-bundle"
     href="http://dl.google.com/android/sdk/<?cs var:sdk.linux_bundle_download ?>"><?cs var:sdk.linux_bundle_download ?></a>
    </td>
    <td><?cs var:sdk.linux_bundle_bytes ?> bytes</td>
    <td><?cs var:sdk.linux_bundle_checksum ?></td>
  </tr>
  </table>


<p class="table-caption"><strong>SDK Tools Only</strong></p>
  <table class="download">
    <tr>
      <th>Platform</th>
@@ -150,7 +192,7 @@
  <tr>
    <td rowspan="2">Windows</td>
    <td>
  <a onclick="onDownload(this,false)" href="http://dl.google.com/android/<?cs var:sdk.win_download
  <a onclick="return onDownload(this)" href="http://dl.google.com/android/<?cs var:sdk.win_download
?>"><?cs var:sdk.win_download ?></a>
    </td>
    <td><?cs var:sdk.win_bytes ?> bytes</td>
@@ -159,7 +201,7 @@
  <tr>
    <!-- blank TD from Windows rowspan -->
    <td>
  <a onclick="onDownload(this,false)" id="win-sdk" href="http://dl.google.com/android/<?cs
  <a onclick="return onDownload(this)" id="win-tools" href="http://dl.google.com/android/<?cs
var:sdk.win_installer
?>"><?cs var:sdk.win_installer ?></a> (Recommended)
    </td>
@@ -169,7 +211,7 @@ var:sdk.win_installer
  <tr class="alt-color">
    <td>Mac OS X (intel)</td>
    <td>
  <a onclick="onDownload(this,false)" id="mac-sdk" href="http://dl.google.com/android/<?cs
  <a onclick="return onDownload(this)" id="mac-tools" href="http://dl.google.com/android/<?cs
var:sdk.mac_download
?>"><?cs var:sdk.mac_download ?></a>
    </td>
@@ -179,7 +221,7 @@ var:sdk.mac_download
  <tr>
    <td>Linux (i386)</td>
    <td>
  <a onclick="onDownload(this,false)" id="linux-sdk" href="http://dl.google.com/android/<?cs
  <a onclick="return onDownload(this)" id="linux-tools" href="http://dl.google.com/android/<?cs
var:sdk.linux_download
?>"><?cs var:sdk.linux_download ?></a>
    </td>
@@ -189,49 +231,107 @@ var:sdk.linux_download
  </table>


<script>
  function onDownload(link,fromButton) {
    $("#filename").text($(link).html());
    $("#next-steps").fadeIn('slow');
    $("#intro").fadeOut('slow');
    $('.pax').slideUp();
    $('.reqs').slideUp();
    // Deliver Analytics event
    if (fromButton) {
      _gaq.push(['_trackEvent', 'Tools', 'Download SDK', 'Button <' + text($(link).html()) + '>']);
    } else {
      _gaq.push(['_trackEvent', 'Tools', 'Download SDK', 'Link <' + text($(link).html()) + '>']);
    }
  }

  
  
  
  
<script>

  var os;
  var $link;
  var $bundlelink;
  var $toolslink;

  if (navigator.appVersion.indexOf("Win")!=-1) {
    os = "Windows";
    $link = $('#win-sdk');
    $bundlelink = $('#win-bundle');
    $toolslink = $('#win-tools');
  } else if (navigator.appVersion.indexOf("Mac")!=-1) {
    os = "Mac";
    $link = $('#mac-sdk');
    $bundlelink = $('#mac-bundle');
    $toolslink = $('#mac-tools');
  } else if (navigator.appVersion.indexOf("Linux")!=-1) {
    os = "Linux";
    $link = $('#linux-sdk');
    $bundlelink = $('#linux-bundle');
    $toolslink = $('#linux-tools');
  }

  if (os) {
    $('#not-supported').hide();
    $('#download-button').show();
    $('#download-button').text("Download the SDK for " + os);
    $('#download-button').click(function() {onDownload($link.get());}).attr('href', $link.attr('href'),true);

    /* set up primary adt download button */
    $('#download-bundle-button').show();
    $('#download-bundle-button').append("Download the SDK <br/><span class='small'>ADT Bundle for " + os + "</span>");
    $('#download-bundle-button').click(function() {return onDownload(this,true);}).attr('href', $bundlelink.attr('href'));

    /* set up sdk tools only button */
    $('#download-tools-button').show();
    $('#download-tools-button').append("Download the SDK Tools for " + os);
    $('#download-tools-button').click(function() {return onDownload(this,true);}).attr('href', $toolslink.attr('href'));
  } else {
    $('.pax').show();
  }

  function onDownload(link, button) {

    if (button) {
      $("#downloadForRealz").html($(link).text());
    } else {
      $("#downloadForRealz").html("Download " + $(link).text());
      $("a#next-link").html("Setting Up an Existing IDE").attr('href',toRoot + 'sdk/installing/index.html');
    }
    $("#downloadForRealz").attr('href',$(link).attr('href'));

    $("#tos").fadeIn('fast');
    $("#landing").fadeOut('fast');

    location.hash = "download";
    return false;
  }


  function onAgreeChecked() {
    if ($("input#agree").is(":checked")) {
      $("a#downloadForRealz").removeClass('disabled');
    } else {
      $("a#downloadForRealz").addClass('disabled');
    }
  }

  function onDownloadForRealz(link) {
    if ($("input#agree").is(':checked')) {
      $("div.sdk-terms").slideUp();
      $("#sdk-terms-form,.sdk-terms-intro").fadeOut('slow');
      $("#next-steps").fadeIn('slow');
      $("h1#tos-header").text('Get Ready to Code!');
      return true;
    } else {
      $("label#agreeLabel").parent().stop().animate({color: "#258AAF"}, 200,
        function() {$("label#agreeLabel").parent().stop().animate({color: "#222"}, 200)}
      );
      return false;
    }
  }

  $(window).hashchange( function(){
    console.log('hash: '+location.hash);
    if (location.hash == "") {
      location.reload();
    }
  });

</script>

</div><!-- end pax -->
</div><!-- end wrap -->


</div><!-- end the wrapper used for relative/absolute positions  -->
<?cs # THIS DIV WAS OPENED IN INDEX.JD ?>




  <?cs else ?> <?cs # end if online ?>

    <?cs if:sdk.preview ?><?cs # it's preview offline docs ?>