This repository was archived by the owner on Oct 18, 2024. It is now read-only.
File tree 4 files changed +7
-8
lines changed
aaptcompiler/src/main/java/com/android/aaptcompiler
resources-api/src/main/java/com/itsaky/androidide/xml/res
utils/src/test/java/com/itsaky/androidide/xml/resources
4 files changed +7
-8
lines changed Original file line number Diff line number Diff line change @@ -23,8 +23,6 @@ plugins {
23
23
id(" kotlin-kapt" )
24
24
}
25
25
26
-
27
-
28
26
dependencies {
29
27
kapt(libs.google.auto.service)
30
28
Original file line number Diff line number Diff line change @@ -775,7 +775,7 @@ class ResourceEntry(override val name: String) : IResourceEntry {
775
775
var allowNew: AllowNew ? = null
776
776
var overlayable: OverlayableItem ? = null
777
777
778
- val values = mutableListOf<ResourceConfigValue >()
778
+ override val values = mutableListOf<ResourceConfigValue >()
779
779
780
780
override fun findValue (config : ConfigDescription , product : String ): ResourceConfigValue ? {
781
781
return values.find { it.config == config && it.product == product }
Original file line number Diff line number Diff line change @@ -25,5 +25,6 @@ import com.android.aaptcompiler.ResourceConfigValue
25
25
*/
26
26
interface IResourceEntry {
27
27
val name: String
28
+ val values: Collection <ResourceConfigValue >
28
29
fun findValue (config : ConfigDescription , product : String = ""): ResourceConfigValue ?
29
30
}
Original file line number Diff line number Diff line change @@ -156,7 +156,7 @@ class ResourceTableRegistryTest {
156
156
}
157
157
158
158
resourceTable!! .findResource(
159
- com.android.aaptcompiler. ResourceName (
159
+ ResourceName (
160
160
pck = " android" ,
161
161
type = STRING ,
162
162
entry = " ok"
@@ -169,15 +169,15 @@ class ResourceTableRegistryTest {
169
169
assertThat(this ).isNotNull()
170
170
assertThat(this !! .value).isNotNull()
171
171
this .value.apply {
172
- assertThat(this ).isInstanceOf(com.android.aaptcompiler. BasicString ::class .java)
172
+ assertThat(this ).isInstanceOf(BasicString ::class .java)
173
173
assertThat(this .toString()).isEqualTo(" OK" )
174
174
}
175
175
}
176
176
}
177
177
178
178
resourceTable
179
179
.findResource(
180
- com.android.aaptcompiler. ResourceName (
180
+ ResourceName (
181
181
pck = " android" ,
182
182
type = STRING ,
183
183
entry = " cancel"
@@ -191,15 +191,15 @@ class ResourceTableRegistryTest {
191
191
assertThat(this ).isNotNull()
192
192
assertThat(this !! .value).isNotNull()
193
193
this .value.apply {
194
- assertThat(this ).isInstanceOf(com.android.aaptcompiler. BasicString ::class .java)
194
+ assertThat(this ).isInstanceOf(BasicString ::class .java)
195
195
assertThat(this .toString()).isEqualTo(" Cancel" )
196
196
}
197
197
}
198
198
}
199
199
200
200
resourceTable
201
201
.findResource(
202
- com.android.aaptcompiler. ResourceName (
202
+ ResourceName (
203
203
pck = " android" ,
204
204
type = COLOR ,
205
205
entry = " holo_red_dark"
You can’t perform that action at this time.
0 commit comments