ProtoLayout নামস্থানে স্থানান্তর করুন

সংস্করণ 1.2 অনুযায়ী, বেশিরভাগ টাইলস লেআউট API গুলি androidx.wear.protolayout নামস্থানে রয়েছে। সর্বশেষ API ব্যবহার করতে, আপনার কোডে নিম্নলিখিত মাইগ্রেশন পদক্ষেপগুলি সম্পূর্ণ করুন৷

নির্ভরতা আপডেট করুন

আপনার অ্যাপ মডিউলের বিল্ড ফাইলে, নিম্নলিখিত পরিবর্তনগুলি করুন:

  // Remove
 
implementation 'androidx.wear.tiles:tiles-material:version'

 
// Include additional dependencies
  implementation
"androidx.wear.protolayout:protolayout:1.2.0"
  implementation
"androidx.wear.protolayout:protolayout-material:1.2.0"
  implementation
"androidx.wear.protolayout:protolayout-expression:1.2.0"

 
// Update
  implementation
"androidx.wear.tiles:tiles:1.4.0"
  // Remove
 
implementation("androidx.wear.tiles:tiles-material:version")

 
// Include additional dependencies
  implementation
("androidx.wear.protolayout:protolayout:1.2.0")
  implementation
("androidx.wear.protolayout:protolayout-material:1.2.0")
  implementation
("androidx.wear.protolayout:protolayout-expression:1.2.0")

 
// Update
  implementation
("androidx.wear.tiles:tiles:1.4.0")

নামস্থান আপডেট করুন

আপনার অ্যাপের Kotlin- এবং Java-ভিত্তিক কোড ফাইলগুলিতে, নিম্নলিখিত আপডেটগুলি করুন৷ বিকল্পভাবে, আপনি এই নেমস্পেস রিনেমিং স্ক্রিপ্ট চালাতে পারেন।

  1. সমস্ত androidx.wear.tiles.material.* আমদানি androidx.wear.protolayout.material.* দিয়ে প্রতিস্থাপন করুন। androidx.wear.tiles.material.layouts লাইব্রেরির জন্যও এই ধাপটি সম্পূর্ণ করুন।
  2. অন্যান্য বেশিরভাগ androidx.wear.tiles.* androidx.wear.protolayout.*

    androidx.wear.tiles.EventBuilders , androidx.wear.tiles.RequestBuilders , androidx.wear.tiles.TileBuilders , এবং androidx.wear.tiles.TileService এর জন্য আমদানি একই থাকতে হবে।

  3. TileService এবং TileBuilder ক্লাস থেকে কিছু অবনমিত পদ্ধতির নাম পরিবর্তন করুন:

    1. TileBuilders : getTimeline() to getTileTimeline() , এবং setTimeline() to setTileTimeline()
    2. TileService : onResourcesRequest() থেকে onTileResourcesRequest()
    3. RequestBuilders.TileRequest : getDeviceParameters() to getDeviceConfiguration() , setDeviceParameters() to setDeviceConfiguration() , getState() to getCurrentState() , এবং setState() to setCurrentState()
{% শব্দার্থে %}

এখন দেখানোর মতো কোনও সাজেশন নেই।

আপনার Google অ্যাকাউন্টে করে দেখুন।

{% endverbatim %}