适配英文排版

pull/5/head
fengyuecanzhu 4 years ago
parent 389d80bd76
commit ea5d34b659
  1. 4
      app/src/main/assets/updatelog.fy
  2. 32
      app/src/main/java/xyz/fycz/myreader/ui/activity/DonateActivity.java
  3. 5
      app/src/main/java/xyz/fycz/myreader/util/utils/AdUtils.java
  4. 2
      app/src/main/java/xyz/fycz/myreader/widget/page/PageLoader.java
  5. 24
      app/src/main/res/layout/activity_donate.xml
  6. 2
      app/src/main/res/values/strings.xml

@ -1,3 +1,7 @@
风月读书v1.9.6
更新内容:
1、适配英文书籍排版(建议使用等距排版)
2021.05.09
风月读书v1.9.5
更新内容:

@ -8,6 +8,8 @@ import android.view.View;
import androidx.appcompat.widget.Toolbar;
import com.weaction.ddsdk.ad.DdSdkFlowAd;
import com.weaction.ddsdk.ad.DdSdkInterAd;
import com.weaction.ddsdk.ad.DdSdkInterVideoAd;
import com.weaction.ddsdk.ad.DdSdkRewardAd;
import java.util.List;
@ -117,6 +119,36 @@ public class DonateActivity extends BaseActivity {
}
});
});
binding.llInterAd.setOnClickListener(v -> {
/*
* 参数 1 activity
* 参数 2 marginDp (float)插屏默认 margin 全屏幕的 24dp此处允许开发者手动调节 margin 大小单位为 dp允许范围为 0dp (全屏) ~ 48dp请开发者按需填写
*/
DdSdkInterAd.show(this, 48f, new DdSdkInterAd.Callback() {
@Override
public void show() {
Log.i(TAG, "插屏广告展示成功");
AdUtils.adRecord("inter","adShow");
}
@Override
public void click() {
Log.i(TAG, "插屏广告");
AdUtils.adRecord("inter","adClick");
}
@Override
public void error(String msg) {
}
@Override
public void close() {
Log.i(TAG, "插屏广告被关闭");
AdUtils.adRecord("inter","adClose");
}
});
});
}

@ -125,10 +125,7 @@ public class AdUtils {
public static void initAd() {
if (!hasInitAd) {
hasInitAd = true;
DdSdkHelper.init("1234", "216", "51716a16fbdf50905704b6575b1b3b60",
"142364", "35ce0efe5f3cc960b116db227498e238",
"8167", "85bd159309c3da1b",
App.getApplication(), true);
}
}
}

@ -1673,7 +1673,7 @@ public abstract class PageLoader {
}
// 重置段落
if (!showTitle) {
paragraph = paragraph.replaceAll("\\s", "").trim();
paragraph = paragraph.replaceAll("[ | ]", " ").trim();
// 如果只有换行符,那么就不执行
if (paragraph.equals("")) continue;
paragraph = indent + paragraph + "\n";

@ -150,7 +150,30 @@
android:text="@string/flow_ad_tip"
android:textColor="@color/textSecondary" />
</RelativeLayout>
<LinearLayout
android:id="@+id/ll_inter_ad"
android:layout_width="match_parent"
android:layout_height="60dp"
android:background="@drawable/selector_common_bg"
android:orientation="vertical"
android:paddingLeft="20dp"
android:paddingTop="8dp"
android:paddingRight="20dp">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/inter_ad"
android:textColor="@color/textSecondary"
android:textSize="@dimen/text_normal_size" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:paddingTop="5dp"
android:text="@string/donate_tip"
android:textColor="@color/textAssist" />
</LinearLayout>
<LinearLayout
android:id="@+id/ll_rewarded_video"
android:layout_width="match_parent"
@ -175,6 +198,7 @@
android:text="@string/donate_tip"
android:textColor="@color/textAssist" />
</LinearLayout>
</LinearLayout>

@ -478,6 +478,8 @@
<string name="select_local_pic">选择本地图片</string>
<string name="menu_edit">编辑书籍</string>
<string name="skip_ad">跳过 | %ds</string>
<string name="inter_ad">插屏广告</string>
<string name="inter_video">插屏视频</string>
<string-array name="reset_screen_time">
<item>跟随系统</item>

Loading…
Cancel
Save