@@ -41,7 +41,8 @@ public final class RomUtils {
41
41
private static final String [] ROM_SMARTISAN = {"smartisan" };
42
42
private static final String [] ROM_HTC = {"htc" };
43
43
private static final String [] ROM_SONY = {"sony" };
44
- private static final String [] ROM_AMIGO = {"amigo" };
44
+ private static final String [] ROM_GIONEE = {"gionee" , "amigo" };
45
+ private static final String [] ROM_MOTOROLA = {"motorola" };
45
46
46
47
private static final String VERSION_PROPERTY_HUAWEI = "ro.build.version.emui" ;
47
48
private static final String VERSION_PROPERTY_VIVO = "ro.vivo.os.build.display.id" ;
@@ -223,12 +224,21 @@ public static boolean isSony() {
223
224
}
224
225
225
226
/**
226
- * Return whether the rom is made by amigo .
227
+ * Return whether the rom is made by gionee .
227
228
*
228
229
* @return {@code true}: yes<br>{@code false}: no
229
230
*/
230
- public static boolean isAmigo () {
231
- return ROM_AMIGO [0 ].equals (getRomInfo ().name );
231
+ public static boolean isGionee () {
232
+ return ROM_GIONEE [0 ].equals (getRomInfo ().name );
233
+ }
234
+
235
+ /**
236
+ * Return whether the rom is made by motorola.
237
+ *
238
+ * @return {@code true}: yes<br>{@code false}: no
239
+ */
240
+ public static boolean isMotorola () {
241
+ return ROM_MOTOROLA [0 ].equals (getRomInfo ().name );
232
242
}
233
243
234
244
/**
@@ -312,8 +322,10 @@ public static RomInfo getRomInfo() {
312
322
bean .name = ROM_HTC [0 ];
313
323
} else if (isRightRom (brand , manufacturer , ROM_SONY )) {
314
324
bean .name = ROM_SONY [0 ];
315
- } else if (isRightRom (brand , manufacturer , ROM_AMIGO )) {
316
- bean .name = ROM_AMIGO [0 ];
325
+ } else if (isRightRom (brand , manufacturer , ROM_GIONEE )) {
326
+ bean .name = ROM_GIONEE [0 ];
327
+ } else if (isRightRom (brand , manufacturer , ROM_MOTOROLA )) {
328
+ bean .name = ROM_MOTOROLA [0 ];
317
329
} else {
318
330
bean .name = manufacturer ;
319
331
}
0 commit comments