Google announced the release of Android 18 Beta 1 late Friday, kicking off a biweekly release schedule, where previous versions received monthly updates. Google also indicated that the Android 17 QPR3 Beta is winding down.
“Today we’re releasing the first Beta of Android 18, continuing our work to build a platform that prioritizes privacy, security, and refined performance,” Google vice president Matthew McCullough says. “Android 18 extends the memory management foundation we built across Android 17, with Beta 1 introducing per-process soft memory limits for background services.”
Android 18 Beta 1 includes a handful of changes for developers, with improvements to memory handling, concurrency, and garbage collection. Google is also modernizing the Android Runtime (ART) and cleaning up legacy SDK surfaces, it says, and it has rewritten the Android graphics stack in Rust. And there are updates to the media and photo pickers, on-device search, system font customization, desktop windowing, Health Connect, and web app support.
Android 18 will be a major SDK release–API level 38–and will include breaking behavior changes. That said, the development timeline is still quite tight, with Google planning to move quickly from Beta to Platform Stability in February. At that time, it will deliver final SDK/NDK APIs and “largely final app-facing behaviors.” Then, it will be updated with quarterly minor SDK releases through early 2028.
Android 18 Beta 1 is available on supported Pixel devices and on the Android Developer website
Tagged with
Share post
`;i&&(a=`${a}
`),e.insertAdjacentHTML(n,a)}return document.getElementById(t)}_repeatDynamicAds(t){let n=[],r=t.location===e.Recipe?99:this.locationMaxLazySequence.get(t.location),i=t.lazy?D(r,0):0,a=t.max,o=t.lazyMax,s=i===0&&t.lazy?a+o:Math.min(Math.max(i-t.sequence+1,0),a+o),c=Math.max(a,s);for(let e=0;e=a,o=r;t.name===`Recipe_1`&&r>=5&&(o=r+1),n.push({…t,sequence:o,lazy:i})}return n}_locationEnabled(e){let t=this._clsOptions.enabledLocations.includes(e.location),n=this._clsOptions.disableAds&&this._clsOptions.disableAds.all||document.body.classList.contains(`adthrive-disable-all`),r=!document.body.classList.contains(`adthrive-disable-content`)&&!this._clsOptions.disableAds.reasons.has(`content_plugin`);return t&&!n&&r}};let X=()=>(window.adthriveInsertionCoordination||(window.adthriveInsertionCoordination={records:[]}),window.adthriveInsertionCoordination),dn=e=>{let t=X();return t.owner||=e,t.owner===e},fn=e=>{let t=X();t.owner===e&&(t.owner=void 0)},Z=(e,t,n={})=>{var r,i,a,o;let s=X(),c={…n,placements:(r=n.placements)==null?void 0:r.slice(0,20),elementIds:(i=n.elementIds)==null?void 0:i.slice(0,20),path:e,owner:s.owner,outcome:t,pagePath:window.location.pathname,visibilityState:document.visibilityState,readyState:document.readyState,time:Math.round(((a=window.performance)==null||(o=a.now)==null?void 0:o.call(a))??0)};return s.sink?s.sink(c):s.records.length<20&&s.records.push(c),c};var pn=class{constructor(){s(this,`_map`,[])}add(e,t,n,r=document){this._map.push({el:e,coords:t,dynamicAd:n,target:r})}addSorted(e,t,n,r=document){let i=this._upperBoundIndex(t);this._map.splice(i,0,{el:e,coords:t,dynamicAd:n,target:r})}get map(){return this._map}sort(){this._map.sort(({coords:e},{coords:t})=>e-t)}filterUsed(){this._map=this._map.filter(({dynamicAd:e})=>!e.used)}findNeighborIndices(e){let t=this._upperBoundIndex(e);return[t-1>=0?t-1:null,t>>1;this._map[r].coords<=e?t=r+1:n=r}return t}reset(){this._map=[]}},mn=class extends pn{};let hn=e=>{let t=ne(),n=se(),r=e.siteAdsProfiles,i=null;if(r&&r.length)for(let e of r){let r=e.targeting.device,a=e.targeting.browserEngine,o=r&&r.length&&r.includes(n),s=a&&a.length&&a.includes(t);o&&s&&(i=e)}return i},gn=e=>{let t=hn(e);if(t){let e=t.profileId;document.body.classList.add(`raptive-profile-${e}`)}},_n=(e,t,n)=>{t.length?Z(e,`inserted`,{…n,placements:t.map(e=>e.name),elementIds:t.map(e=>{var t;return(t=e.element)==null?void 0:t.id})}):(fn(e),Z(e,`no_candidates`,n))},Q={Rewarded_1:`Rewarded_1`,Video_Collapse_Autoplay_SoundOff:`Video_Collapse_Autoplay_SoundOff`,Video_Individual_Autoplay_SOff:`Video_Individual_Autoplay_SOff`,Video_Coll_SOff_Smartphone:`Video_Coll_SOff_Smartphone`,Video_In_Post_ClicktoPlay_SoundOn:`Video_In-Post_ClicktoPlay_SoundOn`,Video_Collapse_Autoplay_SoundOff_15s:`Video_Collapse_Autoplay_SoundOff_15s`,Video_Individual_Autoplay_SOff_15s:`Video_Individual_Autoplay_SOff_15s`,Video_Coll_SOff_Smartphone_15s:`Video_Coll_SOff_Smartphone_15s`,Video_In_Post_ClicktoPlay_SoundOn_15s:`Video_In-Post_ClicktoPlay_SoundOn_15s`};var vn=class{get enabled(){throw Error(`Enablement must be defined at factory creation time.`)}},yn=class extends vn{constructor(e,t,n){super(),this._videoConfig=e,this._component=t,this._context=n,s(this,`_potentialPlayerMap`,void 0),s(this,`_device`,void 0),s(this,`_stickyRelatedOnPage`,!1),s(this,`_relatedMediaIds`,[]),s(this,`_ownsInjectedDom`,!1),this._device=B()?`desktop`:`mobile`,this._potentialPlayerMap=this.setPotentialPlayersMap()}setPotentialPlayersMap(){let e=this._videoConfig.players||[],t=this._filterPlayerMap();return t.stationaryRelated=this._getPotentialStationaryPlayers(e,t.stationaryRelated),this._potentialPlayerMap=t,this._potentialPlayerMap}_getPotentialStationaryPlayers(e,t){let n=new Set(t);return e.forEach(e=>e.type===`stationaryRelated`&&e.enabled&&n.add(e)),[…n]}_filterPlayerMap(){let e=this._videoConfig.players,t={stickyRelated:[],stickyPlaylist:[],stationaryRelated:[]};return e&&e.length?e.filter(e=>{var t;return(t=e.devices)==null?void 0:t.includes(this._device)}).reduce((e,t)=>{if(e[t.type]||(A.event(this._component,`constructor`,`Unknown Video Player Type detected`,t.type),e[t.type]=[]),t.enabled){let n=t.type;this._videoConfig.shouldDisableStickyRelated&&t.type===`stickyRelated`&&(n=`stationaryRelated`),e[n].push(t)}return e},t):t}_checkPlayerSelectorOnPage(e){for(let t of this._potentialPlayerMap[e]){let e=this._getPlacementElement(t);if(e)return{player:t,playerElement:e}}return{player:null,playerElement:null}}_createInjectionAnchor(){let e=document.createElement(`div`);return this._ownsInjectedDom&&(e.dataset.raptiveVideoFallbackAnchor=`true`),e}_getOverrideElement(e,t,n){if(e&&t){let r=this._createInjectionAnchor();t.insertAdjacentElement(e.position,r),n=r}else{let{player:e,playerElement:t}=this._checkPlayerSelectorOnPage(`stickyPlaylist`);if(e&&t){let r=this._createInjectionAnchor();t.insertAdjacentElement(e.position,r),n=r}}return n}_shouldOverrideElement(e){let t=e.getAttribute(`override-embed`);return t===`true`||t===`false`?t===`true`:this._videoConfig.relatedSettings?this._videoConfig.relatedSettings.overrideEmbedLocation:!1}_checkPageSelector(e,t,n=[]){return e&&t&&n.length===0?(window.location.pathname!==`/`&&A.event(`VideoUtils`,`getPlacementElement`,{name:`Error`,message:`PSNF: ${e} does not exist on the page`}),!1):!0}_getElementSelector(e,t,n){return t&&t.length>n?t[n]:(A.event(`VideoUtils`,`getPlacementElement`,{name:`Error`,message:`ESNF: ${e} does not exist on the page`}),null)}_getPlacementElement(e){let{pageSelector:t,elementSelector:n,skip:r}=e,{valid:i,elements:a,…o}=Ee(t),{valid:s,elements:c,…l}=Te(n);return t!==“&&!i?(A.error(`VideoUtils`,`getPlacementElement`,Error(`${t} is not a valid selector`),o),null):s?this._checkPageSelector(t,i,a)&&this._getElementSelector(n,c,r)||null:(A.error(`VideoUtils`,`getPlacementElement`,Error(`${n} is not a valid selector`),l),null)}_getEmbeddedPlayerType(e){if(this._videoConfig.shouldDisableStickyRelated)return`static`;let t=e.getAttribute(`data-player-type`);return t&&t!==”default”||(t=this._videoConfig.relatedSettings?this._videoConfig.relatedSettings.defaultPlayerType:`static`),this._stickyRelatedOnPage&&(t=`static`),t}_getMediaId(e){let t=e.getAttribute(`data-video-id`);return t?(this._relatedMediaIds.push(t),t):!1}_getOrientation(e){return e.getAttribute(`orientation`)===`vertical`?`vertical`:`horizontal`}_createRelatedPlayer(e,t,n,r,i){t===`collapse`?this._createCollapsePlayer(e,n):t===`static`&&this._createStaticPlayer(e,n,r,i)}_createCollapsePlayer(e,t){let{player:n,playerElement:r}=this._checkPlayerSelectorOnPage(`stickyRelated`),i=n||this._potentialPlayerMap.stationaryRelated[0];if(i&&i.playerId&&!this._videoConfig.shouldDisableStickyRelated){let a=document.querySelector(`#cls-video-container-${e} > div`);a?t=a:this._shouldOverrideElement(t)&&(t=this._getOverrideElement(n,r,t)),this._createStickyRelatedPlayer({…i,mediaId:e},t)}else A.error(this._component,`_createCollapsePlayer`,`No video player found`)}_createStaticPlayer(e,t,n,r){if(this._potentialPlayerMap.stationaryRelated.length&&this._potentialPlayerMap.stationaryRelated[0].playerId){let i=this._potentialPlayerMap.stationaryRelated[0];this._createStationaryRelatedPlayer({…i,mediaOrPlaylistId:e,orientation:r},t,n)}else A.error(this._component,`_createStaticPlayer`,`No video player found`)}_shouldRunAutoplayPlayers(){return!!(this._isVideoAllowedOnPage()&&(this._potentialPlayerMap.stickyRelated.length||this._potentialPlayerMap.stickyPlaylist.length))}_setPlaylistMediaIdWhenStationaryOnPage(e,t){if(this._potentialPlayerMap.stationaryRelated.length&&this._potentialPlayerMap.stationaryRelated[0].playerId&&e&&e.length){let n=e[0].getAttribute(`data-video-id`);return n?{…t,mediaId:n}:t}return t}_determineAutoplayPlayers(e){let t=this._component,n=t===`VideoManagerComponent`,r=this._context;if(this._stickyRelatedOnPage){A.event(t,`stickyRelatedOnPage`,n&&{device:r&&r.device,isDesktop:this._device}||{});return}let{playerElement:i}=this._checkPlayerSelectorOnPage(`stickyPlaylist`),{player:a}=this._checkPlayerSelectorOnPage(`stickyPlaylist`);a&&a.playerId&&i?(a=this._setPlaylistMediaIdWhenStationaryOnPage(e,a),this._createPlaylistPlayer(a,i)):Math.random()<.01&&setTimeout(()=>{A.event(t,`noStickyPlaylist`,n&&{vendor:`none`,device:r&&r.device,isDesktop:this._device}||{})},1e3)}_initializeRelatedPlayers(e){let t=new Map;for(let n=0;n{let e=new c;if(!e||!e.enabled)return;e.siteAds&&gn(e.siteAds);let{tablet:t,desktop:n}=e.siteAds.breakpoints,r={device:L(t,n),capabilitySource:`plugin`};dn($)?(new un(e,new mn).start(),_n($,e.injectedSlots,r),new bn(new me(e),e).init()):Z($,`duplicate_prevented`,r)})()}catch(e){A.error(`CLS`,`pluginsertion-iife`,e),window.adthriveCLS&&(window.adthriveCLS.injectedFromPlugin=!1)}})();
