কার্যকলাপ
| সর্বশেষ আপডেট | স্থিতিশীল রিলিজ | রিলিজ প্রার্থী | বিটা রিলিজ | আলফা রিলিজ |
|---|---|---|---|---|
| ২৩ সেপ্টেম্বর, ২০২৬ | ১.১৩.০ | - | - | ১.১৪.০-আলফা০৩ |
নির্ভরতা ঘোষণা করা
Activity-তে ডিপেন্ডেন্সি যোগ করতে হলে, আপনাকে আপনার প্রজেক্টে Google Maven রিপোজিটরি যোগ করতে হবে। আরও তথ্যের জন্য Google-এর Maven রিপোজিটরি পড়ুন।
আপনার অ্যাপ বা মডিউলের build.gradle ফাইলে প্রয়োজনীয় আর্টিফ্যাক্টগুলোর ডিপেন্ডেন্সি যোগ করুন:
গ্রোভি
dependencies { def activity_version = "1.13.0" // Java language implementation implementation "androidx.activity:activity:$activity_version" // Kotlin implementation "androidx.activity:activity-ktx:$activity_version" }
কোটলিন
dependencies { val activity_version = "1.13.0" // Java language implementation implementation("androidx.activity:activity:$activity_version") // Kotlin implementation("androidx.activity:activity-ktx:$activity_version") }
নির্ভরতা সম্পর্কে আরও তথ্যের জন্য, 'বিল্ড নির্ভরতা যোগ করুন ' দেখুন।
প্রতিক্রিয়া
আপনার মতামত জেটপ্যাককে আরও উন্নত করতে সাহায্য করে। আপনি যদি নতুন কোনো সমস্যা খুঁজে পান অথবা এই লাইব্রেরিটি উন্নত করার জন্য কোনো ধারণা থাকে, তবে আমাদের জানান। নতুন কোনো সমস্যা তৈরি করার আগে অনুগ্রহ করে এই লাইব্রেরির বিদ্যমান সমস্যাগুলো দেখে নিন। আপনি তারকা বোতামে ক্লিক করে কোনো বিদ্যমান সমস্যায় আপনার ভোট যোগ করতে পারেন।
আরও তথ্যের জন্য ইস্যু ট্র্যাকার ডকুমেন্টেশন দেখুন।
সংস্করণ ১.১৪
সংস্করণ 1.14.0-alpha03
২৩ সেপ্টেম্বর, ২০২৬
androidx.activity:activity:1.14.0-alpha03 , androidx.activity:activity-compose:1.14.0-alpha03 , এবং androidx.activity:activity-ktx:1.14.0-alpha03 রিলিজ করা হয়েছে। ভার্সন 1.14.0-alpha03-এ এই কমিটগুলো রয়েছে।
এপিআই পরিবর্তন
-
EdgeToEdge#enable()এর পরিবর্তেWindowCompat#enableEdgeToEdge(Window)ব্যবহার করুন ( Ibff3e ) - Material 2-এর টেক্সট ফিল্ডের যে ওভারলোডগুলো
value, onValueChangeপ্যারামিটার গ্রহণ করে, সেগুলো এখন অপ্রচলিত। অনুগ্রহ করে সেই ওভারলোডে স্থানান্তরিত হন যা এর স্টেট হোইস্ট করতেTextFieldStateব্যবহার করে। ( I6b841 , b/556234973 )
বাগ সংশোধন
-
androidx.lifecycle:lifecycle-runtimeডিপেন্ডেন্সিটি 2.10.0-এ আপডেট করা হয়েছে। AGP ভার্সন 9.5.0-alpha04 বা তার পরবর্তী সংস্করণের সাথে বান্ডেল করা লাইফসাইকেল রানটাইম লিন্ট চেকগুলো চালানোর জন্য এই ভার্সনটি প্রয়োজন। ( I99bfd , b/556807521 ) -
ComponentActivityনতুনdefaultViewModelArgsএখন সরাসরি বুট কনফিগারেশনও সমর্থন করে। ( I10a08 )
সংস্করণ 1.14.0-alpha02
০৯ সেপ্টেম্বর, ২০২৬
androidx.activity:activity:1.14.0-alpha02 , androidx.activity:activity-compose:1.14.0-alpha02 , এবং androidx.activity:activity-ktx:1.14.0-alpha02 রিলিজ করা হয়েছে। ভার্সন 1.14.0-alpha02-এ এই কমিটগুলো রয়েছে।
বাগ সংশোধন
- Compose লাইব্রেরির জন্য
compileSdk37.1 সংস্করণে আপডেট করা হয়েছে। এর ফলে Compose ব্যবহারকারী সমস্ত অ্যাপ এবং লাইব্রেরির জন্যcompileSdkপর্যায়ক্রমে আপডেট করতে হবে। ( I05b0f )
সংস্করণ 1.14.0-alpha01
২৬ আগস্ট, ২০২৬
androidx.activity:activity:1.14.0-alpha01 , androidx.activity:activity-compose:1.14.0-alpha01 , এবং androidx.activity:activity-ktx:1.14.0-alpha01 রিলিজ করা হয়েছে। ভার্সন 1.14.0-alpha01-এ এই কমিটগুলো রয়েছে।
এপিআই পরিবর্তন
- এক্সপোর্ট করা অ্যাক্টিভিটিগুলোর জন্য ইনটেন্ট এক্সট্রাগুলো এখন আর
defaultViewModelCreationExtrasএ স্বয়ংক্রিয়ভাবে যুক্ত হয় না। এক্সপোর্ট করা অ্যাক্টিভিটিগুলোর ডেভেলপাররাdefaultViewModelArgsওভাররাইড করে সুস্পষ্টভাবে ভ্যালিডেটেড ইনটেন্ট এক্সট্রা সরবরাহ করতে পারেন। ( Id0cb6 , b/213646066 ) - অ্যাক্টিভিটি এখন সংশ্লিষ্ট কম্পোনেন্টগুলোর ইনস্ট্যান্স সহজে তৈরি করার জন্য
NavigationEventDispatcherOwnerএবংOnBackPressedDispatcherOwnerফ্যাক্টরি ফাংশন প্রদান করে। ( I1d259 , Iadd5c ) -
OnBackPressedDispatcherএখন একটিasNavigationEventDispatcherএক্সটেনশন প্রদান করে, যার মাধ্যমে এটিকে সহজেই একটিNavigationEventDispatcherএ রূপান্তর করা যায়। ( Id11cf )
সংস্করণ ১.১৩
সংস্করণ ১.১৩.০
১১ মার্চ, ২০২৬
androidx.activity:activity:1.13.0 , androidx.activity:activity-compose:1.13.0 , এবং androidx.activity:activity-ktx:1.13.0 রিলিজ করা হয়েছে। ভার্সন 1.13.0-এ এই কমিটগুলো অন্তর্ভুক্ত রয়েছে।
১.১২.০ সংস্করণ থেকে গুরুত্বপূর্ণ পরিবর্তনসমূহ:
-
ComponentActivityএখনOnPictureInPictureUiStateChangedProviderইন্টারফেসটি ইমপ্লিমেন্ট করে, যার ফলে এটি এখন নতুনcore:core-pipআর্টিফ্যাক্টের সাথে ইন্টিগ্রেট করতে পারে, যা যেকোনো কম্পোনেন্টকে পিকচার-ইন-পিকচার UI স্টেট পরিবর্তনের ইভেন্ট গ্রহণ করার সুযোগ দেয়। - সিস্টেম স্ট্যাটাস বারের রঙ যাতে সঠিকভাবে আপডেট হয়, তা নিশ্চিত করতে কনফিগারেশন পরিবর্তনের ক্ষেত্রে
EdgeToEdgeএখন পুনরায় চালু করা হয়।
সংস্করণ 1.13.0-rc01
২৫শে ফেব্রুয়ারি, ২০২৬
androidx.activity:activity:1.13.0-rc01 , androidx.activity:activity-compose:1.13.0-rc01 , এবং androidx.activity:activity-ktx:1.13.0-rc01 রিলিজ করা হয়েছে। ভার্সন 1.13.0-rc01-এ এই কমিটগুলো রয়েছে।
বাগ সংশোধন
- অ্যাক্টিভিটি ১.১২.৪ থেকে: সর্বশেষ URI নিরাপত্তা ফিক্সযুক্ত ডিভাইসগুলিতে ব্যবহার করার সময় ফটো এবং ভিডিও
ActivityResultContractsএখন সঠিকভাবে চালু হবে। ( I61201 , b/433708587 )
সংস্করণ 1.13.0-alpha01
১৪ জানুয়ারী, ২০২৬
androidx.activity:activity:1.13.0-alpha01 , androidx.activity:activity-compose:1.13.0-alpha01 , এবং androidx.activity:activity-ktx:1.13.0-alpha01 রিলিজ করা হয়েছে। ভার্সন 1.13.0-alpha01-এ এই কমিটগুলো রয়েছে।
নতুন বৈশিষ্ট্য
- সিস্টেম স্ট্যাটাস বারের রঙ যাতে সঠিকভাবে আপডেট হয়, তা নিশ্চিত করতে কনফিগারেশন পরিবর্তনের ক্ষেত্রে
EdgeToEdgeএখন পুনরায় চালু করা হয়। ( Id1381 , b/364713509 )
এপিআই পরিবর্তন
-
ComponentActivityএখনOnPictureInPictureUiStateChangedProviderইন্টারফেসটি ইমপ্লিমেন্ট করে, যার ফলে এটি এখন নতুনcore:core-pipআর্টিফ্যাক্টের সাথে ইন্টিগ্রেট করতে পারে, যা যেকোনো কম্পোনেন্টকে পিকচার-ইন-পিকচার UI স্টেট পরিবর্তনের ইভেন্ট গ্রহণ করার সুযোগ দেয়। ( I4df5c , b/441310308 )
বাগ সংশোধন
- অ্যাক্টিভিটি ১.১২.২ থেকে: একটি সমস্যার সমাধান করা হয়েছে যেখানে লাইফসাইকেল-সচেতন
OnBackPressedCallbackএ ম্যানুয়ালিisEnabledসেট করলে তাLifecycleস্টেটকে ওভাররাইড করে দিত, যার ফলে ক্র্যাশ হওয়ার সম্ভাবনা ছিল। ( I7d898 , b/461999811 )
সংস্করণ ১.১২
সংস্করণ ১.১২.৪
১১ ফেব্রুয়ারী, ২০২৬
androidx.activity:activity:1.12.4 , androidx.activity:activity-compose:1.12.4 , এবং androidx.activity:activity-ktx:1.12.4 রিলিজ করা হয়েছে। ভার্সন 1.12.4-এ এই কমিটগুলো অন্তর্ভুক্ত রয়েছে।
বাগ সংশোধন
- সর্বশেষ URI নিরাপত্তা সমাধানযুক্ত ডিভাইসগুলিতে ব্যবহার করা হলে ফটো এবং ভিডিও
ActivityResultContractsএখন সঠিকভাবে চালু হবে। ( I61201 , b/433708587 )
সংস্করণ ১.১২.৩
২৮ জানুয়ারী, ২০২৬
androidx.activity:activity:1.12.3 , androidx.activity:activity-compose:1.12.3 , এবং androidx.activity:activity-ktx:1.12.3 রিলিজ করা হয়েছে। ভার্সন 1.12.3-এ এই কমিটগুলো অন্তর্ভুক্ত রয়েছে।
সংস্করণ ১.১২.২
১৭ ডিসেম্বর, ২০২৫
androidx.activity:activity:1.12.2 , androidx.activity:activity-compose:1.12.2 , এবং androidx.activity:activity-ktx:1.12.2 রিলিজ করা হয়েছে। ভার্সন 1.12.2-এ এই কমিটগুলো অন্তর্ভুক্ত রয়েছে।
বাগ সংশোধন
- একটি সমস্যার সমাধান করা হয়েছে যেখানে লাইফসাইকেল-সচেতন
OnBackPressedCallbackএ ম্যানুয়ালি isEnabled সেট করলে তা লাইফসাইকেল স্টেটকে ওভাররাইড করে দিত, যার ফলে ক্র্যাশ হওয়ার সম্ভাবনা ছিল। ( I7d898 , b/461999811 )
সংস্করণ ১.১২.১
০৩ ডিসেম্বর, ২০২৫
androidx.activity:activity:1.12.1 , androidx.activity:activity-compose:1.12.1 , এবং androidx.activity:activity-ktx:1.12.1 রিলিজ করা হয়েছে। ভার্সন 1.12.1-এ এই কমিটগুলো অন্তর্ভুক্ত রয়েছে।
আপডেট করা নির্ভরতা
- কার্যকলাপ এখন নেভিগেশন ইভেন্ট 1.0.1- এর উপর নির্ভরশীল।
সংস্করণ ১.১২.০
১৯ নভেম্বর, ২০২৫
androidx.activity:activity:1.12.0 , androidx.activity:activity-compose:1.12.0 , এবং androidx.activity:activity-ktx:1.12.0 রিলিজ করা হয়েছে। ভার্সন 1.12.0-তে এই কমিটগুলো অন্তর্ভুক্ত রয়েছে।
১.১১.০ সংস্করণ থেকে গুরুত্বপূর্ণ পরিবর্তনসমূহ:
-
Androidx Activityলাইব্রেরিটি এখন নতুনNavigationEventলাইব্রেরির উপর নির্ভরশীল। এর মধ্যেComponentActivityএবংComponentDialogএNavigationEventDispatcherএর সাপোর্ট অন্তর্ভুক্ত রয়েছে। পূর্ববর্তী লাইব্রেরির সাথে ব্যাকওয়ার্ড কম্প্যাটিবল থাকা নিশ্চিত করার জন্যOnBackPressedAPI-গুলোওNavigationEventAPI-এর উপর ভিত্তি করে নতুন করে লেখা হয়েছে।
সংস্করণ 1.12.0-rc01
০৫ নভেম্বর, ২০২৫
androidx.activity:activity:1.12.0-rc01 , androidx.activity:activity-compose:1.12.0-rc01 , এবং androidx.activity:activity-ktx:1.12.0-rc01 রিলিজ করা হয়েছে। ভার্সন 1.12.0-rc01-এ এই কমিটগুলো রয়েছে।
বাগ সংশোধন
- কাস্টম অ্যাক্টিভিটি ক্লাস ব্যবহারকারী অ্যাপগুলিতে
BackHandlerএবংPredictiveBackHandlerএর রানটাইম ব্যর্থতা সংশোধন করা হয়েছে। যেসব অ্যাপNavigationEventDispatcherOwnerসমর্থন করে, সেগুলিতে এই কম্পোজেবলগুলি এখন ডিসপ্যাচ ক্রম বজায় রেখে নিরাপদেLocalOnBackPressedDispatcherOwnerএ ফলব্যাক করে। ( I43873 )
সংস্করণ 1.12.0-beta01
২২ অক্টোবর, ২০২৫
androidx.activity:activity:1.12.0-beta01 , androidx.activity:activity-compose:1.12.0-beta01 , এবং androidx.activity:activity-ktx:1.12.0-beta01 রিলিজ করা হয়েছে। ভার্সন 1.12.0-beta01-এ এই কমিটগুলো রয়েছে।
এপিআই পরিবর্তন
- রানটাইম আচরণের পরিবর্তন এবং মাইগ্রেশন পরিচালনার জন্য পরীক্ষামূলক
ActivityFlagsAPI চালু করা হলো। প্রথম ফ্ল্যাগটিOnBackPressedCallbackজন্য স্থিতিশীল ক্রম সক্ষম করে, যা লাইফসাইকেল পরিবর্তন জুড়ে ব্যাক নেভিগেশনকে আরও অনুমানযোগ্য করে তোলে। ডেভেলপাররাActivityFlags.isOnBackPressedLifecycleOrderMaintained = falseসেট করে এটি থেকে অপ্ট-আউট করতে পারেন। ( I06bdf , Id08bb , I439aa , b/422730945 , b/450533622 )
নির্ভরতা আপডেট
- লাইফসাইকেল নির্ভরতা 2.9.4 ( Ic9fb2 ) এ আপডেট করুন
সংস্করণ 1.12.0-alpha09
২৪ সেপ্টেম্বর, ২০২৫
androidx.activity:activity:1.12.0-alpha09 , androidx.activity:activity-compose:1.12.0-alpha09 , এবং androidx.activity:activity-ktx:1.12.0-alpha09 রিলিজ করা হয়েছে। ভার্সন 1.12.0-alpha09-এ এই কমিটগুলো রয়েছে।
নির্ভরশীলতার পরিবর্তন
- কার্যকলাপ এখন নেভিগেশন ইভেন্ট 1.0.0-alpha08 এর উপর নির্ভরশীল।
সংস্করণ 1.12.0-alpha08
১০ সেপ্টেম্বর, ২০২৫
androidx.activity:activity:1.12.0-alpha08 , androidx.activity:activity-compose:1.12.0-alpha08 , এবং androidx.activity:activity-ktx:1.12.0-alpha08 রিলিজ করা হয়েছে। ভার্সন 1.12.0-alpha08-এ এই কমিটগুলো রয়েছে।
নির্ভরতা আপডেট
- কার্যকলাপ এখন নেভিগেশন ইভেন্ট 1.0.0-alpha08 এর উপর নির্ভরশীল।
সংস্করণ 1.12.0-alpha07
২৭ আগস্ট, ২০২৫
androidx.activity:activity:1.12.0-alpha07 , androidx.activity:activity-compose:1.12.0-alpha07 , এবং androidx.activity:activity-ktx:1.12.0-alpha07 রিলিজ করা হয়েছে। ভার্সন 1.12.0-alpha07-এ এই কমিটগুলো অন্তর্ভুক্ত রয়েছে।
বাগ সংশোধন
- API 35-এ
EdgeToEdgeএর একটি সমস্যা সমাধান করা হয়েছে, যেখানে অদৃশ্য ভিউগুলির কারণে অপ্রত্যাশিত পরিমাপ ইনসেট ঘটত। ( If49ff )
নির্ভরতা আপডেট
- কার্যকলাপ এখন নেভিগেশন ইভেন্ট
1.0.0-alpha07এর উপর নির্ভরশীল।
সংস্করণ 1.12.0-alpha06
১৩ আগস্ট, ২০২৫
androidx.activity:activity:1.12.0-alpha06 , androidx.activity:activity-compose:1.12.0-alpha06 , এবং androidx.activity:activity-ktx:1.12.0-alpha06 রিলিজ করা হয়েছে। ভার্সন 1.12.0-alpha06-এ এই কমিটগুলো রয়েছে।
MinSdk আপডেট
- AndroidX-এর ডিফল্ট
minSdkAPI 21 থেকে API 23-এ স্থানান্তরিত করা হয়েছে ( Ibdfca , b/380448311 , b/435705964 , b/435705223 )
ডকুমেন্টেশন আপডেট
-
PredictiveBackHandlerএর জন্য KDocs আপডেট করা হয়েছে, যেখানে একটি পরিচিত টাইমিং সমস্যার কথা উল্লেখ করা হয়েছে। এই সমস্যাটি হলো, এটি নিষ্ক্রিয় হওয়ার একই ফ্রেমে কোনো জেসচার প্রসেস করতে পারে। ( I5be5c , b/431534103 ) -
BackHandlerএবংPredictiveBackHandlerএর জন্য KDocs আপডেট করা হয়েছে, যেখানে 'সর্বশেষ কম্পোজ করাটিই জয়ী হবে' এই আচরণটি স্পষ্টভাবে উল্লেখ করার পাশাপাশিenabledফ্ল্যাগ ব্যবহার করে শর্তহীন কম্পোজিশনের সুপারিশ করা হয়েছে। ( I7ab94 )
নির্ভরতা আপডেট
- কার্যকলাপ এখন নেভিগেশন ইভেন্ট
1.0.0-alpha06এর উপর নির্ভরশীল।
সংস্করণ 1.12.0-alpha05
৩০ জুলাই, ২০২৫
androidx.activity:activity:1.12.0-alpha05 , androidx.activity:activity-compose:1.12.0-alpha05 , এবং androidx.activity:activity-ktx:1.12.0-alpha05 রিলিজ করা হয়েছে। ভার্সন 1.12.0-alpha05-এ এই কমিটগুলো রয়েছে।
নির্ভরতা আপডেট
- কার্যকলাপ এখন নেভিগেশন ইভেন্ট
1.0.0-alpha05এর উপর নির্ভরশীল।
সংস্করণ 1.12.0-alpha04
২ জুলাই, ২০২৫
androidx.activity:activity:1.12.0-alpha04 , androidx.activity:activity-compose:1.12.0-alpha04 , এবং androidx.activity:activity-ktx:1.12.0-alpha04 রিলিজ করা হয়েছে। ভার্সন 1.12.0-alpha04-এ এই কমিটগুলো রয়েছে।
নির্ভরশীলতার পরিবর্তন
- অ্যাক্টিভিটি এখন NavigationEvent Alpha04-এর উপর নির্ভর করে।
সংস্করণ 1.12.0-alpha03
১৮ জুন, ২০২৫
androidx.activity:activity:1.12.0-alpha03 , androidx.activity:activity-compose:1.12.0-alpha03 , এবং androidx.activity:activity-ktx:1.12.0-alpha03 রিলিজ করা হয়েছে। ভার্সন 1.12.0-alpha03-এ এই কমিটগুলো রয়েছে।
বাগ সংশোধন
ComponentActivityতে এখনOnBackPressedDispatcherএবংNavigationEventDispatcherউভয়ই লেজিভাবে ইনিশিয়ালাইজ করা হয়। ( I710e6 )OnBackPressedDistpatcherসাথে সম্পর্কিত নিম্নলিখিত সমস্যাগুলো সমাধান করা হয়েছে:- শুধুমাত্র সর্বশেষ ডিসপ্যাচারটিতেই একটি
OnBackPressedCallbackতার সক্রিয় অবস্থা সম্পর্কে অবহিত করার জন্য যুক্ত করা হয়েছে ( b/418715930 ) - যখন লাইফসাইকেল গ্রহণকারী
addCallbackফাংশনটি ব্যবহার করা হয়, তখনOnBackPressedDispatcherভুল কলব্যাকটি সরিয়ে দেয়। ( b/422714753 ) -
OnBackPressedDispatcher.remove()একটি নিবন্ধিতOnBackPressedCallbackএর সমস্ত দৃষ্টান্ত মুছে ফেলে না। ( b/423024414 )
- শুধুমাত্র সর্বশেষ ডিসপ্যাচারটিতেই একটি
সংস্করণ 1.12.0-alpha02
৪ জুন, ২০২৫
androidx.activity:activity:1.12.0-alpha02 , androidx.activity:activity-compose:1.12.0-alpha02 , এবং androidx.activity:activity-ktx:1.12.0-alpha02 রিলিজ করা হয়েছে। ভার্সন 1.12.0-alpha02-এ এই কমিটগুলো রয়েছে।
বাগ সংশোধন
- NavigationEvent
1.0.0-alpha02থেকে : একটিConcurrentModificationExceptionসংশোধন করা হয়েছে যাNavigationEventCallback.remove()কল করার সময় ক্লোজেবল-এর অভ্যন্তরীণ তালিকা একই সাথে পরিবর্তন করার কারণে ঘটতে পারতো। ( I63066 )
সংস্করণ 1.12.0-alpha01
২০ মে, ২০২৫
androidx.activity:activity:1.12.0-alpha01 , androidx.activity:activity-compose:1.12.0-alpha01 , এবং androidx.activity:activity-ktx:1.12.0-alpha01 রিলিজ করা হয়েছে। ভার্সন 1.12.0-alpha01-এ এই কমিটগুলো রয়েছে।
নতুন বৈশিষ্ট্য
-
ComponentActivityএবংComponentDialogNavigationEventDispatcherOwnerAPI-এর মাধ্যমে NavigationEvent1.0.0-alpha01সাথে একীভূত করা হয়েছে। আপনি এখন আপনারComponentActivityথেকেnavigationEventDispatcherফিল্ডের মাধ্যমে একটিNavigationEventDispatcherপেতে পারেন। যেহেতুOnBackPressedDispatcherনতুন লাইব্রেরির উপর ভিত্তি করে পুনরায় লেখা হয়েছে, তাই পূর্ববর্তী সমস্ত ব্যবহার সঠিকভাবে কাজ করতে থাকবে। এখন থেকে আপনারNavigationEventDispatcherএবংNavigationEventCallbackব্যবহার করা উচিত। ( Ib8eed , I6cc44 , Ib7724 , I9a0f7 , b/412597031 , b/415028038 , b/412596729 , b/412597140 , b/412596012 )
সংস্করণ ১.১১
সংস্করণ ১.১১.০
১০ সেপ্টেম্বর, ২০২৫
androidx.activity:activity:1.11.0 , androidx.activity:activity-compose:1.11.0 , এবং androidx.activity:activity-ktx:1.11.0 রিলিজ করা হয়েছে। ভার্সন 1.11.0-এ এই কমিটগুলো অন্তর্ভুক্ত রয়েছে।
১.১০.০ সংস্করণ থেকে গুরুত্বপূর্ণ পরিবর্তনসমূহ:
-
PickVisualMediaRequestএMediaCapabilitiesAPI যোগ করা হয়েছে, যার ফলে অ্যাপ্লিকেশনগুলো তাদের মিডিয়া সক্ষমতা, যেমন সমর্থিত HDR টাইপ, নির্দিষ্ট করতে পারবে। - অ্যাক্টিভিটিটি এখন এপিআই ৩৬ দিয়ে কম্পাইল করা হয়েছে।
সংস্করণ 1.11.0-rc01
২৩ এপ্রিল, ২০২৫
androidx.activity:activity:1.11.0-rc01 , androidx.activity:activity-compose:1.11.0-rc01 , এবং androidx.activity:activity-ktx:1.11.0-rc01 রিলিজ করা হয়েছে। ভার্সন 1.11.0-rc01-এ এই কমিটগুলো রয়েছে।
সংস্করণ 1.11.0-beta01
৯ এপ্রিল, ২০২৫
androidx.activity:activity:1.11.0-beta01 , androidx.activity:activity-compose:1.11.0-beta01 , এবং androidx.activity:activity-ktx:1.11.0-beta01 রিলিজ করা হয়েছে। ভার্সন 1.11.0-beta01-এ এই কমিটগুলো রয়েছে।
সংস্করণ 1.11.0-alpha02
২৬ মার্চ, ২০২৫
androidx.activity:activity:1.11.0-alpha02 , androidx.activity:activity-compose:1.11.0-alpha02 , এবং androidx.activity:activity-ktx:1.11.0-alpha02 রিলিজ করা হয়েছে। ভার্সন 1.11.0-alpha02-এ এই কমিটগুলো রয়েছে।
এপিআই পরিবর্তন
-
OnBackPressedCallbackএরhandleOnBackStartedএবংhandleOnBackProgressedফাংশন দ্বারা প্রদত্তBackEventCompatমধ্যে Android 16 Beta03-এর নতুনEDGE_NONEএবংframeTimeMillisএকীভূত করা হয়েছে।
নির্ভরতা আপডেট
- অ্যাক্টিভিটিটি এখন এপিআই ৩৬ দিয়ে কম্পাইল করা হয়েছে। ( I510e8 , b/301910674 )
সংস্করণ 1.11.0-alpha01
১২ মার্চ, ২০২৫
androidx.activity:activity:1.11.0-alpha01 , androidx.activity:activity-compose:1.11.0-alpha01 , এবং androidx.activity:activity-ktx:1.11.0-alpha01 রিলিজ করা হয়েছে। ভার্সন 1.11.0-alpha01-এ এই কমিটগুলো রয়েছে।
নতুন বৈশিষ্ট্য
-
PickVisualMediaRequestএMediaCapabilitiesAPI যোগ করা হয়েছে, যাতে অ্যাপ্লিকেশনগুলো তাদের মিডিয়া সক্ষমতা, যেমন সমর্থিত HDR প্রকার, নির্দিষ্ট করতে পারে। ( Ic3ee7 )
সংস্করণ ১.১০
সংস্করণ ১.১০.১
২৬ ফেব্রুয়ারী, ২০২৫
androidx.activity:activity:1.10.1 , androidx.activity:activity-compose:1.10.1 , এবং androidx.activity:activity-ktx:1.10.1 রিলিজ করা হয়েছে। ভার্সন 1.10.1-এ এই কমিটগুলো অন্তর্ভুক্ত রয়েছে।
বাগ সংশোধন
-
ViewTreeOnBackPressedDispatcherOwnersএবংFullyDrawnReporterOwnersএখন একটি ভিউ-এর ডিসজয়েন্ট প্যারেন্ট, যেমন একটিViewOverlayমাধ্যমে রিজলভ করা যাবে। ডিসজয়েন্ট ভিউ প্যারেন্ট সম্পর্কে আরও তথ্যের জন্য কোর-এর রিলিজ নোট অথবাViewTree.setViewTreeDisjointParentএর ডকুমেন্টেশন দেখুন। ( Ie7750 )
সংস্করণ ১.১০.০
১৫ জানুয়ারী, ২০২৫
androidx.activity:activity:1.10.0 , androidx.activity:activity-compose:1.10.0 , এবং androidx.activity:activity-ktx:1.10.0 রিলিজ করা হয়েছে। ভার্সন 1.10.0-এ এই কমিটগুলো অন্তর্ভুক্ত রয়েছে।
১.৯.০ সংস্করণ থেকে গুরুত্বপূর্ণ পরিবর্তনসমূহ
-
PhotoPickerএখন ক্রমানুসারে ছবি বাছাই করা এবং কোন ট্যাবটি (অ্যালবাম অথবা ছবি) প্রথমে দেখা যাবে তা বেছে নেওয়ার সুবিধা রয়েছে। -
PickVisualMediaএবংPickMultipleVisualMediaঅ্যাক্টিভিটি রেজাল্ট কন্ট্রাক্টগুলো, যা ফটো পিকারকে ট্রিগার করে, সিস্টেম ফটো পিকার উপলব্ধ না থাকলে আর সরাসরি গুগল প্লে সার্ভিসের উপর দায়িত্ব অর্পণ করে না; বরং ফলব্যাক হিসেবে OEM এবং সিস্টেম অ্যাপগুলোকে একটি সামঞ্জস্যপূর্ণ ফটো পিকার অভিজ্ঞতা প্রদানের জন্য পাবলিকACTION_SYSTEM_FALLBACK_PICK_IMAGESঅ্যাকশন এবং সম্পর্কিত এক্সট্রাগুলো ব্যবহার করে। - নতুন
LocalActivityকম্পোজিশনটি বর্তমান স্কোপের জন্যActivityপ্রদান করে, ফলে ডেভেলপারদেরLocalContextথেকেActivityনেওয়ার প্রয়োজন হয় না।
সংস্করণ 1.10.0-rc01
১১ ডিসেম্বর, ২০২৪
androidx.activity:activity:1.10.0-rc01 , androidx.activity:activity-compose:1.10.0-rc01 , এবং androidx.activity:activity-ktx:1.10.0-rc01 রিলিজ করা হয়েছে। ভার্সন 1.10.0-rc01-এ এই কমিটগুলো রয়েছে।
বাগ সংশোধন
- একটি সমস্যার সমাধান করা হয়েছে যেখানে
PredictiveBackHandlerসক্রিয় থাকা অবস্থায় এর এনাবলড অবস্থা পরিবর্তন করলে কলব্যাকটি তাৎক্ষণিকভাবে শর্ট সার্কিট হয়ে যেত। এখন থেকে এনাবলড অবস্থার পরিবর্তন নির্বিশেষে এটি বর্তমান কলব্যাকটি সম্পন্ন করবে। ( Ib8719 )
সংস্করণ 1.10.0-beta01
১৩ নভেম্বর, ২০২৪
androidx.activity:activity:1.10.0-beta01 , androidx.activity:activity-compose:1.10.0-beta01 , এবং androidx.activity:activity-ktx:1.10.0-beta01 সর্বশেষ আলফার পর থেকে কোনো পরিবর্তন ছাড়াই প্রকাশ করা হয়েছে। সংস্করণ 1.10.0-beta01-এ এই কমিটগুলো রয়েছে।
সংস্করণ 1.10.0-alpha03
৩০ অক্টোবর, ২০২৪
androidx.activity:activity:1.10.0-alpha03 , androidx.activity:activity-compose:1.10.0-alpha03 , এবং androidx.activity:activity-ktx:1.10.0-alpha03 রিলিজ করা হয়েছে। ভার্সন 1.10.0-alpha03-এ এই কমিটগুলো অন্তর্ভুক্ত রয়েছে।
এপিআই পরিবর্তন
- একটি নতুন
LocalActivityকম্পোজিশন লোকাল যোগ করা হয়েছে যা বর্তমান স্কোপের জন্যActivityপ্রদান করে, ফলে ডেভেলপারদেরLocalContextথেকেActivityনেওয়ার প্রয়োজন হয় না। এর সাথে একটি নতুন লিন্ট রুলও রয়েছে যা পরীক্ষা করে দেখে কখনLocalContextভুলভাবেActivityতে কাস্ট করা হচ্ছে। ( I7746a , b/283009666 )
বাগ সংশোধন
- অ্যাক্টিভিটি
1.9.3থেকে: হ্যান্ডলারটি নিষ্ক্রিয় হয়ে যাওয়ার পরPredictiveBackHandlerআর তার কলব্যাক ফায়ার করবে না। এর মাধ্যমে সেই সমস্যার সমাধান করা হবে যেখানে Navigation Compose-এরNavHostএকটিIndexOutOfBoundsExceptionথ্রো করত। ( I3f75e , b/365027664 , b/340202286 )
নির্ভরতা আপডেট
- অ্যাক্টিভিটি কম্পোজ এখন কম্পোজ রানটাইম 1.7.0 ( I7746a , b/283009666 ) এর উপর নির্ভরশীল।
সংস্করণ 1.10.0-alpha02
৪ সেপ্টেম্বর, ২০২৪
androidx.activity:activity:1.10.0-alpha02 , androidx.activity:activity-compose:1.10.0-alpha02 , এবং androidx.activity:activity-ktx:1.10.0-alpha02 রিলিজ করা হয়েছে। ভার্সন 1.10.0-alpha02-এ এই কমিটগুলো অন্তর্ভুক্ত রয়েছে।
আচরণগত পরিবর্তন
-
PickVisualMediaএবংPickMultipleVisualMediaঅ্যাক্টিভিটি রেজাল্ট কন্ট্রাক্টগুলো, যা ফটো পিকারকে ট্রিগার করে, সিস্টেম ফটো পিকার উপলব্ধ না থাকলে আর সরাসরি গুগল প্লে সার্ভিসের উপর দায়িত্ব অর্পণ করে না, বরং একটি ফলব্যাক হিসেবে OEM এবং সিস্টেম অ্যাপগুলোকে একটি সামঞ্জস্যপূর্ণ ফটো পিকার অভিজ্ঞতা প্রদানের জন্য পাবলিকACTION_SYSTEM_FALLBACK_PICK_IMAGESঅ্যাকশন এবং সম্পর্কিত এক্সট্রাগুলো ব্যবহার করে। যেসব ডিভাইসে গুগল প্লে সার্ভিসের সাম্প্রতিক সংস্করণ রয়েছে, সেগুলোর ব্যবহারকারীর অভিজ্ঞতার উপর এর কোনো প্রভাব পড়া উচিত নয়। ( I3513d )
বাগ সংশোধন
- নতুন প্ল্যাটফর্ম এপিআই-গুলিতে অ্যাক্সেসের ম্যানুয়াল রূপরেখা সরিয়ে দেওয়া হয়েছে, কারণ AGP 7.3 বা তার পরবর্তী সংস্করণের (যেমন R8 সংস্করণ 3.3) সাথে R8 ব্যবহার করার সময় এবং AGP 8.1 বা তার পরবর্তী সংস্করণের (যেমন D8 সংস্করণ 8.1) সাথে সমস্ত বিল্ডের জন্য এটি এপিআই মডেলিংয়ের মাধ্যমে স্বয়ংক্রিয়ভাবে ঘটে। যেসব ক্লায়েন্ট AGP ব্যবহার করছেন না, তাদের D8 সংস্করণ 8.1 বা তার পরবর্তী সংস্করণে আপডেট করার পরামর্শ দেওয়া হচ্ছে। আরও বিস্তারিত জানতে এই নিবন্ধটি দেখুন। ( I9496c , b/345472586 )
- অ্যাক্টিভিটি
1.9.2থেকে: একটি সমস্যার সমাধান করা হয়েছে যেখানে অ্যাক্টিভিটি কম্পোজPredictiveBackHandlerএপিআই (Activity Compose PredictiveBackHandler API) নিষ্ক্রিয় থাকা ফ্রেমেও সিস্টেম ব্যাক জেসচারটি পরিচালনা করতে থাকতো, যার ফলে নেভিগেশন কম্পোজের (Navigation Compose) মতো লাইব্রেরিগুলো একটি খালি ব্যাক স্ট্যাক থাকা সত্ত্বেও ব্যাক জেসচার পরিচালনা করতে পারতো, যা একটিIndexOutOfBoundsException) থ্রো করতো। ( Ie3301 , b/340202286 ) - অ্যাক্টিভিটি
1.9.1থেকে:PredictiveBackHandlerএর একটি সমস্যা সমাধান করা হয়েছে, যেখানে সিস্টেম ব্যাক করার পরOnBackPressedDispatcherথেকেonBackPressedকরার চেষ্টা ব্যর্থ হতো। ( I5f1f8 )
সংস্করণ 1.10.0-alpha01
২৬ জুন, ২০২৪
androidx.activity:activity:1.10.0-alpha01 , androidx.activity:activity-compose:1.10.0-alpha01 , এবং androidx.activity:activity-ktx:1.10.0-alpha01 রিলিজ করা হয়েছে। এই সংস্করণটি একটি অভ্যন্তরীণ শাখায় তৈরি করা হয়েছে।
নতুন বৈশিষ্ট্য
- অ্যান্ড্রয়েড V-তে প্রবর্তিত নতুন
PhotoPickerবৈশিষ্ট্যগুলির জন্য সমর্থন যোগ করা হয়েছে, যার মধ্যে রয়েছে ছবিগুলিকে ক্রমানুসারে বাছাই করার এবং কোন ট্যাবটি (অ্যালবাম বা ছবি) প্রথমে দৃশ্যমান হবে তা বেছে নেওয়ার সুবিধা।
সংস্করণ ১.৯
সংস্করণ ১.৯.৩
১৬ অক্টোবর, ২০২৪
androidx.activity:activity:1.9.3 , androidx.activity:activity-compose:1.9.3 , এবং androidx.activity:activity-ktx:1.9.3 রিলিজ করা হয়েছে। ভার্সন 1.9.3-এ এই কমিটগুলো অন্তর্ভুক্ত রয়েছে।
বাগ সংশোধন
- হ্যান্ডলারটি নিষ্ক্রিয় হয়ে যাওয়ার পর
PredictiveBackHandlerআর তার কলব্যাক ফায়ার করবে না। এর ফলে সেই সমস্যাটির সমাধান হবে যেখানে Navigation Compose-এরNavHostএকটিIndexOutOfBoundsExceptionথ্রো করত। ( I3f75e , b/340202286 )
সংস্করণ ১.৯.২
৪ সেপ্টেম্বর, ২০২৪
androidx.activity:activity:1.9.2 , androidx.activity:activity-compose:1.9.2 , এবং androidx.activity:activity-ktx:1.9.2 প্রকাশিত হয়েছে। সংস্করণ 1.9.2-এ এই lthcocommit-গুলো রয়েছে।
বাগ সংশোধন
- একটি সমস্যার সমাধান করা হয়েছে যেখানে Activity Compose
PredictiveBackHandlerAPI-টি নিষ্ক্রিয় থাকা ফ্রেমেও সিস্টেম ব্যাক জেসচারটি পরিচালনা করতে থাকতো, যার ফলে Navigation Compose-এর মতো লাইব্রেরিগুলো একটি খালি ব্যাক স্ট্যাক থাকা সত্ত্বেও ব্যাক জেসচার পরিচালনা করত এবং এর ফলস্বরূপ একটিIndexOutOfBoundsExceptionথ্রো করত। ( Ie3301 , b/340202286 )
সংস্করণ ১.৯.১
২৪ জুলাই, ২০২৪
androidx.activity:activity:1.9.1 , androidx.activity:activity-compose:1.9.1 , এবং androidx.activity:activity-ktx:1.9.1 রিলিজ করা হয়েছে। ভার্সন 1.9.1-এ এই কমিটগুলো অন্তর্ভুক্ত রয়েছে।
বাগ সংশোধন
-
PredictiveBackHandlerএর একটি সমস্যা সমাধান করা হয়েছে, যেখানে সিস্টেম ব্যাক করার পরOnBackPressedDispatcherথেকেonBackPressedকরার চেষ্টা ব্যর্থ হতো। ( I5f1f8 )
সংস্করণ ১.৯.০
১৭ এপ্রিল, ২০২৪
androidx.activity:activity:1.9.0 , androidx.activity:activity-compose:1.9.0 , এবং androidx.activity:activity-ktx:1.9.0 রিলিজ করা হয়েছে। ভার্সন 1.9.0-এ এই কমিটগুলো অন্তর্ভুক্ত রয়েছে।
১.৮.০ সংস্করণ থেকে গুরুত্বপূর্ণ পরিবর্তনসমূহ
-
ComponentActivityএখনOnUserLeaveHintProviderইমপ্লিমেন্ট করে, যা কম্পোনেন্টগুলোকেonUserLeaveHintইভেন্টের জন্য কলব্যাক করার সুযোগ দেয়। -
OnBackPressedCallback,BackHandler, এবংPredictiveBackHandlerAPI-গুলো এখন ব্যাক হ্যান্ডলিং করার সময়onBackPressedDispatcher.onBackPressed()কল করলে সতর্কবার্তা দেখায়, কারণ এটি সর্বদা Predictive Back Animation-কে ভেঙে দেয়। আরও বিস্তারিত জানতে সেরা অনুশীলন নির্দেশিকা দেখুন। - অ্যাক্টিভিটি এপিআই-এর বাকি অংশ কোটলিনে নতুন করে লেখা হয়েছে এবং পূর্বে
activity-ktxএ উপলব্ধ সমস্ত এক্সটেনশনactivityতে স্থানান্তর করা হয়েছে।activity-ktxএখন সম্পূর্ণ খালি।-
ActivityResultLauncherকে Kotlin-এ রূপান্তরের অংশ হিসেবে,getContractমেথডটি এখন একটি অ্যাবস্ট্রাক্ট Kotlin প্রপার্টি। এটি একটি বাইনারি কম্প্যাটিবল পরিবর্তন, কিন্তু আপনারActivityResultLauncherএর ইমপ্লিমেন্টেশনটি Kotlin-এ লেখা হলে এটি সোর্স কোডকে ক্ষতিগ্রস্ত করবে।
-
সংস্করণ 1.9.0-rc01
৩ এপ্রিল, ২০২৪
androidx.activity:activity:1.9.0-rc01 , androidx.activity:activity-compose:1.9.0-rc01 , এবং androidx.activity:activity-ktx:1.9.0-rc01 রিলিজ করা হয়েছে। ভার্সন 1.9.0-rc01-এ এই কমিটগুলো রয়েছে।
নির্ভরতা আপডেট
- কার্যকলাপটি এখন প্রোফাইল ইনস্টলার ১.৩.১ এর উপর নির্ভরশীল।
সংস্করণ 1.9.0-beta01
২০ মার্চ, ২০২৪
androidx.activity:activity:1.9.0-beta01 , androidx.activity:activity-compose:1.9.0-beta01 , এবং androidx.activity:activity-ktx:1.9.0-beta01 প্রকাশিত হয়েছে। সংস্করণ 1.9.0-beta01-এ এই কমিটগুলো রয়েছে।
বাগ সংশোধন
- অ্যাক্টিভিটি তৈরির অংশ হিসেবে
OnBackPressedDispatcherকল করার কারণে অ্যাক্টিভিটি1.9.0-alpha02এ প্রবর্তিত একটি অ্যাক্টিভিটি স্টার্টআপ পারফরম্যান্স রিগ্রেশন সংশোধন করা হয়েছে। ( Ie75e3 )
সংস্করণ 1.9.0-alpha03
৭ ফেব্রুয়ারী, ২০২৪
androidx.activity:activity:1.9.0-alpha03 , androidx.activity:activity-compose:1.9.0-alpha03 , এবং androidx.activity:activity-ktx:1.9.0-alpha03 রিলিজ করা হয়েছে। ভার্সন 1.9.0-alpha03-এ এই কমিটগুলো অন্তর্ভুক্ত রয়েছে।
লিন্ট সতর্কতা
-
OnBackPressedCallback,BackHandler, এবংPredictiveBackHandlerAPI-গুলো এখন ব্যাক হ্যান্ডলিং করার সময়onBackPressedDispatcher.onBackPressed()কল করলে সতর্কবার্তা দেখায়, কারণ এটি সর্বদা Predictive Back Animation-কে ভেঙে দেবে। আরও বিস্তারিত জানতে সেরা অনুশীলন নির্দেশিকা দেখুন। ( 1e4222 , 2c950d , b/287505200 )
বাগ সংশোধন
- যদি আগে থেকেই চলমান কোনো প্রেডিক্টিভ ব্যাক জেসচার চলাকালীন সিস্টেম থেকে একটি ব্যাক ইভেন্ট পাঠানো হয়, তাহলে বর্তমানে চলমান প্রেডিক্টিভ ব্যাক জেসচারটি বাতিল হয়ে যায় এবং নতুন ব্যাক ইভেন্টটি একটি নতুন প্রেডিক্টিভ ব্যাক জেসচার শুরু করার জন্য তার স্থান গ্রহণ করে। ( I3482e )
- ব্যাকগ্রাউন্ড থ্রেড থেকে প্রথমবারের মতো কোনো
ComponentActivityএরonBackPressedDispatcherঅ্যাক্সেস করার সময় হওয়া ক্র্যাশটি সংশোধন করা হয়েছে। এখন যেকোনো থ্রেড থেকেonBackPressedDispatcherনিরাপদে অ্যাক্সেস করা যাবে। ( I79955 )
সংস্করণ 1.9.0-alpha02
২৪ জানুয়ারী, ২০২৪
androidx.activity:activity:1.9.0-alpha02 , androidx.activity:activity-compose:1.9.0-alpha02 , এবং androidx.activity:activity-ktx:1.9.0-alpha02 রিলিজ করা হয়েছে। ভার্সন 1.9.0-alpha02-এ এই কমিটগুলো অন্তর্ভুক্ত রয়েছে।
কোটলিন রূপান্তর
-
ActivityResultRegistryকোটলিনে নতুন করে লেখা হয়েছে। এটি নিশ্চিত করে যে,registerএ পাঠানো কন্ট্রাক্টের জেনেরিকগুলোর নালিবিলিটি (nullability) আপনাকে ফেরত দেওয়াActivityResultLauncherএ সঠিকভাবে স্থানান্তরিত হবে। ( I121f0 ) -
ActivityResultকোটলিনে নতুন করে লেখা হয়েছে।ActivityResultযে কোটলিন এক্সটেনশনগুলোresultCodeএবংdataফিল্ডে ডিস্ট্রাকচারিং সমর্থন করে, সেগুলোকেactivity-ktxথেকেactivityতে স্থানান্তর করা হয়েছে। ( I0565a ) -
ComponentActivityএবংtrackPipAnimationHintViewএর জন্যby viewModels()এর কোটলিন এক্সটেনশনগুলোactivity-ktxথেকেactivityতে সরানো হয়েছে। `activity-ktxআর্টিফ্যাক্টটি এখন সম্পূর্ণ খালি। ( I0a444 )
বাগ সংশোধন
-
enableEdgeToEdgeAPI এখন যেকোনো ডিসপ্লে কাটআউটের চারপাশে অঙ্কন করে। ( a3644b , b/311173461 ) - অ্যাক্টিভিটি
1.8.2থেকে: ফটো পিকার অ্যাক্টিভিটি কন্ট্রাক্টেরACTION_SYSTEM_FALLBACK_PICK_IMAGESএ পাস করা এক্সট্রাটি সংশোধন করা হয়েছে, যাতে"com.google.android.gms.provider.extra.PICK_IMAGES_MAX"কী-এর পরিবর্তে সঠিকভাবেEXTRA_SYSTEM_FALLBACK_PICK_IMAGES_MAXকী পাস করা হয়। আপনি যদি একজন OEM হন এবং একটি সিস্টেম ফলব্যাক ফটো পিকার প্রয়োগ করেন, তবে সর্বাধিক সামঞ্জস্যতা নিশ্চিত করার জন্য উভয় এক্সট্রা সমর্থন করার জন্য দৃঢ়ভাবে সুপারিশ করা হচ্ছে। ( I96a00 )
সংস্করণ 1.9.0-alpha01
২৯ নভেম্বর, ২০২৩
androidx.activity:activity:1.9.0-alpha01 , androidx.activity:activity-compose:1.9.0-alpha01 , এবং androidx.activity:activity-ktx:1.9.0-alpha01 রিলিজ করা হয়েছে। ভার্সন 1.9.0-alpha01-এ এই কমিটগুলো অন্তর্ভুক্ত রয়েছে।
নতুন বৈশিষ্ট্য
-
ComponentActivityএখনOnUserLeaveHintProviderইমপ্লিমেন্ট করে, যা কম্পোনেন্টগুলোকেonUserLeaveHintইভেন্টের জন্য কলব্যাক করার সুযোগ দেয়। ( I54892 )
এপিআই পরিবর্তন
-
ComponentActivityকোটলিনে নতুন করে লেখা হয়েছে। ( I14f31 ) -
ActivityResultCallerকোটলিনে নতুন করে লেখা হয়েছে। ( Ib02e4 ) -
ActivityResultLauncherকোটলিনে নতুন করে লেখা হয়েছে। এই রূপান্তরের অংশ হিসেবে,getContractমেথডটি এখন একটি অ্যাবস্ট্রাক্ট কোটলিন প্রপার্টি। এটি একটি বাইনারি কম্প্যাটিবল পরিবর্তন, কিন্তু আপনারActivityResultLauncherএর ইমপ্লিমেন্টেশনটি কোটলিনে লেখা হলে এটি সোর্স কোডকে ক্ষতিগ্রস্ত করবে। ( Id4615 ) -
PickVisualMediaRequestএর সর্বনিম্ন API লেভেল এখনPickVisualMediaActivity Result কন্ট্রাক্টের মতোই 19 হয়েছে। ( Id6e21 )
নির্ভরতা আপডেট
- কার্যকলাপ এখন Core
1.13.0-alpha01এর উপর নির্ভরশীল। ( I14f31 )
সংস্করণ ১.৮
সংস্করণ ১.৮.২
১৩ ডিসেম্বর, ২০২৩
androidx.activity:activity:1.8.2 , androidx.activity:activity-compose:1.8.2 , এবং androidx.activity:activity-ktx:1.8.2 রিলিজ করা হয়েছে। ভার্সন 1.8.2-এ এই কমিটগুলো অন্তর্ভুক্ত রয়েছে।
বাগ সংশোধন
- ফটো পিকার অ্যাক্টিভিটি কন্ট্রাক্টের
ACTION_SYSTEM_FALLBACK_PICK_IMAGESএ পাস করা এক্সট্রাটি সংশোধন করা হয়েছে, যাতে"com.google.android.gms.provider.extra.PICK_IMAGES_MAX"কী-এর পরিবর্তে এখন সঠিকভাবেEXTRA_SYSTEM_FALLBACK_PICK_IMAGES_MAXকী-টি পাস করা হয়। আপনি যদি একজন OEM হন এবং একটি সিস্টেম ফলব্যাক ফটো পিকার প্রয়োগ করেন, তবে সর্বাধিক সামঞ্জস্যতা নিশ্চিত করার জন্য উভয় এক্সট্রা সমর্থন করার জন্য দৃঢ়ভাবে সুপারিশ করা হচ্ছে। ( I96a00 )
সংস্করণ ১.৮.১
১৫ নভেম্বর, ২০২৩
androidx.activity:activity:1.8.1 , androidx.activity:activity-compose:1.8.1 , এবং androidx.activity:activity-ktx:1.8.1 রিলিজ করা হয়েছে। ভার্সন 1.8.1-এ এই কমিটগুলো অন্তর্ভুক্ত রয়েছে।
বাগ সংশোধন
- ব্যাক জেসচারটি হ্যান্ডেল করার সময় একটি নতুন
OnBackPressedCallbackযোগ করা হলেও,OnBackPressedDispatcherএখন সঠিকOnBackPressedCallbackএই ডিসপ্যাচ করতে থাকে। ( Id0ff6 )
সংস্করণ ১.৮.০
৪ অক্টোবর, ২০২৩
androidx.activity:activity:1.8.0 , androidx.activity:activity-compose:1.8.0 , এবং androidx.activity:activity-ktx:1.8.0 রিলিজ করা হয়েছে। ভার্সন 1.8.0-তে এই কমিটগুলো অন্তর্ভুক্ত রয়েছে।
১.৭.০ সংস্করণ থেকে গুরুত্বপূর্ণ পরিবর্তনসমূহ
- প্রেডিক্টিভ ব্যাক -
OnBackPressedCallbackএখন ব্যাক জেসচার শুরু হওয়া, জেসচার চলাকালীন অগ্রগতি এবং ব্যাক জেসচার বাতিল হওয়া পরিচালনা করার জন্য নতুন প্রেডিক্টিভ ব্যাক কলব্যাক প্রদান করে। এর সাথে ব্যাক জেসচারটি সম্পন্ন হওয়ার জন্য পূর্ববর্তীhandleOnBackPressed()কলব্যাকটিও রয়েছে। অ্যাক্টিভিটি কম্পোজে প্রেডিক্টিভ ব্যাক জেসচার ইভেন্টগুলো পরিচালনা করার জন্য এর সাথেPredictiveBackHandlerকম্পোজেবলটিও আসে। এটি BackEventCompat অবজেক্টের একটি ফ্লো প্রদান করে, যা আপনার দেওয়া সাসপেন্ডিং ল্যাম্বডাতে অবশ্যই সংগ্রহ করতে হবে:
PredictiveBackHandler { progress: Flow<BackEventCompat> ->
// code for gesture back started
try {
progress.collect { backEvent ->
// code for progress
}
// code for completion
} catch (e: CancellationException) {
// code for cancellation
}
}
ব্যাক হ্যান্ডলিং-এর এপিআই ব্যবহারের সুবিধার জন্য ComponentActivity.onBackPressed() এখন অপ্রচলিত ঘোষণা করা হয়েছে। ডেভেলপারদের এখন এই মেথডটি ওভাররাইড না করে OnBackPressedDispatcher ব্যবহার করা উচিত।
- EdgeToEdge - পূর্ববর্তী সংস্করণের সাথে সামঞ্জস্যপূর্ণভাবে সহজে প্রান্ত থেকে প্রান্ত পর্যন্ত ডিসপ্লে সেট আপ করার জন্য
ComponentActivity.enableEdgeToEdge()যোগ করা হয়েছে।
সংস্করণ 1.8.0-rc01
২০ সেপ্টেম্বর, ২০২৩
androidx.activity:activity:1.8.0-rc01 , androidx.activity:activity-compose:1.8.0-rc01 , এবং androidx.activity:activity-ktx:1.8.0-rc01 রিলিজ করা হয়েছে। ভার্সন 1.8.0-rc01-এ এই কমিটগুলো অন্তর্ভুক্ত রয়েছে।
সংস্করণ 1.8.0-beta01
৬ সেপ্টেম্বর, ২০২৩
androidx.activity:activity:1.8.0-beta01 , androidx.activity:activity-compose:1.8.0-beta01 , এবং androidx.activity:activity-ktx:1.8.0-beta01 রিলিজ করা হয়েছে। ভার্সন 1.8.0-beta01-এ এই কমিটগুলো অন্তর্ভুক্ত রয়েছে।
ডকুমেন্টেশন উন্নতি
-
BackEventCompatএর ডকুমেন্টেশন উন্নত করা হয়েছে। ( aosp/2722254 )
সংস্করণ 1.8.0-alpha07
২৩শে আগস্ট, ২০২৩
androidx.activity:activity:1.8.0-alpha07 , androidx.activity:activity-compose:1.8.0-alpha07 , এবং androidx.activity:activity-ktx:1.8.0-alpha07 রিলিজ করা হয়েছে। ভার্সন 1.8.0-alpha07-এ এই কমিটগুলো অন্তর্ভুক্ত রয়েছে।
নতুন বৈশিষ্ট্য
অ্যাক্টিভিটি কম্পোজ প্রেডিক্টিভ ব্যাক জেসচার ইভেন্টগুলি পরিচালনা করার জন্য একটি নতুন
PredictiveBackHandlerComposable যুক্ত করেছে। এটিBackEventCompatঅবজেক্টের একটিFlowপ্রদান করে যা আপনার সরবরাহ করা সাসপেন্ডিং ল্যাম্বডাতে অবশ্যই সংগ্রহ করতে হবে:PredictiveBackHandler { progress: Flow<BackEventCompat> -> // code for gesture back started try { progress.collect { backEvent -> // code for progress } // code for completion } catch (e: CancellationException) { // code for cancellation } }Flowযেনcollect()কল করে, তা নিশ্চিত করার জন্য এতে লিন্ট রুলের মাধ্যমে একটি কম্পাইল টাইম ওয়ার্নিংও রয়েছে। ( Id2773 , b/294884345 )ComponentActivityএরonBackPressedDispatcherএখন লেজিভাবে ইনিশিয়ালাইজ করা হয়, যাতে এটি কেবল প্রয়োজনের সময়ই তৈরি হয়। ( I0bf8e )
বাগ সংশোধন
- অ্যান্ড্রয়েড ১৩-এ,
ComponentActivityআর NPE দেখাবে না যখন এটি একটিonBackPressed()কলব্যাক পাবে এবং Activity-টি ইতিমধ্যেইDESTROYEDহয়ে গেছে। ( Idb055 , b/291869278 ) - পরীক্ষামূলক
isAtLeastU()API-এর ব্যবহার সরানো হয়েছে ( Ie9117 , b/289269026 )
সংস্করণ 1.8.0-alpha06
২১ জুন, ২০২৩
androidx.activity:activity:1.8.0-alpha06 , androidx.activity:activity-compose:1.8.0-alpha06 , এবং androidx.activity:activity-ktx:1.8.0-alpha06 রিলিজ করা হয়েছে। ভার্সন 1.8.0-alpha06-এ এই কমিটগুলো অন্তর্ভুক্ত রয়েছে।
নতুন বৈশিষ্ট্য
-
OnBackPressedDispatcherএখন Predictive Back Gesture চলাকালীন রিমুভ করা যেকোনো কলব্যাক সঠিকভাবে বাতিল করে। ( I3f90f )
এপিআই পরিবর্তন
-
enableEdgeToEdgeAPI-তেSystemBarStyle.autoপাস করার সময়, এখন আপনি নাইট মোড সনাক্ত করার জন্য কাস্টম লজিক প্রদান করতেdetectDarkModeল্যাম্বডা প্যারামিটারটি ওভাররাইড করতে পারবেন। ( aosp/2546393 , b/278263793 )
সংস্করণ 1.8.0-alpha05
৭ জুন, ২০২৩
androidx.activity:activity:1.8.0-alpha05 , androidx.activity:activity-compose:1.8.0-alpha05 , এবং androidx.activity:activity-ktx:1.8.0-alpha05 প্রকাশিত হয়েছে। এই সংস্করণটি একটি অভ্যন্তরীণ শাখায় তৈরি করা হয়েছে।
এপিআই পরিবর্তন
- অ্যাক্টিভিটি এখন একটি
BackEventCompatক্লাস প্রদান করে, যাBackEventএর একটি পশ্চাৎ-সামঞ্জস্যপূর্ণ সংস্করণ হিসেবে কাজ করে এবং ফ্রেমওয়ার্কেরBackEventক্লাস থেকে বিচ্ছিন্ন থাকে। - বড় পরিবর্তন:
OnBackPressedCallbackএরhandleOnBackStartedএবংhandleOnBackProgressedমেথডগুলো এখন ফ্রেমওয়ার্কেরandroid.window.BackEventক্লাসের পরিবর্তে একটিandroidx.activity.BackEventCompatইনস্ট্যান্স গ্রহণ করবে।OnBackPressedDispatcherএর সমতুল্য@VisibleForTestingAPI-গুলোও আপডেট করা হয়েছে। -
OnBackPressedDispatcherএর কনস্ট্রাক্টর এখন একটি ঐচ্ছিকConsumer<Boolean>ইনস্ট্যান্স গ্রহণ করে, যা ডিসপ্যাচারের মালিকদেরকে সক্রিয় কলব্যাকের সংখ্যা শূন্য থেকে অশূন্যে বা এর বিপরীতক্রমে পরিবর্তিত হলে একটি কলব্যাক গ্রহণ করার সুযোগ দেয়।
বাগ সংশোধন
- অ্যাক্টিভিটি
1.7.2থেকে :reportকল করার আগে স্ক্রিন থেকে অন্য স্ক্রিনে গেলেReportDrawnক্র্যাশ করার সমস্যা সমাধান করা হয়েছে। ( Ic46f1 , b/260506820 )
সংস্করণ 1.8.0-alpha04
১০ মে, ২০২৩
androidx.activity:activity:1.8.0-alpha04 , androidx.activity:activity-compose:1.8.0-alpha04 , এবং androidx.activity:activity-ktx:1.8.0-alpha04 রিলিজ করা হয়েছে। এটি একটি অভ্যন্তরীণ শাখা থেকে রিলিজ করা হয়েছিল।
বাগ সংশোধন
- From Activity 1.7.1 : - The
ReportFullyDrawExecuterno longer leaks when usingComponentActivitywithActivityScenario. ( Id2ff2 , b/277434271 )
Version 1.8.0-alpha03
১২ এপ্রিল, ২০২৩
androidx.activity:activity:1.8.0-alpha03 , androidx.activity:activity-compose:1.8.0-alpha03 , and androidx.activity:activity-ktx:1.8.0-alpha03 are released. This was released from an internal branch.
নতুন বৈশিষ্ট্য
- Added
ComponentActivity.setUpEdgeToEdge()to easily set up the edge-to-edge display in a backward-compatible manner.
API Changes
-
ComponentActivity.onBackPressed()has now been deprecated in favor of the APIs for handling back. Developers should now utilize theOnBackPressedDispatcher, rather than overriding this method. ( Ibce2f , b/271596918 ) -
ComponentDialogandComponentActivitynow contain public APIinitViewTreeOwners()to be used to initialize all view tree owners before setting the content view. ( Ibdce0 , b/261314581 )
বাগ সংশোধন
- Fixed an issue where Fragments were incorrectly invalidating MenuHosts and causing other menus in the Activity to have unexpected behavior. ( I9404e , b/244336571 )
Other Changes
- The
ActivityResultRegisternow uses KotlinRandominstead of Java. ( I4d98f , b/272096025 )
Version 1.8.0-alpha02
৮ মার্চ, ২০২৩
androidx.activity:activity:1.8.0-alpha02 , androidx.activity:activity-compose:1.8.0-alpha02 , and androidx.activity:activity-ktx:1.8.0-alpha02 are released. Developed from an internal branch.
Dependency update
- From Activity
1.7.0-rc01: Activity now depends onLifecycle 2.6.0.
Version 1.8.0-alpha01
৮ ফেব্রুয়ারী, ২০২৩
androidx.activity:activity:1.8.0-alpha01 , androidx.activity:activity-compose:1.8.0-alpha01 , and androidx.activity:activity-ktx:1.8.0-alpha01 are released. This was built from an internal branch.
নতুন বৈশিষ্ট্য
- The
OnBackPressedCallbackclass now contains new Predictive Back progress callbacks for handling the back gesture starting, progress throughout the gesture, and the back gesture being canceled in addition to the previoushandleOnBackPressed()callback for when the back gesture is committed.
Version 1.7
Version 1.7.2
২৪ মে, ২০২৩
androidx.activity:activity:1.7.2 , androidx.activity:activity-compose:1.7.2 , and androidx.activity:activity-ktx:1.7.2 are released. Version 1.7.2 contains these commits.
বাগ সংশোধন
- Fix
ReportDrawncrashing when navigating away from a screen beforereportis called. ( Ic46f1 , b/260506820 )
সংস্করণ ১.৭.১
১৯ এপ্রিল, ২০২৩
androidx.activity:activity:1.7.1 , androidx.activity:activity-compose:1.7.1 , and androidx.activity:activity-ktx:1.7.1 are released. Version 1.7.1 contains these commits.
বাগ সংশোধন
- The
ReportFullyDrawExecuterno longer leaks when usingComponentActivitywithActivityScenario. ( Id2ff2 , b/277434271 )
সংস্করণ ১.৭.০
March 22, 2023
androidx.activity:activity:1.7.0 , androidx.activity:activity-compose:1.7.0 , and androidx.activity:activity-ktx:1.7.0 are released. Version 1.7.0 contains these commits.
Important changes since 1.6.0
- The Photo Picker activity contracts in
PickVisualMediaandPickMultipleVisualMediahave been updated to contain an additional fallback for whenMediaStore.ACTION_PICK_IMAGESis unavailable that allows OEMs and system apps, such as Google Play services, to provide a consistent Photo Picker experience on a wider range of Android devices and API levels by implementing the fallback action . The Photo Picker will use this fallback if it is available before falling back to usingIntent.ACTION_OPEN_DOCUMENT, which remains to support all API 19 and higher devices. -
ComponentDialognow implementsSavedStateRegistryOwnerand has access to its ownSavedStateRegistryand sets theSavedStateRegistryOwnerfor itsViewTree. It is now possible to use Jetpack Compose within aComponentDialogas it meets both theLifecycleOwnerandSavedStateRegistryOwnerattached to the Window via theViewTreeAPIs requirements. -
IntentSenderRequest.Builder.setFlags()now allows you to set multiple flags fromIntent, rather than only a single flag.
Kotlin Conversion
A number of Activity classes have been converted to Kotlin. All converted classes still retain their binary compatibility with previous versions. The following classes have source incompatible changes for classes written in Kotlin: ActivityResultRegistryOwner , OnBackPressedDispatcherOwner .
The table below provides the source conversions for the new version of Activity:
| Activity 1.5 | Activity 1.6 |
|---|---|
override fun getActivityResultRegistry() = activityResultRegistry | override val activityResultRegistry = activityResultRegistry |
override fun getOnBackPressedDispatcher() = onBackPressedDispatcher | override val onBackPressedDispatcher = onBackPressedDispatcher |
These classes were also converted to Kotlin, but remain source compatible: ContextAware , ContextAwareHelper , OnContextAvailableListener , IntentSenderRequest , and OnBackPressedDispatcher
FullyDrawnReporter APIs
ComponentActivity now provides a FullyDrawnReporter instance that allows multiple components to report when they are ready for interaction. ComponentActivity will wait for all components to complete before calling reportFullyDrawn() on your behalf. These APIs take care of the timing requirements for you and do not need to be called as part of an onDraw call.
These APIs are encouraged to enable:
- Signaling the Android Runtime when startup completes, to ensure all of the code run during a multi-frame startup sequence is included and prioritized for background compilation.
- Signaling Macrobenchmark and Play Vitals when your application should be considered fully drawn for startup metrics, so you can track performance.
Three Activity Compose APIs have been added to make it more convenient to use the FullyDrawnReporter from individual composables:
-
ReportDrawnindicates that your composable is immediately ready for interaction. -
ReportDrawnWhentakes a predicate (ie,list.count > 0) to indicate when your composable is ready for interaction. -
ReportDrawnAftertakes a suspending method that, when it completes, indicates that you are ready for interaction.
Dependency Updates
- Activity now depends on Lifecycle
2.6.1. ( 8fc31d ) - Activity now depends on ProfileInstaller
1.3.0. ( 83d3b1 )
Version 1.7.0-rc01
৮ মার্চ, ২০২৩
androidx.activity:activity:1.7.0-rc01 , androidx.activity:activity-compose:1.7.0-rc01 , and androidx.activity:activity-ktx:1.7.0-rc01 are released. Version 1.7.0-rc01 contains these commits.
Dependency update
- Activity now depends on
Lifecycle 2.6.0.
Version 1.7.0-beta02
February 22, 2023
androidx.activity:activity:1.7.0-beta02 , androidx.activity:activity-compose:1.7.0-beta02 , and androidx.activity:activity-ktx:1.7.0-beta02 are released. Version 1.7.0-beta02 contains these commits.
API Changes
- The action and extra used by the
PickVisualMediaandPickMultipleVisualMediacontracts as a fallback for whenMediaStore.ACTION_PICK_IMAGESis unavailable are now public constants that provide API stability to OEMs and system apps that want to provide a consistent Photo Picker experience. The implementation of this fallback is still limited to only system apps. ( Icd320 )
Version 1.7.0-beta01
৮ ফেব্রুয়ারী, ২০২৩
androidx.activity:activity:1.7.0-beta01 , androidx.activity:activity-compose:1.7.0-beta01 , and androidx.activity:activity-ktx:1.7.0-beta01 are released. Version 1.7.0-beta01 contains these commits.
নতুন বৈশিষ্ট্য
-
IntentSenderRequest.Builder.setFlags()now allows you to set multiple flags fromIntent, rather than only a single flag. ( Iac04c )
বাগ সংশোধন
- The fallback for
PickVisualMediafor when the framework Photo Picker is unavailable now correctly limits the handling to apps installed in the device's system image. ( If8ae6 )
Kotlin Conversions
-
ActivityResultRegistryOwneris now written in Kotlin. This is a source incompatible change for those classes written in Kotlin - you must now override theactivityResultRegistryproperty rather than implementing the previousgetActivityResultRegistry()function. ( I0b00e ) -
OnBackPressedDispatcherOwneris now written in Kotlin. This is a source incompatible change for those classes written in Kotlin - you must now override theonBackPressedDispatcherproperty rather than implementing the previousgetOnBackPressedDispatcherfunction. ( Ia277d ) -
ContextAware,ContextAwareHelper,OnContextAvailableListener,IntentSenderRequestandOnBackPressedDispatcherare now written in Kotlin. ( I1a73e , Iada92 , aosp/2410754 , I18ac7 , b/257291701 )
Version 1.7.0-alpha04
২৫ জানুয়ারী, ২০২৩
androidx.activity:activity:1.7.0-alpha04 , androidx.activity:activity-compose:1.7.0-alpha04 , and androidx.activity:activity-ktx:1.7.0-alpha04 are released. Version 1.7.0-alpha04 contains these commits.
নতুন বৈশিষ্ট্য
- The
PickVisualMediaandPickMultipleVisualMediaActivity Result contracts will now use a Google Play services provided Photo Picker where available in cases where the Android system provided Photo Picker (eg,MediaStore.ACTION_PICK_IMAGES) is not available. TheisPhotoPickerAvailable()API that only detects the Android system provided Photo Picker has been deprecated. It is recommended to use the newisPhotoPickerAvailable(Context)API, which will return if either Photo Picker is available. ( I55be6 )
Version 1.7.0-alpha03
১১ জানুয়ারী, ২০২৩
androidx.activity:activity:1.7.0-alpha03 , androidx.activity:activity-compose:1.7.0-alpha03 , and androidx.activity:activity-ktx:1.7.0-alpha03 are released. Version 1.7.0-alpha03 contains these commits.
নতুন বৈশিষ্ট্য
-
ComponentDialognow implementsSavedStateRegistryOwnerand has access to its ownSavedStateRegistryand sets theSavedStateRegistryOwnerfor its ViewTree. It is now possible to use Jetpack Compose within aComponentDialogas it meets both theLifecycleOwnerandSavedStateRegistryOwnerattached to the Window via the ViewTree APIs requirements. ( Idca17 , I73468 b/261162296 )
API Changes
- Added a
ReportDrawncomposable that immediately marks the activity as ready to callreportFullyDrawn. ( Ic5b14 , b/259687964 )
Kotlin Conversions
- The
ActvitiyResultCallbackandOnBackPressedCallbackclasses have both been converted to Kotlin while maintaining source and binary compatibility. ( Ifc5e5 , Ide1b0 , b/257291701 )
Version 1.7.0-alpha02
২৪ অক্টোবর, ২০২২
androidx.activity:activity:1.7.0-alpha02 , androidx.activity:activity-compose:1.7.0-alpha02 , and androidx.activity:activity-ktx:1.7.0-alpha02 are released. Version 1.7.0-alpha02 contains these commits.
বাগ সংশোধন
- From Activity
1.6.1: Fixed an issue with thePickMultipleVisualMediaActivity Result contract not launching on Android R devices when using the default value formaxItems. ( Ie2776 , b/249182130 )
Version 1.7.0-alpha01
৫ অক্টোবর, ২০২২
androidx.activity:activity:1.7.0-alpha01 , androidx.activity:activity-compose:1.7.0-alpha01 , and androidx.activity:activity-ktx:1.7.0-alpha01 are released. Version 1.7.0-alpha01 contains these commits.
FullyDrawnReporter APIs
ComponentActivity now provides a FullyDrawnReporter instance that allows multiple components to report when they are ready for interaction. ComponentActivity will wait for all components to complete before calling reportFullyDrawn() on your behalf. These APIs take care of the timing requirements for you and do not need to be called as part of an onDraw call.
These APIs are encouraged to enable:
- Signaling the Android Runtime when startup completes, to ensure all of the code run during a multi-frame startup sequence is included and prioritized for background compilation.
- Signaling Macrobenchmark and Play Vitals when your application should be considered fully drawn for startup metrics, so you can track performance.
Two Activity Compose APIs have been added to make it more convenient to use the FullyDrawnReporter from individual composables:
-
ReportDrawnWhentakes a predicate (ie,list.count > 0) to indicate when your composable is ready for interaction. -
ReportDrawnAftertakes a suspending method that, when it completes, indicates that you are ready for interaction.
Version 1.6.1
Version 1.6.1
২৪ অক্টোবর, ২০২২
androidx.activity:activity:1.6.1 , androidx.activity:activity-compose:1.6.1 , and androidx.activity:activity-ktx:1.6.1 are released. Version 1.6.1 contains these commits.
বাগ সংশোধন
- Fixed an issue with the
PickMultipleVisualMediaActivity Result contract not launching on Android R devices when using the default value formaxItems. ( Ie2776 , b/249182130 )
সংস্করণ ১.৬.০
সংস্করণ ১.৬.০
September 21, 2022
androidx.activity:activity:1.6.0 , androidx.activity:activity-compose:1.6.0 , and androidx.activity:activity-ktx:1.6.0 are released. Version 1.6.0 contains these commits.
Important changes since 1.5.0
- Added
ActivityResultContracts.PickVisualMediaandActivityResultContracts.PickMultipleVisualMediafor providing a backward compatible contract that usesMediaStore.ACTION_PICK_IMAGESwhen the Photo Picker is available andIntent.ACTION_OPEN_DOCUMENTwhen it is not available. - Integrated the
OnBackInvokedCallbackin Android 13 into theOnBackPressedDispatchersprovided byComponentActivityandComponentDialog. This ensures that all APIs built onOnBackPressedDispatcherwork when enabling a predictive back gesture .
Version 1.6.0-rc02
৭ সেপ্টেম্বর, ২০২২
androidx.activity:activity:1.6.0-rc02 , androidx.activity:activity-compose:1.6.0-rc02 , and androidx.activity:activity-ktx:1.6.0-rc02 are released. Version 1.6.0-rc02 contains these commits.
বাগ সংশোধন
-
OnBackPressedDispatchernow registers theOnBackInvokedCallbackwith thePRIORITY_DEFAULTinstead ofPRIORITY_OVERLAY. ( I3901f ) - Classes that extend
ComponentActivitywill now always have both of theironMultiWindowModeChanged()callbacks dispatched. ( Ic4d85 ) - The
ActivityResultRegistrywill no longer return a result to theActivityResultCallbackwhen thelaunchcall throws anyExceptionand the callback was registered without aLifecycleOwner. ( Ia7ff7 , b/238350794 ) -
ComponentActivitywill now properly dispatch menu calls without the need to call the super function in your activity. ( Ie33c5 , b/238057118 )
Dependency Update
- The
Activitylibrary now depends on Lifecycle2.5.1. ( If6697 )
Version 1.6.0-rc01
August 24, 2022
androidx.activity:activity:1.6.0-rc01 , androidx.activity:activity-compose:1.6.0-rc01 , and androidx.activity:activity-ktx:1.6.0-rc01 are released. Version 1.6.0-rc01 contains these commits.
বাগ সংশোধন
- Initializing an
OnBackPressedDispatcherwill no longer causeClassVerificationErrors when using SDK versions prior to 33. ( Ic32e1 ) - Classes that override
ComponentActivity'sonPictureInPictureModeChanged()callback will now always have their callbacks dispatched. ( Ib7fdb )
Version 1.6.0-beta01
১০ আগস্ট, ২০২২
androidx.activity:activity:1.6.0-beta01 , androidx.activity:activity-compose:1.6.0-beta01 , and androidx.activity:activity-ktx:1.6.0-beta01 are released. Version 1.6.0-beta01 contains these commits.
API Changes
- Marked the deprecated
startActivityForResultandstartIntentSenderForResultmethods onComponentActivitywith@NonNullbecause passingnullhas always resulted in a crash. ( Id2a25 , b/231476082 )
বাগ সংশোধন
- From Activity
1.5.1: TheActivityResultRegistrywill no longer return a result to theActivityResultCallbackwhen thelaunchcall throws anyExceptionand the callback was registered without aLifecycleOwner. ( Ia7ff7 , b/238350794 ) - From Activity
1.5.1:ComponentActivitywill now properly dispatch menu calls toonPrepareOptionMenu(),onCreateOptionsMenu()andonOptionsItemSelected()overrides without the need to call the super function. ( Ie33c5 , b/238057118 )
Dependency Update
- From Activity
1.5.1: TheActivitylibrary now depends on theLifecycleversion2.5.1. ( If6697 )
Version 1.6.0-alpha05
১৫ জুন, ২০২২
androidx.activity:activity:1.6.0-alpha05 , androidx.activity:activity-compose:1.6.0-alpha05 , and androidx.activity:activity-ktx:1.6.0-alpha05 are released. Version 1.6.0-alpha05 was developed in a private pre-release branch and has no public commits.
API Changes
-
minCompileSdkis now 33 to align with Tiramisu Beta 3 SDK
বাগ সংশোধন
- Fixed crash on older devices when doing SDK extension check for the
PickVisualMediaActivityResultContractso that it should now work withACTION_OPEN_DOCUMENTon devices running Android 10 and lower.
Version 1.6.0-alpha04
১৮ মে, ২০২২
androidx.activity:activity:1.6.0-alpha04 and androidx.activity:activity-ktx:1.6.0-alpha04 are released.
বাগ সংশোধন
- Fixed an error in
PickVisualMediaRequestwhere attempting to create a request, either via the Builder or the top level Kotlin function, would result in a stack overflow. - Integrated the
OnBackInvokedCallbackin Android 13 Dev Beta 2 into theOnBackPressedDispatcherprovided byComponentDialog. This ensures that all APIs built onOnBackPressedDispatcherwork when enabling a predictive back gesture .
Version 1.6.0-alpha03
April 27, 2022
androidx.activity:activity:1.6.0-alpha03 , androidx.activity:activity-compose:1.6.0-alpha03 , and androidx.activity:activity-ktx:1.6.0-alpha03 are released.
- Note: This version will only compile against the Android 13 Developer Beta 1 SDK.
নতুন বৈশিষ্ট্য
- Added
ActivityResultContracts.PickVisualMediaandActivityResultContracts.PickMultipleVisualMediafor providing a backward compatible contract that usesMediaStore.ACTION_PICK_IMAGESwhen the Photo Picker is available andIntent.ACTION_OPEN_DOCUMENTwhen it is not available. - Integrated the
OnBackInvokedCallbackin Android 13 Dev Beta 1 into theOnBackPressedDispatcherprovided byComponentActivity. This ensures that all APIs built onOnBackPressedDispatcherwork when enabling a predictive back gesture .
Version 1.6.0-alpha01
March 23, 2022
androidx.activity:activity:1.6.0-alpha01 , androidx.activity:activity-compose:1.6.0-alpha01 , and androidx.activity:activity-ktx:1.6.0-alpha01 are released.
- Note: This version will only compile against the Android 13 Developer Preview 2 SDK.
নতুন বৈশিষ্ট্য
- Integrated changes in Android 13 Dev Preview 2 into
ComponentActivity.
সংস্করণ ১.৫.১
সংস্করণ ১.৫.১
২৭ জুলাই, ২০২২
androidx.activity:activity:1.5.1 , androidx.activity:activity-compose:1.5.1 , and androidx.activity:activity-ktx:1.5.1 are released. Version 1.5.1 contains these commits.
বাগ সংশোধন
The
ActivityResultRegistrywill no longer return a result to theActivityResultCallbackwhen thelaunch()call throws anyExceptionand the callback was registered without aLifecycleOwner. ( Ia7ff7 , b/238350794 )ComponentActivitywill now properly dispatch menu calls toonPrepareOptionMenu(),onCreateOptionsMenu()andonOptionsItemSelected()overrides without the need to call the super function. ( Ie33c5 , b/238057118 )
Dependency update
- The
Activitylibrary now depends on the Lifecycle2.5.1. ( If6697 )
সংস্করণ ১.৫.০
সংস্করণ ১.৫.০
২৯ জুন, ২০২২
androidx.activity:activity:1.5.0 , androidx.activity:activity-compose:1.5.0 , and androidx.activity:activity-ktx:1.5.0 are released. Version 1.5.0 contains these commits.
Important changes since 1.4.0
- ComponentDialog -
ComponentDialogis a subclass ofDialogthat includes anOnBackPressedDispatcherthat will be called when the system back button is pressed and the dialog is visible. Importantly, this subclass also sets theViewTreeOnBackPressedDispatcherOwner, allowing views a generic way to retrieve the correct dispatcher whether it exists in aComponentActivityor aComponentDialog. - Callback Interfaces -
ComponentActivitynow implements a set of modular callback interfaces that can be used instead of theActivitycallbacks. These interfaces include the following:OnNewIntentProvider,OnConfigurationChangedProvider,OnTrimMemoryProvider,OnPictureInPictureModeChangedProvider,OnMultiWindowModeChangedProvider - CreationExtras Integration -
ComponentActivitynow has the ability to provide a statelessViewModelProvider.Factoryvia Lifecycle2.5.0'sCreationExtras.
অন্যান্য পরিবর্তন
- The no parameter constructor for
ActivityResultContracts.CreateDocumenthas been deprecated and replaced with a new constructor that takes a concrete mime type (eg, "image/png") as is required byIntent.ACTION_CREATE_DOCUMENT.
Version 1.5.0-rc01
May 11, 2022
androidx.activity:activity:1.5.0-rc01 , androidx.activity:activity-compose:1.5.0-rc01 , and androidx.activity:activity-ktx:1.5.0-rc01 are released with no changes from 1.5.0-beta01. Version 1.5.0-rc01 contains these commits.
Version 1.5.0-beta01
২০ এপ্রিল, ২০২২
androidx.activity:activity:1.5.0-beta01 , androidx.activity:activity-compose:1.5.0-beta01 , and androidx.activity:activity-ktx:1.5.0-beta01 are released. Version 1.5.0-beta01 contains these commits.
Dependency updates
- Activity now depends on Lifecycle
2.4.0-beta01.
Version 1.5.0-alpha05
৬ এপ্রিল, ২০২২
androidx.activity:activity:1.5.0-alpha05 , androidx.activity:activity-compose:1.5.0-alpha05 , and androidx.activity:activity-ktx:1.5.0-alpha05 are released. Version 1.5.0-alpha05 contains these commits.
বাগ সংশোধন
-
ComponentActivity'sonPanelClosed()now calls the superonPanelClosed()as well, fixing an issue where theonContextMenuClosedmethod would not be called. ( Ib6f77 )
Version 1.5.0-alpha04
March 23, 2022
androidx.activity:activity:1.5.0-alpha04 , androidx.activity:activity-compose:1.5.0-alpha04 , and androidx.activity:activity-ktx:1.5.0-alpha04 are released. Version 1.5.0-alpha04 contains these commits.
বাগ সংশোধন
-
SavedStateViewFactorynow supports usingCreationExtraseven when it was initialized with aSavedStateRegistryOwner. If extras are provided, the initialized arguments are ignored. ( I6c43b , b/224844583 )
Version 1.5.0-alpha03
February 23, 2022
androidx.activity:activity:1.5.0-alpha03 , androidx.activity:activity-compose:1.5.0-alpha03 , and androidx.activity:activity-ktx:1.5.0-alpha03 are released. Version 1.5.0-alpha03 contains these commits.
API Changes
- You can now pass
CreationExtrasto the activityby viewModels()function ( I6a3e6 , b/217600303 )
Version 1.5.0-alpha02
৯ ফেব্রুয়ারী, ২০২২
androidx.activity:activity:1.5.0-alpha02 , androidx.activity:activity-compose:1.5.0-alpha02 , and androidx.activity:activity-ktx:1.5.0-alpha02 are released. Version 1.5.0-alpha02 contains these commits.
নতুন বৈশিষ্ট্য
-
ComponentActivitynow implements theOnPictureInPictureModeChangedProviderinterface to allow any component to receive picture-in-picture mode change events. ( I9f567 ) -
ComponentActivitynow implements theOnMultiWindowModeChangedProviderinterface to allow any component to receive multi-window mode change events. ( I62d91 )
Version 1.5.0-alpha01
২৬ জানুয়ারী, ২০২২
androidx.activity:activity:1.5.0-alpha01 , androidx.activity:activity-compose:1.5.0-alpha01 , and androidx.activity:activity-ktx:1.5.0-alpha01 are released. Version 1.5.0-alpha01 contains these commits.
নতুন বৈশিষ্ট্য
-
ComponentActivitynow integrates with ViewModel CreationExtras, introduced as part of Lifecycle2.5.0-alpha01. ( Ie7e00 , b/207012584 ) - Added
ComponentDialog, a subclass ofDialogthat includes anOnBackPressedDispatcherthat will be called when the system back button is pressed when the dialog is visible. Importantly, this subclass also sets theViewTreeOnBackPressedDispatcherOwner, allowing views a generic way to retrieve the correct dispatcher whether it exists in aComponentActivityor aComponentDialog. ( I8a1bc ) -
ComponentActivitynow implements the newOnNewIntentProviderinterface to allow any component to receive these events. ( If1f8b ) -
ComponentActivitynow implements the newOnConfigurationChangedProviderinterface to allow any component to receive these events. ( If623b ) -
ComponentActivitynow implements the newOnTrimMemoryProviderinterface to allow any component to receive these events. ( Ia9295 )
API Changes
- The no parameter constructor for
ActivityResultContracts.CreateDocumenthas been deprecated and replaced with a new constructor that takes a concrete mime type (eg,"image/png") as is required byIntent.ACTION_CREATE_DOCUMENT. ( I2bec6 ) - The
OnBackPressedDispatcherOwnerassociated with a View can now be retrieved via theViewTreeOnBackPressedDispatcherOwner, rather than relying on casting theContext. ( I74685 )
বাগ সংশোধন
- Fixed a crash when accessing a
ViewModelfor the very first time from aregisterForActivityResult()callback or the callbacks to aLifecycleObserveradded as part ofinitof aComponentActivity. ( Ife83f )
Version 1.4.0
Version 1.4.0
October 27, 2021
androidx.activity:activity:1.4.0 , androidx.activity:activity-compose:1.4.0 , and androidx.activity:activity-ktx:1.4.0 are released. Version 1.4.0 contains these commits.
Important changes since 1.3.0
- AndroidX
ComponentActivitynow implements theMenuHostinterface. This allows any component to add menu items to theActionBarby adding aMenuProviderinstance to the activity. EachMenuProvidercan optionally be added with aLifecyclethat will automatically control the visibility of those menu items based on theLifecyclestate and handle the removal of theMenuProviderwhen theLifecycleis destroyed. - The
ActivityResultContractclass has been rewritten in Kotlin to ensure that developers writing custom contracts in Kotlin can define the correct nullability for their input and output classes. - The
ActivityResultContractsclass and its contracts have been rewritten in Kotlin to ensure the proper nullability.
Version 1.4.0-rc01
১৩ অক্টোবর, ২০২১
androidx.activity:activity:1.4.0-rc01 , androidx.activity:activity-compose:1.4.0-rc01 , and androidx.activity:activity-ktx:1.4.0-rc01 are released. Version 1.4.0-rc01 contains these commits.
বাগ সংশোধন
- The
ActivityResultRegistrywill no longer return a result to theActivityResultCallbackwhen thelaunchcall throws anyException. ( If4f91 , b/200845664 )
Version 1.4.0-beta01
September 29, 2021
androidx.activity:activity:1.4.0-beta01 , androidx.activity:activity-compose:1.4.0-beta01 , and androidx.activity:activity-ktx:1.4.0-beta01 are released. Version 1.4.0-beta01 contains these commits.
API Changes
- Fixed the type for the
ActivityResultContracts.OpenMultipleDocumentsandActivityResultContracts.GetMultipleContentsthat caused then to use an output type ofList<? extends Uri>when using the code from the Java programming language. ( If71de ) - Public constants within the
ActivityResultContracts.StartActivityForResult,ActivityResultContracts.StartIntentSenderForResult, andActivityResultContracts.RequestMultiplePermissionsclasses are now accessible when using Kotlin via their now publicCompanionobjects. ( aosp/1832555 )
Documentation Updates
- The deprecation message for APIs now handled by the Activity Result APIs , namely
startActivityForResult,startIntentSenderForResult,onActivityResult,requestPermissions, andonRequestPermissionsResult, have all been expanded with more details. ( cce80f )
Version 1.4.0-alpha02
১৫ সেপ্টেম্বর, ২০২১
androidx.activity:activity:1.4.0-alpha02 , androidx.activity:activity-compose:1.4.0-alpha02 , and androidx.activity:activity-ktx:1.4.0-alpha02 are released. Version 1.4.0-alpha02 contains these commits.
নতুন বৈশিষ্ট্য
- The
activity-composeartifact now contains aLaunchDuringCompositionlint error that prevents you from calling thelaunchmethod ofActivityResultLauncheras part of composition as composition should be side-effect free. Use the APIs for handling side-effects . ( 7c2bbe , b/191347220 )
API Changes
- The
ActivityResultContractclass has been rewritten in Kotlin to ensure that developers writing custom contracts in Kotlin can define the correct nullability for their input and output classes. ( I8a8f5 ) - The
ActivityResultContractsclass and its contracts have been rewritten in Kotlin to ensure the proper nullability. ( I69802 )
Version 1.4.0-alpha01
September 1, 2021
androidx.activity:activity:1.4.0-alpha01 , androidx.activity:activity-compose:1.4.0-alpha01 , and androidx.activity:activity-ktx:1.4.0-alpha01 are released. Version 1.4.0-alpha01 contains these commits.
নতুন বৈশিষ্ট্য
- AndroidX
ComponentActivitynow implements theMenuHostinterface.. This allows any component to add menu items to theActionBarby adding aMenuProviderinstance to the activity. EachMenuProvidercan optionally be added with aLifecyclethat will automatically control the visibility of those menu items based on theLifecyclestate and handle the removal of theMenuProviderwhen theLifecycleis destroyed. ( I3b608 ):
/**
* Using the addMenuProvider() API directly in your Activity
**/
class ExampleActivity : ComponentActivity(R.layout.activity_example) {
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
// Add menu items without overriding methods in the Activity
addMenuProvider(object : MenuProvider {
override fun onCreateMenu(menu: Menu, menuInflater: MenuInflater) {
// Add menu items here
menuInflater.inflate(R.menu.example_menu, menu)
}
override fun onMenuItemSelected(menuItem: MenuItem): Boolean {
// Handle the menu selection
return true
}
})
}
}
/**
* Using the addMenuProvider() API in a Fragment
**/
class ExampleFragment : Fragment(R.layout.fragment_example) {
override fun onViewCreated(view: View, savedInstanceState: Bundle?) {
// The usage of an interface lets you inject your own implementation
val menuHost: MenuHost = requireActivity()
// Add menu items without using the Fragment Menu APIs
// Note how we can tie the MenuProvider to the viewLifecycleOwner
// and an optional Lifecycle.State (here, RESUMED) to indicate when
// the menu should be visible
menuHost.addMenuProvider(object : MenuProvider {
override fun onCreateMenu(menu: Menu, menuInflater: MenuInflater) {
// Add menu items here
menuInflater.inflate(R.menu.example_menu, menu)
}
override fun onMenuItemSelected(menuItem: MenuItem): Boolean {
// Handle the menu selection
return true
}
}, viewLifecycleOwner, Lifecycle.State.RESUMED)
}
Behavior Changes
- The
ActivityResultRegistrywill now throw anIllegalStateExceptionwhen attempting to calllaunch()on anActivityResultLauncherthat has not be registered or that has been unregistered. ( Ida75d , b/192567522 )
External Contribution
সংস্করণ ১.৩.১
সংস্করণ ১.৩.১
৪ আগস্ট, ২০২১
androidx.activity:activity:1.3.1 , androidx.activity:activity-compose:1.3.1 , and androidx.activity:activity-ktx:1.3.1 are released. Version 1.3.1 contains these commits.
Dependency updates
- Activity now depends on Kotlin
1.5.21. - Activity Compose now depends on Compose
1.0.1.
সংস্করণ ১.৩.০
সংস্করণ ১.৩.০
২৮ জুলাই, ২০২১
androidx.activity:activity:1.3.0 , androidx.activity:activity-compose:1.3.0 , and androidx.activity:activity-ktx:1.3.0 are released. Version 1.3.0 contains these commits.
Important changes since 1.2.0
- Activity Compose artifact - The
activity-composeartifact provides thesetContentextension method for hosting your Jetpack Compose UI in an activity and Compose specific wrappers for interacting with theComponentActivityAPIs for handling the system back button and the Activity Result APIs. See the documentation for more details. - CaptureVideo contract - The
CaptureVideoActivityResultContractreplaces the now deprecatedTakeVideocontract and returns a boolean denoting success that works across many camera apps. - Picture-In-Picture Hint View Tracking - Users of
activity-ktxcan now use thetrackPipAnimationHintViewextension method onActivityto automatically rebuild thePictureInPictureParamswith the new position of the view as it changes position relative to the window.
Version 1.3.0-rc02
১৪ জুলাই, ২০২১
androidx.activity:activity:1.3.0-rc02 , androidx.activity:activity-compose:1.3.0-rc02 , and androidx.activity:activity-ktx:1.3.0-rc02 are released. Version 1.3.0-rc02 contains these commits.
বাগ সংশোধন
- The
ActivityResultRegistrycallbacks are now properly saved and restored so callbacks are not duplicated in the savedState. ( I97816 , b/191893160 )
Version 1.3.0-rc01
১ জুলাই, ২০২১
androidx.activity:activity:1.3.0-rc01 , androidx.activity:activity-compose:1.3.0-rc01 , and androidx.activity:activity-ktx:1.3.0-rc01 are released with no changes from 1.3.0-beta02 . Version 1.3.0-rc01 contains these commits.
Version 1.3.0-beta02
১৬ জুন, ২০২১
androidx.activity:activity:1.3.0-beta02 , androidx.activity:activity-compose:1.3.0-beta02 , and androidx.activity:activity-ktx:1.3.0-beta02 are released. Version 1.3.0-beta02 contains these commits.
Updated activity-compose to depend on Compose 1.0.0-beta09 . androidx.compose.ui:ui-test-junit4 now has a compile time dependency on activity-compose .
Version 1.3.0-beta01
June 2, 2021
androidx.activity:activity:1.3.0-beta01 , androidx.activity:activity-compose:1.3.0-beta01 , and androidx.activity:activity-ktx:1.3.0-beta01 are released. Version 1.3.0-beta01 contains these commits.
API Changes
- The previously deprecated
@Composable registerForActivityResult()method has been removed. Please userememberLauncherForActivityResult(). ( Ic39d3 )
Version 1.3.0-alpha08
১৮ মে, ২০২১
androidx.activity:activity:1.3.0-alpha08 , androidx.activity:activity-compose:1.3.0-alpha08 , and androidx.activity:activity-ktx:1.3.0-alpha08 are released. Version 1.3.0-alpha08 contains these commits.
নতুন বৈশিষ্ট্য
- The new
CaptureVideoActivityResultContractreturns a boolean to yourActivityResultCallbackindicating if your video was successfully saved to the given URI. This replaces the now deprecatedTakeVideocontract as camera apps very rarely supported returning a thumbnail bitmap, making the result unhelpful. ( Ie21f2 , b/185938070 ) - Added new API
Activity#setPipAnimationHintViewto update the PipParams' source rect hint whenever the view moves. ( I9063d )
API Changes
- The
rememberLauncherForActivityResultfunction now returns a launcher that deprecates theunregister()function - registration and unregistering the launcher is handled automatically byrememberLauncherForActivityResult. ( I2443e )
Compose Compatibility
-
androidx.activity:activity-compose:1.3.0-alpha08is only compatible with Compose version1.0.0-beta07and above.
Version 1.3.0-alpha07
April 21, 2021
androidx.activity:activity:1.3.0-alpha07 , androidx.activity:activity-compose:1.3.0-alpha07 , and androidx.activity:activity-ktx:1.3.0-alpha07 are released. Version 1.3.0-alpha07 contains these commits.
বাগ সংশোধন
-
rememberLauncherForActivityResultnow returns a stable reference to the sameActivityResultLauncherinstance even if the contract changes due to recompositions. ( Id2d6d ) - Using unstable versions of Fragments above
1.3.0will no longer throw a false positive lint error telling you to use1.3.0. ( aosp/1670206 , b/184847092 )
Version 1.3.0-alpha06
৭ এপ্রিল, ২০২১
androidx.activity:activity:1.3.0-alpha06 , androidx.activity:activity-compose:1.3.0-alpha06 , and androidx.activity:activity-ktx:1.3.0-alpha06 are released. Version 1.3.0-alpha06 contains these commits.
API Changes
- The
registerForActivityResult()API has been renamed torememberLauncherForActivityResult()to better indicate that the returnedActivityResultLauncheris a managed object that is remembered on your behalf. Attempting to callunregisterthe returnedActivityResultLauncherwill now throw an error. ( I2bb6d ) -
LocalOnBackPressedDispatcherOwner.currentandLocalActivityResultRegistryOwner.currentnow return a nullable value to better determine whether it is available in the current composition. APIs that requires those APIs, such asBackHandlerandrememberLauncherForActivityResult(), respectively, will now throw a more descriptive error if the underlying owner is not found.NavHostnow works even when anOnBackPressedDispatcherOwneris not found, such is the case when previewing theNavHost. ( I7d8b4 )
বাগ সংশোধন
- The
BackHandlerwill now properly intercept back presses in the event that the Activity isSTOPPED, thenSTARTEDagain, and other callbacks were added with a LifecycleOwner. ( I71de6 , b/182284739 ) - Using the
launch()method extension with a customActivityResultContractthat has aUnitinput will no longer cause aNullPointerException( I76282 , b/183837954 )
Version 1.3.0-alpha05
March 24, 2021
androidx.activity:activity:1.3.0-alpha05 , androidx.activity:activity-compose:1.3.0-alpha05 , and androidx.activity:activity-ktx:1.3.0-alpha05 are released. Version 1.3.0-alpha05 contains these commits.
বাগ সংশোধন
- From Activity 1.2.2 : Fixed an issue in the
InvalidFragmentVersionForActivityResultlint check that led to a false positive when using Fragment 1.3.1 or higher. ( I54da1 , b/182388985 ) - From Activity 1.2.2 :
ComponentActivitynow avoids aClassNotFoundExceptionwhen launching anIntentfrom anActivityResultContractthat was previously held as an extra in anotherIntent. ( Ieff05 , b/182906230 )
Dependency Updates
- From Activity 1.2.2 : Activity now depends on Lifecycle
2.3.1.
Version 1.3.0-alpha04
১০ মার্চ, ২০২১
androidx.activity:activity:1.3.0-alpha04 , androidx.activity:activity-compose:1.3.0-alpha04 , and androidx.activity:activity-ktx:1.3.0-alpha04 are released. Version 1.3.0-alpha04 contains these commits.
বাগ সংশোধন
- From Activity
1.2.1:RequestMultiplePermissionsnow always returns results for all requested permissions instead of only permissions that weren't previously granted. ( I50bc3 , b/180884668 ) - From Activity
1.2.1:ActivityResultRegistrynow ensures that in progresslaunch()requests will return their results even if youunregister(), thenregister()again with the same key. ( I9ef34 , b/181267562 ) - Activity Compose no longer adds test dependencies to the runtime classpath. ( Ifd8b3 )
- Fixed an issue with
BackHandlerwhere the previously setonBacklambda was still being used after recomposition. ( 8eb5eb )
Version 1.3.0-alpha03
February 24, 2021
androidx.activity:activity:1.3.0-alpha03 , androidx.activity:activity-compose:1.3.0-alpha03 , and androidx.activity:activity-ktx:1.3.0-alpha03 are released. Version 1.3.0-alpha03 contains these commits.
নতুন বৈশিষ্ট্য
- There is a now a Composable
registerForActivityResultfunction for getting results from activities within composables. ( Ia7851 , b/172690553 )
API Changes
-
LocalOnBackPressedDispatcherOwnernow has aprovidesfunctions that can be used withCompositionLocalProvider, replacing theasProvidableCompositionLocal()API. ( I45d24 )
Version 1.3.0-alpha02
১০ ফেব্রুয়ারী, ২০২১
androidx.activity:activity:1.3.0-alpha02 , androidx.activity:activity-compose:1.3.0-alpha02 , and androidx.activity:activity-ktx:1.3.0-alpha02 are released. Version 1.3.0-alpha02 contains these commits.
বাগ সংশোধন
- Fixed an issue in Activity Compose
1.3.0-alpha01that causes aNoSuchMethodError: No static method setContentexception when using Compose1.0.0-alpha12. All Compose users should depend on1.3.0-alpha02and above. ( b/179911234 )
API Changes
- The
BackHandlerAPI can be used to allow a Composable to intercept the system back button. ( I58ed5 , b/172154006 )
Version 1.3.0-alpha01
১০ ফেব্রুয়ারী, ২০২১
androidx.activity:activity:1.3.0-alpha01 , androidx.activity:activity-compose:1.3.0-alpha01 , and androidx.activity:activity-ktx:1.3.0-alpha01 are released. Version 1.3.0-alpha01 contains these commits.
নতুন বৈশিষ্ট্য
- The new
activity-composeartifact provides Jetpack Compose specific helpers forandroidx.activityspecific APIs.-
ComponentActivity.setContenthas moved fromandroidx.compose.ui.platform.setContenttoandroidx.activity.compose.setContent. ( Icf416 )
-
পরিচিত সমস্যা
- Using Activity Compose
1.3.0-alpha01and libraries that depend on it, such asandroidx.compose.ui:ui-test-junit4:1.0.0-alpha12, will result in aNoSuchMethodError: No static method setContentexception. ( b/179911234 )
Version 1.2.4
Version 1.2.4
July 21, 2021
androidx.activity:activity:1.2.4 and androidx.activity:activity-ktx:1.2.4 are released. Version 1.2.4 contains these commits.
বাগ সংশোধন
- From Activity
1.3.0-rc02: The ActivityResultRegistry callbacks are now properly saved and restored so callbacks are not duplicated in the savedState. ( I97816 , b/191893160 )
সংস্করণ ১.২.৩
সংস্করণ ১.২.৩
৫ মে, ২০২১
androidx.activity:activity:1.2.3 and androidx.activity:activity-ktx:1.2.3 are released. Version 1.2.3 contains these commits.
বাগ সংশোধন
- Using the
launch()method extension with a customActivityResultContractthat has aUnitinput will no longer cause aNullPointerException( I76282 , b/183837954 ) - Fixed a false positive lint error telling you to use Fragment
1.3.0when using an snapshot, alpha, beta, or RC build of a newer version of Fragments. ( f4a57e , b/184847092 )
সংস্করণ ১.২.২
সংস্করণ ১.২.২
March 24, 2021
androidx.activity:activity:1.2.2 and androidx.activity:activity-ktx:1.2.2 are released. Version 1.2.2 contains these commits.
বাগ সংশোধন
- Fixed an issue in the
InvalidFragmentVersionForActivityResultlint check that led to a false positive when using Fragment 1.3.1 or higher. ( I54da1 , b/182388985 ) -
ComponentActivitynow avoids aClassNotFoundExceptionwhen launching anIntentfrom anActivityResultContractthat was previously held as an extra in anotherIntent. ( Ieff05 , b/182906230 )
Dependency Updates
- Activity now depends on Lifecycle
2.3.1.
সংস্করণ ১.২.১
সংস্করণ ১.২.১
১০ মার্চ, ২০২১
androidx.activity:activity:1.2.1 and androidx.activity:activity-ktx:1.2.1 are released. Version 1.2.1 contains these commits.
বাগ সংশোধন
-
RequestMultiplePermissionsnow always returns results for all requested permissions instead of only permissions that weren't previously granted. ( I50bc3 , b/180884668 ) -
ActivityResultRegistrynow ensures that in progresslaunch()requests will return their results even if youunregister(), thenregister()again with the same key. ( I9ef34 , b/181267562 )
সংস্করণ ১.২.০
সংস্করণ ১.২.০
১০ ফেব্রুয়ারী, ২০২১
androidx.activity:activity:1.2.0 and androidx.activity:activity-ktx:1.2.0 are released. Version 1.2.0 contains these commits.
Major changes since 1.1.0
- Activity Result APIs :
ComponentActivitynow provides anActivityResultRegistrythat lets you handlestartActivityForResult()+onActivityResult()as well asrequestPermissions()+onRequestPermissionsResult()flows without overriding methods in your Activity or Fragment, brings increased type safety viaActivityResultContract, and provides hooks for testing these flows. See the updated Getting a Result from an Activity .
ContextAware:ComponentActivitynow implementsContextAware, allowing you to add one or moreOnContextAvailableListenerinstances which will receive a callback before the baseActivity.onCreate().- A suspending Kotlin extension
withContextAvailable()allows you to run a non-suspending block when the Context becomes available and return a result. - This API is used by
FragmentActivityin Fragment 1.3.0 to restore the state of theFragmentManager. Any listeners added to subclasses ofFragmentActivitywill run after that listener. - This API is used by
AppCompatActivityin AppCompat 1.3.0-alpha02 or higher. Any listeners added to subclasses ofAppCompatActivitywill run after that listener.
- A suspending Kotlin extension
ViewTreeSupport :ComponentActivitynow supports theViewTreeLifecycleOwner.get(View),ViewTreeViewModelStoreOwner.get(View), andViewTreeSavedStateRegistryOwnerAPIs added in Lifecycle2.3.0and SavedState1.1.0such that it will return the Activity as theLifecycleOwner,ViewModelStoreOwner, andSavedStateRegistryOwnerfor any Views directly added to theComponentActivity.
- reportFullyDrawn() backport - The
Activitymethod ofreportFullyDrawn()has been backported inComponentActivityto work on all API levels, fixing a crash on API 19 and adding tracing for this method for all API levels.
Version 1.2.0-rc01
১৬ ডিসেম্বর, ২০২০
androidx.activity:activity:1.2.0-rc01 and androidx.activity:activity-ktx:1.2.0-rc01 are released. Version 1.2.0-rc01 contains these commits.
বাগ সংশোধন
- The
ActivityResultRegistrynow always restores the exact state that was saved. ( Idd56b ) - Add tracing to
ComponentActivity.reportFullyDrawn( Ic7632 )
External Contribution
-
ComponentActivitynow overridesreportFullyDrawn(), allowing it to be called on all API levels and fixing a crash when calling this method without the appropriate system permission on API 19 devices. Thanks Simon Schiller! ( b/163239764 , #103 )
Version 1.2.0-beta02
December 2, 2020
androidx.activity:activity:1.2.0-beta02 and androidx.activity:activity-ktx:1.2.0-beta02 are released. Version 1.2.0-beta02 contains these commits.
বাগ সংশোধন
- Fixed an issue where the Activity Result API would not wait for the Lifecycle to be
STARTEDbefore delivering results when registered with aLifecycle. ( I109ea )
External Contribution
- Updated the documentation for
launch()to explicitly call out that it can throw anActivityNotFoundException. Thanks Michał Zieliński! ( aosp/1493580 )
Version 1.2.0-beta01
১ অক্টোবর, ২০২০
androidx.activity:activity:1.2.0-beta01 and androidx.activity:activity-ktx:1.2.0-beta01 are released. Version 1.2.0-beta01 contains these commits.
বাগ সংশোধন
The
ActivityResultRegistrynow randomly generates integers until it finds one that is unallocated to use as a request coderegister(), thus preventing the possible integer overflow caused by incrementing request codes. ( b/168779518 )Lifecycleobservers are properly removed when callingunregister()on anActivityResultLauncher. ( b/165608393 )
Behavior Changes
- The
ActivityResultRegistrynow throws anIllegalStateExceptionwhen attempting to callregister()with aLifecycleOwnerwhoseLifecyclehas already reachedSTARTED. ( b/165435866 )
Documentation Updated
-
ContextAwaredocumentation links toLifecycleOwnerto highlightLifecyclecallbacks as the appropriate place for creation and destruction events. ( aosp/1414152 )
Version 1.2.0-alpha08
১৯ আগস্ট, ২০২০
androidx.activity:activity:1.2.0-alpha08 and androidx.activity:activity-ktx:1.2.0-alpha08 are released. Version 1.2.0-alpha08 contains these commits.
নতুন বৈশিষ্ট্য
-
ComponentActivitynow implementsContextAware, allowing you to add one or moreOnContextAvailableListenerinstances which will receive a callback before the baseActivity.onCreate(). ( b/161390636 )- A suspending Kotlin extension
withContextAvailable()allows you to run a non-suspending block when the Context becomes available and return a result. ( I8290c ) - This API is used by
FragmentActivityin Fragment 1.3.0-alpha08 to restore the state of theFragmentManager. Any listeners added to subclasses ofFragmentActivitywill run after that listener. ( I513da ) - This API is used by
AppCompatActivityin AppCompat 1.3.0-alpha02 . Any listeners added to subclasses ofAppCompatActivitywill run after that listener. ( I513da )
- A suspending Kotlin extension
বাগ সংশোধন
- Fixed an issue with the
ActivityResultFragmentVersionDetectorLint check that caused it to break when using Lint 27.1.0 or higher. ( b/162155191 )
Version 1.2.0-alpha07
২২ জুলাই, ২০২০
androidx.activity:activity:1.2.0-alpha07 and androidx.activity:activity-ktx:1.2.0-alpha07 are released. Version 1.2.0-alpha07 contains these commits.
নতুন বৈশিষ্ট্য
- Added a new
InvalidFragmentVersionForActivityResultlint check that verifies that you are using Fragment1.3.0-alpha07when using the Activity Result API , avoiding runtime crashes due to “invalid request code” issues and non-functioning permission requests caused by using older versions of Fragments. ( b/152554847 )
External Contribution
- Fixed an
ArrayIndexOutOfBoundsExceptionwhen parsing the results for theRequestPermissionActivity Result contract. ( I8f9e3 , b/161057605 )
Version 1.2.0-alpha06
১০ জুন, ২০২০
androidx.activity:activity:1.2.0-alpha06 and androidx.activity:activity-ktx:1.2.0-alpha06 are released. Version 1.2.0-alpha06 contains these commits.
নতুন বৈশিষ্ট্য
- You can now destructure the
ActivityResultclass in kotlin to directly access therequestCodeandintent. ( b/157212935 ) -
ActivityResultLaunchernow allows you to get theActivityResultContractthat was used to register the launcher. ( b/156875743 )
API Changes
- Breaking change : The
invoke()method onActivityResultRegistryhas been renamed toonLaunch(). ( b/157496491 ) - The
OpenMultipleDocumentscontract now returns an empty list instead ofnullto the registered callback if no result is returned. ( b/157348014 )
Version 1.2.0-alpha05
২০ মে, ২০২০
androidx.activity:activity:1.2.0-alpha05 and androidx.activity:activity-ktx:1.2.0-alpha05 are released. Version 1.2.0-alpha05 contains these commits.
নতুন বৈশিষ্ট্য
- Added support for
ViewTreeViewModelStoreOwnerfrom Lifecycle2.3.0-alpha03, andViewTreeSavedStateRegistryOwnerfrom SavedState1.1.0-alpha01when using aViewwithin aComponentActivity. ( aosp/1297993 , aosp/1300264 )
API Changes
- The
TakePicturecontract now returns abooleanindicating success rather than a thumbnailBitmapas this was very rarely supported by camera apps when writing the image to the providedUri. ( b/154302879 ) - The
invoke()extensions onActivityResultLauncherhave been removed in favor of explicitly usinglaunch()to better indicate that these are asynchronous operations. Kotlin extensions forlaunchhave been added to theandroidx.activity.resultpackage forActivityResultLauncher<Void>andActivityResultLauncher<Unit>that remove the need to pass innullorUnit, respectively, mirroring that behavior from the previouslyinvoke()extensions. ( aosp/1304674 , aosp/1304675 ) - The
IntentSenderRequest.Buildermethods forsetFlagsMask()andsetFlagsValues()has been combined into a singlesetFlags()method. ( aosp/1302111 )
বাগ সংশোধন
- When registering an
ActivityResultCallbackwith aLifecycleOwner, fixed an issue where the callback would be triggered before the state reachesSTARTED. ( aosp/1309744 )
Behavior Changes
- The
ActivityResultRegistrynow generates request codes starting at0xFFFFrather than at0, preventing overlap when usingstartActivityForResult()orrequestPermissions()in an activity. ( aosp/1302324 )
Version 1.2.0-alpha04
April 29, 2020
androidx.activity:activity:1.2.0-alpha04 and androidx.activity:activity-ktx:1.2.0-alpha04 are released. Version 1.2.0-alpha04 contains these commits.
নতুন বৈশিষ্ট্য
- Added a contract that can call startIntentSenderForResult to the ActivityResult APIs. ( b/153007517 )
API Changes
- The
prepareCall()method has been renamed toregisterForActivityResult(), both onComponentActivityhere and in Fragment1.3.0-alpha04. ( aosp/1278717 ) - The
GetContents,OpenDocuments, andRequestPermissionscontracts have been renamed toGetMultipleContents,OpenMultipleDocuments, andRequestMultiplePermissions, respectively. ( aosp/1280161 ) -
ComponentActivitynow implements theActivityResultRegisteryOwnerinterface. ( aosp/1290888 ) - - The
startActivityForResult()/onActivityResult()andonRequestPermissionsResult()APIs onComponentActivityhave been deprecated. Please use the Activity Result APIs . ( b/154751887 )
বাগ সংশোধন
- When using the
GetMultipleContentsandOpenMultipleDocumentscontracts and selecting a single item, it is now correctly returned to your callback. ( b/152941153 )
Version 1.2.0-alpha03
১ এপ্রিল, ২০২০
androidx.activity:activity:1.2.0-alpha03 and androidx.activity:activity-ktx:1.2.0-alpha03 are released. Version 1.2.0-alpha03 contains these commits.
নতুন বৈশিষ্ট্য
- Added the
TakeVideo,PickContact,GetContent,GetContents,OpenDocument,OpenDocuments,OpenDocumentTree, andCreateDocumentcontracts to the set of pre-built contracts provided byActivityResultContracts. ( aosp/1262482 , aosp/1266916 , aosp/1268960 ) - The Activity Result APIs now support launching an activity for result with an optional
ActivityOptionsCompat. ( b/151860054 )
API Changes
- The
TakePicturecontract now takes aUriinput for where the image should be stored. The previous contract that does not take any input has been renamed toTakePicturePreview. ( aosp/1262482 ) - The
registerActivityResultCallback()method onActivityResultRegistryhas been renamed toregister(). ( aosp/1267621 ) - The
dispose()method onActivityResultLauncherhas been renamed tounregister()and theunregisterResultCallback()onActivityResultRegistryhas been removed. ( aosp/1267621 ) - The
createIntent()method ofActivityResultContactnow takes aContextin addition to the input to make it possible to create explicit Intents. ( aosp/1238800 ) - An
ActivityResultContractcan now overridegetSynchronousResult()to deliver a result without callingstartActivityForResult. This is used by theRequestPermissionandRequestPermissionscontracts to correctly deliver a 'granted' status if the requested permissions are already granted. ( b/151110799 ) - The previously available
Dialcontract has been removed as thatIntentis not meant to be used withstartActivityForResult(). ( aosp/1266916 ) - Many of the Activity Result APIs not meant to be extended are now
final. This includesgetActivityResultRegistry(), theprepareCall()methods, all methods ofActivityResultRegistryexceptinvoke(), and a number of the default contracts that do not support optional extras. ( b/152439361 )
বাগ সংশোধন
- Fixed a
NullPointerExceptioninActivityResultRegistrywhen attempting to deliver results to a callback that has not yet been re-registered after a configuration change;ActivityResultRegistrynow holds onto these pending results and delivers them when the callback is re-registered. ( b/152137004 )
Version 1.2.0-alpha02
March 18, 2020
androidx.activity:activity:1.2.0-alpha02 and androidx.activity:activity-ktx:1.2.0-alpha02 are released. Version 1.2.0-alpha02 contains these commits.
নতুন বৈশিষ্ট্য
- ActivityResultRegistry :
ComponentActivitynow provides anActivityResultRegistrythat lets you handle thestartActivityForResult()+onActivityResult()as well asrequestPermissions()+onRequestPermissionsResult()flows without overriding methods in your Activity or Fragment, brings increased type safety viaActivityResultContract, and provides hooks for testing these flows. See the updated Getting a Result from an Activity . ( b/125158199 )
Version 1.2.0-alpha01
৪ মার্চ, ২০২০
androidx.activity:activity:1.2.0-alpha01 and androidx.activity:activity-ktx:1.2.0-alpha01 are released. Version 1.2.0-alpha01 contains these commits.
নতুন বৈশিষ্ট্য
- Added support for the
ViewTreeLifecycleOwner.get(View)API added in Lifecycle2.3.0-alpha01such that it will return the Activity as theLifecycleOwnerfor any Views directly added to the Activity. ( aosp/1182955 )
বাগ সংশোধন
- Fixed a regression introduced in Activity
1.1.0when running on older versions of the platform whereonBackPressed()would cause anIllegalStateExceptiondue to a bug in theandroid.app.FragmentManager. ( b/146290338 )
সংস্করণ ১.১.০
সংস্করণ ১.১.০
January 22, 2020
androidx.activity:activity:1.1.0 is released. Version 1.1.0 contains these commits .
Important changes since 1.0.0
- Lifecycle ViewModel SavedState Integration :
SavedStateViewModelFactoryis now the default factory used when usingby viewModels(), theViewModelProviderconstructor, orViewModelProviders.of()with aComponentActivityor its subclasses.
Version 1.1.0-rc03
৪ ডিসেম্বর, ২০১৯
androidx.activity:activity:1.1.0-rc03 and androidx.activity:activity-ktx:1.1.0-rc03 are released. Version 1.1.0-rc03 contains these commits .
Dependency changes
- Activity now depends on Lifecycle
2.2.0-rc03and Lifecycle ViewModel SavedState1.0.0-rc03.
Version 1.1.0-rc02
৭ নভেম্বর, ২০১৯
androidx.activity:activity:1.1.0-rc02 and androidx.activity:activity-ktx:1.1.0-rc02 are released. Version 1.1.0-rc02 contains these commits .
Dependency changes
- Activity now depends on lifecycle
2.2.0-rc02.
Version 1.1.0-rc01
October 23, 2019
androidx.activity:activity:1.1.0-rc01 and androidx.activity:activity-ktx:1.1.0-rc01 are released with no changes from 1.1.0-beta01 . Version 1.1.0-rc01 contains these commits .
Version 1.1.0-beta01
৯ অক্টোবর, ২০১৯
androidx.activity:activity:1.1.0-beta01 and androidx.activity:activity-ktx:1.1.0-beta01 are released. Version 1.1.0-beta01 contains these commits .
Dependency changes
- Activity now depends on SavedState 1.0.0 stable.
Version 1.1.0-alpha03
৫ সেপ্টেম্বর, ২০১৯
androidx.activity:activity:1.1.0-alpha03 and androidx.activity:activity-ktx:1.1.0-alpha03 are released. The commits included in this version can be found here .
নতুন বৈশিষ্ট্য
- Activity now depends on Core 1.1.0 stable.
বাগ সংশোধন
- Activity now depends on Lifecycle
2.2.0-alpha04.
Version 1.1.0-alpha02
৭ আগস্ট, ২০১৯
androidx.activity:activity:1.1.0-alpha02 and androidx.activity:activity-ktx:1.1.0-alpha02 are released. The commits included in this version can be found here .
নতুন বৈশিষ্ট্য
-
SavedStateViewModelFactoryis now the default factory used when usingby viewModels(), theViewModelProviderconstructor, orViewModelProviders.of()with aComponentActivity( b/135716331 )
Version 1.1.0-alpha01
July 2, 2019
androidx.activity:activity:1.1.0-alpha01 and androidx.activity:activity-ktx:1.1.0-alpha01 are released. The commits included in this version can be found here .
নতুন বৈশিষ্ট্য
-
activitynow depends on Lifecycle2.2.0-alpha02. ( aosp/1007817 ) -
activity-ktxadded a dependency onlifecycle-runtime-ktx; you no longer need to explicitly add it to your dependencies when usingactivity-ktxor libraries that depend onactivity-ktx(such asfragment-ktx). ( aosp/987162 )
সংস্করণ ১.০.০
সংস্করণ ১.০.০
৫ সেপ্টেম্বর, ২০১৯
androidx.activity:activity:1.0.0 and androidx.activity:activity-ktx:1.0.0 are released. The commits included in this version can be found here .
Major Features of 1.0.0
- ComponentActivity :
ComponentActivityserves as the new base class forFragmentActivityin Fragment1.1.0and, by extension,AppCompatActivityin AppCompat1.1.0. - activity-ktx : The
activity-ktxmodule includes aby viewModelsKotlin property extension for accessing ViewModels. This module is automatically included when you includefragment-ktxfrom Fragment1.1.0. - OnBackPressedDispatcher : As a composable alternative to overriding
onBackPressed(), you can now register aOnBackPressedCallbackfrom anyLifecycleOwner(such as a fragment) to intercept system back button events. A lambda with receiver versionaddCallbackhas been added toactivity-ktx. See Provide custom back navigation documentation for more details. - onRetainCustomNonConfigurationInstance deprecation : the
onRetainCustomNonConfigurationInstance()and the relatedgetLastCustomNonConfigurationInstance()APIs have been deprecated. It is strongly recommended to use ViewModels to store non-configuration state as they offer a composable solution suitable for anyViewModelStoreOwnerthat makes the ownership of the retained objects clear and provides anonCleared()callback for cleaning up resources when the activity is finally destroyed.
Version 1.0.0-rc01
July 2, 2019
androidx.activity:activity:1.0.0-rc01 and androidx.activity:activity-ktx:1.0.0-rc01 are released with no changes from 1.0.0-beta01 . The commits included in this version can be found here .
Version 1.0.0-beta01
June 5, 2019
androidx.activity::activity:1.0.0-beta01 and androidx.activity:activity-ktx:1.0.0-beta01 are released with no changes from 1.0.0-alpha08 . The commits included in this version can be found here .
Version 1.0.0-alpha08
৭ মে, ২০১৯
androidx.activity:activity:1.0.0-alpha08 and androidx.activity:activity-ktx:1.0.0-alpha08 are released. The commits included in this version can be found here .
এপিআই পরিবর্তন
- Breaking change: The previously deprecated
addOnBackPressedCallbackandremoveOnBackPressedCallbackmethods onComponentActivityhave been removed. aosp/953857 - The
setEnabled()andisEnabled()methods ofOnBackPressedCallbackare now final. b/131416833 - The
remove()method ofOnBackPressedCallbackis now final. aosp/952720 -
OnBackPressedDispatchernow has public constructors, allowing you to construct your own instances for testing, etc. aosp/953431 -
onBackPressed()forComponentActivityis now explicitly marked as@MainThreadaosp/952721
বাগ সংশোধন
- Fixed a
ConcurrentModificationExceptionwhen callingremove()from within thehandleOnBackPressed()method of aOnBackPressedCalbackthat was added with aLifecycleOwner. b/131765095
Version 1.0.0-alpha07
April 25th, 2019
androidx.activity:activity:1.0.0-alpha07 and androidx.activity:activity-ktx:1.0.0-alpha07 are released. The commits included in this version can be found here .
এপিআই পরিবর্তন
This release makes significant changes to the handling of the onBackPressed() . See the updated custom back documentation for more details.
- The methods for
OnBackPressedCallbackandOnBackPressedDispatcherhave been marked as@MainThread. ( aosp/943813 ) - The
handleOnBackPressed()method no longer returns aboolean. Instead,OnBackPressedCallbackis now an abstract class that can be enabled or disabled - only when the newisEnabled()method returns true willhandleOnBackPressed()be called, in which you must handle the back button. ( aosp/944518 ) - The
addCallbackmethods ofOnBackPressedDispatcherno longer return aCancellableinstance.OnBackPressedCallbacknow contain aremove()method that fulfill this functionality, allowing you to callremove()duringhandleOnBackPressed(). ( aosp/944519 ) ( aosp/946316 ) -
activity-ktxnow contains a receiver scoped callback foraddCallbackthat accepts a lamdba that implementshandleOnBackPressed()and has access toisEnabledandremove()( aosp/944520 )
Version 1.0.0-alpha06
April 3rd, 2019
androidx.activity:activity:1.0.0-alpha06 and androidx.activity:activity-ktx:1.0.0-alpha06 are released. The commits included in this version can be found here .
এপিআই পরিবর্তন
- ComponentActivity now contain a second constructor that takes a
@LayoutRes int, which replaces the previous behavior of annotating your AppCompatActivity class with@ContentView. This approach works in both app and library modules. ( b/128352521 ) - The
OnBackPressedCallbackrelated APIs on ComponentActivity have been deprecated in favor of the newOnBackPressedDispatcher, retrievable viagetOnBackPressedDispatcher(). ( aosp/922523 ) - Methods to add a new
OnBackPressedCallbackto theOnBackPressedDispatchernow return aCancellableobject, allowing removal of the callback without requiring an explicit reference to theOnBackPressedDispatcher. ( aosp/922523 ) - Adding a
OnBackPressedCallbackwith an associatedLifecycleOwnernow results in adding and removing theOnBackPressedCallbackas the Lifecycle is started and stopped, respectively. ( aosp/922523 )
Version 1.0.0-alpha05
March 13th, 2019
androidx.activity:activity:1.0.0-alpha05 and androidx.activity:activity-ktx:1.0.0-alpha05 are released. The full list of commits included in this release can be found here .
নতুন বৈশিষ্ট্য
-
@ContentViewannotation lookups are now cached ( b/123709449 )
Version 1.0.0-alpha04
৩০ জানুয়ারী, ২০১৯
androidx.activity:activity 1.0.0-alpha04 and androidx.activity:activity-ktx 1.0.0-alpha04 are released.
নতুন বৈশিষ্ট্য
- Added support for the
@ContentViewclass annotation that allows you to indicate which layout XML file should be inflated as an alternative to usingsetContentView(). ( aosp/837619 )
এপিআই পরিবর্তন
- Added a note that
getViewModelStore()should not be overridden and will be made final in a future release. Please file a feature request if you are currently overriding this method. ( aosp/837619 )
বাগ সংশোধন
- The
activitymodule now depends on version 2.1.0-alpha02 of ViewModel to match theactivity-ktxmodule's dependency.
Version 1.0.0-alpha03
December 17, 2018
androidx.activity 1.0.0-alpha03 is released.
নতুন বৈশিষ্ট্য
- ComponentActivity now implements
BundleSavedStateRegistryOwnerand depends on the newly released SavedState library [ aosp/815133 ] - ComponentActivity now works around an Android framework bug that would cause InputMethodManager to leak the last focused view [ b/37122102 ]
Version 1.0.0-alpha02
December 3, 2018
এপিআই পরিবর্তন
- Added a note that
getLifecycle()should not be overridden and will be madefinalin a future release. Please file a feature request if you are currently overriding this method. ( aosp/815834 )
Version 1.0.0-alpha01
৫ নভেম্বর, ২০১৮
androidx.activity 1.0.0-alpha01 introduces ComponentActivity , a new base class of the existing FragmentActivity and AppCompatActivity .
নতুন বৈশিষ্ট্য
- You can now register an
OnBackPressedCallbackviaaddOnBackPressedCallbackto receiveonBackPressed()callbacks without needing to override the method in your activity. - Added a new
by viewModels()Kotlin property delegate for retrievingViewModels from aComponentActivity. - Pending input events (such as clicks) are now canceled in
onStop().
এপিআই পরিবর্তন
- The implementation of
LifecycleOwnerandViewModelStoreOwnerhave been moved fromFragmentActivitytoComponentActivity. -
onRetainCustomNonConfigurationInstancehas been deprecated. Use aViewModelfor storing objects that need to survive configuration changes.
কার্যকলাপ
| সর্বশেষ আপডেট | Stable Release | Release Candidate | Beta Release | Alpha Release |
|---|---|---|---|---|
| ২৩ সেপ্টেম্বর, ২০২৬ | ১.১৩.০ | - | - | 1.14.0-alpha03 |
Declaring dependencies
To add a dependency on Activity, you must add the Google Maven repository to your project. Read Google's Maven repository for more information.
Add the dependencies for the artifacts you need in the build.gradle file for your app or module:
গ্রোভি
dependencies { def activity_version = "1.13.0" // Java language implementation implementation "androidx.activity:activity:$activity_version" // Kotlin implementation "androidx.activity:activity-ktx:$activity_version" }
কোটলিন
dependencies { val activity_version = "1.13.0" // Java language implementation implementation("androidx.activity:activity:$activity_version") // Kotlin implementation("androidx.activity:activity-ktx:$activity_version") }
For more information about dependencies, see Add build dependencies .
প্রতিক্রিয়া
Your feedback helps make Jetpack better. Let us know if you discover new issues or have ideas for improving this library. Please take a look at the existing issues in this library before you create a new one. You can add your vote to an existing issue by clicking the star button.
See the Issue Tracker documentation for more information.
Version 1.14
Version 1.14.0-alpha03
২৩ সেপ্টেম্বর, ২০২৬
androidx.activity:activity:1.14.0-alpha03 , androidx.activity:activity-compose:1.14.0-alpha03 , and androidx.activity:activity-ktx:1.14.0-alpha03 are released. Version 1.14.0-alpha03 contains these commits .
API Changes
- Use
WindowCompat#enableEdgeToEdge(Window)instead ofEdgeToEdge#enable()( Ibff3e ) - Material 2 text field overloads that accept
value, onValueChangeparameters are deprecated. Please migrate to the overload that usesTextFieldStateto hoist its state. ( I6b841 , b/556234973 )
বাগ সংশোধন
-
androidx.lifecycle:lifecycle-runtimedependency was updated to 2.10.0. This version is required for bundled lifecycle runtime lint checks to run with AGP version 9.5.0-alpha04 or later. ( I99bfd , b/556807521 ) -
ComponentActivitynewdefaultViewModelArgsnow supports direct boot configuration as well. ( I10a08 )
Version 1.14.0-alpha02
০৯ সেপ্টেম্বর, ২০২৬
androidx.activity:activity:1.14.0-alpha02 , androidx.activity:activity-compose:1.14.0-alpha02 , and androidx.activity:activity-ktx:1.14.0-alpha02 are released. Version 1.14.0-alpha02 contains these commits .
বাগ সংশোধন
-
compileSdkfor Compose libraries updated to 37.1. This will require transitively updatingcompileSdkfor all apps and libraries using Compose. ( I05b0f )
Version 1.14.0-alpha01
২৬ আগস্ট, ২০২৬
androidx.activity:activity:1.14.0-alpha01 , androidx.activity:activity-compose:1.14.0-alpha01 , and androidx.activity:activity-ktx:1.14.0-alpha01 are released. Version 1.14.0-alpha01 contains these commits .
API Changes
- Intent extras are no longer automatically added to
defaultViewModelCreationExtrasfor exported activities. Developers of exported activities can overridedefaultViewModelArgsto explicitly provide validated intent extras. ( Id0cb6 , b/213646066 ) - Activity now provides
NavigationEventDispatcherOwnerandOnBackPressedDispatcherOwnerfactory functions for creating the instances of the respective components easily. ( I1d259 , Iadd5c ) -
OnBackPressedDispatchernow provides anasNavigationEventDispatcherextension to easily covert it to aNavigationEventDispatcher. ( Id11cf )
Version 1.13
Version 1.13.0
১১ মার্চ, ২০২৬
androidx.activity:activity:1.13.0 , androidx.activity:activity-compose:1.13.0 , and androidx.activity:activity-ktx:1.13.0 are released. Version 1.13.0 contains these commits .
Important changes since 1.12.0:
-
ComponentActivitynow implements theOnPictureInPictureUiStateChangedProviderinterface which means it can now integrate with the newcore:core-pipartifact that allows allow any component to receive picture-in-picture ui state change events. -
EdgeToEdgeis now re-invoked on configuration changes to ensure that the system status bar color is properly updated.
Version 1.13.0-rc01
২৫শে ফেব্রুয়ারি, ২০২৬
androidx.activity:activity:1.13.0-rc01 , androidx.activity:activity-compose:1.13.0-rc01 , and androidx.activity:activity-ktx:1.13.0-rc01 are released. Version 1.13.0-rc01 contains these commits .
বাগ সংশোধন
- From Activity 1.12.4 : The Photo and Video
ActivityResultContractsnow will correctly launch when being used on devices with the latest URI security fixes. ( I61201 , b/433708587 )
Version 1.13.0-alpha01
১৪ জানুয়ারী, ২০২৬
androidx.activity:activity:1.13.0-alpha01 , androidx.activity:activity-compose:1.13.0-alpha01 , and androidx.activity:activity-ktx:1.13.0-alpha01 are released. Version 1.13.0-alpha01 contains these commits .
নতুন বৈশিষ্ট্য
-
EdgeToEdgeis now re-invoked on configuration changes to ensure that the system status bar color is properly updated. ( Id1381 , b/364713509 )
API Changes
-
ComponentActivitynow implements theOnPictureInPictureUiStateChangedProviderinterface which means it can now integrate with the newcore:core-pipartifact that allows allow any component to receive picture-in-picture ui state change events. ( I4df5c , b/441310308 )
বাগ সংশোধন
- From Activity 1.12.2: Fixed an issue where manually setting
isEnabledon a lifecycle-awareOnBackPressedCallbackwould override theLifecyclestate, potentially causing crashes. ( I7d898 , b/461999811 )
Version 1.12
Version 1.12.4
১১ ফেব্রুয়ারী, ২০২৬
androidx.activity:activity:1.12.4 , androidx.activity:activity-compose:1.12.4 , and androidx.activity:activity-ktx:1.12.4 are released. Version 1.12.4 contains these commits .
বাগ সংশোধন
- The Photo and Video
ActivityResultContractsnow will correctly launch when being used on devices with the latest URI security fixes. ( I61201 , b/433708587 )
Version 1.12.3
২৮ জানুয়ারী, ২০২৬
androidx.activity:activity:1.12.3 , androidx.activity:activity-compose:1.12.3 , and androidx.activity:activity-ktx:1.12.3 are released. Version 1.12.3 contains these commits .
Version 1.12.2
১৭ ডিসেম্বর, ২০২৫
androidx.activity:activity:1.12.2 , androidx.activity:activity-compose:1.12.2 , and androidx.activity:activity-ktx:1.12.2 are released. Version 1.12.2 contains these commits .
বাগ সংশোধন
- Fixed an issue where manually setting isEnabled on a lifecycle-aware
OnBackPressedCallbackwould override the Lifecycle state, potentially causing crashes. ( I7d898 , b/461999811 )
সংস্করণ ১.১২.১
০৩ ডিসেম্বর, ২০২৫
androidx.activity:activity:1.12.1 , androidx.activity:activity-compose:1.12.1 , and androidx.activity:activity-ktx:1.12.1 are released. Version 1.12.1 contains these commits .
Updated Dependency
- Activity now depends on Navigation Event 1.0.1
Version 1.12.0
১৯ নভেম্বর, ২০২৫
androidx.activity:activity:1.12.0 , androidx.activity:activity-compose:1.12.0 , and androidx.activity:activity-ktx:1.12.0 are released. Version 1.12.0 contains these commits .
Important changes since 1.11.0:
- The
Androidx Activitylibrary is now dependent on the newNavigationEventlibrary. This includes support for theNavigationEventDispatcherinComponentActivityandComponentDialog. TheOnBackPressedAPIs have also been rewritten on top of theNavigationEventAPIs to ensure it is backward compatible with the previous library.
Version 1.12.0-rc01
November 05, 2025
androidx.activity:activity:1.12.0-rc01 , androidx.activity:activity-compose:1.12.0-rc01 , and androidx.activity:activity-ktx:1.12.0-rc01 are released. Version 1.12.0-rc01 contains these commits .
বাগ সংশোধন
- Fix runtime failures for
BackHandlerandPredictiveBackHandlerin apps using custom Activity classes. These composables now safely fall back toLocalOnBackPressedDispatcherOwnerwhile preserving dispatch order in apps that supportNavigationEventDispatcherOwner. ( I43873 )
Version 1.12.0-beta01
২২ অক্টোবর, ২০২৫
androidx.activity:activity:1.12.0-beta01 , androidx.activity:activity-compose:1.12.0-beta01 , and androidx.activity:activity-ktx:1.12.0-beta01 are released. Version 1.12.0-beta01 contains these commits .
API Changes
- Introduce the experimental
ActivityFlagsAPI for managing runtime behavior changes and migrations. The first flag enables stable ordering forOnBackPressedCallback, making back navigation more predictable across lifecycle changes. Developers can opt out by settingActivityFlags.isOnBackPressedLifecycleOrderMaintained = false. ( I06bdf , Id08bb , I439aa , b/422730945 , b/450533622 )
Dependency Update
- Update lifecycle dependencies to 2.9.4 ( Ic9fb2 )
Version 1.12.0-alpha09
২৪ সেপ্টেম্বর, ২০২৫
androidx.activity:activity:1.12.0-alpha09 , androidx.activity:activity-compose:1.12.0-alpha09 , and androidx.activity:activity-ktx:1.12.0-alpha09 are released. Version 1.12.0-alpha09 contains these commits .
Dependency Changes
- Activity now depends on Navigation Event 1.0.0-alpha08 .
Version 1.12.0-alpha08
১০ সেপ্টেম্বর, ২০২৫
androidx.activity:activity:1.12.0-alpha08 , androidx.activity:activity-compose:1.12.0-alpha08 , and androidx.activity:activity-ktx:1.12.0-alpha08 are released. Version 1.12.0-alpha08 contains these commits .
Dependency Update
- Activity now depends on Navigation Event 1.0.0-alpha08 .
Version 1.12.0-alpha07
২৭ আগস্ট, ২০২৫
androidx.activity:activity:1.12.0-alpha07 , androidx.activity:activity-compose:1.12.0-alpha07 , and androidx.activity:activity-ktx:1.12.0-alpha07 are released. Version 1.12.0-alpha07 contains these commits .
বাগ সংশোধন
- Fixed an issue with
EdgeToEdgeon API 35 in which invisible views caused unexpected measurement insets. ( If49ff )
Dependency Update
- Activity now depends on Navigation Event
1.0.0-alpha07.
Version 1.12.0-alpha06
August 13, 2025
androidx.activity:activity:1.12.0-alpha06 , androidx.activity:activity-compose:1.12.0-alpha06 , and androidx.activity:activity-ktx:1.12.0-alpha06 are released. Version 1.12.0-alpha06 contains these commits .
MinSdk Update
- The default
minSdkfor the AndroidX has been moved from API 21 to API 23 ( Ibdfca , b/380448311 , b/435705964 , b/435705223 )
Documentation Updates
- Updated KDocs for
PredictiveBackHandlerto call out a known timing issue where it may process a gesture in the same frame it is disabled. ( I5be5c , b/431534103 ) - Updated KDocs for
BackHandlerandPredictiveBackHandlerto explicitly state the 'last composed wins' behavior in addition to recommending unconditional composition with theenabledflag. ( I7ab94 )
Dependency update
- Activity now depends on Navigation Event
1.0.0-alpha06.
Version 1.12.0-alpha05
৩০ জুলাই, ২০২৫
androidx.activity:activity:1.12.0-alpha05 , androidx.activity:activity-compose:1.12.0-alpha05 , and androidx.activity:activity-ktx:1.12.0-alpha05 are released. Version 1.12.0-alpha05 contains these commits .
Dependency Update
- Activity now depends on Navigation Event
1.0.0-alpha05.
Version 1.12.0-alpha04
২ জুলাই, ২০২৫
androidx.activity:activity:1.12.0-alpha04 , androidx.activity:activity-compose:1.12.0-alpha04 , and androidx.activity:activity-ktx:1.12.0-alpha04 are released. Version 1.12.0-alpha04 contains these commits .
Dependency Changes
- Activity now depends on NavigationEvent Alpha04
Version 1.12.0-alpha03
১৮ জুন, ২০২৫
androidx.activity:activity:1.12.0-alpha03 , androidx.activity:activity-compose:1.12.0-alpha03 , and androidx.activity:activity-ktx:1.12.0-alpha03 are released. Version 1.12.0-alpha03 contains these commits .
বাগ সংশোধন
OnBackPressedDispatcherandNavigationEventDispatcherare now both initialized lazily inComponentActivity. ( I710e6 )Fixed issues with
OnBackPressedDistpatcherthat caused the following:- Only the latest dispatcher an
OnBackPressedCallbackwas added to being notified of its enabled state ( b/418715930 ) -
OnBackPressedDispatcherremoves the wrong callback when using theaddCallbackfunction that takes a lifecycle. ( b/422714753 ) -
OnBackPressedDispatcher.remove()does not remove all instances of a registeredOnBackPressedCallback. ( b/423024414 )
- Only the latest dispatcher an
Version 1.12.0-alpha02
June 4, 2025
androidx.activity:activity:1.12.0-alpha02 , androidx.activity:activity-compose:1.12.0-alpha02 , and androidx.activity:activity-ktx:1.12.0-alpha02 are released. Version 1.12.0-alpha02 contains these commits .
বাগ সংশোধন
- From NavigationEvent
1.0.0-alpha02: Fixed aConcurrentModificationExceptionthat could occur whenNavigationEventCallback.remove()was called due to simultaneously modifying the internal list of closeables. ( I63066 )
Version 1.12.0-alpha01
২০ মে, ২০২৫
androidx.activity:activity:1.12.0-alpha01 , androidx.activity:activity-compose:1.12.0-alpha01 , and androidx.activity:activity-ktx:1.12.0-alpha01 are released. Version 1.12.0-alpha01 contains these commits .
নতুন বৈশিষ্ট্য
-
ComponentActivityandComponentDialoghave been integrated with NavigationEvent1.0.0-alpha01via theNavigationEventDispatcherOwnerAPI. You can now retrieve aNavigationEventDispatcherfrom yourComponentActivityvia thenavigationEventDispatcherfield. Since theOnBackPressedDispatcherhas been re-written on top of the new library all previous usages should continue to work correctly. You should useNavigationEventDispatcherandNavigationEventCallbackgoing forward. ( Ib8eed , I6cc44 , Ib7724 , I9a0f7 , b/412597031 , b/415028038 , b/412596729 , b/412597140 , b/412596012 )
Version 1.11
Version 1.11.0
১০ সেপ্টেম্বর, ২০২৫
androidx.activity:activity:1.11.0 , androidx.activity:activity-compose:1.11.0 , and androidx.activity:activity-ktx:1.11.0 are released. Version 1.11.0 contains these commits .
Important changes since 1.10.0:
- Added
MediaCapabilitiesAPI toPickVisualMediaRequestto let applications specify its media capabilities, such as supported HDR Types. - Activity is now compiled with API 36.
Version 1.11.0-rc01
২৩ এপ্রিল, ২০২৫
androidx.activity:activity:1.11.0-rc01 , androidx.activity:activity-compose:1.11.0-rc01 , and androidx.activity:activity-ktx:1.11.0-rc01 are released. Version 1.11.0-rc01 contains these commits .
Version 1.11.0-beta01
৯ এপ্রিল, ২০২৫
androidx.activity:activity:1.11.0-beta01 , androidx.activity:activity-compose:1.11.0-beta01 , and androidx.activity:activity-ktx:1.11.0-beta01 are released. Version 1.11.0-beta01 contains these commits .
Version 1.11.0-alpha02
২৬ মার্চ, ২০২৫
androidx.activity:activity:1.11.0-alpha02 , androidx.activity:activity-compose:1.11.0-alpha02 , and androidx.activity:activity-ktx:1.11.0-alpha02 are released. Version 1.11.0-alpha02 contains these commits .
API Changes
- Integrated the new
EDGE_NONEandframeTimeMillisfrom Android 16 Beta03 into theBackEventCompatprovided byOnBackPressedCallback'shandleOnBackStartedandhandleOnBackProgressedfunctions.
Dependency Updates
- Activity is now compiled with API 36. ( I510e8 , b/301910674 )
Version 1.11.0-alpha01
১২ মার্চ, ২০২৫
androidx.activity:activity:1.11.0-alpha01 , androidx.activity:activity-compose:1.11.0-alpha01 , and androidx.activity:activity-ktx:1.11.0-alpha01 are released. Version 1.11.0-alpha01 contains these commits .
নতুন বৈশিষ্ট্য
- Added
MediaCapabilitiesAPI toPickVisualMediaRequestto let applications specify its media capabilities, such as supported HDR Types. ( Ic3ee7 )
Version 1.10
Version 1.10.1
২৬ ফেব্রুয়ারী, ২০২৫
androidx.activity:activity:1.10.1 , androidx.activity:activity-compose:1.10.1 , and androidx.activity:activity-ktx:1.10.1 are released. Version 1.10.1 contains these commits .
বাগ সংশোধন
-
ViewTreeOnBackPressedDispatcherOwnersandFullyDrawnReporterOwnerscan now be resolved through disjoint parents of a view, such as aViewOverlay. See the release notes of core or the documentation inViewTree.setViewTreeDisjointParentfor more information on disjoint view parents. ( Ie7750 )
Version 1.10.0
১৫ জানুয়ারী, ২০২৫
androidx.activity:activity:1.10.0 , androidx.activity:activity-compose:1.10.0 , and androidx.activity:activity-ktx:1.10.0 are released. Version 1.10.0 contains these commits .
Important changes since 1.9.0
-
PhotoPickernow allows picking images in order and choosing which tab (either albums or images) should be initially visible. - The
PickVisualMediaandPickMultipleVisualMediaActivity Result contracts that trigger the Photo Picker no longer directly delegates to Google Play services if the system Photo picker is not available, but uses the publicACTION_SYSTEM_FALLBACK_PICK_IMAGESaction and related extras to provide a consistent Photo Picker experience to OEMs and system apps as a fallback. - New
LocalActivitycomposition local that provides theActivityfor the current scope, removing the need for developers to get anActivityfrom theLocalContext.
Version 1.10.0-rc01
December 11, 2024
androidx.activity:activity:1.10.0-rc01 , androidx.activity:activity-compose:1.10.0-rc01 , and androidx.activity:activity-ktx:1.10.0-rc01 are released. Version 1.10.0-rc01 contains these commits .
বাগ সংশোধন
- Fixed an issue where changing the enabled state while the
PredictiveBackHandleris currently active would short circuit the callback immediately. It will now finish the current callback regardless of the enabled status changes. ( Ib8719 )
Version 1.10.0-beta01
১৩ নভেম্বর, ২০২৪
androidx.activity:activity:1.10.0-beta01 , androidx.activity:activity-compose:1.10.0-beta01 , and androidx.activity:activity-ktx:1.10.0-beta01 are released with no changes since the last alpha. Version 1.10.0-beta01 contains these commits .
Version 1.10.0-alpha03
৩০ অক্টোবর, ২০২৪
androidx.activity:activity:1.10.0-alpha03 , androidx.activity:activity-compose:1.10.0-alpha03 , and androidx.activity:activity-ktx:1.10.0-alpha03 are released. Version 1.10.0-alpha03 contains these commits .
API Changes
- Added a new
LocalActivitycomposition local that provides theActivityfor the current scope, removing the need for developers to get anActivityfrom theLocalContext. It also comes with a new lint rule that checks when theLocalContextis incorrectly being cast to anActivity. ( I7746a , b/283009666 )
বাগ সংশোধন
- From Activity
1.9.3:PredictiveBackHandlerwill no longer fire it's callback after the handler has been disabled. This will fix an issue where theNavHostfrom Navigation Compose would throw anIndexOutOfBoundsException. ( I3f75e , b/365027664 , b/340202286 )
Dependency Update
- Activity Compose now depends on Compose Runtime 1.7.0 ( I7746a , b/283009666 )
Version 1.10.0-alpha02
৪ সেপ্টেম্বর, ২০২৪
androidx.activity:activity:1.10.0-alpha02 , androidx.activity:activity-compose:1.10.0-alpha02 , and androidx.activity:activity-ktx:1.10.0-alpha02 are released. Version 1.10.0-alpha02 contains these commits .
Behavior Changes
- The
PickVisualMediaandPickMultipleVisualMediaActivity Result contracts that trigger the Photo Picker no longer directly delegates to Google Play services if the system Photo picker is not available, but uses the publicACTION_SYSTEM_FALLBACK_PICK_IMAGESaction and related extras to provide a consistent Photo Picker experience to OEMs and system apps as a fallback. This should have no effect on the user experience for devices that have a recent version of Google Play services. ( I3513d )
বাগ সংশোধন
- Removed manual outlining of access to new platform APIs since this happens automatically via API modeling when using R8 with AGP 7.3 or later (eg R8 version 3.3) and for all builds when using AGP 8.1 or later (eg D8 version 8.1). Clients who are not using AGP are advised to update to D8 version 8.1 or later. See this article for more details. ( I9496c , b/345472586 )
- From Activity
1.9.2: Fixed an issue where the Activity ComposePredictiveBackHandlerAPI would continue to handle the system back gesture on the frame it was disabled, which could result in libraries like Navigation Compose to handle back even with an empty back stack, resulting in it throwing anIndexOutOfBoundsException. ( Ie3301 , b/340202286 ) - From Activity
1.9.1: Fixed an issue withPredictiveBackHandlerwhere after doing system back, attempting to doonBackPressedfrom theOnBackPressedDispatcherwould fail. ( I5f1f8 )
Version 1.10.0-alpha01
June 26, 2024
androidx.activity:activity:1.10.0-alpha01 , androidx.activity:activity-compose:1.10.0-alpha01 , and androidx.activity:activity-ktx:1.10.0-alpha01 are released. This version is developed in an internal branch.
নতুন বৈশিষ্ট্য
- Added support for new
PhotoPickerfeatures introduced in Android V including being able to pick images in order and choose which tab (either albums or images) should be initially visible.
Version 1.9
Version 1.9.3
১৬ অক্টোবর, ২০২৪
androidx.activity:activity:1.9.3 , androidx.activity:activity-compose:1.9.3 , and androidx.activity:activity-ktx:1.9.3 are released. Version 1.9.3 contains these commits .
বাগ সংশোধন
-
PredictiveBackHandlerwill no longer fire it's callback after the handler has been disabled. This will fix an issue where theNavHostfrom Navigation Compose would throw anIndexOutOfBoundsException. ( I3f75e , b/340202286 )
সংস্করণ ১.৯.২
৪ সেপ্টেম্বর, ২০২৪
androidx.activity:activity:1.9.2 , androidx.activity:activity-compose:1.9.2 , and androidx.activity:activity-ktx:1.9.2 are released. Version 1.9.2 contains these lthcocommits .
বাগ সংশোধন
- Fixed an issue where the Activity Compose
PredictiveBackHandlerAPI would continue to handle the system back gesture on the frame it was disabled, which could result in libraries like Navigation Compose to handle back even with an empty back stack, resulting in it throwing anIndexOutOfBoundsException. ( Ie3301 , b/340202286 )
Version 1.9.1
২৪ জুলাই, ২০২৪
androidx.activity:activity:1.9.1 , androidx.activity:activity-compose:1.9.1 , and androidx.activity:activity-ktx:1.9.1 are released. Version 1.9.1 contains these commits .
বাগ সংশোধন
- Fixed an issue with
PredictiveBackHandlerwhere after doing system back, attempting to doonBackPressedfrom theOnBackPressedDispatcherwould fail. ( I5f1f8 )
Version 1.9.0
April 17, 2024
androidx.activity:activity:1.9.0 , androidx.activity:activity-compose:1.9.0 , and androidx.activity:activity-ktx:1.9.0 are released. Version 1.9.0 contains these commits .
Important changes since 1.8.0
-
ComponentActivitynow implementsOnUserLeaveHintProviderto allow components to callbacks foronUserLeaveHintevents. - The
OnBackPressedCallback,BackHandler, andPredictiveBackHandlerAPIs now warn when callingonBackPressedDispatcher.onBackPressed()when handling back as that will always break the Predictive Back Animation . See the best practices guide for more details. - The remainder of the Activity APIs have been rewritten in Kotlin and all extensions previously available in
activity-ktxhave been moved toactivity.activity-ktxis now completely empty.- As part of the conversion of
ActivityResultLauncherto Kotlin, thegetContractmethod is now an abstract Kotlin property. This is a binary compatible change, but source breaking if your implementation ofActivityResultLauncheris written in Kotlin.
- As part of the conversion of
Version 1.9.0-rc01
৩ এপ্রিল, ২০২৪
androidx.activity:activity:1.9.0-rc01 , androidx.activity:activity-compose:1.9.0-rc01 , and androidx.activity:activity-ktx:1.9.0-rc01 are released. Version 1.9.0-rc01 contains these commits .
Dependency update
- Activity now depends on Profile Installer 1.3.1 .
Version 1.9.0-beta01
২০ মার্চ, ২০২৪
androidx.activity:activity:1.9.0-beta01 , androidx.activity:activity-compose:1.9.0-beta01 , and androidx.activity:activity-ktx:1.9.0-beta01 are released. Version 1.9.0-beta01 contains these commits .
বাগ সংশোধন
- Fixed an Activity startup performance regression introduced in Activity
1.9.0-alpha02caused by calling theOnBackPressedDispatcheras part of the creation of the Activity. ( Ie75e3 )
Version 1.9.0-alpha03
৭ ফেব্রুয়ারী, ২০২৪
androidx.activity:activity:1.9.0-alpha03 , androidx.activity:activity-compose:1.9.0-alpha03 , and androidx.activity:activity-ktx:1.9.0-alpha03 are released. Version 1.9.0-alpha03 contains these commits.
Lint Warning
- The
OnBackPressedCallback,BackHandler, andPredictiveBackHandlerAPIs now warn when callingonBackPressedDispatcher.onBackPressed()when handling back as that will always break the Predictive Back Animation . See the best practices guide for more details. ( 1e4222 , 2c950d , b/287505200 )
বাগ সংশোধন
- If a back event is sent from the system started during an already running Predictive Back Gesture, the currently running Predictive Back Gesture is canceled and the new back event takes over to begin a new Predictive Back Gesture. ( I3482e )
- Fixed a crash when accessing the
onBackPressedDispatcherfrom aComponentActivityfor the first time from a background thread. It is now safe to access theonBackPressedDispatcheron any thread. ( I79955 )
Version 1.9.0-alpha02
২৪ জানুয়ারী, ২০২৪
androidx.activity:activity:1.9.0-alpha02 , androidx.activity:activity-compose:1.9.0-alpha02 , and androidx.activity:activity-ktx:1.9.0-alpha02 are released. Version 1.9.0-alpha02 contains these commits.
Kotlin Conversions
-
ActivityResultRegistryhas been rewritten in Kotlin. This ensures that the nullability of the generics on the contract passed toregisterwill correctly be passed through to theActivityResultLauncherreturned to you. ( I121f0 ) -
ActivityResulthas been rewritten in Kotlin. TheActivityResultKotlin extensions that support destructuring into theresultCodeanddatafields have been moved fromactivity-ktxtoactivity. ( I0565a ) - The Kotlin extensions of
by viewModels()forComponentActivityandtrackPipAnimationHintViewhave been moved fromactivity-ktxtoactivity. Theactivity-ktxartifact is now completely empty. ( I0a444 )
বাগ সংশোধন
- The
enableEdgeToEdgeAPI now draws around any display cutouts. ( a3644b , b/311173461 ) - From Activity
1.8.2: Fixed the extra passed to the Photo Picker Activity Contract'sACTION_SYSTEM_FALLBACK_PICK_IMAGESto correctly pass it theEXTRA_SYSTEM_FALLBACK_PICK_IMAGES_MAXkey, rather than using the extra with the key"com.google.android.gms.provider.extra.PICK_IMAGES_MAX". It is strongly recommended if you are an OEM who implements a system fallback Photo Picker to support both extras to ensure the widest compatibility. ( I96a00 )
Version 1.9.0-alpha01
২৯ নভেম্বর, ২০২৩
androidx.activity:activity:1.9.0-alpha01 , androidx.activity:activity-compose:1.9.0-alpha01 , and androidx.activity:activity-ktx:1.9.0-alpha01 are released. Version 1.9.0-alpha01 contains these commits.
নতুন বৈশিষ্ট্য
-
ComponentActivitynow implementsOnUserLeaveHintProviderto allow components to callbacks foronUserLeaveHintevents. ( I54892 )
API Changes
-
ComponentActivityhas been rewritten in Kotlin. ( I14f31 ) -
ActivityResultCallerhas been rewritten in Kotlin. ( Ib02e4 ) -
ActivityResultLauncherhas been rewritten in Kotlin. As part of that conversion, thegetContractmethod is now an abstract Kotlin property. This is a binary compatible change, but source breaking if your implementation ofActivityResultLauncheris written in Kotlin. ( Id4615 ) -
PickVisualMediaRequestnow has the same minimum API level of 19 as thePickVisualMediaActivity Result contract. ( Id6e21 )
Dependency Update
- Activity now depends on Core
1.13.0-alpha01. ( I14f31 )
Version 1.8
Version 1.8.2
১৩ ডিসেম্বর, ২০২৩
androidx.activity:activity:1.8.2 , androidx.activity:activity-compose:1.8.2 , and androidx.activity:activity-ktx:1.8.2 are released. Version 1.8.2 contains these commits.
বাগ সংশোধন
- Fixed the extra passed to the Photo Picker Activity Contract's
ACTION_SYSTEM_FALLBACK_PICK_IMAGESto correctly pass it theEXTRA_SYSTEM_FALLBACK_PICK_IMAGES_MAXkey, rather than using the extra with the key"com.google.android.gms.provider.extra.PICK_IMAGES_MAX". It is strongly recommended if you are an OEM who implements a system fallback Photo Picker to support both extras to ensure the widest compatibility. ( I96a00 )
Version 1.8.1
১৫ নভেম্বর, ২০২৩
androidx.activity:activity:1.8.1 , androidx.activity:activity-compose:1.8.1 , and androidx.activity:activity-ktx:1.8.1 are released. Version 1.8.1 contains these commits.
বাগ সংশোধন
-
OnBackPressedDispatchernow continues to dispatch to the correctOnBackPressedCallbackeven after a newOnBackPressedCallbackis added while the back gesture is being handled. ( Id0ff6 )
Version 1.8.0
৪ অক্টোবর, ২০২৩
androidx.activity:activity:1.8.0 , androidx.activity:activity-compose:1.8.0 , and androidx.activity:activity-ktx:1.8.0 are released. Version 1.8.0 contains these commits.
Important changes since 1.7.0
- Predictive Back - The
OnBackPressedCallbacknow offers new Predictive Back callbacks for handling the back gesture starting, progress throughout the gesture, and the back gesture being canceled in addition to the previoushandleOnBackPressed()callback for when the back gesture is committed. This also comes with thePredictiveBackHandlerComposable to handle predictive back gesture events in Activity Compose. It provides a Flow of BackEventCompat objects that must be collected in the suspending lamba you provide:
PredictiveBackHandler { progress: Flow<BackEventCompat> ->
// code for gesture back started
try {
progress.collect { backEvent ->
// code for progress
}
// code for completion
} catch (e: CancellationException) {
// code for cancellation
}
}
ComponentActivity.onBackPressed() has now been deprecated in favor of the APIs for handling back. Developers should now utilize the OnBackPressedDispatcher , rather than overriding this method.
- EdgeToEdge -
ComponentActivity.enableEdgeToEdge()has been added to easily set up the edge-to-edge display in a backward-compatible manner.
Version 1.8.0-rc01
২০ সেপ্টেম্বর, ২০২৩
androidx.activity:activity:1.8.0-rc01 , androidx.activity:activity-compose:1.8.0-rc01 , and androidx.activity:activity-ktx:1.8.0-rc01 are released. Version 1.8.0-rc01 contains these commits.
Version 1.8.0-beta01
৬ সেপ্টেম্বর, ২০২৩
androidx.activity:activity:1.8.0-beta01 , androidx.activity:activity-compose:1.8.0-beta01 , and androidx.activity:activity-ktx:1.8.0-beta01 are released. Version 1.8.0-beta01 contains these commits.
Documentation Improvement
- Improved the documentation of
BackEventCompat. ( aosp/2722254 )
Version 1.8.0-alpha07
২৩শে আগস্ট, ২০২৩
androidx.activity:activity:1.8.0-alpha07 , androidx.activity:activity-compose:1.8.0-alpha07 , and androidx.activity:activity-ktx:1.8.0-alpha07 are released. Version 1.8.0-alpha07 contains these commits.
নতুন বৈশিষ্ট্য
Activity Compose has added a new
PredictiveBackHandlerComposable to handle predictive back gesture events. It provides aFlowofBackEventCompatobjects that must be collected in the suspending lamba you provide:PredictiveBackHandler { progress: Flow<BackEventCompat> -> // code for gesture back started try { progress.collect { backEvent -> // code for progress } // code for completion } catch (e: CancellationException) { // code for cancellation } }It also comes with a compile time warning via lint rule to ensure the
Flowcallscollect(). ( Id2773 , b/294884345 )The
onBackPressedDispatcherinComponentActivityis now initialized lazily so that it is only created when required. ( I0bf8e )
বাগ সংশোধন
-
ComponentActivitywill no longer show a NPE on Android 13 when it gets anonBackPressed()callback and the Activity has already beenDESTROYED. ( Idb055 , b/291869278 ) - Removed usages of experimental
isAtLeastU()API ( Ie9117 , b/289269026 )
Version 1.8.0-alpha06
২১ জুন, ২০২৩
androidx.activity:activity:1.8.0-alpha06 , androidx.activity:activity-compose:1.8.0-alpha06 , and androidx.activity:activity-ktx:1.8.0-alpha06 are released. Version 1.8.0-alpha06 contains these commits.
নতুন বৈশিষ্ট্য
- The
OnBackPressedDispatchernow correctly cancels any callbacks that are removed during a Predictive Back Gesture. ( I3f90f )
API Changes
- When passing
SystemBarStyle.autoto theenableEdgeToEdgeAPI, you can now override thedetectDarkModelambda parameter to provide custom logic for detecting night mode. ( aosp/2546393 , b/278263793 )
Version 1.8.0-alpha05
৭ জুন, ২০২৩
androidx.activity:activity:1.8.0-alpha05 , androidx.activity:activity-compose:1.8.0-alpha05 , and androidx.activity:activity-ktx:1.8.0-alpha05 are released. This version is developed in an internal branch.
API Changes
- Activity now provides a
BackEventCompatclass that serves as a backward compatible version ofBackEventthat is decoupled from the frameworkBackEventclass. - Breaking change: The
handleOnBackStartedandhandleOnBackProgressedmethods ofOnBackPressedCallbacknow receive anandroidx.activity.BackEventCompatinstance rather than a frameworkandroid.window.BackEventclass. The equivalent@VisibleForTestingAPIs onOnBackPressedDispatcherhave also been updated. - The constructor for
OnBackPressedDispatchernow takes an optionalConsumer<Boolean>instance that allows the owners of the dispatcher to receive a callback whenever the number of enabled callbacks changes from zero to non-zero or vice versa.
বাগ সংশোধন
- From Activity
1.7.2: FixReportDrawncrashing when navigating away from a screen beforereportis called. ( Ic46f1 , b/260506820 )
Version 1.8.0-alpha04
১০ মে, ২০২৩
androidx.activity:activity:1.8.0-alpha04 , androidx.activity:activity-compose:1.8.0-alpha04 , and androidx.activity:activity-ktx:1.8.0-alpha04 are released. This was released from an internal branch.
বাগ সংশোধন
- From Activity 1.7.1 : - The
ReportFullyDrawExecuterno longer leaks when usingComponentActivitywithActivityScenario. ( Id2ff2 , b/277434271 )
Version 1.8.0-alpha03
১২ এপ্রিল, ২০২৩
androidx.activity:activity:1.8.0-alpha03 , androidx.activity:activity-compose:1.8.0-alpha03 , and androidx.activity:activity-ktx:1.8.0-alpha03 are released. This was released from an internal branch.
নতুন বৈশিষ্ট্য
- Added
ComponentActivity.setUpEdgeToEdge()to easily set up the edge-to-edge display in a backward-compatible manner.
API Changes
-
ComponentActivity.onBackPressed()has now been deprecated in favor of the APIs for handling back. Developers should now utilize theOnBackPressedDispatcher, rather than overriding this method. ( Ibce2f , b/271596918 ) -
ComponentDialogandComponentActivitynow contain public APIinitViewTreeOwners()to be used to initialize all view tree owners before setting the content view. ( Ibdce0 , b/261314581 )
বাগ সংশোধন
- Fixed an issue where Fragments were incorrectly invalidating MenuHosts and causing other menus in the Activity to have unexpected behavior. ( I9404e , b/244336571 )
Other Changes
- The
ActivityResultRegisternow uses KotlinRandominstead of Java. ( I4d98f , b/272096025 )
Version 1.8.0-alpha02
৮ মার্চ, ২০২৩
androidx.activity:activity:1.8.0-alpha02 , androidx.activity:activity-compose:1.8.0-alpha02 , and androidx.activity:activity-ktx:1.8.0-alpha02 are released. Developed from an internal branch.
Dependency update
- From Activity
1.7.0-rc01: Activity now depends onLifecycle 2.6.0.
Version 1.8.0-alpha01
৮ ফেব্রুয়ারী, ২০২৩
androidx.activity:activity:1.8.0-alpha01 , androidx.activity:activity-compose:1.8.0-alpha01 , and androidx.activity:activity-ktx:1.8.0-alpha01 are released. This was built from an internal branch.
নতুন বৈশিষ্ট্য
- The
OnBackPressedCallbackclass now contains new Predictive Back progress callbacks for handling the back gesture starting, progress throughout the gesture, and the back gesture being canceled in addition to the previoushandleOnBackPressed()callback for when the back gesture is committed.
Version 1.7
Version 1.7.2
২৪ মে, ২০২৩
androidx.activity:activity:1.7.2 , androidx.activity:activity-compose:1.7.2 , and androidx.activity:activity-ktx:1.7.2 are released. Version 1.7.2 contains these commits.
বাগ সংশোধন
- Fix
ReportDrawncrashing when navigating away from a screen beforereportis called. ( Ic46f1 , b/260506820 )
সংস্করণ ১.৭.১
১৯ এপ্রিল, ২০২৩
androidx.activity:activity:1.7.1 , androidx.activity:activity-compose:1.7.1 , and androidx.activity:activity-ktx:1.7.1 are released. Version 1.7.1 contains these commits.
বাগ সংশোধন
- The
ReportFullyDrawExecuterno longer leaks when usingComponentActivitywithActivityScenario. ( Id2ff2 , b/277434271 )
সংস্করণ ১.৭.০
March 22, 2023
androidx.activity:activity:1.7.0 , androidx.activity:activity-compose:1.7.0 , and androidx.activity:activity-ktx:1.7.0 are released. Version 1.7.0 contains these commits.
Important changes since 1.6.0
- The Photo Picker activity contracts in
PickVisualMediaandPickMultipleVisualMediahave been updated to contain an additional fallback for whenMediaStore.ACTION_PICK_IMAGESis unavailable that allows OEMs and system apps, such as Google Play services, to provide a consistent Photo Picker experience on a wider range of Android devices and API levels by implementing the fallback action . The Photo Picker will use this fallback if it is available before falling back to usingIntent.ACTION_OPEN_DOCUMENT, which remains to support all API 19 and higher devices. -
ComponentDialognow implementsSavedStateRegistryOwnerand has access to its ownSavedStateRegistryand sets theSavedStateRegistryOwnerfor itsViewTree. It is now possible to use Jetpack Compose within aComponentDialogas it meets both theLifecycleOwnerandSavedStateRegistryOwnerattached to the Window via theViewTreeAPIs requirements. -
IntentSenderRequest.Builder.setFlags()now allows you to set multiple flags fromIntent, rather than only a single flag.
Kotlin Conversion
A number of Activity classes have been converted to Kotlin. All converted classes still retain their binary compatibility with previous versions. The following classes have source incompatible changes for classes written in Kotlin: ActivityResultRegistryOwner , OnBackPressedDispatcherOwner .
The table below provides the source conversions for the new version of Activity:
| Activity 1.5 | Activity 1.6 |
|---|---|
override fun getActivityResultRegistry() = activityResultRegistry | override val activityResultRegistry = activityResultRegistry |
override fun getOnBackPressedDispatcher() = onBackPressedDispatcher | override val onBackPressedDispatcher = onBackPressedDispatcher |
These classes were also converted to Kotlin, but remain source compatible: ContextAware , ContextAwareHelper , OnContextAvailableListener , IntentSenderRequest , and OnBackPressedDispatcher
FullyDrawnReporter APIs
ComponentActivity now provides a FullyDrawnReporter instance that allows multiple components to report when they are ready for interaction. ComponentActivity will wait for all components to complete before calling reportFullyDrawn() on your behalf. These APIs take care of the timing requirements for you and do not need to be called as part of an onDraw call.
These APIs are encouraged to enable:
- Signaling the Android Runtime when startup completes, to ensure all of the code run during a multi-frame startup sequence is included and prioritized for background compilation.
- Signaling Macrobenchmark and Play Vitals when your application should be considered fully drawn for startup metrics, so you can track performance.
Three Activity Compose APIs have been added to make it more convenient to use the FullyDrawnReporter from individual composables:
-
ReportDrawnindicates that your composable is immediately ready for interaction. -
ReportDrawnWhentakes a predicate (ie,list.count > 0) to indicate when your composable is ready for interaction. -
ReportDrawnAftertakes a suspending method that, when it completes, indicates that you are ready for interaction.
Dependency Updates
- Activity now depends on Lifecycle
2.6.1. ( 8fc31d ) - Activity now depends on ProfileInstaller
1.3.0. ( 83d3b1 )
Version 1.7.0-rc01
৮ মার্চ, ২০২৩
androidx.activity:activity:1.7.0-rc01 , androidx.activity:activity-compose:1.7.0-rc01 , and androidx.activity:activity-ktx:1.7.0-rc01 are released. Version 1.7.0-rc01 contains these commits.
Dependency update
- Activity now depends on
Lifecycle 2.6.0.
Version 1.7.0-beta02
February 22, 2023
androidx.activity:activity:1.7.0-beta02 , androidx.activity:activity-compose:1.7.0-beta02 , and androidx.activity:activity-ktx:1.7.0-beta02 are released. Version 1.7.0-beta02 contains these commits.
API Changes
- The action and extra used by the
PickVisualMediaandPickMultipleVisualMediacontracts as a fallback for whenMediaStore.ACTION_PICK_IMAGESis unavailable are now public constants that provide API stability to OEMs and system apps that want to provide a consistent Photo Picker experience. The implementation of this fallback is still limited to only system apps. ( Icd320 )
Version 1.7.0-beta01
৮ ফেব্রুয়ারী, ২০২৩
androidx.activity:activity:1.7.0-beta01 , androidx.activity:activity-compose:1.7.0-beta01 , and androidx.activity:activity-ktx:1.7.0-beta01 are released. Version 1.7.0-beta01 contains these commits.
নতুন বৈশিষ্ট্য
-
IntentSenderRequest.Builder.setFlags()now allows you to set multiple flags fromIntent, rather than only a single flag. ( Iac04c )
বাগ সংশোধন
- The fallback for
PickVisualMediafor when the framework Photo Picker is unavailable now correctly limits the handling to apps installed in the device's system image. ( If8ae6 )
Kotlin Conversions
-
ActivityResultRegistryOwneris now written in Kotlin. This is a source incompatible change for those classes written in Kotlin - you must now override theactivityResultRegistryproperty rather than implementing the previousgetActivityResultRegistry()function. ( I0b00e ) -
OnBackPressedDispatcherOwneris now written in Kotlin. This is a source incompatible change for those classes written in Kotlin - you must now override theonBackPressedDispatcherproperty rather than implementing the previousgetOnBackPressedDispatcherfunction. ( Ia277d ) -
ContextAware,ContextAwareHelper,OnContextAvailableListener,IntentSenderRequestandOnBackPressedDispatcherare now written in Kotlin. ( I1a73e , Iada92 , aosp/2410754 , I18ac7 , b/257291701 )
Version 1.7.0-alpha04
২৫ জানুয়ারী, ২০২৩
androidx.activity:activity:1.7.0-alpha04 , androidx.activity:activity-compose:1.7.0-alpha04 , and androidx.activity:activity-ktx:1.7.0-alpha04 are released. Version 1.7.0-alpha04 contains these commits.
নতুন বৈশিষ্ট্য
- The
PickVisualMediaandPickMultipleVisualMediaActivity Result contracts will now use a Google Play services provided Photo Picker where available in cases where the Android system provided Photo Picker (eg,MediaStore.ACTION_PICK_IMAGES) is not available. TheisPhotoPickerAvailable()API that only detects the Android system provided Photo Picker has been deprecated. It is recommended to use the newisPhotoPickerAvailable(Context)API, which will return if either Photo Picker is available. ( I55be6 )
Version 1.7.0-alpha03
১১ জানুয়ারী, ২০২৩
androidx.activity:activity:1.7.0-alpha03 , androidx.activity:activity-compose:1.7.0-alpha03 , and androidx.activity:activity-ktx:1.7.0-alpha03 are released. Version 1.7.0-alpha03 contains these commits.
নতুন বৈশিষ্ট্য
-
ComponentDialognow implementsSavedStateRegistryOwnerand has access to its ownSavedStateRegistryand sets theSavedStateRegistryOwnerfor its ViewTree. It is now possible to use Jetpack Compose within aComponentDialogas it meets both theLifecycleOwnerandSavedStateRegistryOwnerattached to the Window via the ViewTree APIs requirements. ( Idca17 , I73468 b/261162296 )
API Changes
- Added a
ReportDrawncomposable that immediately marks the activity as ready to callreportFullyDrawn. ( Ic5b14 , b/259687964 )
Kotlin Conversions
- The
ActvitiyResultCallbackandOnBackPressedCallbackclasses have both been converted to Kotlin while maintaining source and binary compatibility. ( Ifc5e5 , Ide1b0 , b/257291701 )
Version 1.7.0-alpha02
২৪ অক্টোবর, ২০২২
androidx.activity:activity:1.7.0-alpha02 , androidx.activity:activity-compose:1.7.0-alpha02 , and androidx.activity:activity-ktx:1.7.0-alpha02 are released. Version 1.7.0-alpha02 contains these commits.
বাগ সংশোধন
- From Activity
1.6.1: Fixed an issue with thePickMultipleVisualMediaActivity Result contract not launching on Android R devices when using the default value formaxItems. ( Ie2776 , b/249182130 )
Version 1.7.0-alpha01
৫ অক্টোবর, ২০২২
androidx.activity:activity:1.7.0-alpha01 , androidx.activity:activity-compose:1.7.0-alpha01 , and androidx.activity:activity-ktx:1.7.0-alpha01 are released. Version 1.7.0-alpha01 contains these commits.
FullyDrawnReporter APIs
ComponentActivity now provides a FullyDrawnReporter instance that allows multiple components to report when they are ready for interaction. ComponentActivity will wait for all components to complete before calling reportFullyDrawn() on your behalf. These APIs take care of the timing requirements for you and do not need to be called as part of an onDraw call.
These APIs are encouraged to enable:
- Signaling the Android Runtime when startup completes, to ensure all of the code run during a multi-frame startup sequence is included and prioritized for background compilation.
- Signaling Macrobenchmark and Play Vitals when your application should be considered fully drawn for startup metrics, so you can track performance.
Two Activity Compose APIs have been added to make it more convenient to use the FullyDrawnReporter from individual composables:
-
ReportDrawnWhentakes a predicate (ie,list.count > 0) to indicate when your composable is ready for interaction. -
ReportDrawnAftertakes a suspending method that, when it completes, indicates that you are ready for interaction.
Version 1.6.1
Version 1.6.1
২৪ অক্টোবর, ২০২২
androidx.activity:activity:1.6.1 , androidx.activity:activity-compose:1.6.1 , and androidx.activity:activity-ktx:1.6.1 are released. Version 1.6.1 contains these commits.
বাগ সংশোধন
- Fixed an issue with the
PickMultipleVisualMediaActivity Result contract not launching on Android R devices when using the default value formaxItems. ( Ie2776 , b/249182130 )
সংস্করণ ১.৬.০
সংস্করণ ১.৬.০
September 21, 2022
androidx.activity:activity:1.6.0 , androidx.activity:activity-compose:1.6.0 , and androidx.activity:activity-ktx:1.6.0 are released. Version 1.6.0 contains these commits.
Important changes since 1.5.0
- Added
ActivityResultContracts.PickVisualMediaandActivityResultContracts.PickMultipleVisualMediafor providing a backward compatible contract that usesMediaStore.ACTION_PICK_IMAGESwhen the Photo Picker is available andIntent.ACTION_OPEN_DOCUMENTwhen it is not available. - Integrated the
OnBackInvokedCallbackin Android 13 into theOnBackPressedDispatchersprovided byComponentActivityandComponentDialog. This ensures that all APIs built onOnBackPressedDispatcherwork when enabling a predictive back gesture .
Version 1.6.0-rc02
৭ সেপ্টেম্বর, ২০২২
androidx.activity:activity:1.6.0-rc02 , androidx.activity:activity-compose:1.6.0-rc02 , and androidx.activity:activity-ktx:1.6.0-rc02 are released. Version 1.6.0-rc02 contains these commits.
বাগ সংশোধন
-
OnBackPressedDispatchernow registers theOnBackInvokedCallbackwith thePRIORITY_DEFAULTinstead ofPRIORITY_OVERLAY. ( I3901f ) - Classes that extend
ComponentActivitywill now always have both of theironMultiWindowModeChanged()callbacks dispatched. ( Ic4d85 ) - The
ActivityResultRegistrywill no longer return a result to theActivityResultCallbackwhen thelaunchcall throws anyExceptionand the callback was registered without aLifecycleOwner. ( Ia7ff7 , b/238350794 ) -
ComponentActivitywill now properly dispatch menu calls without the need to call the super function in your activity. ( Ie33c5 , b/238057118 )
Dependency Update
- The
Activitylibrary now depends on Lifecycle2.5.1. ( If6697 )
Version 1.6.0-rc01
August 24, 2022
androidx.activity:activity:1.6.0-rc01 , androidx.activity:activity-compose:1.6.0-rc01 , and androidx.activity:activity-ktx:1.6.0-rc01 are released. Version 1.6.0-rc01 contains these commits.
বাগ সংশোধন
- Initializing an
OnBackPressedDispatcherwill no longer causeClassVerificationErrors when using SDK versions prior to 33. ( Ic32e1 ) - Classes that override
ComponentActivity'sonPictureInPictureModeChanged()callback will now always have their callbacks dispatched. ( Ib7fdb )
Version 1.6.0-beta01
১০ আগস্ট, ২০২২
androidx.activity:activity:1.6.0-beta01 , androidx.activity:activity-compose:1.6.0-beta01 , and androidx.activity:activity-ktx:1.6.0-beta01 are released. Version 1.6.0-beta01 contains these commits.
API Changes
- Marked the deprecated
startActivityForResultandstartIntentSenderForResultmethods onComponentActivitywith@NonNullbecause passingnullhas always resulted in a crash. ( Id2a25 , b/231476082 )
বাগ সংশোধন
- From Activity
1.5.1: TheActivityResultRegistrywill no longer return a result to theActivityResultCallbackwhen thelaunchcall throws anyExceptionand the callback was registered without aLifecycleOwner. ( Ia7ff7 , b/238350794 ) - From Activity
1.5.1:ComponentActivitywill now properly dispatch menu calls toonPrepareOptionMenu(),onCreateOptionsMenu()andonOptionsItemSelected()overrides without the need to call the super function. ( Ie33c5 , b/238057118 )
Dependency Update
- From Activity
1.5.1: TheActivitylibrary now depends on theLifecycleversion2.5.1. ( If6697 )
Version 1.6.0-alpha05
১৫ জুন, ২০২২
androidx.activity:activity:1.6.0-alpha05 , androidx.activity:activity-compose:1.6.0-alpha05 , and androidx.activity:activity-ktx:1.6.0-alpha05 are released. Version 1.6.0-alpha05 was developed in a private pre-release branch and has no public commits.
API Changes
-
minCompileSdkis now 33 to align with Tiramisu Beta 3 SDK
বাগ সংশোধন
- Fixed crash on older devices when doing SDK extension check for the
PickVisualMediaActivityResultContractso that it should now work withACTION_OPEN_DOCUMENTon devices running Android 10 and lower.
Version 1.6.0-alpha04
১৮ মে, ২০২২
androidx.activity:activity:1.6.0-alpha04 and androidx.activity:activity-ktx:1.6.0-alpha04 are released.
বাগ সংশোধন
- Fixed an error in
PickVisualMediaRequestwhere attempting to create a request, either via the Builder or the top level Kotlin function, would result in a stack overflow. - Integrated the
OnBackInvokedCallbackin Android 13 Dev Beta 2 into theOnBackPressedDispatcherprovided byComponentDialog. This ensures that all APIs built onOnBackPressedDispatcherwork when enabling a predictive back gesture .
Version 1.6.0-alpha03
April 27, 2022
androidx.activity:activity:1.6.0-alpha03 , androidx.activity:activity-compose:1.6.0-alpha03 , and androidx.activity:activity-ktx:1.6.0-alpha03 are released.
- Note: This version will only compile against the Android 13 Developer Beta 1 SDK.
নতুন বৈশিষ্ট্য
- Added
ActivityResultContracts.PickVisualMediaandActivityResultContracts.PickMultipleVisualMediafor providing a backward compatible contract that usesMediaStore.ACTION_PICK_IMAGESwhen the Photo Picker is available andIntent.ACTION_OPEN_DOCUMENTwhen it is not available. - Integrated the
OnBackInvokedCallbackin Android 13 Dev Beta 1 into theOnBackPressedDispatcherprovided byComponentActivity. This ensures that all APIs built onOnBackPressedDispatcherwork when enabling a predictive back gesture .
Version 1.6.0-alpha01
March 23, 2022
androidx.activity:activity:1.6.0-alpha01 , androidx.activity:activity-compose:1.6.0-alpha01 , and androidx.activity:activity-ktx:1.6.0-alpha01 are released.
- Note: This version will only compile against the Android 13 Developer Preview 2 SDK.
নতুন বৈশিষ্ট্য
- Integrated changes in Android 13 Dev Preview 2 into
ComponentActivity.
সংস্করণ ১.৫.১
সংস্করণ ১.৫.১
২৭ জুলাই, ২০২২
androidx.activity:activity:1.5.1 , androidx.activity:activity-compose:1.5.1 , and androidx.activity:activity-ktx:1.5.1 are released. Version 1.5.1 contains these commits.
বাগ সংশোধন
The
ActivityResultRegistrywill no longer return a result to theActivityResultCallbackwhen thelaunch()call throws anyExceptionand the callback was registered without aLifecycleOwner. ( Ia7ff7 , b/238350794 )ComponentActivitywill now properly dispatch menu calls toonPrepareOptionMenu(),onCreateOptionsMenu()andonOptionsItemSelected()overrides without the need to call the super function. ( Ie33c5 , b/238057118 )
Dependency update
- The
Activitylibrary now depends on the Lifecycle2.5.1. ( If6697 )
সংস্করণ ১.৫.০
সংস্করণ ১.৫.০
২৯ জুন, ২০২২
androidx.activity:activity:1.5.0 , androidx.activity:activity-compose:1.5.0 , and androidx.activity:activity-ktx:1.5.0 are released. Version 1.5.0 contains these commits.
Important changes since 1.4.0
- ComponentDialog -
ComponentDialogis a subclass ofDialogthat includes anOnBackPressedDispatcherthat will be called when the system back button is pressed and the dialog is visible. Importantly, this subclass also sets theViewTreeOnBackPressedDispatcherOwner, allowing views a generic way to retrieve the correct dispatcher whether it exists in aComponentActivityor aComponentDialog. - Callback Interfaces -
ComponentActivitynow implements a set of modular callback interfaces that can be used instead of theActivitycallbacks. These interfaces include the following:OnNewIntentProvider,OnConfigurationChangedProvider,OnTrimMemoryProvider,OnPictureInPictureModeChangedProvider,OnMultiWindowModeChangedProvider - CreationExtras Integration -
ComponentActivitynow has the ability to provide a statelessViewModelProvider.Factoryvia Lifecycle2.5.0'sCreationExtras.
অন্যান্য পরিবর্তন
- The no parameter constructor for
ActivityResultContracts.CreateDocumenthas been deprecated and replaced with a new constructor that takes a concrete mime type (eg, "image/png") as is required byIntent.ACTION_CREATE_DOCUMENT.
Version 1.5.0-rc01
May 11, 2022
androidx.activity:activity:1.5.0-rc01 , androidx.activity:activity-compose:1.5.0-rc01 , and androidx.activity:activity-ktx:1.5.0-rc01 are released with no changes from 1.5.0-beta01. Version 1.5.0-rc01 contains these commits.
Version 1.5.0-beta01
২০ এপ্রিল, ২০২২
androidx.activity:activity:1.5.0-beta01 , androidx.activity:activity-compose:1.5.0-beta01 , and androidx.activity:activity-ktx:1.5.0-beta01 are released. Version 1.5.0-beta01 contains these commits.
Dependency updates
- Activity now depends on Lifecycle
2.4.0-beta01.
Version 1.5.0-alpha05
৬ এপ্রিল, ২০২২
androidx.activity:activity:1.5.0-alpha05 , androidx.activity:activity-compose:1.5.0-alpha05 , and androidx.activity:activity-ktx:1.5.0-alpha05 are released. Version 1.5.0-alpha05 contains these commits.
বাগ সংশোধন
-
ComponentActivity'sonPanelClosed()now calls the superonPanelClosed()as well, fixing an issue where theonContextMenuClosedmethod would not be called. ( Ib6f77 )
Version 1.5.0-alpha04
March 23, 2022
androidx.activity:activity:1.5.0-alpha04 , androidx.activity:activity-compose:1.5.0-alpha04 , and androidx.activity:activity-ktx:1.5.0-alpha04 are released. Version 1.5.0-alpha04 contains these commits.
বাগ সংশোধন
-
SavedStateViewFactorynow supports usingCreationExtraseven when it was initialized with aSavedStateRegistryOwner. If extras are provided, the initialized arguments are ignored. ( I6c43b , b/224844583 )
Version 1.5.0-alpha03
February 23, 2022
androidx.activity:activity:1.5.0-alpha03 , androidx.activity:activity-compose:1.5.0-alpha03 , and androidx.activity:activity-ktx:1.5.0-alpha03 are released. Version 1.5.0-alpha03 contains these commits.
API Changes
- You can now pass
CreationExtrasto the activityby viewModels()function ( I6a3e6 , b/217600303 )
Version 1.5.0-alpha02
৯ ফেব্রুয়ারী, ২০২২
androidx.activity:activity:1.5.0-alpha02 , androidx.activity:activity-compose:1.5.0-alpha02 , and androidx.activity:activity-ktx:1.5.0-alpha02 are released. Version 1.5.0-alpha02 contains these commits.
নতুন বৈশিষ্ট্য
-
ComponentActivitynow implements theOnPictureInPictureModeChangedProviderinterface to allow any component to receive picture-in-picture mode change events. ( I9f567 ) -
ComponentActivitynow implements theOnMultiWindowModeChangedProviderinterface to allow any component to receive multi-window mode change events. ( I62d91 )
Version 1.5.0-alpha01
২৬ জানুয়ারী, ২০২২
androidx.activity:activity:1.5.0-alpha01 , androidx.activity:activity-compose:1.5.0-alpha01 , and androidx.activity:activity-ktx:1.5.0-alpha01 are released. Version 1.5.0-alpha01 contains these commits.
নতুন বৈশিষ্ট্য
-
ComponentActivitynow integrates with ViewModel CreationExtras, introduced as part of Lifecycle2.5.0-alpha01. ( Ie7e00 , b/207012584 ) - Added
ComponentDialog, a subclass ofDialogthat includes anOnBackPressedDispatcherthat will be called when the system back button is pressed when the dialog is visible. Importantly, this subclass also sets theViewTreeOnBackPressedDispatcherOwner, allowing views a generic way to retrieve the correct dispatcher whether it exists in aComponentActivityor aComponentDialog. ( I8a1bc ) -
ComponentActivitynow implements the newOnNewIntentProviderinterface to allow any component to receive these events. ( If1f8b ) -
ComponentActivitynow implements the newOnConfigurationChangedProviderinterface to allow any component to receive these events. ( If623b ) -
ComponentActivitynow implements the newOnTrimMemoryProviderinterface to allow any component to receive these events. ( Ia9295 )
API Changes
- The no parameter constructor for
ActivityResultContracts.CreateDocumenthas been deprecated and replaced with a new constructor that takes a concrete mime type (eg,"image/png") as is required byIntent.ACTION_CREATE_DOCUMENT. ( I2bec6 ) - The
OnBackPressedDispatcherOwnerassociated with a View can now be retrieved via theViewTreeOnBackPressedDispatcherOwner, rather than relying on casting theContext. ( I74685 )
বাগ সংশোধন
- Fixed a crash when accessing a
ViewModelfor the very first time from aregisterForActivityResult()callback or the callbacks to aLifecycleObserveradded as part ofinitof aComponentActivity. ( Ife83f )
Version 1.4.0
Version 1.4.0
October 27, 2021
androidx.activity:activity:1.4.0 , androidx.activity:activity-compose:1.4.0 , and androidx.activity:activity-ktx:1.4.0 are released. Version 1.4.0 contains these commits.
Important changes since 1.3.0
- AndroidX
ComponentActivitynow implements theMenuHostinterface. This allows any component to add menu items to theActionBarby adding aMenuProviderinstance to the activity. EachMenuProvidercan optionally be added with aLifecyclethat will automatically control the visibility of those menu items based on theLifecyclestate and handle the removal of theMenuProviderwhen theLifecycleis destroyed. - The
ActivityResultContractclass has been rewritten in Kotlin to ensure that developers writing custom contracts in Kotlin can define the correct nullability for their input and output classes. - The
ActivityResultContractsclass and its contracts have been rewritten in Kotlin to ensure the proper nullability.
Version 1.4.0-rc01
১৩ অক্টোবর, ২০২১
androidx.activity:activity:1.4.0-rc01 , androidx.activity:activity-compose:1.4.0-rc01 , and androidx.activity:activity-ktx:1.4.0-rc01 are released. Version 1.4.0-rc01 contains these commits.
বাগ সংশোধন
- The
ActivityResultRegistrywill no longer return a result to theActivityResultCallbackwhen thelaunchcall throws anyException. ( If4f91 , b/200845664 )
Version 1.4.0-beta01
September 29, 2021
androidx.activity:activity:1.4.0-beta01 , androidx.activity:activity-compose:1.4.0-beta01 , and androidx.activity:activity-ktx:1.4.0-beta01 are released. Version 1.4.0-beta01 contains these commits.
API Changes
- Fixed the type for the
ActivityResultContracts.OpenMultipleDocumentsandActivityResultContracts.GetMultipleContentsthat caused then to use an output type ofList<? extends Uri>when using the code from the Java programming language. ( If71de ) - Public constants within the
ActivityResultContracts.StartActivityForResult,ActivityResultContracts.StartIntentSenderForResult, andActivityResultContracts.RequestMultiplePermissionsclasses are now accessible when using Kotlin via their now publicCompanionobjects. ( aosp/1832555 )
Documentation Updates
- The deprecation message for APIs now handled by the Activity Result APIs , namely
startActivityForResult,startIntentSenderForResult,onActivityResult,requestPermissions, andonRequestPermissionsResult, have all been expanded with more details. ( cce80f )
Version 1.4.0-alpha02
১৫ সেপ্টেম্বর, ২০২১
androidx.activity:activity:1.4.0-alpha02 , androidx.activity:activity-compose:1.4.0-alpha02 , and androidx.activity:activity-ktx:1.4.0-alpha02 are released. Version 1.4.0-alpha02 contains these commits.
নতুন বৈশিষ্ট্য
- The
activity-composeartifact now contains aLaunchDuringCompositionlint error that prevents you from calling thelaunchmethod ofActivityResultLauncheras part of composition as composition should be side-effect free. Use the APIs for handling side-effects . ( 7c2bbe , b/191347220 )
API Changes
- The
ActivityResultContractclass has been rewritten in Kotlin to ensure that developers writing custom contracts in Kotlin can define the correct nullability for their input and output classes. ( I8a8f5 ) - The
ActivityResultContractsclass and its contracts have been rewritten in Kotlin to ensure the proper nullability. ( I69802 )
Version 1.4.0-alpha01
September 1, 2021
androidx.activity:activity:1.4.0-alpha01 , androidx.activity:activity-compose:1.4.0-alpha01 , and androidx.activity:activity-ktx:1.4.0-alpha01 are released. Version 1.4.0-alpha01 contains these commits.
নতুন বৈশিষ্ট্য
- AndroidX
ComponentActivitynow implements theMenuHostinterface.. This allows any component to add menu items to theActionBarby adding aMenuProviderinstance to the activity. EachMenuProvidercan optionally be added with aLifecyclethat will automatically control the visibility of those menu items based on theLifecyclestate and handle the removal of theMenuProviderwhen theLifecycleis destroyed. ( I3b608 ):
/**
* Using the addMenuProvider() API directly in your Activity
**/
class ExampleActivity : ComponentActivity(R.layout.activity_example) {
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
// Add menu items without overriding methods in the Activity
addMenuProvider(object : MenuProvider {
override fun onCreateMenu(menu: Menu, menuInflater: MenuInflater) {
// Add menu items here
menuInflater.inflate(R.menu.example_menu, menu)
}
override fun onMenuItemSelected(menuItem: MenuItem): Boolean {
// Handle the menu selection
return true
}
})
}
}
/**
* Using the addMenuProvider() API in a Fragment
**/
class ExampleFragment : Fragment(R.layout.fragment_example) {
override fun onViewCreated(view: View, savedInstanceState: Bundle?) {
// The usage of an interface lets you inject your own implementation
val menuHost: MenuHost = requireActivity()
// Add menu items without using the Fragment Menu APIs
// Note how we can tie the MenuProvider to the viewLifecycleOwner
// and an optional Lifecycle.State (here, RESUMED) to indicate when
// the menu should be visible
menuHost.addMenuProvider(object : MenuProvider {
override fun onCreateMenu(menu: Menu, menuInflater: MenuInflater) {
// Add menu items here
menuInflater.inflate(R.menu.example_menu, menu)
}
override fun onMenuItemSelected(menuItem: MenuItem): Boolean {
// Handle the menu selection
return true
}
}, viewLifecycleOwner, Lifecycle.State.RESUMED)
}
Behavior Changes
- The
ActivityResultRegistrywill now throw anIllegalStateExceptionwhen attempting to calllaunch()on anActivityResultLauncherthat has not be registered or that has been unregistered. ( Ida75d , b/192567522 )
External Contribution
সংস্করণ ১.৩.১
সংস্করণ ১.৩.১
৪ আগস্ট, ২০২১
androidx.activity:activity:1.3.1 , androidx.activity:activity-compose:1.3.1 , and androidx.activity:activity-ktx:1.3.1 are released. Version 1.3.1 contains these commits.
Dependency updates
- Activity now depends on Kotlin
1.5.21. - Activity Compose now depends on Compose
1.0.1.
সংস্করণ ১.৩.০
সংস্করণ ১.৩.০
২৮ জুলাই, ২০২১
androidx.activity:activity:1.3.0 , androidx.activity:activity-compose:1.3.0 , and androidx.activity:activity-ktx:1.3.0 are released. Version 1.3.0 contains these commits.
Important changes since 1.2.0
- Activity Compose artifact - The
activity-composeartifact provides thesetContentextension method for hosting your Jetpack Compose UI in an activity and Compose specific wrappers for interacting with theComponentActivityAPIs for handling the system back button and the Activity Result APIs. See the documentation for more details. - CaptureVideo contract - The
CaptureVideoActivityResultContractreplaces the now deprecatedTakeVideocontract and returns a boolean denoting success that works across many camera apps. - Picture-In-Picture Hint View Tracking - Users of
activity-ktxcan now use thetrackPipAnimationHintViewextension method onActivityto automatically rebuild thePictureInPictureParamswith the new position of the view as it changes position relative to the window.
Version 1.3.0-rc02
১৪ জুলাই, ২০২১
androidx.activity:activity:1.3.0-rc02 , androidx.activity:activity-compose:1.3.0-rc02 , and androidx.activity:activity-ktx:1.3.0-rc02 are released. Version 1.3.0-rc02 contains these commits.
বাগ সংশোধন
- The
ActivityResultRegistrycallbacks are now properly saved and restored so callbacks are not duplicated in the savedState. ( I97816 , b/191893160 )
Version 1.3.0-rc01
১ জুলাই, ২০২১
androidx.activity:activity:1.3.0-rc01 , androidx.activity:activity-compose:1.3.0-rc01 , and androidx.activity:activity-ktx:1.3.0-rc01 are released with no changes from 1.3.0-beta02 . Version 1.3.0-rc01 contains these commits.
Version 1.3.0-beta02
১৬ জুন, ২০২১
androidx.activity:activity:1.3.0-beta02 , androidx.activity:activity-compose:1.3.0-beta02 , and androidx.activity:activity-ktx:1.3.0-beta02 are released. Version 1.3.0-beta02 contains these commits.
Updated activity-compose to depend on Compose 1.0.0-beta09 . androidx.compose.ui:ui-test-junit4 now has a compile time dependency on activity-compose .
Version 1.3.0-beta01
June 2, 2021
androidx.activity:activity:1.3.0-beta01 , androidx.activity:activity-compose:1.3.0-beta01 , and androidx.activity:activity-ktx:1.3.0-beta01 are released. Version 1.3.0-beta01 contains these commits.
API Changes
- The previously deprecated
@Composable registerForActivityResult()method has been removed. Please userememberLauncherForActivityResult(). ( Ic39d3 )
Version 1.3.0-alpha08
১৮ মে, ২০২১
androidx.activity:activity:1.3.0-alpha08 , androidx.activity:activity-compose:1.3.0-alpha08 , and androidx.activity:activity-ktx:1.3.0-alpha08 are released. Version 1.3.0-alpha08 contains these commits.
নতুন বৈশিষ্ট্য
- The new
CaptureVideoActivityResultContractreturns a boolean to yourActivityResultCallbackindicating if your video was successfully saved to the given URI. This replaces the now deprecatedTakeVideocontract as camera apps very rarely supported returning a thumbnail bitmap, making the result unhelpful. ( Ie21f2 , b/185938070 ) - Added new API
Activity#setPipAnimationHintViewto update the PipParams' source rect hint whenever the view moves. ( I9063d )
API Changes
- The
rememberLauncherForActivityResultfunction now returns a launcher that deprecates theunregister()function - registration and unregistering the launcher is handled automatically byrememberLauncherForActivityResult. ( I2443e )
Compose Compatibility
-
androidx.activity:activity-compose:1.3.0-alpha08is only compatible with Compose version1.0.0-beta07and above.
Version 1.3.0-alpha07
April 21, 2021
androidx.activity:activity:1.3.0-alpha07 , androidx.activity:activity-compose:1.3.0-alpha07 , and androidx.activity:activity-ktx:1.3.0-alpha07 are released. Version 1.3.0-alpha07 contains these commits.
বাগ সংশোধন
-
rememberLauncherForActivityResultnow returns a stable reference to the sameActivityResultLauncherinstance even if the contract changes due to recompositions. ( Id2d6d ) - Using unstable versions of Fragments above
1.3.0will no longer throw a false positive lint error telling you to use1.3.0. ( aosp/1670206 , b/184847092 )
Version 1.3.0-alpha06
৭ এপ্রিল, ২০২১
androidx.activity:activity:1.3.0-alpha06 , androidx.activity:activity-compose:1.3.0-alpha06 , and androidx.activity:activity-ktx:1.3.0-alpha06 are released. Version 1.3.0-alpha06 contains these commits.
API Changes
- The
registerForActivityResult()API has been renamed torememberLauncherForActivityResult()to better indicate that the returnedActivityResultLauncheris a managed object that is remembered on your behalf. Attempting to callunregisterthe returnedActivityResultLauncherwill now throw an error. ( I2bb6d ) -
LocalOnBackPressedDispatcherOwner.currentandLocalActivityResultRegistryOwner.currentnow return a nullable value to better determine whether it is available in the current composition. APIs that requires those APIs, such asBackHandlerandrememberLauncherForActivityResult(), respectively, will now throw a more descriptive error if the underlying owner is not found.NavHostnow works even when anOnBackPressedDispatcherOwneris not found, such is the case when previewing theNavHost. ( I7d8b4 )
বাগ সংশোধন
- The
BackHandlerwill now properly intercept back presses in the event that the Activity isSTOPPED, thenSTARTEDagain, and other callbacks were added with a LifecycleOwner. ( I71de6 , b/182284739 ) - Using the
launch()method extension with a customActivityResultContractthat has aUnitinput will no longer cause aNullPointerException( I76282 , b/183837954 )
Version 1.3.0-alpha05
March 24, 2021
androidx.activity:activity:1.3.0-alpha05 , androidx.activity:activity-compose:1.3.0-alpha05 , and androidx.activity:activity-ktx:1.3.0-alpha05 are released. Version 1.3.0-alpha05 contains these commits.
বাগ সংশোধন
- From Activity 1.2.2 : Fixed an issue in the
InvalidFragmentVersionForActivityResultlint check that led to a false positive when using Fragment 1.3.1 or higher. ( I54da1 , b/182388985 ) - From Activity 1.2.2 :
ComponentActivitynow avoids aClassNotFoundExceptionwhen launching anIntentfrom anActivityResultContractthat was previously held as an extra in anotherIntent. ( Ieff05 , b/182906230 )
Dependency Updates
- From Activity 1.2.2 : Activity now depends on Lifecycle
2.3.1.
Version 1.3.0-alpha04
১০ মার্চ, ২০২১
androidx.activity:activity:1.3.0-alpha04 , androidx.activity:activity-compose:1.3.0-alpha04 , and androidx.activity:activity-ktx:1.3.0-alpha04 are released. Version 1.3.0-alpha04 contains these commits.
বাগ সংশোধন
- From Activity
1.2.1:RequestMultiplePermissionsnow always returns results for all requested permissions instead of only permissions that weren't previously granted. ( I50bc3 , b/180884668 ) - From Activity
1.2.1:ActivityResultRegistrynow ensures that in progresslaunch()requests will return their results even if youunregister(), thenregister()again with the same key. ( I9ef34 , b/181267562 ) - Activity Compose no longer adds test dependencies to the runtime classpath. ( Ifd8b3 )
- Fixed an issue with
BackHandlerwhere the previously setonBacklambda was still being used after recomposition. ( 8eb5eb )
Version 1.3.0-alpha03
February 24, 2021
androidx.activity:activity:1.3.0-alpha03 , androidx.activity:activity-compose:1.3.0-alpha03 , and androidx.activity:activity-ktx:1.3.0-alpha03 are released. Version 1.3.0-alpha03 contains these commits.
নতুন বৈশিষ্ট্য
- There is a now a Composable
registerForActivityResultfunction for getting results from activities within composables. ( Ia7851 , b/172690553 )
API Changes
-
LocalOnBackPressedDispatcherOwnernow has aprovidesfunctions that can be used withCompositionLocalProvider, replacing theasProvidableCompositionLocal()API. ( I45d24 )
Version 1.3.0-alpha02
১০ ফেব্রুয়ারী, ২০২১
androidx.activity:activity:1.3.0-alpha02 , androidx.activity:activity-compose:1.3.0-alpha02 , and androidx.activity:activity-ktx:1.3.0-alpha02 are released. Version 1.3.0-alpha02 contains these commits.
বাগ সংশোধন
- Fixed an issue in Activity Compose
1.3.0-alpha01that causes aNoSuchMethodError: No static method setContentexception when using Compose1.0.0-alpha12. All Compose users should depend on1.3.0-alpha02and above. ( b/179911234 )
API Changes
- The
BackHandlerAPI can be used to allow a Composable to intercept the system back button. ( I58ed5 , b/172154006 )
Version 1.3.0-alpha01
১০ ফেব্রুয়ারী, ২০২১
androidx.activity:activity:1.3.0-alpha01 , androidx.activity:activity-compose:1.3.0-alpha01 , and androidx.activity:activity-ktx:1.3.0-alpha01 are released. Version 1.3.0-alpha01 contains these commits.
নতুন বৈশিষ্ট্য
- The new
activity-composeartifact provides Jetpack Compose specific helpers forandroidx.activityspecific APIs.-
ComponentActivity.setContenthas moved fromandroidx.compose.ui.platform.setContenttoandroidx.activity.compose.setContent. ( Icf416 )
-
পরিচিত সমস্যা
- Using Activity Compose
1.3.0-alpha01and libraries that depend on it, such asandroidx.compose.ui:ui-test-junit4:1.0.0-alpha12, will result in aNoSuchMethodError: No static method setContentexception. ( b/179911234 )
Version 1.2.4
Version 1.2.4
July 21, 2021
androidx.activity:activity:1.2.4 and androidx.activity:activity-ktx:1.2.4 are released. Version 1.2.4 contains these commits.
বাগ সংশোধন
- From Activity
1.3.0-rc02: The ActivityResultRegistry callbacks are now properly saved and restored so callbacks are not duplicated in the savedState. ( I97816 , b/191893160 )
সংস্করণ ১.২.৩
সংস্করণ ১.২.৩
৫ মে, ২০২১
androidx.activity:activity:1.2.3 and androidx.activity:activity-ktx:1.2.3 are released. Version 1.2.3 contains these commits.
বাগ সংশোধন
- Using the
launch()method extension with a customActivityResultContractthat has aUnitinput will no longer cause aNullPointerException( I76282 , b/183837954 ) - Fixed a false positive lint error telling you to use Fragment
1.3.0when using an snapshot, alpha, beta, or RC build of a newer version of Fragments. ( f4a57e , b/184847092 )
সংস্করণ ১.২.২
সংস্করণ ১.২.২
March 24, 2021
androidx.activity:activity:1.2.2 and androidx.activity:activity-ktx:1.2.2 are released. Version 1.2.2 contains these commits.
বাগ সংশোধন
- Fixed an issue in the
InvalidFragmentVersionForActivityResultlint check that led to a false positive when using Fragment 1.3.1 or higher. ( I54da1 , b/182388985 ) -
ComponentActivitynow avoids aClassNotFoundExceptionwhen launching anIntentfrom anActivityResultContractthat was previously held as an extra in anotherIntent. ( Ieff05 , b/182906230 )
Dependency Updates
- Activity now depends on Lifecycle
2.3.1.
সংস্করণ ১.২.১
সংস্করণ ১.২.১
১০ মার্চ, ২০২১
androidx.activity:activity:1.2.1 and androidx.activity:activity-ktx:1.2.1 are released. Version 1.2.1 contains these commits.
বাগ সংশোধন
-
RequestMultiplePermissionsnow always returns results for all requested permissions instead of only permissions that weren't previously granted. ( I50bc3 , b/180884668 ) -
ActivityResultRegistrynow ensures that in progresslaunch()requests will return their results even if youunregister(), thenregister()again with the same key. ( I9ef34 , b/181267562 )
সংস্করণ ১.২.০
সংস্করণ ১.২.০
১০ ফেব্রুয়ারী, ২০২১
androidx.activity:activity:1.2.0 and androidx.activity:activity-ktx:1.2.0 are released. Version 1.2.0 contains these commits.
Major changes since 1.1.0
- Activity Result APIs :
ComponentActivitynow provides anActivityResultRegistrythat lets you handlestartActivityForResult()+onActivityResult()as well asrequestPermissions()+onRequestPermissionsResult()flows without overriding methods in your Activity or Fragment, brings increased type safety viaActivityResultContract, and provides hooks for testing these flows. See the updated Getting a Result from an Activity .
ContextAware:ComponentActivitynow implementsContextAware, allowing you to add one or moreOnContextAvailableListenerinstances which will receive a callback before the baseActivity.onCreate().- A suspending Kotlin extension
withContextAvailable()allows you to run a non-suspending block when the Context becomes available and return a result. - This API is used by
FragmentActivityin Fragment 1.3.0 to restore the state of theFragmentManager. Any listeners added to subclasses ofFragmentActivitywill run after that listener. - This API is used by
AppCompatActivityin AppCompat 1.3.0-alpha02 or higher. Any listeners added to subclasses ofAppCompatActivitywill run after that listener.
- A suspending Kotlin extension
ViewTreeSupport :ComponentActivitynow supports theViewTreeLifecycleOwner.get(View),ViewTreeViewModelStoreOwner.get(View), andViewTreeSavedStateRegistryOwnerAPIs added in Lifecycle2.3.0and SavedState1.1.0such that it will return the Activity as theLifecycleOwner,ViewModelStoreOwner, andSavedStateRegistryOwnerfor any Views directly added to theComponentActivity.
- reportFullyDrawn() backport - The
Activitymethod ofreportFullyDrawn()has been backported inComponentActivityto work on all API levels, fixing a crash on API 19 and adding tracing for this method for all API levels.
Version 1.2.0-rc01
১৬ ডিসেম্বর, ২০২০
androidx.activity:activity:1.2.0-rc01 and androidx.activity:activity-ktx:1.2.0-rc01 are released. Version 1.2.0-rc01 contains these commits.
বাগ সংশোধন
- The
ActivityResultRegistrynow always restores the exact state that was saved. ( Idd56b ) - Add tracing to
ComponentActivity.reportFullyDrawn( Ic7632 )
External Contribution
-
ComponentActivitynow overridesreportFullyDrawn(), allowing it to be called on all API levels and fixing a crash when calling this method without the appropriate system permission on API 19 devices. Thanks Simon Schiller! ( b/163239764 , #103 )
Version 1.2.0-beta02
December 2, 2020
androidx.activity:activity:1.2.0-beta02 and androidx.activity:activity-ktx:1.2.0-beta02 are released. Version 1.2.0-beta02 contains these commits.
বাগ সংশোধন
- Fixed an issue where the Activity Result API would not wait for the Lifecycle to be
STARTEDbefore delivering results when registered with aLifecycle. ( I109ea )
External Contribution
- Updated the documentation for
launch()to explicitly call out that it can throw anActivityNotFoundException. Thanks Michał Zieliński! ( aosp/1493580 )
Version 1.2.0-beta01
১ অক্টোবর, ২০২০
androidx.activity:activity:1.2.0-beta01 and androidx.activity:activity-ktx:1.2.0-beta01 are released. Version 1.2.0-beta01 contains these commits.
বাগ সংশোধন
The
ActivityResultRegistrynow randomly generates integers until it finds one that is unallocated to use as a request coderegister(), thus preventing the possible integer overflow caused by incrementing request codes. ( b/168779518 )Lifecycleobservers are properly removed when callingunregister()on anActivityResultLauncher. ( b/165608393 )
Behavior Changes
- The
ActivityResultRegistrynow throws anIllegalStateExceptionwhen attempting to callregister()with aLifecycleOwnerwhoseLifecyclehas already reachedSTARTED. ( b/165435866 )
Documentation Updated
-
ContextAwaredocumentation links toLifecycleOwnerto highlightLifecyclecallbacks as the appropriate place for creation and destruction events. ( aosp/1414152 )
Version 1.2.0-alpha08
১৯ আগস্ট, ২০২০
androidx.activity:activity:1.2.0-alpha08 and androidx.activity:activity-ktx:1.2.0-alpha08 are released. Version 1.2.0-alpha08 contains these commits.
নতুন বৈশিষ্ট্য
-
ComponentActivitynow implementsContextAware, allowing you to add one or moreOnContextAvailableListenerinstances which will receive a callback before the baseActivity.onCreate(). ( b/161390636 )- A suspending Kotlin extension
withContextAvailable()allows you to run a non-suspending block when the Context becomes available and return a result. ( I8290c ) - This API is used by
FragmentActivityin Fragment 1.3.0-alpha08 to restore the state of theFragmentManager. Any listeners added to subclasses ofFragmentActivitywill run after that listener. ( I513da ) - This API is used by
AppCompatActivityin AppCompat 1.3.0-alpha02 . Any listeners added to subclasses ofAppCompatActivitywill run after that listener. ( I513da )
- A suspending Kotlin extension
বাগ সংশোধন
- Fixed an issue with the
ActivityResultFragmentVersionDetectorLint check that caused it to break when using Lint 27.1.0 or higher. ( b/162155191 )
Version 1.2.0-alpha07
২২ জুলাই, ২০২০
androidx.activity:activity:1.2.0-alpha07 and androidx.activity:activity-ktx:1.2.0-alpha07 are released. Version 1.2.0-alpha07 contains these commits.
নতুন বৈশিষ্ট্য
- Added a new
InvalidFragmentVersionForActivityResultlint check that verifies that you are using Fragment1.3.0-alpha07when using the Activity Result API , avoiding runtime crashes due to “invalid request code” issues and non-functioning permission requests caused by using older versions of Fragments. ( b/152554847 )
External Contribution
- Fixed an
ArrayIndexOutOfBoundsExceptionwhen parsing the results for theRequestPermissionActivity Result contract. ( I8f9e3 , b/161057605 )
Version 1.2.0-alpha06
১০ জুন, ২০২০
androidx.activity:activity:1.2.0-alpha06 and androidx.activity:activity-ktx:1.2.0-alpha06 are released. Version 1.2.0-alpha06 contains these commits.
নতুন বৈশিষ্ট্য
- You can now destructure the
ActivityResultclass in kotlin to directly access therequestCodeandintent. ( b/157212935 ) -
ActivityResultLaunchernow allows you to get theActivityResultContractthat was used to register the launcher. ( b/156875743 )
API Changes
- Breaking change : The
invoke()method onActivityResultRegistryhas been renamed toonLaunch(). ( b/157496491 ) - The
OpenMultipleDocumentscontract now returns an empty list instead ofnullto the registered callback if no result is returned. ( b/157348014 )
Version 1.2.0-alpha05
২০ মে, ২০২০
androidx.activity:activity:1.2.0-alpha05 and androidx.activity:activity-ktx:1.2.0-alpha05 are released. Version 1.2.0-alpha05 contains these commits.
নতুন বৈশিষ্ট্য
- Added support for
ViewTreeViewModelStoreOwnerfrom Lifecycle2.3.0-alpha03, andViewTreeSavedStateRegistryOwnerfrom SavedState1.1.0-alpha01when using aViewwithin aComponentActivity. ( aosp/1297993 , aosp/1300264 )
API Changes
- The
TakePicturecontract now returns abooleanindicating success rather than a thumbnailBitmapas this was very rarely supported by camera apps when writing the image to the providedUri. ( b/154302879 ) - The
invoke()extensions onActivityResultLauncherhave been removed in favor of explicitly usinglaunch()to better indicate that these are asynchronous operations. Kotlin extensions forlaunchhave been added to theandroidx.activity.resultpackage forActivityResultLauncher<Void>andActivityResultLauncher<Unit>that remove the need to pass innullorUnit, respectively, mirroring that behavior from the previouslyinvoke()extensions. ( aosp/1304674 , aosp/1304675 ) - The
IntentSenderRequest.Buildermethods forsetFlagsMask()andsetFlagsValues()has been combined into a singlesetFlags()method. ( aosp/1302111 )
বাগ সংশোধন
- When registering an
ActivityResultCallbackwith aLifecycleOwner, fixed an issue where the callback would be triggered before the state reachesSTARTED. ( aosp/1309744 )
Behavior Changes
- The
ActivityResultRegistrynow generates request codes starting at0xFFFFrather than at0, preventing overlap when usingstartActivityForResult()orrequestPermissions()in an activity. ( aosp/1302324 )
Version 1.2.0-alpha04
April 29, 2020
androidx.activity:activity:1.2.0-alpha04 and androidx.activity:activity-ktx:1.2.0-alpha04 are released. Version 1.2.0-alpha04 contains these commits.
নতুন বৈশিষ্ট্য
- Added a contract that can call startIntentSenderForResult to the ActivityResult APIs. ( b/153007517 )
API Changes
- The
prepareCall()method has been renamed toregisterForActivityResult(), both onComponentActivityhere and in Fragment1.3.0-alpha04. ( aosp/1278717 ) - The
GetContents,OpenDocuments, andRequestPermissionscontracts have been renamed toGetMultipleContents,OpenMultipleDocuments, andRequestMultiplePermissions, respectively. ( aosp/1280161 ) -
ComponentActivitynow implements theActivityResultRegisteryOwnerinterface. ( aosp/1290888 ) - - The
startActivityForResult()/onActivityResult()andonRequestPermissionsResult()APIs onComponentActivityhave been deprecated. Please use the Activity Result APIs . ( b/154751887 )
বাগ সংশোধন
- When using the
GetMultipleContentsandOpenMultipleDocumentscontracts and selecting a single item, it is now correctly returned to your callback. ( b/152941153 )
Version 1.2.0-alpha03
১ এপ্রিল, ২০২০
androidx.activity:activity:1.2.0-alpha03 and androidx.activity:activity-ktx:1.2.0-alpha03 are released. Version 1.2.0-alpha03 contains these commits.
নতুন বৈশিষ্ট্য
- Added the
TakeVideo,PickContact,GetContent,GetContents,OpenDocument,OpenDocuments,OpenDocumentTree, andCreateDocumentcontracts to the set of pre-built contracts provided byActivityResultContracts. ( aosp/1262482 , aosp/1266916 , aosp/1268960 ) - The Activity Result APIs now support launching an activity for result with an optional
ActivityOptionsCompat. ( b/151860054 )
API Changes
- The
TakePicturecontract now takes aUriinput for where the image should be stored. The previous contract that does not take any input has been renamed toTakePicturePreview. ( aosp/1262482 ) - The
registerActivityResultCallback()method onActivityResultRegistryhas been renamed toregister(). ( aosp/1267621 ) - The
dispose()method onActivityResultLauncherhas been renamed tounregister()and theunregisterResultCallback()onActivityResultRegistryhas been removed. ( aosp/1267621 ) - The
createIntent()method ofActivityResultContactnow takes aContextin addition to the input to make it possible to create explicit Intents. ( aosp/1238800 ) - An
ActivityResultContractcan now overridegetSynchronousResult()to deliver a result without callingstartActivityForResult. This is used by theRequestPermissionandRequestPermissionscontracts to correctly deliver a 'granted' status if the requested permissions are already granted. ( b/151110799 ) - The previously available
Dialcontract has been removed as thatIntentis not meant to be used withstartActivityForResult(). ( aosp/1266916 ) - Many of the Activity Result APIs not meant to be extended are now
final. This includesgetActivityResultRegistry(), theprepareCall()methods, all methods ofActivityResultRegistryexceptinvoke(), and a number of the default contracts that do not support optional extras. ( b/152439361 )
বাগ সংশোধন
- Fixed a
NullPointerExceptioninActivityResultRegistrywhen attempting to deliver results to a callback that has not yet been re-registered after a configuration change;ActivityResultRegistrynow holds onto these pending results and delivers them when the callback is re-registered. ( b/152137004 )
Version 1.2.0-alpha02
March 18, 2020
androidx.activity:activity:1.2.0-alpha02 and androidx.activity:activity-ktx:1.2.0-alpha02 are released. Version 1.2.0-alpha02 contains these commits.
নতুন বৈশিষ্ট্য
- ActivityResultRegistry :
ComponentActivitynow provides anActivityResultRegistrythat lets you handle thestartActivityForResult()+onActivityResult()as well asrequestPermissions()+onRequestPermissionsResult()flows without overriding methods in your Activity or Fragment, brings increased type safety viaActivityResultContract, and provides hooks for testing these flows. See the updated Getting a Result from an Activity . ( b/125158199 )
Version 1.2.0-alpha01
৪ মার্চ, ২০২০
androidx.activity:activity:1.2.0-alpha01 and androidx.activity:activity-ktx:1.2.0-alpha01 are released. Version 1.2.0-alpha01 contains these commits.
নতুন বৈশিষ্ট্য
- Added support for the
ViewTreeLifecycleOwner.get(View)API added in Lifecycle2.3.0-alpha01such that it will return the Activity as theLifecycleOwnerfor any Views directly added to the Activity. ( aosp/1182955 )
বাগ সংশোধন
- Fixed a regression introduced in Activity
1.1.0when running on older versions of the platform whereonBackPressed()would cause anIllegalStateExceptiondue to a bug in theandroid.app.FragmentManager. ( b/146290338 )
সংস্করণ ১.১.০
সংস্করণ ১.১.০
January 22, 2020
androidx.activity:activity:1.1.0 is released. Version 1.1.0 contains these commits .
Important changes since 1.0.0
- Lifecycle ViewModel SavedState Integration :
SavedStateViewModelFactoryis now the default factory used when usingby viewModels(), theViewModelProviderconstructor, orViewModelProviders.of()with aComponentActivityor its subclasses.
Version 1.1.0-rc03
৪ ডিসেম্বর, ২০১৯
androidx.activity:activity:1.1.0-rc03 and androidx.activity:activity-ktx:1.1.0-rc03 are released. Version 1.1.0-rc03 contains these commits .
Dependency changes
- Activity now depends on Lifecycle
2.2.0-rc03and Lifecycle ViewModel SavedState1.0.0-rc03.
Version 1.1.0-rc02
৭ নভেম্বর, ২০১৯
androidx.activity:activity:1.1.0-rc02 and androidx.activity:activity-ktx:1.1.0-rc02 are released. Version 1.1.0-rc02 contains these commits .
Dependency changes
- Activity now depends on lifecycle
2.2.0-rc02.
Version 1.1.0-rc01
October 23, 2019
androidx.activity:activity:1.1.0-rc01 and androidx.activity:activity-ktx:1.1.0-rc01 are released with no changes from 1.1.0-beta01 . Version 1.1.0-rc01 contains these commits .
Version 1.1.0-beta01
৯ অক্টোবর, ২০১৯
androidx.activity:activity:1.1.0-beta01 and androidx.activity:activity-ktx:1.1.0-beta01 are released. Version 1.1.0-beta01 contains these commits .
Dependency changes
- Activity now depends on SavedState 1.0.0 stable.
Version 1.1.0-alpha03
৫ সেপ্টেম্বর, ২০১৯
androidx.activity:activity:1.1.0-alpha03 and androidx.activity:activity-ktx:1.1.0-alpha03 are released. The commits included in this version can be found here .
নতুন বৈশিষ্ট্য
- Activity now depends on Core 1.1.0 stable.
বাগ সংশোধন
- Activity now depends on Lifecycle
2.2.0-alpha04.
Version 1.1.0-alpha02
৭ আগস্ট, ২০১৯
androidx.activity:activity:1.1.0-alpha02 and androidx.activity:activity-ktx:1.1.0-alpha02 are released. The commits included in this version can be found here .
নতুন বৈশিষ্ট্য
-
SavedStateViewModelFactoryis now the default factory used when usingby viewModels(), theViewModelProviderconstructor, orViewModelProviders.of()with aComponentActivity( b/135716331 )
Version 1.1.0-alpha01
July 2, 2019
androidx.activity:activity:1.1.0-alpha01 and androidx.activity:activity-ktx:1.1.0-alpha01 are released. The commits included in this version can be found here .
নতুন বৈশিষ্ট্য
-
activitynow depends on Lifecycle2.2.0-alpha02. ( aosp/1007817 ) -
activity-ktxadded a dependency onlifecycle-runtime-ktx; you no longer need to explicitly add it to your dependencies when usingactivity-ktxor libraries that depend onactivity-ktx(such asfragment-ktx). ( aosp/987162 )
সংস্করণ ১.০.০
সংস্করণ ১.০.০
৫ সেপ্টেম্বর, ২০১৯
androidx.activity:activity:1.0.0 and androidx.activity:activity-ktx:1.0.0 are released. The commits included in this version can be found here .
Major Features of 1.0.0
- ComponentActivity :
ComponentActivityserves as the new base class forFragmentActivityin Fragment1.1.0and, by extension,AppCompatActivityin AppCompat1.1.0. - activity-ktx : The
activity-ktxmodule includes aby viewModelsKotlin property extension for accessing ViewModels. This module is automatically included when you includefragment-ktxfrom Fragment1.1.0. - OnBackPressedDispatcher : As a composable alternative to overriding
onBackPressed(), you can now register aOnBackPressedCallbackfrom anyLifecycleOwner(such as a fragment) to intercept system back button events. A lambda with receiver versionaddCallbackhas been added toactivity-ktx. See Provide custom back navigation documentation for more details. - onRetainCustomNonConfigurationInstance deprecation : the
onRetainCustomNonConfigurationInstance()and the relatedgetLastCustomNonConfigurationInstance()APIs have been deprecated. It is strongly recommended to use ViewModels to store non-configuration state as they offer a composable solution suitable for anyViewModelStoreOwnerthat makes the ownership of the retained objects clear and provides anonCleared()callback for cleaning up resources when the activity is finally destroyed.
Version 1.0.0-rc01
July 2, 2019
androidx.activity:activity:1.0.0-rc01 and androidx.activity:activity-ktx:1.0.0-rc01 are released with no changes from 1.0.0-beta01 . The commits included in this version can be found here .
Version 1.0.0-beta01
June 5, 2019
androidx.activity::activity:1.0.0-beta01 and androidx.activity:activity-ktx:1.0.0-beta01 are released with no changes from 1.0.0-alpha08 . The commits included in this version can be found here .
Version 1.0.0-alpha08
৭ মে, ২০১৯
androidx.activity:activity:1.0.0-alpha08 and androidx.activity:activity-ktx:1.0.0-alpha08 are released. The commits included in this version can be found here .
এপিআই পরিবর্তন
- Breaking change: The previously deprecated
addOnBackPressedCallbackandremoveOnBackPressedCallbackmethods onComponentActivityhave been removed. aosp/953857 - The
setEnabled()andisEnabled()methods ofOnBackPressedCallbackare now final. b/131416833 - The
remove()method ofOnBackPressedCallbackis now final. aosp/952720 -
OnBackPressedDispatchernow has public constructors, allowing you to construct your own instances for testing, etc. aosp/953431 -
onBackPressed()forComponentActivityis now explicitly marked as@MainThreadaosp/952721
বাগ সংশোধন
- Fixed a
ConcurrentModificationExceptionwhen callingremove()from within thehandleOnBackPressed()method of aOnBackPressedCalbackthat was added with aLifecycleOwner. b/131765095
Version 1.0.0-alpha07
April 25th, 2019
androidx.activity:activity:1.0.0-alpha07 and androidx.activity:activity-ktx:1.0.0-alpha07 are released. The commits included in this version can be found here .
এপিআই পরিবর্তন
This release makes significant changes to the handling of the onBackPressed() . See the updated custom back documentation for more details.
- The methods for
OnBackPressedCallbackandOnBackPressedDispatcherhave been marked as@MainThread. ( aosp/943813 ) - The
handleOnBackPressed()method no longer returns aboolean. Instead,OnBackPressedCallbackis now an abstract class that can be enabled or disabled - only when the newisEnabled()method returns true willhandleOnBackPressed()be called, in which you must handle the back button. ( aosp/944518 ) - The
addCallbackmethods ofOnBackPressedDispatcherno longer return aCancellableinstance.OnBackPressedCallbacknow contain aremove()method that fulfill this functionality, allowing you to callremove()duringhandleOnBackPressed(). ( aosp/944519 ) ( aosp/946316 ) -
activity-ktxnow contains a receiver scoped callback foraddCallbackthat accepts a lamdba that implementshandleOnBackPressed()and has access toisEnabledandremove()( aosp/944520 )
Version 1.0.0-alpha06
April 3rd, 2019
androidx.activity:activity:1.0.0-alpha06 and androidx.activity:activity-ktx:1.0.0-alpha06 are released. The commits included in this version can be found here .
এপিআই পরিবর্তন
- ComponentActivity now contain a second constructor that takes a
@LayoutRes int, which replaces the previous behavior of annotating your AppCompatActivity class with@ContentView. This approach works in both app and library modules. ( b/128352521 ) - The
OnBackPressedCallbackrelated APIs on ComponentActivity have been deprecated in favor of the newOnBackPressedDispatcher, retrievable viagetOnBackPressedDispatcher(). ( aosp/922523 ) - Methods to add a new
OnBackPressedCallbackto theOnBackPressedDispatchernow return aCancellableobject, allowing removal of the callback without requiring an explicit reference to theOnBackPressedDispatcher. ( aosp/922523 ) - Adding a
OnBackPressedCallbackwith an associatedLifecycleOwnernow results in adding and removing theOnBackPressedCallbackas the Lifecycle is started and stopped, respectively. ( aosp/922523 )
Version 1.0.0-alpha05
March 13th, 2019
androidx.activity:activity:1.0.0-alpha05 and androidx.activity:activity-ktx:1.0.0-alpha05 are released. The full list of commits included in this release can be found here .
নতুন বৈশিষ্ট্য
-
@ContentViewannotation lookups are now cached ( b/123709449 )
Version 1.0.0-alpha04
৩০ জানুয়ারী, ২০১৯
androidx.activity:activity 1.0.0-alpha04 and androidx.activity:activity-ktx 1.0.0-alpha04 are released.
নতুন বৈশিষ্ট্য
- Added support for the
@ContentViewclass annotation that allows you to indicate which layout XML file should be inflated as an alternative to usingsetContentView(). ( aosp/837619 )
এপিআই পরিবর্তন
- Added a note that
getViewModelStore()should not be overridden and will be made final in a future release. Please file a feature request if you are currently overriding this method. ( aosp/837619 )
বাগ সংশোধন
- The
activitymodule now depends on version 2.1.0-alpha02 of ViewModel to match theactivity-ktxmodule's dependency.
Version 1.0.0-alpha03
December 17, 2018
androidx.activity 1.0.0-alpha03 is released.
নতুন বৈশিষ্ট্য
- ComponentActivity now implements
BundleSavedStateRegistryOwnerand depends on the newly released SavedState library [ aosp/815133 ] - ComponentActivity now works around an Android framework bug that would cause InputMethodManager to leak the last focused view [ b/37122102 ]
Version 1.0.0-alpha02
December 3, 2018
এপিআই পরিবর্তন
- Added a note that
getLifecycle()should not be overridden and will be madefinalin a future release. Please file a feature request if you are currently overriding this method. ( aosp/815834 )
Version 1.0.0-alpha01
৫ নভেম্বর, ২০১৮
androidx.activity 1.0.0-alpha01 introduces ComponentActivity , a new base class of the existing FragmentActivity and AppCompatActivity .
নতুন বৈশিষ্ট্য
- You can now register an
OnBackPressedCallbackviaaddOnBackPressedCallbackto receiveonBackPressed()callbacks without needing to override the method in your activity. - Added a new
by viewModels()Kotlin property delegate for retrievingViewModels from aComponentActivity. - Pending input events (such as clicks) are now canceled in
onStop().
এপিআই পরিবর্তন
- The implementation of
LifecycleOwnerandViewModelStoreOwnerhave been moved fromFragmentActivitytoComponentActivity. -
onRetainCustomNonConfigurationInstancehas been deprecated. Use aViewModelfor storing objects that need to survive configuration changes.