20250906_012327_326
This commit is contained in:
		| @@ -1,8 +1,8 @@ | |||||||
| #Created by .winboll/winboll_app_build.gradle | #Created by .winboll/winboll_app_build.gradle | ||||||
| #Mon Sep 01 08:07:48 HKT 2025 | #Fri Sep 05 17:21:44 GMT 2025 | ||||||
| stageCount=8 | stageCount=8 | ||||||
| libraryProject= | libraryProject= | ||||||
| baseVersion=15.3 | baseVersion=15.3 | ||||||
| publishVersion=15.3.7 | publishVersion=15.3.7 | ||||||
| buildCount=0 | buildCount=10 | ||||||
| baseBetaVersion=15.3.8 | baseBetaVersion=15.3.8 | ||||||
|   | |||||||
| @@ -57,6 +57,7 @@ public class ComposeSMSActivity extends BaseActivity { | |||||||
|     @Override |     @Override | ||||||
|     protected void onCreate(Bundle savedInstanceState) { |     protected void onCreate(Bundle savedInstanceState) { | ||||||
|         super.onCreate(savedInstanceState); |         super.onCreate(savedInstanceState); | ||||||
|  | 		LogUtils.d(TAG, "onCreate"); | ||||||
|         setContentView(R.layout.activity_composesms); |         setContentView(R.layout.activity_composesms); | ||||||
|  |  | ||||||
|         // 初始化Intent数据(增加空判断,避免NullPointerException) |         // 初始化Intent数据(增加空判断,避免NullPointerException) | ||||||
| @@ -192,8 +193,20 @@ public class ComposeSMSActivity extends BaseActivity { | |||||||
|  |  | ||||||
|         // 定位到第一个匹配项(如果有) |         // 定位到第一个匹配项(如果有) | ||||||
|         if (!matchedContacts.isEmpty()) { |         if (!matchedContacts.isEmpty()) { | ||||||
|             mlvContracts.setSelection(0); | 			//LogUtils.d(TAG, String.format("matchedContacts.size() %d", matchedContacts.size())); | ||||||
|             mtvTOName.setText(matchedContacts.get(0).getName()); | 			// 先设置列表选中项 | ||||||
|  |             //mlvContracts.setSelection(0); | ||||||
|  | 			for (int i = 0; i < matchedContacts.size(); i++) { | ||||||
|  | 				PhoneBean item = matchedContacts.get(i); | ||||||
|  | 				//LogUtils.d(TAG, String.format("item.getTelPhone() %s", item.getTelPhone())); | ||||||
|  | 				//LogUtils.d(TAG, String.format("metTO.getText() %s", metTO.getText())); | ||||||
|  | 				if (item.getTelPhone().equals(metTO.getText().toString())) { | ||||||
|  | 					mtvTOName.setText(item.getName()); | ||||||
|  | 					mlvContracts.setSelection(i); | ||||||
|  | 					LogUtils.d(TAG, String.format("%s match %s", metTO.getText().toString(), item.getTelPhone())); | ||||||
|  | 					break; | ||||||
|  | 				} | ||||||
|  | 			} | ||||||
|         } else { |         } else { | ||||||
|             mtvTOName.setText(""); // 无结果时清空姓名显示 |             mtvTOName.setText(""); // 无结果时清空姓名显示 | ||||||
|         } |         } | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 ZhanGSKen
					ZhanGSKen