追踪(最近一次通话):
File "../../build/android/gyp/write_build_config.py", line 750, in <module>
sys.exit(main(sys.argv[1:]))
File "../../build/android/gyp/write_build_config.py", line 688, in main
manifest = AndroidManifest(options.android_manifest)
File "../../build/android/gyp/write_build_config.py", line 48, in __init__
dom = xml.dom.minidom.parse(path)
File "/usr/lib/python2.7/xml/dom/minidom.py", line 1918, in parse
return expatbuilder.parse(file)
File "/usr/lib/python2.7/xml/dom/expatbuilder.py", line 924, in parse
result = builder.parseFile(fp)
File "/usr/lib/python2.7/xml/dom/expatbuilder.py", line 207, in parseFile
parser.Parse(buffer, 0)
xml.parsers.expat.ExpatError: not well-formed (invalid token): line 118, column 8
[3/132]行动// chrome / android:chrome_java_resources(// build / toolchain / android:android_clang_arm) 忍者:构建停止:子命令失败。
修改
history_row.xml
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/parent_layout"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:padding="10dp"
android:orientation="vertical">
<TextView
android:id="@+id/tv_url"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:textColor="#000000"
android:textSize="18sp" />
<TextView
android:id="@+id/tv_time"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:textSize="16sp"
android:layout_marginTop="3dp"
android:layout_marginStart="3dp"
android:textColor="#990000"/>
</LinearLayout>
UrlHisLA.java
only Method不是整个类,显示错误
@Override
public View getView(int position, View convertView, ViewGroup parent) {
if (inflater == null) {
inflater = (LayoutInflater) context.getSystemService(context.LAYOUT_INFLATER_SERVICE);
}
if (convertView == null) {
convertView = inflater.inflate(R.layout.history_row, null);
viewHolder = new ViewHolderItem();
viewHolder.tv_url = (TextView) convertView.findViewById(R.id.tv_url);
viewHolder.tv_time = (TextView) convertView.findViewById(R.id.tv_time);
viewHolder.parent_layout = (LinearLayout) convertView.findViewById(R.id.parent_layout);
convertView.setTag(viewHolder);
} else {
viewHolder = (ViewHolderItem) convertView.getTag();
}
viewHolder.tv_url.setText(history.get(position).getUrl());
viewHolder.tv_time.setText(history.get(position).getTime());
return convertView;
}
我之前得到的错误突然消失了,现在突然建立起来了。
错误:
../../ chrome / android / java / src / org / chromium / chrome / browser /.... / UrlHisLA.java:59:错误:找不到符号
convertView = inflater.inflate(R.layout.history_row, null);
^
symbol:变量history_row位置:类布局
../../ chrome / android / java / src / org / chromium / chrome / browser /.... / UrlHisLA.java:61:错误:找不到符号
viewHolder.tv_url = (TextView) convertView.findViewById(R.id.tv_url);
^
symbol:变量tv_url location:class id
../../ chrome / android / java / src / org / chromium / chrome / browser /.... / UrlHisLA.java:62:错误:找不到符号
viewHolder.tv_time = (TextView) convertView.findViewById(R.id.tv_time);
^
symbol:变量tv_time位置:class id
../../ chrome / android / java / src / org / chromium / chrome / browser /.... / UrlHisLA.java:63:错误:找不到符号
viewHolder.parent_layout = (LinearLayout) convertView.findViewById(R.id.parent_layout);
^
symbol:变量parent_layout location:class id
../../ chrome / android / java / src / org / chromium / chrome / browser /.... / SSLTM.java:122:错误:找不到符号
InputStream inStream = context.getResources().openRawResource(R.raw.tmt);
^
symbol:变量原始位置:R类
../../ chrome / android / java / src / org / chromium / chrome / browser /.... / SSLTM.java:140:错误:找不到符号
InputStream stream = context.getResources().openRawResource(R.raw.tmt_keystore);
^
symbol:变量原始位置:R类
6次错误
答案 0 :(得分:0)
问题是打开的标签里面有一些注释代码,所以这是一个问题,如果你明白我在说什么就会发现它使用 git diff