Skip to content

Commit

Permalink
add isInEditMode
Browse files Browse the repository at this point in the history
  • Loading branch information
youlookwhat committed Oct 29, 2019
1 parent f537218 commit abc96a0
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,9 @@ public ByRecyclerView(Context context, AttributeSet attrs) {

public ByRecyclerView(Context context, AttributeSet attrs, int defStyle) {
super(context, attrs, defStyle);
if (isInEditMode()) {
return;
}
init();
}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package me.jingbin.library;

import android.content.Context;
import android.util.AttributeSet;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
Expand All @@ -20,15 +19,7 @@ public class SimpleLoadMoreView extends LinearLayout implements BaseLoadMore {
private LinearLayout llMoreLoading;

public SimpleLoadMoreView(Context context) {
this(context, null);
}

public SimpleLoadMoreView(Context context, AttributeSet attrs) {
this(context, attrs, 0);
}

public SimpleLoadMoreView(Context context, AttributeSet attrs, int defStyleAttr) {
super(context, attrs, defStyleAttr);
super(context, null);
initView(context);
}

Expand Down
2 changes: 1 addition & 1 deletion ByRecyclerview/src/main/res/values-en/strings.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<resources>
<string name="app_name">library</string>
<string name="app_name">ByRecyclerView</string>

<string name="header_hint_normal">Drop down refresh</string>
<string name="header_hint_release">Release refresh</string>
Expand Down
2 changes: 1 addition & 1 deletion app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
package="me.jingbin.byrecyclerviewsupport">

<application
android:allowBackup="true"
android:allowBackup="false"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:roundIcon="@mipmap/ic_launcher_round"
Expand Down

0 comments on commit abc96a0

Please sign in to comment.