public AttrDescView_widget_DatePicker_endYear_startYear(ClassDescViewBased parent, String name) { super(parent, name); Class datePickerClass1, datePickerClass2; if (Build.VERSION.SDK_INT < MiscUtil.LOLLIPOP) { datePickerClass1 = parent.getDeclaredClass(); datePickerClass2 = datePickerClass1; } else // Lollipop { this.fieldDelegate = new FieldContainer<Object>(parent.getDeclaredClass(), "mDelegate"); datePickerClass1 = MiscUtil.resolveClass(DatePicker.class.getName() + "$AbstractDatePickerDelegate"); datePickerClass2 = MiscUtil.resolveClass(DatePicker.class.getName() + "$DatePickerSpinnerDelegate"); } this.fieldCurrentLocale = new FieldContainer<Locale>(datePickerClass1, "mCurrentLocale"); String methodName = null; if ("endYear".equals(name)) methodName = "setMaxDate"; else if ("startYear".equals(name)) methodName = "setMinDate"; this.methodMaxMinDate = new MethodContainer<Void>(datePickerClass2, methodName, new Class[] {long.class}); }
public AttrDescView_widget_ToggleButton_textOffandOn(ClassDescViewBased parent, String name) { super(parent, name, null); // Android tiene un texto por defecto this.methodContainer = new MethodContainer(parent.getDeclaredClass(), "syncTextState", null); }