Skip to content

Commit

Permalink
Update AndroiModuleModel to AndroidModel now that is has been renamed…
Browse files Browse the repository at this point in the history
… in Hedgehog
  • Loading branch information
pbreault committed Jun 11, 2023
1 parent 5a93d8e commit f651a34
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.developerphil.adbidea.adb

import com.android.ddmlib.IDevice
import com.android.tools.idea.gradle.project.model.AndroidModuleModel
import com.android.tools.idea.model.AndroidModel
import com.android.tools.idea.util.androidFacet
import com.developerphil.adbidea.adb.DeviceResult.DeviceNotFound
import com.developerphil.adbidea.adb.DeviceResult.SuccessfulDeviceResult
Expand All @@ -24,7 +24,8 @@ class DeviceResultFetcher constructor(
val facets = AndroidUtils.getApplicationFacets(project)
if (facets.isNotEmpty()) {
val facet = getFacet(facets) ?: return null
val packageName = AndroidModuleModel.get(facet)?.applicationId ?: return null

val packageName = AndroidModel.get(facet)?.applicationId ?: return null

if (!bridge.isReady()) {
NotificationHelper.error("No platform configured")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,7 @@ import com.android.ddmlib.IDevice
import com.android.ddmlib.IDevice.HardwareFeature
import com.android.sdklib.AndroidVersion
import com.android.sdklib.IAndroidTarget
import com.android.tools.idea.gradle.project.model.AndroidModuleModel
import com.android.tools.idea.model.AndroidModuleInfo
import com.android.tools.idea.model.AndroidModel
import com.android.tools.idea.model.StudioAndroidModuleInfo
import com.android.tools.idea.run.AndroidDevice
import com.android.tools.idea.run.ConnectedAndroidDevice
Expand Down Expand Up @@ -78,7 +77,7 @@ class MyDeviceChooser(
private val myProjectTarget: IAndroidTarget =
getInstance(myFacet.module)?.target ?: error("Module [${myFacet.module.name}] already disposed")

private val androidModuleModel = AndroidModuleModel.get(myFacet)
private val androidModuleModel = AndroidModel.get(myFacet)
private val mySupportedAbis = androidModuleModel?.supportedAbis ?: Collections.emptySet()

@Volatile
Expand Down

0 comments on commit f651a34

Please sign in to comment.