Commit 8afee2bd1e51efccbe98689758c1f6b9ab1d314a
1 parent
38c88362
Exists in
yxb_dev
and in
2 other branches
no message
Showing
4 changed files
with
13 additions
and
10 deletions
Show diff stats
app/src/main/AndroidManifest.xml
@@ -144,7 +144,6 @@ | @@ -144,7 +144,6 @@ | ||
144 | 144 | ||
145 | <activity | 145 | <activity |
146 | android:name=".ui.MainActivity" | 146 | android:name=".ui.MainActivity" |
147 | - android:launchMode="singleInstance" | ||
148 | android:screenOrientation="portrait"/> | 147 | android:screenOrientation="portrait"/> |
149 | 148 | ||
150 | <activity | 149 | <activity |
app/src/main/java/com/shunzhi/parent/adapter/SchoolListAdapter.java
@@ -32,7 +32,6 @@ public class SchoolListAdapter extends BaseRecyclerViewAdapter<SortBean> { | @@ -32,7 +32,6 @@ public class SchoolListAdapter extends BaseRecyclerViewAdapter<SortBean> { | ||
32 | public SchoolListAdapter(Context context, List<SortBean> list) { | 32 | public SchoolListAdapter(Context context, List<SortBean> list) { |
33 | this.context = context; | 33 | this.context = context; |
34 | this.list = list; | 34 | this.list = list; |
35 | - Log.e("sss-===",list.size()+""); | ||
36 | ischeck = new boolean[list.size()]; | 35 | ischeck = new boolean[list.size()]; |
37 | for (int i=0;i<ischeck.length;i++){ | 36 | for (int i=0;i<ischeck.length;i++){ |
38 | ischeck[i]=false; | 37 | ischeck[i]=false; |
@@ -93,12 +92,18 @@ public class SchoolListAdapter extends BaseRecyclerViewAdapter<SortBean> { | @@ -93,12 +92,18 @@ public class SchoolListAdapter extends BaseRecyclerViewAdapter<SortBean> { | ||
93 | item_view.setOnClickListener(new View.OnClickListener() { | 92 | item_view.setOnClickListener(new View.OnClickListener() { |
94 | @Override | 93 | @Override |
95 | public void onClick(View v) { | 94 | public void onClick(View v) { |
96 | - ischeck[position] = true; | ||
97 | - if(currentPosition!=-1) { | 95 | + if(ischeck[position]){ |
96 | + currentPosition=-1; | ||
98 | ischeck[currentPosition] = false; | 97 | ischeck[currentPosition] = false; |
98 | + currentSortBean = null; | ||
99 | + }else { | ||
100 | + ischeck[position] = true; | ||
101 | + if (currentPosition != -1) { | ||
102 | + ischeck[currentPosition] = false; | ||
103 | + } | ||
104 | + currentPosition = position; | ||
105 | + currentSortBean = object; | ||
99 | } | 106 | } |
100 | - currentPosition = position; | ||
101 | - currentSortBean=object; | ||
102 | notifyDataSetChanged(); | 107 | notifyDataSetChanged(); |
103 | } | 108 | } |
104 | }); | 109 | }); |
app/src/main/java/com/shunzhi/parent/ui/activity/binding/SelectSchoolActivity.java
@@ -96,7 +96,7 @@ public class SelectSchoolActivity extends BaseMVPCompatActivity<SchoolListContra | @@ -96,7 +96,7 @@ public class SelectSchoolActivity extends BaseMVPCompatActivity<SchoolListContra | ||
96 | } | 96 | } |
97 | 97 | ||
98 | private void setSchoolList() { | 98 | private void setSchoolList() { |
99 | - mPresenter.schoolListResult(AppContext.getInstance().cityName, ""); | 99 | + mPresenter.schoolListResult(AppContext.getInstance().district, ""); |
100 | } | 100 | } |
101 | 101 | ||
102 | @Override | 102 | @Override |
app/src/main/java/com/shunzhi/parent/ui/activity/mywebview/WebViewActivity.java
@@ -4,7 +4,6 @@ import android.content.Context; | @@ -4,7 +4,6 @@ import android.content.Context; | ||
4 | import android.content.Intent; | 4 | import android.content.Intent; |
5 | import android.graphics.Bitmap; | 5 | import android.graphics.Bitmap; |
6 | import android.os.Bundle; | 6 | import android.os.Bundle; |
7 | -import android.util.Log; | ||
8 | import android.view.View; | 7 | import android.view.View; |
9 | import android.webkit.JavascriptInterface; | 8 | import android.webkit.JavascriptInterface; |
10 | import android.webkit.WebChromeClient; | 9 | import android.webkit.WebChromeClient; |
@@ -68,7 +67,7 @@ public class WebViewActivity extends BaseCompatActivity { | @@ -68,7 +67,7 @@ public class WebViewActivity extends BaseCompatActivity { | ||
68 | @Override | 67 | @Override |
69 | public void onClick(View v) { | 68 | public void onClick(View v) { |
70 | if(type!=-1&&type!= AppConfig.ORDER_CENTER) { | 69 | if(type!=-1&&type!= AppConfig.ORDER_CENTER) { |
71 | - startActivity(new Intent().setClass(WebViewActivity.this, MainActivity.class)); | 70 | + startActivity(new Intent().setFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP).setClass(WebViewActivity.this, MainActivity.class)); |
72 | }else{ | 71 | }else{ |
73 | finish(); | 72 | finish(); |
74 | } | 73 | } |
@@ -134,7 +133,7 @@ public class WebViewActivity extends BaseCompatActivity { | @@ -134,7 +133,7 @@ public class WebViewActivity extends BaseCompatActivity { | ||
134 | } else { | 133 | } else { |
135 | super.onBackPressedSupport(); | 134 | super.onBackPressedSupport(); |
136 | if (type != -1 && type != AppConfig.ORDER_CENTER) { | 135 | if (type != -1 && type != AppConfig.ORDER_CENTER) { |
137 | - startActivity(new Intent().setClass(this, MainActivity.class)); | 136 | + startActivity(new Intent().setFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP).setClass(this, MainActivity.class)); |
138 | } | 137 | } |
139 | } | 138 | } |
140 | } | 139 | } |