Skip to content

Commit

Permalink
Fix Fragment bug
Browse files Browse the repository at this point in the history
  • Loading branch information
Ahmad Aghazadeh committed Oct 5, 2018
1 parent 3b4a92a commit 63ad3a7
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ public static void setCodeView(CodeEditor view, MutableLiveData<String> code, Mu

private void init(Context context, AttributeSet attrs) {
try {
removeAllViews();

this.context = context;
initEditor();
String code = "";
Expand All @@ -132,6 +132,7 @@ private void init(Context context, AttributeSet attrs) {
RelativeLayout.LayoutParams rootViewParam = new RelativeLayout.LayoutParams(RelativeLayout.LayoutParams.MATCH_PARENT, LayoutParams.MATCH_PARENT);

rootView = new RelativeLayout(context);
rootView.removeAllViews();
rootView.setLayoutParams(rootViewParam);
GutterView gutterView = new GutterView(context);
gutterView.setId(R.id.gutterView);
Expand Down

0 comments on commit 63ad3a7

Please sign in to comment.