Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No resource identifier found for attribute 'connectingLineWeight' in package 'com.tencent.weread.eink' #2303

Open
ahxxm opened this issue Feb 28, 2020 · 2 comments

Comments

@ahxxm
Copy link

@ahxxm ahxxm commented Feb 28, 2020

W: ~/dev/wereadtmp/weread_android_1.1.1_10140948_900/res/layout/ga.xml:5: error: No resource identifier found for attribute 'barWeight' in package 'com.tencent.weread.eink'
W: ~/dev/wereadtmp/weread_android_1.1.1_10140948_900/res/layout/ga.xml:5: error: No resource identifier found for attribute 'connectingLineColor' in package 'com.tencent.weread.eink'
W: 
W: ~/dev/wereadtmp/weread_android_1.1.1_10140948_900/res/layout/ga.xml:5: error: No resource identifier found for attribute 'connectingLineWeight' in package 'com.tencent.weread.eink'
W: 
W: ~/dev/wereadtmp/weread_android_1.1.1_10140948_900/res/layout/ga.xml:5: error: No resource identifier found for attribute 'tickHeight' in package 'com.tencent.weread.eink'
W: 
W: ~/dev/wereadtmp/weread_android_1.1.1_10140948_900/res/layout/ga.xml:5: error: No resource identifier found for attribute 'tickMode' in package 'com.tencent.weread.eink'
W: 
W: ~/dev/wereadtmp/weread_android_1.1.1_10140948_900/res/layout/gg.xml:7: error: No resource identifier found for attribute 'barWeight' in package 'com.tencent.weread.eink'
W: 
W: ~/dev/wereadtmp/weread_android_1.1.1_10140948_900/res/layout/gg.xml:7: error: No resource identifier found for attribute 'connectingLineColor' in package 'com.tencent.weread.eink'
W: 
W: ~/dev/wereadtmp/weread_android_1.1.1_10140948_900/res/layout/gg.xml:7: error: No resource identifier found for attribute 'connectingLineWeight' in package 'com.tencent.weread.eink'
W: 
W: ~/dev/wereadtmp/weread_android_1.1.1_10140948_900/res/layout/gg.xml:7: error: No resource identifier found for attribute 'tickHeight' in package 'com.tencent.weread.eink'
W: 
W: ~/dev/wereadtmp/weread_android_1.1.1_10140948_900/res/layout/gg.xml:7: error: No resource identifier found for attribute 'tickMode' in package 'com.tencent.weread.eink'
W: 

Information

  1. Apktool Version (apktool -version) - 2.4.1
  2. Operating System (Mac, Linux, Windows) - Mac
  3. APK From? (Playstore, ROM, Other) - Other, reader for eink

Steps to Reproduce

  • apktool d file.apk
  • LC_ALL=C sed -i '' -e 's|res-auto|lib-auto|g' $(find . -name "*.xml") (more errors without this)
  • apktool b

Framework and APK

Framework: https://files.catbox.moe/h63092.apk
APK: https://files.catbox.moe/lt26pp.apk

Questions to ask before submission

  1. Have you tried apktool d, apktool b without changing anything? Yes
  2. If you are trying to install a modified apk, did you resign it? Yes
  3. Are you using the latest apktool version? Yes
@ahxxm

This comment has been minimized.

Copy link
Author

@ahxxm ahxxm commented Feb 28, 2020

I also tried manually edit ga.xml and gg.xml,

diff --git a/res/layout/ga.xml b/res/layout/ga.xml
index 4890008a..9bbc9903 100644
--- a/res/layout/ga.xml
+++ b/res/layout/ga.xml
@@ -2,7 +2,7 @@
 <merge android:layout_width="fill_parent" android:layout_height="wrap_content"
   xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/lib-auto">
     <androidx.appcompat.widget.AppCompatImageView android:id="@id/p1" android:paddingLeft="20.0dip" android:layout_width="wrap_content" android:layout_height="wrap_content" app:layout_constraintBottom_toBottomOf="@id/x4" app:layout_constraintLeft_toLeftOf="tb" app:layout_constraintTop_toTopOf="@id/x4" app:srcCompat="@drawable/h7" />
-    <com.tencent.weread.reader.container.themeview.ThemeRangeBar android:layout_gravity="center_vertical" android:id="@id/x4" android:layout_width="0.0dip" android:layout_height="wrap_content" android:layout_marginTop="12.0dip" range:barWeight="@dimen/a4h" range:connectingLineColor="@color/p5" range:connectingLineWeight="@dimen/a4h" app:layout_constraintLeft_toRightOf="@id/p1" app:layout_constraintRight_toLeftOf="@id/p0" app:layout_constraintTop_toTopOf="tb" range:tickHeight="@dimen/a4h" range:tickMode="nv"
+    <com.tencent.weread.reader.container.themeview.ThemeRangeBar android:layout_gravity="center_vertical" android:id="@id/x4" android:layout_width="0.0dip" android:layout_height="wrap_content" android:layout_marginTop="12.0dip" barWeight="3.0dip" connectingLineWeight="3.0dip" app:layout_constraintLeft_toRightOf="@id/p1" app:layout_constraintRight_toLeftOf="@id/p0" app:layout_constraintTop_toTopOf="tb" tickHeight="3.0dip" tickMode="nv"
       xmlns:range="http://schemas.android.com/apk/res/com.tencent.weread.eink" />
     <androidx.appcompat.widget.AppCompatImageView android:id="@id/p0" android:paddingRight="20.0dip" android:layout_width="wrap_content" android:layout_height="wrap_content" app:layout_constraintBottom_toBottomOf="@id/x4" app:layout_constraintRight_toRightOf="tb" app:layout_constraintTop_toTopOf="@id/x4" app:srcCompat="@drawable/h6" />
     <RadioGroup android:orientation="horizontal" android:id="@id/a6n" android:layout_width="0.0dip" android:layout_height="wrap_content" android:layout_marginLeft="20.0dip" android:layout_marginTop="24.0dip" android:layout_marginRight="20.0dip" app:layout_constraintLeft_toLeftOf="tb" app:layout_constraintRight_toRightOf="tb" app:layout_constraintTop_toBottomOf="@id/x4" />
diff --git a/res/layout/gg.xml b/res/layout/gg.xml
index 13d21695..b859274f 100644
--- a/res/layout/gg.xml
+++ b/res/layout/gg.xml
@@ -4,7 +4,7 @@
     <com.qmuiteam.qmui.alpha.QMUIAlphaTextView android:textSize="15.0sp" android:textColor="@color/an" android:ellipsize="end" android:gravity="center" android:id="@id/xc" android:layout_width="0.0dip" android:layout_height="wrap_content" android:layout_marginLeft="20.0dip" android:layout_marginRight="20.0dip" android:layout_marginBottom="20.0dip" android:maxLines="1" app:layout_constraintBottom_toTopOf="@id/x6" app:layout_constraintLeft_toLeftOf="tb" app:layout_constraintRight_toRightOf="tb" />
     <androidx.appcompat.widget.AppCompatTextView android:textSize="15.0sp" android:textColor="@color/an" android:ellipsize="end" android:gravity="center" android:id="@id/xd" android:layout_width="0.0dip" android:layout_height="wrap_content" android:layout_marginLeft="20.0dip" android:layout_marginRight="20.0dip" android:layout_marginBottom="4.0dip" android:maxLines="1" app:layout_constraintBottom_toTopOf="@id/x6" app:layout_constraintLeft_toLeftOf="tb" app:layout_constraintRight_toRightOf="tb" />
     <androidx.appcompat.widget.AppCompatImageButton android:id="@id/xa" android:background="@drawable/bp" android:layout_width="32.0dip" android:layout_height="32.0dip" android:layout_marginLeft="28.0dip" android:scaleType="centerInside" app:layout_constraintBottom_toBottomOf="@id/x6" app:layout_constraintLeft_toLeftOf="tb" app:layout_constraintTop_toTopOf="@id/x6" />
-    <com.tencent.weread.reader.container.themeview.ThemeRangeBar android:id="@id/x6" android:layout_width="0.0dip" android:layout_height="wrap_content" android:layout_marginTop="52.0dip" range:barWeight="@dimen/a4h" range:connectingLineColor="@color/p5" range:connectingLineWeight="@dimen/a4h" app:layout_constraintLeft_toRightOf="@id/xa" app:layout_constraintRight_toLeftOf="@id/x5" app:layout_constraintTop_toTopOf="tb" range:tickHeight="@dimen/a4h" range:tickMode="nv"
+    <com.tencent.weread.reader.container.themeview.ThemeRangeBar android:id="@id/x6" android:layout_width="0.0dip" android:layout_height="wrap_content" android:layout_marginTop="52.0dip" barWeight="3.0dip" connectingLineWeight="3.0dip" app:layout_constraintLeft_toRightOf="@id/xa" app:layout_constraintRight_toLeftOf="@id/x5" app:layout_constraintTop_toTopOf="tb" tickHeight="3.0dip" tickMode="nv"
       xmlns:range="http://schemas.android.com/apk/res/com.tencent.weread.eink" />
     <androidx.appcompat.widget.AppCompatImageButton android:id="@id/x5" android:background="@drawable/bp" android:layout_width="32.0dip" android:layout_height="32.0dip" android:layout_marginRight="28.0dip" android:scaleType="centerInside" app:layout_constraintBottom_toBottomOf="@id/x6" app:layout_constraintRight_toRightOf="tb" app:layout_constraintTop_toTopOf="@id/x6" />
     <androidx.appcompat.widget.AppCompatTextView android:textSize="15.0sp" android:textColor="@color/an" android:ellipsize="end" android:gravity="center" android:id="@id/wo" android:layout_width="0.0dip" android:layout_height="wrap_content" android:layout_marginLeft="20.0dip" android:layout_marginTop="4.0dip" android:layout_marginRight="20.0dip" android:singleLine="true" app:layout_constraintLeft_toLeftOf="tb" app:layout_constraintRight_toRightOf="tb" app:layout_constraintTop_toBottomOf="@id/x6" />

This way it compiles, but login layout is lost:

screenfail
(the stupid qrcode can't be scanned)

origin login layout:
screenok

@ahxxm

This comment has been minimized.

Copy link
Author

@ahxxm ahxxm commented Feb 28, 2020

without LC_ALL=C sed -i '' -e 's|res-auto|lib-auto|g' $(find . -name "*.xml"), start lines of error log:

W: ~/dev/wereadtmp/weread_android_1.1.1_10140948_900/res/layout/a0.xml:2: error: attribute paddingBottomNoButtons (aka com.tencent.weread.eink:paddingBottomNoButtons) not found.
W: ~/dev/wereadtmp/weread_android_1.1.1_10140948_900/res/layout/a0.xml:2: error: attribute paddingTopNoTitle (aka com.tencent.weread.eink:paddingTopNoTitle) not found.
W: ~/dev/wereadtmp/weread_android_1.1.1_10140948_900/res/layout/a4.xml:6: error: attribute textStyle (aka com.tencent.weread.eink:textStyle) not found.
W: ~/dev/wereadtmp/weread_android_1.1.1_10140948_900/res/layout/a6.xml:7: error: attribute separatorStyle (aka com.tencent.weread.eink:separatorStyle) not found.
W: ~/dev/wereadtmp/weread_android_1.1.1_10140948_900/res/layout/ad.xml:4: error: attribute logo (aka com.tencent.weread.eink:logo) not found.
W: ~/dev/wereadtmp/weread_android_1.1.1_10140948_900/res/layout/ad.xml:4: error: attribute navigationIcon (aka com.tencent.weread.eink:navigationIcon) not found.
W: ~/dev/wereadtmp/weread_android_1.1.1_10140948_900/res/layout/ad.xml:4: error: attribute titleTextColor (aka com.tencent.weread.eink:titleTextColor) not found.
W: ~/dev/wereadtmp/weread_android_1.1.1_10140948_900/res/layout/al.xml:7: error: attribute separatorStyle (aka com.tencent.weread.eink:separatorStyle) not found.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
1 participant
You can’t perform that action at this time.