mirror of
https://github.com/pppscn/SmsForwarder
synced 2024-11-17 21:25:31 +00:00
转发记录显示优化
This commit is contained in:
parent
cccea93ac9
commit
e1c80d1022
@ -121,7 +121,7 @@ public class MainActivity extends AppCompatActivity implements ReFlashListView.I
|
|||||||
public void logDetail(LogVo logVo) {
|
public void logDetail(LogVo logVo) {
|
||||||
AlertDialog.Builder builder = new AlertDialog.Builder(MainActivity.this);
|
AlertDialog.Builder builder = new AlertDialog.Builder(MainActivity.this);
|
||||||
builder.setTitle("详情");
|
builder.setTitle("详情");
|
||||||
builder.setMessage(logVo.getFrom() + "\n" + logVo.getContent() + "\n" + logVo.getRule() + "\n" + logVo.getTime());
|
builder.setMessage(logVo.getFrom() + "\n\n" + logVo.getContent() + "\n\n" + logVo.getRule() + "\n\n" + logVo.getTime());
|
||||||
builder.show();
|
builder.show();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -45,7 +45,7 @@ public class RuleModel {
|
|||||||
case FILED_TRANSPOND_ALL:
|
case FILED_TRANSPOND_ALL:
|
||||||
return "全部转发到 ";
|
return "全部转发到 ";
|
||||||
default:
|
default:
|
||||||
return "当 " + FILED_MAP.get(filed) + " " + CHECK_MAP.get(check) + " " + value;
|
return "当 " + FILED_MAP.get(filed) + " " + CHECK_MAP.get(check) + " " + value + " 转发到 ";
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -157,7 +157,7 @@ public class LogUtil {
|
|||||||
cursor.getColumnIndexOrThrow(SenderTable.SenderEntry.TABLE_NAME + "." + SenderTable.SenderEntry.COLUMN_NAME_TYPE));
|
cursor.getColumnIndexOrThrow(SenderTable.SenderEntry.TABLE_NAME + "." + SenderTable.SenderEntry.COLUMN_NAME_TYPE));
|
||||||
|
|
||||||
Log.d(TAG, "getLog: time" + time);
|
Log.d(TAG, "getLog: time" + time);
|
||||||
String rule = RuleModel.getRuleMatch(ruleFiled, ruleCheck, ruleValue) + " 转发到 " + senderName;
|
String rule = RuleModel.getRuleMatch(ruleFiled, ruleCheck, ruleValue) + senderName;
|
||||||
// String rule = time+" 转发到 "+senderName;
|
// String rule = time+" 转发到 "+senderName;
|
||||||
int senderImageId = SenderModel.getImageId(senderType);
|
int senderImageId = SenderModel.getImageId(senderType);
|
||||||
LogVo logVo = new LogVo(itemfrom, content, time, rule, senderImageId);
|
LogVo logVo = new LogVo(itemfrom, content, time, rule, senderImageId);
|
||||||
|
@ -11,11 +11,21 @@
|
|||||||
android:paddingBottom="10dip">
|
android:paddingBottom="10dip">
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/tlog_rule"
|
android:id="@+id/tlog_from"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_alignParentStart="true"
|
android:layout_alignParentStart="true"
|
||||||
android:layout_marginStart="10dp" />
|
android:layout_marginStart="10dp"
|
||||||
|
android:textColor="@android:color/black"
|
||||||
|
android:textColorHighlight="@android:color/holo_red_dark" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tlog_rule"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_centerInParent="true"
|
||||||
|
android:layout_marginStart="10dp"
|
||||||
|
android:visibility="gone" />
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:id="@+id/tlog_sender_image"
|
android:id="@+id/tlog_sender_image"
|
||||||
@ -25,18 +35,11 @@
|
|||||||
|
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:id="@+id/tlog_from"
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginLeft="10dp"
|
|
||||||
android:textColor="@android:color/black"
|
|
||||||
android:textColorHighlight="@android:color/holo_red_dark" />
|
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/tlog_content"
|
android:id="@+id/tlog_content"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_gravity="center_vertical"
|
android:layout_gravity="center_vertical"
|
||||||
android:layout_marginLeft="10dp" />
|
android:layout_marginLeft="10dp"
|
||||||
|
android:layout_marginBottom="10dp" />
|
||||||
</LinearLayout>
|
</LinearLayout>
|
Loading…
Reference in New Issue
Block a user