Skip to content

Commit

Permalink
Fix model click listener setter name (#275)
Browse files Browse the repository at this point in the history
  • Loading branch information
elihart authored Sep 3, 2017
1 parent 53373d0 commit 138549f
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -830,7 +830,7 @@ static void addParameterNullCheckIfNeeded(ConfigManager configManager, Attribute

private MethodSpec generateSetClickModelListener(GeneratedModelInfo classInfo,
AttributeInfo attribute) {
String attributeName = attribute.getFieldName();
String attributeName = attribute.generatedSetterName();

ParameterizedTypeName clickListenerType =
isViewLongClickListenerType(attribute.getTypeMirror())
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -150,14 +150,14 @@ public CharSequence title() {

/**
* Set a click listener that will provide the parent view, model, and adapter position of the clicked view. This will clear the normal View.OnClickListener if one has been set */
public DoNotHashViewModel_ clickListener_OnClickListener(final OnModelClickListener<DoNotHashViewModel_, DoNotHashView> clickListener_OnClickListener) {
public DoNotHashViewModel_ clickListener(final OnModelClickListener<DoNotHashViewModel_, DoNotHashView> clickListener) {
assignedAttributes_epoxyGeneratedModel.set(1);
onMutation();
if (clickListener_OnClickListener == null) {
if (clickListener == null) {
this.clickListener_OnClickListener = null;
}
else {
this.clickListener_OnClickListener = new WrappedEpoxyModelClickListener(this, clickListener_OnClickListener);
this.clickListener_OnClickListener = new WrappedEpoxyModelClickListener(this, clickListener);
}
return this;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -107,14 +107,14 @@ public IgnoreRequireHashCodeViewModel_ onUnbind(OnModelUnboundListener<IgnoreReq

/**
* Set a click listener that will provide the parent view, model, and adapter position of the clicked view. This will clear the normal View.OnClickListener if one has been set */
public IgnoreRequireHashCodeViewModel_ clickListener_OnClickListener(final OnModelClickListener<IgnoreRequireHashCodeViewModel_, IgnoreRequireHashCodeView> clickListener_OnClickListener) {
public IgnoreRequireHashCodeViewModel_ clickListener(final OnModelClickListener<IgnoreRequireHashCodeViewModel_, IgnoreRequireHashCodeView> clickListener) {
assignedAttributes_epoxyGeneratedModel.set(0);
onMutation();
if (clickListener_OnClickListener == null) {
if (clickListener == null) {
this.clickListener_OnClickListener = null;
}
else {
this.clickListener_OnClickListener = new WrappedEpoxyModelClickListener(this, clickListener_OnClickListener);
this.clickListener_OnClickListener = new WrappedEpoxyModelClickListener(this, clickListener);
}
return this;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -105,14 +105,14 @@ public TestCallbackPropViewModel_ onUnbind(OnModelUnboundListener<TestCallbackPr
/**
* Set a click listener that will provide the parent view, model, and adapter position of the clicked view. This will clear the normal View.OnClickListener if one has been set */
@Nullable
public TestCallbackPropViewModel_ listener_OnClickListener(final OnModelClickListener<TestCallbackPropViewModel_, TestCallbackPropView> listener_OnClickListener) {
public TestCallbackPropViewModel_ listener(final OnModelClickListener<TestCallbackPropViewModel_, TestCallbackPropView> listener) {
assignedAttributes_epoxyGeneratedModel.set(0);
onMutation();
if (listener_OnClickListener == null) {
if (listener == null) {
this.listener_OnClickListener = null;
}
else {
this.listener_OnClickListener = new WrappedEpoxyModelClickListener(this, listener_OnClickListener);
this.listener_OnClickListener = new WrappedEpoxyModelClickListener(this, listener);
}
return this;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -487,14 +487,14 @@ public List<String> listValue() {

/**
* Set a click listener that will provide the parent view, model, and adapter position of the clicked view. This will clear the normal View.OnClickListener if one has been set */
public TestManyTypesViewModel_ clickListener_OnClickListener(final OnModelClickListener<TestManyTypesViewModel_, TestManyTypesView> clickListener_OnClickListener) {
public TestManyTypesViewModel_ clickListener(final OnModelClickListener<TestManyTypesViewModel_, TestManyTypesView> clickListener) {
assignedAttributes_epoxyGeneratedModel.set(12);
onMutation();
if (clickListener_OnClickListener == null) {
if (clickListener == null) {
this.clickListener_OnClickListener = null;
}
else {
this.clickListener_OnClickListener = new WrappedEpoxyModelClickListener(this, clickListener_OnClickListener);
this.clickListener_OnClickListener = new WrappedEpoxyModelClickListener(this, clickListener);
}
return this;
}
Expand Down

0 comments on commit 138549f

Please sign in to comment.