ad 翻页效果
This commit is contained in:
parent
5825723362
commit
95546f9b90
|
@ -6,7 +6,7 @@
|
||||||
<uses-permission android:name="android.permission.INTERNET" /> <!-- <uses-permission android:name="android.permission.VIBRATE" /> -->
|
<uses-permission android:name="android.permission.INTERNET" /> <!-- <uses-permission android:name="android.permission.VIBRATE" /> -->
|
||||||
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
|
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
|
||||||
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
|
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
|
||||||
<!--<uses-permission android:name="android.permission.READ_PHONE_STATE" />-->
|
<uses-permission android:name="android.permission.READ_PHONE_STATE" />
|
||||||
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
|
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
|
||||||
<uses-permission android:name="android.permission.REQUEST_INSTALL_PACKAGES" />
|
<uses-permission android:name="android.permission.REQUEST_INSTALL_PACKAGES" />
|
||||||
<!-- chanshanjia-->
|
<!-- chanshanjia-->
|
||||||
|
|
|
@ -144,6 +144,7 @@ public class SplashActivity extends Activity implements WeakHandler.IHandler, Sp
|
||||||
} else if (Constants.AD_SETTING.getSplash2().getSource() == Constants.AD_TOUTIAO) {
|
} else if (Constants.AD_SETTING.getSplash2().getSource() == Constants.AD_TOUTIAO) {
|
||||||
// rid = R.layout.ad_toutiao_activity_splash;
|
// rid = R.layout.ad_toutiao_activity_splash;
|
||||||
// goToMainActivity();
|
// goToMainActivity();
|
||||||
|
finish();//头条不可作为返回全屏广告
|
||||||
return;
|
return;
|
||||||
}else if (Constants.AD_SETTING.getSplash2() .getSource() == Constants.AD_MOB) {
|
}else if (Constants.AD_SETTING.getSplash2() .getSource() == Constants.AD_MOB) {
|
||||||
// goToMainActivity();
|
// goToMainActivity();
|
||||||
|
@ -373,7 +374,7 @@ public class SplashActivity extends Activity implements WeakHandler.IHandler, Sp
|
||||||
private void checkAndRequestPermission() {
|
private void checkAndRequestPermission() {
|
||||||
List<String> lackedPermission = new ArrayList<String>();
|
List<String> lackedPermission = new ArrayList<String>();
|
||||||
if (!(checkSelfPermission(Manifest.permission.READ_PHONE_STATE) == PackageManager.PERMISSION_GRANTED)) {
|
if (!(checkSelfPermission(Manifest.permission.READ_PHONE_STATE) == PackageManager.PERMISSION_GRANTED)) {
|
||||||
lackedPermission.add(Manifest.permission.READ_PHONE_STATE);
|
lackedPermission.add(Manifest.permission.READ_PHONE_STATE);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!(checkSelfPermission(Manifest.permission.WRITE_EXTERNAL_STORAGE) == PackageManager.PERMISSION_GRANTED)) {
|
if (!(checkSelfPermission(Manifest.permission.WRITE_EXTERNAL_STORAGE) == PackageManager.PERMISSION_GRANTED)) {
|
||||||
|
|
|
@ -61,11 +61,11 @@ public class SplashAdManager implements Application.ActivityLifecycleCallbacks,
|
||||||
getAdMob(activity);
|
getAdMob(activity);
|
||||||
}
|
}
|
||||||
Log.d(TAG, "onActivityCreated:mInterstitialAd initialized ");
|
Log.d(TAG, "onActivityCreated:mInterstitialAd initialized ");
|
||||||
if(activity instanceof Main2Activity){
|
/* if(activity instanceof Main2Activity){
|
||||||
|
|
||||||
//showAd(activity);
|
//showAd(activity);
|
||||||
Log.d("zzr", " 启动应用");
|
Log.d("zzr", " 启动应用");
|
||||||
}
|
}*/
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -80,7 +80,7 @@ public class SplashAdManager implements Application.ActivityLifecycleCallbacks,
|
||||||
|
|
||||||
showSplashAd(activity);
|
showSplashAd(activity);
|
||||||
|
|
||||||
Log.d("zzr", "从广告页回到前台");
|
Log.d(TAG, "从广告页回到前台");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -160,8 +160,8 @@ public class SplashAdManager implements Application.ActivityLifecycleCallbacks,
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
long in = new Date().getTime() -lastAd;
|
long in = new Date().getTime() -lastAd;
|
||||||
int interVal = Constants.AD_SETTING.getSplash2().getInterval4Display()*1000;
|
int interVal = Constants.AD_SETTING.getSplash2().getInterval4Display()*10;
|
||||||
Log.d("zzr", "canShowAd: interval is, " +in + ", canshow? "+ (in >interVal));
|
Log.d(TAG, "canShowAd: interval is, " +in + ", canshow? "+ (in >interVal));
|
||||||
return in >interVal;
|
return in >interVal;
|
||||||
}
|
}
|
||||||
public static void setSplashTime(){ lastAd = new Date().getTime(); }
|
public static void setSplashTime(){ lastAd = new Date().getTime(); }
|
||||||
|
|
|
@ -97,6 +97,7 @@ import static com.novelbook.android.utils.Constants.AD_TOUTIAO;
|
||||||
|
|
||||||
public abstract class Activity_base extends AppCompatActivity implements NativeExpressAD.NativeExpressADListener {
|
public abstract class Activity_base extends AppCompatActivity implements NativeExpressAD.NativeExpressADListener {
|
||||||
|
|
||||||
|
private static final int MSG_AD_LOAD =10 ;
|
||||||
private static String TAG ="Activity_base";
|
private static String TAG ="Activity_base";
|
||||||
private ProgressDialog mProgressDialog;
|
private ProgressDialog mProgressDialog;
|
||||||
MyApp application;
|
MyApp application;
|
||||||
|
@ -304,6 +305,9 @@ public abstract class Activity_base extends AppCompatActivity implements Native
|
||||||
}else if (msg.what == MSG_VERSION_FAILE) {
|
}else if (msg.what == MSG_VERSION_FAILE) {
|
||||||
|
|
||||||
Toast.makeText(Activity_base.this, "版本检查失败", Toast.LENGTH_LONG).show();
|
Toast.makeText(Activity_base.this, "版本检查失败", Toast.LENGTH_LONG).show();
|
||||||
|
}else if (msg.what == MSG_AD_LOAD) {
|
||||||
|
|
||||||
|
attachAd();
|
||||||
}
|
}
|
||||||
|
|
||||||
hideProgress();
|
hideProgress();
|
||||||
|
@ -311,7 +315,9 @@ public abstract class Activity_base extends AppCompatActivity implements Native
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
protected void attachAd(){
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
class MyViewHolder extends RecyclerView.ViewHolder {
|
class MyViewHolder extends RecyclerView.ViewHolder {
|
||||||
|
@ -790,6 +796,9 @@ public abstract class Activity_base extends AppCompatActivity implements Native
|
||||||
// Log.d(TAG, "loadBannerAd: set banner VISIBLE,mShowAd " + mShowAd);
|
// Log.d(TAG, "loadBannerAd: set banner VISIBLE,mShowAd " + mShowAd);
|
||||||
//绑定原生广告的数据
|
//绑定原生广告的数据
|
||||||
setAdData(bannerContainer, bannerView, nativeAd);
|
setAdData(bannerContainer, bannerView, nativeAd);
|
||||||
|
|
||||||
|
handler.sendEmptyMessageDelayed( MSG_AD_LOAD,500);
|
||||||
|
|
||||||
// mTTAdNative.loadNativeAd(adSlot,null);
|
// mTTAdNative.loadNativeAd(adSlot,null);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -25,6 +25,7 @@ import com.novelbook.android.db.Chapter;
|
||||||
import com.novelbook.android.db.DownloadTask;
|
import com.novelbook.android.db.DownloadTask;
|
||||||
import com.novelbook.android.db.Novel;
|
import com.novelbook.android.db.Novel;
|
||||||
import com.novelbook.android.netutils.NetUtil;
|
import com.novelbook.android.netutils.NetUtil;
|
||||||
|
import com.novelbook.android.utils.Constants;
|
||||||
import com.novelbook.android.utils.PageFactory;
|
import com.novelbook.android.utils.PageFactory;
|
||||||
import com.umeng.analytics.MobclickAgent;
|
import com.umeng.analytics.MobclickAgent;
|
||||||
|
|
||||||
|
@ -100,6 +101,7 @@ public class CatalogFragment extends BasicFragment implements MarkActivity.Sortc
|
||||||
btnRefresh.setVisibility(View.VISIBLE);
|
btnRefresh.setVisibility(View.VISIBLE);
|
||||||
}else btnRefresh.setVisibility(View.GONE);
|
}else btnRefresh.setVisibility(View.GONE);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -343,5 +345,6 @@ public class CatalogFragment extends BasicFragment implements MarkActivity.Sortc
|
||||||
if (mProgressDialog2.isShowing()) {
|
if (mProgressDialog2.isShowing()) {
|
||||||
mProgressDialog2.dismiss();
|
mProgressDialog2.dismiss();
|
||||||
}
|
}
|
||||||
|
mSwipeRefresh.setRefreshing(false);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -104,11 +104,16 @@ public class Fragment_Shelf extends BasicFragment {
|
||||||
private void loadNovelsOnShelf() {
|
private void loadNovelsOnShelf() {
|
||||||
bookLists = Novel.getNovelsOnShelf();
|
bookLists = Novel.getNovelsOnShelf();
|
||||||
noveIds = "";
|
noveIds = "";
|
||||||
|
int i=0;
|
||||||
for (Novel novel : bookLists) {
|
for (Novel novel : bookLists) {
|
||||||
if (novel.isFinished() || novel.isLocalBook() || novel.isUpdated()) {
|
if (novel.isFinished() || novel.isLocalBook() || novel.isUpdated()) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
if(i>Constants.MAX_SHELF_CNT){
|
||||||
|
break;
|
||||||
|
}
|
||||||
noveIds += novel.getNovelId() + ",";
|
noveIds += novel.getNovelId() + ",";
|
||||||
|
i++;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -152,7 +157,7 @@ public class Fragment_Shelf extends BasicFragment {
|
||||||
*/
|
*/
|
||||||
private void getUpdatedData() {
|
private void getUpdatedData() {
|
||||||
|
|
||||||
|
loadNovelsOnShelf();
|
||||||
List<Integer> novelIds;
|
List<Integer> novelIds;
|
||||||
OnSuccessAndFaultListener successAndFaultListener = new OnSuccessAndFaultListener() {
|
OnSuccessAndFaultListener successAndFaultListener = new OnSuccessAndFaultListener() {
|
||||||
@Override
|
@Override
|
||||||
|
@ -167,7 +172,7 @@ public class Fragment_Shelf extends BasicFragment {
|
||||||
novel2.checkAndUpdate();
|
novel2.checkAndUpdate();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
loadNovelsOnShelf();
|
// loadNovelsOnShelf();
|
||||||
|
|
||||||
/* for(Novel nove : bookLists){
|
/* for(Novel nove : bookLists){
|
||||||
|
|
||||||
|
|
|
@ -12,11 +12,13 @@ import android.view.MenuItem;
|
||||||
import android.view.View;
|
import android.view.View;
|
||||||
import android.widget.ImageButton;
|
import android.widget.ImageButton;
|
||||||
import android.widget.ImageView;
|
import android.widget.ImageView;
|
||||||
|
import android.widget.TextView;
|
||||||
|
|
||||||
import com.flyco.tablayout.SlidingTabLayout;
|
import com.flyco.tablayout.SlidingTabLayout;
|
||||||
import com.novelbook.android.adapter.MyPagerAdapter;
|
import com.novelbook.android.adapter.MyPagerAdapter;
|
||||||
import com.novelbook.android.db.Chapter;
|
import com.novelbook.android.db.Chapter;
|
||||||
import com.novelbook.android.utils.Config;
|
import com.novelbook.android.utils.Config;
|
||||||
|
import com.novelbook.android.utils.Constants;
|
||||||
import com.novelbook.android.utils.PageFactory;
|
import com.novelbook.android.utils.PageFactory;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
|
@ -44,7 +46,8 @@ public class MarkActivity extends Activity_base {
|
||||||
ImageButton ibSort;
|
ImageButton ibSort;
|
||||||
@BindView(R.id.btnRefresh)
|
@BindView(R.id.btnRefresh)
|
||||||
ImageButton btnRefresh;*/
|
ImageButton btnRefresh;*/
|
||||||
|
@BindView(R.id.tvSource)
|
||||||
|
TextView tvSource;
|
||||||
|
|
||||||
private PageFactory pageFactory;
|
private PageFactory pageFactory;
|
||||||
/* private Config config;
|
/* private Config config;
|
||||||
|
@ -100,7 +103,7 @@ public class MarkActivity extends Activity_base {
|
||||||
if (getSupportActionBar() != null) {
|
if (getSupportActionBar() != null) {
|
||||||
getSupportActionBar().setTitle(pageFactory.getBookName());
|
getSupportActionBar().setTitle(pageFactory.getBookName());
|
||||||
}
|
}
|
||||||
|
tvSource.setText(String.format("以下目录及内容来自%s%s",pageFactory.getSite().getName(), Constants.SHOW_NOVEL_CHAPTER_URL ? pageFactory.getSite().getMuluUrl():""));
|
||||||
|
|
||||||
pager.setAdapter(new MyPagerAdapter(getSupportFragmentManager(),pageFactory.getNovle().getId()));
|
pager.setAdapter(new MyPagerAdapter(getSupportFragmentManager(),pageFactory.getNovle().getId()));
|
||||||
tabLayout.setViewPager(pager);
|
tabLayout.setViewPager(pager);
|
||||||
|
|
|
@ -8,9 +8,13 @@ import android.content.DialogInterface;
|
||||||
import android.content.Intent;
|
import android.content.Intent;
|
||||||
import android.content.IntentFilter;
|
import android.content.IntentFilter;
|
||||||
import android.database.SQLException;
|
import android.database.SQLException;
|
||||||
|
import android.graphics.Bitmap;
|
||||||
|
import android.graphics.Canvas;
|
||||||
|
import android.graphics.Color;
|
||||||
import android.graphics.Point;
|
import android.graphics.Point;
|
||||||
import android.graphics.Typeface;
|
import android.graphics.Typeface;
|
||||||
import android.os.Build;
|
import android.os.Build;
|
||||||
|
import android.os.Environment;
|
||||||
import android.os.Handler;
|
import android.os.Handler;
|
||||||
import android.os.Message;
|
import android.os.Message;
|
||||||
import android.support.annotation.Nullable;
|
import android.support.annotation.Nullable;
|
||||||
|
@ -68,6 +72,9 @@ import com.umeng.analytics.MobclickAgent;
|
||||||
|
|
||||||
import org.litepal.LitePal;
|
import org.litepal.LitePal;
|
||||||
|
|
||||||
|
import java.io.BufferedOutputStream;
|
||||||
|
import java.io.File;
|
||||||
|
import java.io.FileOutputStream;
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
import java.text.DecimalFormat;
|
import java.text.DecimalFormat;
|
||||||
import java.text.SimpleDateFormat;
|
import java.text.SimpleDateFormat;
|
||||||
|
@ -135,12 +142,16 @@ public class ReadActivity extends Activity_base implements AdInterface {
|
||||||
@BindView(R.id.imgLoading)
|
@BindView(R.id.imgLoading)
|
||||||
pl.droidsonroids.gif.GifImageView imgLoading;
|
pl.droidsonroids.gif.GifImageView imgLoading;
|
||||||
@BindView(R.id.frmAD)
|
@BindView(R.id.frmAD)
|
||||||
FrameLayout frmAD;
|
LinearLayout frmAD;
|
||||||
|
|
||||||
@BindView(R.id.native_banner_container )
|
@BindView(R.id.native_banner_container )
|
||||||
FrameLayout mNative_status_banner_container;
|
FrameLayout mNative_status_banner_container;
|
||||||
@BindView(R.id.banner_container )
|
@BindView(R.id.banner_container )
|
||||||
FrameLayout mBannerContainer;
|
FrameLayout mBannerContainer;
|
||||||
|
|
||||||
|
@BindView(R.id.frmContainer )
|
||||||
|
FrameLayout frmContainer;
|
||||||
|
|
||||||
@BindView(R.id.llShelfBottom)
|
@BindView(R.id.llShelfBottom)
|
||||||
LinearLayout llShelf;
|
LinearLayout llShelf;
|
||||||
private Config config;
|
private Config config;
|
||||||
|
@ -436,8 +447,13 @@ public class ReadActivity extends Activity_base implements AdInterface {
|
||||||
if (isShow || isSpeaking){
|
if (isShow || isSpeaking){
|
||||||
// return false;
|
// return false;
|
||||||
}
|
}
|
||||||
|
// bookpage.setetCurPage(loadBitmapFromView(frmContainer));
|
||||||
|
// bookpage.setFrmContainer(frmContainer);
|
||||||
|
|
||||||
|
Bitmap bitmap =loadBitmapFromView(frmContainer);
|
||||||
|
hideAd();
|
||||||
pageFactory.prePage();
|
pageFactory.prePage();
|
||||||
|
bookpage.setetCurPage( bitmap);
|
||||||
SplashAdManager.plusPage(ReadActivity.this);
|
SplashAdManager.plusPage(ReadActivity.this);
|
||||||
if (pageFactory.isfirstPage() || !pageFactory.isReady()) {
|
if (pageFactory.isfirstPage() || !pageFactory.isReady()) {
|
||||||
return false;
|
return false;
|
||||||
|
@ -457,9 +473,15 @@ public class ReadActivity extends Activity_base implements AdInterface {
|
||||||
if (isShow || isSpeaking){
|
if (isShow || isSpeaking){
|
||||||
// return false;
|
// return false;
|
||||||
}
|
}
|
||||||
|
//
|
||||||
|
// bookpage.setFrmContainer(frmContainer);
|
||||||
|
Bitmap bitmap =loadBitmapFromView(frmContainer);
|
||||||
|
|
||||||
|
hideAd();
|
||||||
pageFactory.nextPage();
|
pageFactory.nextPage();
|
||||||
|
bookpage.setetCurPage(bitmap);
|
||||||
SplashAdManager.plusPage(ReadActivity.this);
|
SplashAdManager.plusPage(ReadActivity.this);
|
||||||
|
Log.d(TAG, "onTouchEvent:set current bitmap set new bitmap");
|
||||||
if (pageFactory.islastPage() || !pageFactory.isReady()) {
|
if (pageFactory.islastPage() || !pageFactory.isReady()) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
@ -489,19 +511,104 @@ public class ReadActivity extends Activity_base implements AdInterface {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void hideAdBeforeIni() {
|
public void hideAdBeforeIni() {
|
||||||
// if(frmAD.getVisibility()== View.VISIBLE)
|
// hideAd();
|
||||||
// frmAD.setVisibility(View.INVISIBLE);
|
|
||||||
/* if(mBannerContainer.getVisibility()== View.VISIBLE)
|
|
||||||
mBannerContainer.setVisibility(View.GONE);*/
|
|
||||||
// mBannerContainer.removeAllViews();
|
|
||||||
// Log.d(TAG, "pageAnimation hideAdBeforeIni: ");
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
}
|
}
|
||||||
|
void hideAd () {
|
||||||
|
/* if(frmAD.getVisibility()== View.VISIBLE)
|
||||||
|
frmAD.setVisibility(View.INVISIBLE);*/
|
||||||
|
// if(mTopBannerContainer.getVisibility()== View.VISIBLE)
|
||||||
|
// mTopBannerContainer.setVisibility(View.INVISIBLE);
|
||||||
|
if(mBannerContainer.getVisibility()== View.VISIBLE)
|
||||||
|
mBannerContainer.setVisibility(View.GONE);
|
||||||
|
// mBannerContainer.removeAllViews();
|
||||||
|
// Log.d(TAG, "pageAnimation hideAdBeforeIni: ");
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
public Bitmap getBitmapWithAd(){
|
||||||
|
return loadBitmapFromView(frmContainer);
|
||||||
|
}
|
||||||
|
@Override
|
||||||
|
protected void attachAd(){
|
||||||
|
|
||||||
|
/* if(bookpage.isRunning()){
|
||||||
|
return;
|
||||||
|
|
||||||
|
}
|
||||||
|
Bitmap bitmap =loadBitmapFromView(frmContainer);
|
||||||
|
savePicture(bitmap);
|
||||||
|
pageFactory.getPageWidget(). setetCurPage(bitmap);
|
||||||
|
pageFactory.getPageWidget().setPageMode(config.getPageMode());
|
||||||
|
Log.d(TAG, "attachAd: ad attached");*/
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
private Bitmap loadBitmapFromView(View v) {
|
||||||
|
int w=v.getWidth();int h=v.getHeight();Bitmap bmp=Bitmap.createBitmap(w, h, Bitmap.Config.ARGB_8888);
|
||||||
|
Canvas c=new Canvas(bmp);
|
||||||
|
c.drawColor(Color.WHITE);/** 如果不设置canvas画布为白色,则生成透明 */
|
||||||
|
v.layout(0,0,w,h);
|
||||||
|
v.draw(c);
|
||||||
|
// savePicture(bmp,new Date().getTime()+".jpg");
|
||||||
|
return bmp;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
public void savePicture(Bitmap bm) {
|
||||||
|
String fileName =new Date().getTime()+".jpg";
|
||||||
|
if (bm == null) {
|
||||||
|
Toast.makeText(this, "savePicture null !", Toast.LENGTH_SHORT).show();
|
||||||
|
Log.d("SSSSSSSSSSS", "savePicture: savePicture null ");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
String PATH_LOGCAT = Environment.getExternalStorageDirectory()
|
||||||
|
.getAbsolutePath() + File.separator + "anovelbmp";
|
||||||
|
File foder = new File(PATH_LOGCAT);
|
||||||
|
if (!foder.exists()) {
|
||||||
|
foder.mkdirs();
|
||||||
|
}
|
||||||
|
File myCaptureFile = new File(foder, fileName);
|
||||||
|
try {
|
||||||
|
if (!myCaptureFile.exists()) {
|
||||||
|
myCaptureFile.createNewFile();
|
||||||
|
}
|
||||||
|
BufferedOutputStream bos = new BufferedOutputStream(new FileOutputStream(myCaptureFile));
|
||||||
|
bm.compress(Bitmap.CompressFormat.JPEG, 90, bos);
|
||||||
|
bos.flush();
|
||||||
|
bos.close();
|
||||||
|
} catch (IOException e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public static Bitmap convertViewToBitmap(View view){
|
||||||
|
view.measure(View.MeasureSpec.makeMeasureSpec(0, View.MeasureSpec.UNSPECIFIED), View.MeasureSpec.makeMeasureSpec(0, View.MeasureSpec.UNSPECIFIED));
|
||||||
|
view.layout(0, 0, view.getMeasuredWidth(), view.getMeasuredHeight());
|
||||||
|
view.buildDrawingCache();
|
||||||
|
Bitmap bitmap = view.getDrawingCache();
|
||||||
|
|
||||||
|
return bitmap;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Bitmap screenShot(View view) {
|
||||||
|
Log.d(TAG, "screenShot: .....");
|
||||||
|
view.setDrawingCacheEnabled(true);
|
||||||
|
view.buildDrawingCache();
|
||||||
|
Bitmap bmp = view.getDrawingCache();
|
||||||
|
|
||||||
|
|
||||||
|
Bitmap ret = Bitmap.createBitmap(bmp, 0, 0, Constants.SCREEN_WIDTH_PIX, Constants.SCREEN_HEIGHT_PIX);
|
||||||
|
view.destroyDrawingCache();
|
||||||
|
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
private Handler mHandler = new Handler() {
|
private Handler mHandler = new Handler() {
|
||||||
@Override
|
@Override
|
||||||
public void handleMessage(Message msg) {
|
public void handleMessage(Message msg) {
|
||||||
|
@ -1101,10 +1208,10 @@ public class ReadActivity extends Activity_base implements AdInterface {
|
||||||
}catch (Exception e){
|
}catch (Exception e){
|
||||||
Log.e(TAG, "loadBannerAd: ", e);
|
Log.e(TAG, "loadBannerAd: ", e);
|
||||||
}*/
|
}*/
|
||||||
if(mNative_status_banner_container.getVisibility() ==View.VISIBLE) {
|
/* if(mNative_status_banner_container.getVisibility() ==View.VISIBLE) {
|
||||||
Log.d(TAG, "loadBannerAd: hideStatusAds()");
|
Log.d(TAG, "loadBannerAd: hideStatusAds()");
|
||||||
mNative_status_banner_container.setVisibility(View.GONE);
|
mNative_status_banner_container.setVisibility(View.GONE);
|
||||||
}
|
}*/
|
||||||
// mBannerContainer.removeAllViews();
|
// mBannerContainer.removeAllViews();
|
||||||
// mBannerContainer.setBackgroundResource(R.color.transparent);
|
// mBannerContainer.setBackgroundResource(R.color.transparent);
|
||||||
}
|
}
|
||||||
|
@ -1144,7 +1251,7 @@ public class ReadActivity extends Activity_base implements AdInterface {
|
||||||
Log.d(TAG, String.format("loadBannerAd:showNativeBannerInLines height %s, adY %s ",height, adY/Constants.ONE_DP_SIZE ));
|
Log.d(TAG, String.format("loadBannerAd:showNativeBannerInLines height %s, adY %s ",height, adY/Constants.ONE_DP_SIZE ));
|
||||||
|
|
||||||
hideAdSlot(mBannerContainer);
|
hideAdSlot(mBannerContainer);
|
||||||
hideAdSlot(mNative_status_banner_container);
|
// hideAdSlot(mNative_status_banner_container);
|
||||||
if(height<=0){
|
if(height<=0){
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -1157,15 +1264,20 @@ public class ReadActivity extends Activity_base implements AdInterface {
|
||||||
if(mBannerContainer.getChildCount()>0) {
|
if(mBannerContainer.getChildCount()>0) {
|
||||||
mBannerContainer.removeAllViews();
|
mBannerContainer.removeAllViews();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
tmpFrame = new FrameLayout(this);
|
||||||
|
|
||||||
tmpFrame =mBannerContainer;
|
tmpFrame =mBannerContainer;
|
||||||
mLastBannerTime=0;
|
mLastBannerTime=0;
|
||||||
Log.d(TAG, String.format("loadBannerAd:showNativeBannerInLines to get ad, width %s, height %s ,adY %s ",Constants.SCREEN_WIDTH_PIX-50,height,adY));
|
Log.d(TAG, String.format("loadBannerAd:showNativeBannerInLines to get ad, width %s, height %s ,adY %s ",Constants.SCREEN_WIDTH_PIX-50,height,adY));
|
||||||
loadNativeBannerAd(mBannerContainer);
|
loadNativeBannerAd(tmpFrame);
|
||||||
FrameLayout.LayoutParams params = (FrameLayout.LayoutParams) mBannerContainer.getLayoutParams();
|
LinearLayout.LayoutParams params = (LinearLayout.LayoutParams)tmpFrame.getLayoutParams();
|
||||||
params.setMargins(10*Constants.ONE_DP_SIZE, adY+5*Constants.ONE_DP_SIZE, 10*Constants.ONE_DP_SIZE, 0*Constants.ONE_DP_SIZE);
|
params.setMargins(10*Constants.ONE_DP_SIZE, adY+5*Constants.ONE_DP_SIZE, 10*Constants.ONE_DP_SIZE, 0*Constants.ONE_DP_SIZE);
|
||||||
params.width =-1;
|
params.width =-1;
|
||||||
params.height = (int) getResources().getDimension(R.dimen.nativeBannerHeight);
|
params.height = (int) getResources().getDimension(R.dimen.nativeBannerHeight);
|
||||||
mBannerContainer.setLayoutParams(params);
|
tmpFrame.setLayoutParams(params);
|
||||||
|
tmpFrame.setVisibility(View.VISIBLE);
|
||||||
showAdSlot(mBannerContainer);
|
showAdSlot(mBannerContainer);
|
||||||
|
|
||||||
|
|
||||||
|
@ -1181,7 +1293,7 @@ public class ReadActivity extends Activity_base implements AdInterface {
|
||||||
// hideAdSlot(mBannerContainer);
|
// hideAdSlot(mBannerContainer);
|
||||||
Log.d(TAG, String.format("loadBannerAd:showTopBanner width %s, height %s ,adY %s ",Constants.SCREEN_WIDTH_PIX-50,adHeight,adY));
|
Log.d(TAG, String.format("loadBannerAd:showTopBanner width %s, height %s ,adY %s ",Constants.SCREEN_WIDTH_PIX-50,adHeight,adY));
|
||||||
//hideAdSlot(mBannerContainer);
|
//hideAdSlot(mBannerContainer);
|
||||||
hideAdSlot(mNative_status_banner_container);
|
// hideAdSlot(mNative_status_banner_container);
|
||||||
if(adHeight<=0){
|
if(adHeight<=0){
|
||||||
hideAdSlot(mTopBannerContainer);
|
hideAdSlot(mTopBannerContainer);
|
||||||
return;
|
return;
|
||||||
|
@ -1189,7 +1301,8 @@ public class ReadActivity extends Activity_base implements AdInterface {
|
||||||
|
|
||||||
int topMargin = adY >200*Constants.ONE_DP_SIZE ? adY -15*Constants.ONE_DP_SIZE :adY -5*Constants.ONE_DP_SIZE;
|
int topMargin = adY >200*Constants.ONE_DP_SIZE ? adY -15*Constants.ONE_DP_SIZE :adY -5*Constants.ONE_DP_SIZE;
|
||||||
|
|
||||||
FrameLayout.LayoutParams params = (FrameLayout.LayoutParams) mTopBannerContainer.getLayoutParams();
|
// FrameLayout.LayoutParams params = (FrameLayout.LayoutParams) mTopBannerContainer.getLayoutParams();
|
||||||
|
LinearLayout.LayoutParams params = (LinearLayout.LayoutParams) mTopBannerContainer.getLayoutParams();
|
||||||
loadBanner(mTopBannerContainer, Constants.SCREEN_WIDTH_PIX-50,adHeight);
|
loadBanner(mTopBannerContainer, Constants.SCREEN_WIDTH_PIX-50,adHeight);
|
||||||
// loadNativeBannerAd(mTopBannerContainer,BuildConfig.AD_SLOT_TOUTIAO_BANNER_NATIVE_ID, 304,200);
|
// loadNativeBannerAd(mTopBannerContainer,BuildConfig.AD_SLOT_TOUTIAO_BANNER_NATIVE_ID, 304,200);
|
||||||
params.setMargins(10*Constants.ONE_DP_SIZE, topMargin, 10*Constants.ONE_DP_SIZE, 0 );
|
params.setMargins(10*Constants.ONE_DP_SIZE, topMargin, 10*Constants.ONE_DP_SIZE, 0 );
|
||||||
|
@ -1230,7 +1343,7 @@ public class ReadActivity extends Activity_base implements AdInterface {
|
||||||
hideAdSlot(mBannerContainer);
|
hideAdSlot(mBannerContainer);
|
||||||
// hideAdSlot(mTopBannerContainer);
|
// hideAdSlot(mTopBannerContainer);
|
||||||
tmpFrame =mNative_status_banner_container;
|
tmpFrame =mNative_status_banner_container;
|
||||||
FrameLayout.LayoutParams params = (FrameLayout.LayoutParams) mNative_status_banner_container.getLayoutParams();
|
LinearLayout.LayoutParams params = (LinearLayout.LayoutParams) mNative_status_banner_container.getLayoutParams();
|
||||||
hideAdSlot(mNative_status_banner_container);
|
hideAdSlot(mNative_status_banner_container);
|
||||||
|
|
||||||
// mBannerContainer.removeAllViews();
|
// mBannerContainer.removeAllViews();
|
||||||
|
|
|
@ -16,8 +16,8 @@ public class AdSetting {
|
||||||
private slot fixBanner = new slot();
|
private slot fixBanner = new slot();
|
||||||
private slot bigBanner = new slot();
|
private slot bigBanner = new slot();
|
||||||
public boolean isShowAdsense() {
|
public boolean isShowAdsense() {
|
||||||
// return true;
|
return true;
|
||||||
return showAdsense && NetUtil.isNetworkConnected();
|
// return showAdsense && NetUtil.isNetworkConnected();
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setShowAdsense(boolean showAdsense) {
|
public void setShowAdsense(boolean showAdsense) {
|
||||||
|
@ -91,8 +91,8 @@ public class AdSetting {
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean isShow() {
|
public boolean isShow() {
|
||||||
// return true;
|
return true;
|
||||||
return show && NetUtil.isNetworkConnected();
|
// return show && NetUtil.isNetworkConnected();
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setShow(boolean show) {
|
public void setShow(boolean show) {
|
||||||
|
@ -100,8 +100,8 @@ public class AdSetting {
|
||||||
}
|
}
|
||||||
|
|
||||||
public int getSource() {
|
public int getSource() {
|
||||||
return source;
|
//return source;
|
||||||
// return 3 ;
|
return 1 ;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setSource(int source) {
|
public void setSource(int source) {
|
||||||
|
|
|
@ -4,6 +4,7 @@ package com.novelbook.android.db;
|
||||||
import android.text.TextUtils;
|
import android.text.TextUtils;
|
||||||
import android.util.Log;
|
import android.util.Log;
|
||||||
|
|
||||||
|
import com.novelbook.android.utils.CommonUtil;
|
||||||
import com.novelbook.android.utils.Constants;
|
import com.novelbook.android.utils.Constants;
|
||||||
|
|
||||||
import org.litepal.LitePal;
|
import org.litepal.LitePal;
|
||||||
|
@ -309,8 +310,8 @@ public class Novel extends LitePalSupport implements Serializable{
|
||||||
@Override
|
@Override
|
||||||
public int update(long id){
|
public int update(long id){
|
||||||
setValues();
|
setValues();
|
||||||
// checkAndUpdate();
|
// checkAndUpdate();
|
||||||
Log.d("checkshelf", String.format("checkshelf:novel %s going to update,isUpdated %s", getName() ,isUpdated));
|
Log.d("checkshelf", String.format("checkshelf:novel %s going to update,isUpdated %s,lastvist %s", getName() ,isUpdated, CommonUtil.getDateString(lastVisit )));
|
||||||
/* try {
|
/* try {
|
||||||
throw new Exception("check update");
|
throw new Exception("check update");
|
||||||
}catch (Exception e){
|
}catch (Exception e){
|
||||||
|
@ -342,11 +343,11 @@ public void testUpdate(){
|
||||||
) );
|
) );
|
||||||
// isUpdated = isUpdated && !(!TextUtils.isEmpty(chapterName) && !TextUtils.isEmpty(nv.chapterName) && (chapterName.equals(nv.lastReadChaptName) ));
|
// isUpdated = isUpdated && !(!TextUtils.isEmpty(chapterName) && !TextUtils.isEmpty(nv.chapterName) && (chapterName.equals(nv.lastReadChaptName) ));
|
||||||
// boolean isLastReadchaptUpdated = !TextUtils.isEmpty(chapterName) && !TextUtils.isEmpty(nv.lastReadChaptName) && !(chapterName.equals(nv.lastReadChaptName));
|
// boolean isLastReadchaptUpdated = !TextUtils.isEmpty(chapterName) && !TextUtils.isEmpty(nv.lastReadChaptName) && !(chapterName.equals(nv.lastReadChaptName));
|
||||||
boolean isLastReadchaptUpdated = TextUtils.isEmpty(nv.lastReadChaptName) || !(chapterName.equals(nv.lastReadChaptName));
|
boolean isLastReadchaptUpdated = TextUtils.isEmpty(nv.lastReadChaptName) || !(chapterName.equals(nv.lastReadChaptName)); //没看过最新章节
|
||||||
boolean isLastChaptUpdated = !TextUtils.isEmpty(chapterName) && !TextUtils.isEmpty(nv.chapterName) && !(chapterName.equals(nv.chapterName));
|
boolean isLastChaptUpdated = !TextUtils.isEmpty(chapterName) && !TextUtils.isEmpty(nv.chapterName) && !(chapterName.equals(nv.chapterName));
|
||||||
Log.d("Novel", String.format( " isupdated %s, server lastUpdateTime ,server chaptername %s,chaptername %s,lastreadchapt %s" ,isLastReadchaptUpdated,chapterName,nv.chapterName,nv.lastReadChaptName ) );
|
Log.d("Novel", String.format( " server lastUpdateTime ,server chaptername %s,chaptername %s,lastreadchapt %s" , chapterName,nv.chapterName,nv.lastReadChaptName ) );
|
||||||
|
|
||||||
isUpdated = isLastChaptUpdated && isLastReadchaptUpdated ;
|
isUpdated = isUpdated && isLastReadchaptUpdated || isLastChaptUpdated ;
|
||||||
|
|
||||||
Log.d("Novel", String.format( " isupdated %s, server lastUpdateTime isLastReadchaptUpdated %s,isLastChaptUpdated %s" ,isUpdated,isLastReadchaptUpdated,isLastChaptUpdated ) );
|
Log.d("Novel", String.format( " isupdated %s, server lastUpdateTime isLastReadchaptUpdated %s,isLastChaptUpdated %s" ,isUpdated,isLastReadchaptUpdated,isLastChaptUpdated ) );
|
||||||
if(!isUpdated){
|
if(!isUpdated){
|
||||||
|
|
|
@ -1,5 +1,7 @@
|
||||||
package com.novelbook.android.utils;
|
package com.novelbook.android.utils;
|
||||||
|
|
||||||
|
import android.graphics.Bitmap;
|
||||||
|
|
||||||
public interface AdInterface {
|
public interface AdInterface {
|
||||||
/**
|
/**
|
||||||
* 显示activity 上的广告
|
* 显示activity 上的广告
|
||||||
|
@ -17,4 +19,5 @@ public interface AdInterface {
|
||||||
public void hideReadSetting();
|
public void hideReadSetting();
|
||||||
public void showReadSetting();
|
public void showReadSetting();
|
||||||
public void hideStatusAds();
|
public void hideStatusAds();
|
||||||
|
public Bitmap getBitmapWithAd();
|
||||||
}
|
}
|
||||||
|
|
|
@ -1461,6 +1461,7 @@ int muluRetryCount =0;
|
||||||
}
|
}
|
||||||
*/
|
*/
|
||||||
}else if(msg.what==MSG_READBOOK_FAIL ) { //change source
|
}else if(msg.what==MSG_READBOOK_FAIL ) { //change source
|
||||||
|
if(pagefactory!=null)
|
||||||
pagefactory.drawStatus(PageFactory.Status.FAIL);
|
pagefactory.drawStatus(PageFactory.Status.FAIL);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -73,6 +73,7 @@ public class Constants {
|
||||||
|
|
||||||
public final static int MAX_PAGE_CNT =10;//最多加载的页数
|
public final static int MAX_PAGE_CNT =10;//最多加载的页数
|
||||||
public final static int MAX_SLEEP_4_CHAPT_DOWNLOAD =10000;//最多等待时间10s
|
public final static int MAX_SLEEP_4_CHAPT_DOWNLOAD =10000;//最多等待时间10s
|
||||||
|
public final static int MAX_SHELF_CNT =100;
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -195,6 +195,7 @@ public class PageFactory implements ChangeSource{
|
||||||
private final int MSG_NEXTPAGE_FAIL=4;
|
private final int MSG_NEXTPAGE_FAIL=4;
|
||||||
private final int MSG_HID_AD=5;
|
private final int MSG_HID_AD=5;
|
||||||
private final int MSG_SHOW_LOADING=5;
|
private final int MSG_SHOW_LOADING=5;
|
||||||
|
private int mLoadingChaptNo;
|
||||||
|
|
||||||
public AdInterface getmAd() {
|
public AdInterface getmAd() {
|
||||||
return mAd;
|
return mAd;
|
||||||
|
@ -541,7 +542,7 @@ public class PageFactory implements ChangeSource{
|
||||||
|
|
||||||
|
|
||||||
int bannerPagecnt = Constants.AD_SETTING.getChapterBanner().getPageCount4Display();
|
int bannerPagecnt = Constants.AD_SETTING.getChapterBanner().getPageCount4Display();
|
||||||
int nativeBannerPageCnt = Constants.AD_SETTING.getChapterContentBanner().getPageCount4Display();
|
int nativeBannerPageCnt =4;// Constants.AD_SETTING.getChapterContentBanner().getPageCount4Display();
|
||||||
if (Constants.AD_SETTING.getChapterContentBanner().isShow() &&
|
if (Constants.AD_SETTING.getChapterContentBanner().isShow() &&
|
||||||
nativeBannerPageCnt > 0 &&
|
nativeBannerPageCnt > 0 &&
|
||||||
mNavtiveBannerPlusCnt >= nativeBannerPageCnt) {
|
mNavtiveBannerPlusCnt >= nativeBannerPageCnt) {
|
||||||
|
@ -960,7 +961,8 @@ private void hideSysUI(){
|
||||||
}
|
}
|
||||||
Log.d(TAG, "drawStatus: mStatus is " +mStatus);
|
Log.d(TAG, "drawStatus: mStatus is " +mStatus);
|
||||||
if (mStatus==Status.OPENING ) {
|
if (mStatus==Status.OPENING ) {
|
||||||
String url = mBookUtil.getChapter(getNovel().getLastReadChapt()).getChapterUrl();
|
mLoadingChaptNo =mLoadingChaptNo >0?mLoadingChaptNo: getNovel().getLastReadChapt();
|
||||||
|
String url = mBookUtil.getChapter(mLoadingChaptNo).getChapterUrl();
|
||||||
Log.d(TAG, "drawStatus: url is " +url);
|
Log.d(TAG, "drawStatus: url is " +url);
|
||||||
if(!TextUtils.isEmpty(url)) {
|
if(!TextUtils.isEmpty(url)) {
|
||||||
if(url.length()>100)
|
if(url.length()>100)
|
||||||
|
@ -983,7 +985,7 @@ private void hideSysUI(){
|
||||||
if(Constants.SHOW_NOVEL_CHAPTER_URL) {
|
if(Constants.SHOW_NOVEL_CHAPTER_URL) {
|
||||||
c.drawText(url, targetRect.centerX(), baseline, waitPaint);
|
c.drawText(url, targetRect.centerX(), baseline, waitPaint);
|
||||||
}
|
}
|
||||||
String chaptName= mBookUtil.getChapter(getNovel().getLastReadChapt()).getChapterName();
|
String chaptName= mBookUtil.getChapter(mLoadingChaptNo).getChapterName();
|
||||||
if(!TextUtils.isEmpty(chaptName)) {
|
if(!TextUtils.isEmpty(chaptName)) {
|
||||||
if(chaptName.length()>100)
|
if(chaptName.length()>100)
|
||||||
chaptName =chaptName.substring(0,100);
|
chaptName =chaptName.substring(0,100);
|
||||||
|
@ -1285,8 +1287,7 @@ private void hideSysUI(){
|
||||||
c.drawText(chapterName, mWidth - marginWidth - nChaterWidth, statusMarginBottom + mBatterryFontSize, mBatterryPaint);
|
c.drawText(chapterName, mWidth - marginWidth - nChaterWidth, statusMarginBottom + mBatterryFontSize, mBatterryPaint);
|
||||||
|
|
||||||
}
|
}
|
||||||
if(mBookPageWidget!=null)
|
|
||||||
mBookPageWidget.postInvalidate();
|
|
||||||
if(currentPage!=null && currentPage.getPageNo()==1){
|
if(currentPage!=null && currentPage.getPageNo()==1){
|
||||||
|
|
||||||
String sn = getNovel().getDomainName();
|
String sn = getNovel().getDomainName();
|
||||||
|
@ -1306,6 +1307,17 @@ private void hideSysUI(){
|
||||||
c.drawText( Constants.announcement, marginWidth, statusMarginBottom + mBatterryFontSize+anny, mBatterryPaint);
|
c.drawText( Constants.announcement, marginWidth, statusMarginBottom + mBatterryFontSize+anny, mBatterryPaint);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
if(mBookPageWidget!=null) {
|
||||||
|
mBookPageWidget.postInvalidate();
|
||||||
|
/* if(mAd!=null)
|
||||||
|
new Handler().postDelayed(new Runnable() {
|
||||||
|
@Override
|
||||||
|
public void run() {
|
||||||
|
mBookPageWidget.setetCurPage(mAd.getBitmapWithAd());
|
||||||
|
mBookPageWidget.setPageMode(config.getPageMode());
|
||||||
|
}
|
||||||
|
}, 1000);*/
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public void showAd(){
|
public void showAd(){
|
||||||
|
@ -1365,7 +1377,7 @@ private void hideSysUI(){
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if(mStatus ==Status.LASTPAGE) {
|
if(mStatus ==Status.LASTPAGE) {
|
||||||
onDraw(mBookPageWidget.getCurPage(),currentPage ,true,false);
|
// onDraw(mBookPageWidget.getCurPage(),currentPage ,true,false);
|
||||||
if(mBookPageWidget==null){
|
if(mBookPageWidget==null){
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -1377,6 +1389,7 @@ private void hideSysUI(){
|
||||||
}
|
}
|
||||||
Log.d(TAG, " prePage() onDraw: mBookPageWidget.getNextPage() ");
|
Log.d(TAG, " prePage() onDraw: mBookPageWidget.getNextPage() ");
|
||||||
currentPage = getPrePage();
|
currentPage = getPrePage();
|
||||||
|
|
||||||
onDraw(mBookPageWidget.getNextPage(),currentPage ,true,true);
|
onDraw(mBookPageWidget.getNextPage(),currentPage ,true,true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1403,6 +1416,7 @@ private void hideSysUI(){
|
||||||
if(mBookUtil.getChapters().size()==0 &&NetUtil.isNetworkConnected()){
|
if(mBookUtil.getChapters().size()==0 &&NetUtil.isNetworkConnected()){
|
||||||
mBookUtil.setChapterNo(currentChapter+1);
|
mBookUtil.setChapterNo(currentChapter+1);
|
||||||
mStatus = Status.OPENING;
|
mStatus = Status.OPENING;
|
||||||
|
|
||||||
drawStatus();
|
drawStatus();
|
||||||
new Thread() {
|
new Thread() {
|
||||||
@Override
|
@Override
|
||||||
|
@ -1435,6 +1449,7 @@ private void hideSysUI(){
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
mLoadingChaptNo =currentChapter+1;
|
||||||
m_islastPage =currentChapter == mBookUtil.getChapters().size();// ||mBookUtil.getChapters().size()==0;
|
m_islastPage =currentChapter == mBookUtil.getChapters().size();// ||mBookUtil.getChapters().size()==0;
|
||||||
if ( m_islastPage){
|
if ( m_islastPage){
|
||||||
|
|
||||||
|
@ -1453,9 +1468,11 @@ private void hideSysUI(){
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
Log.d(TAG, "nextPage() onDraw: mBookPageWidget.getCurPage() ");
|
Log.d(TAG, "nextPage() onDraw: mBookPageWidget.getCurPage() ");
|
||||||
onDraw(mBookPageWidget.getCurPage(),currentPage ,true,false);
|
// onDraw(mBookPageWidget.getCurPage(),currentPage ,true,false);
|
||||||
|
Log.d(TAG, "nextpage:set current bitmap ..ondraw");
|
||||||
prePage = currentPage;
|
prePage = currentPage;
|
||||||
currentPage = getNextPage();
|
currentPage = getNextPage();
|
||||||
|
mLoadingChaptNo=0;
|
||||||
// currentPage = currentChaptPages.get(currentPage.getPageNo()-1);
|
// currentPage = currentChaptPages.get(currentPage.getPageNo()-1);
|
||||||
if(mBookPageWidget==null){
|
if(mBookPageWidget==null){
|
||||||
return;
|
return;
|
||||||
|
@ -1676,6 +1693,7 @@ private void hideSysUI(){
|
||||||
if(prePageNo <=0){
|
if(prePageNo <=0){
|
||||||
nextChaptPages =currentChaptPages;
|
nextChaptPages =currentChaptPages;
|
||||||
currentChapter--;
|
currentChapter--;
|
||||||
|
mLoadingChaptNo =currentChapter;
|
||||||
if(currentChapter ==0) {
|
if(currentChapter ==0) {
|
||||||
return new TRPage("没有内容了");
|
return new TRPage("没有内容了");
|
||||||
}
|
}
|
||||||
|
@ -1687,7 +1705,7 @@ private void hideSysUI(){
|
||||||
preReadChaptCache(currentChapter - 1);
|
preReadChaptCache(currentChapter - 1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
mLoadingChaptNo =0;
|
||||||
return currentChaptPages.get(prePageNo-1);
|
return currentChaptPages.get(prePageNo-1);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,8 +1,12 @@
|
||||||
package com.novelbook.android.view;
|
package com.novelbook.android.view;
|
||||||
|
|
||||||
|
import android.app.Activity;
|
||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
import android.graphics.Bitmap;
|
import android.graphics.Bitmap;
|
||||||
import android.graphics.Canvas;
|
import android.graphics.Canvas;
|
||||||
|
import android.graphics.Color;
|
||||||
|
import android.graphics.Paint;
|
||||||
|
import android.os.Environment;
|
||||||
import android.util.AttributeSet;
|
import android.util.AttributeSet;
|
||||||
import android.util.DisplayMetrics;
|
import android.util.DisplayMetrics;
|
||||||
import android.util.Log;
|
import android.util.Log;
|
||||||
|
@ -11,7 +15,9 @@ import android.view.View;
|
||||||
import android.view.ViewConfiguration;
|
import android.view.ViewConfiguration;
|
||||||
import android.view.WindowManager;
|
import android.view.WindowManager;
|
||||||
import android.view.animation.LinearInterpolator;
|
import android.view.animation.LinearInterpolator;
|
||||||
|
import android.widget.FrameLayout;
|
||||||
import android.widget.Scroller;
|
import android.widget.Scroller;
|
||||||
|
import android.widget.Toast;
|
||||||
|
|
||||||
import com.novelbook.android.utils.CommonUtil;
|
import com.novelbook.android.utils.CommonUtil;
|
||||||
import com.novelbook.android.utils.PageFactory;
|
import com.novelbook.android.utils.PageFactory;
|
||||||
|
@ -21,6 +27,12 @@ import com.novelbook.android.view.animation.NoneAnimation;
|
||||||
import com.novelbook.android.view.animation.SimulationAnimation;
|
import com.novelbook.android.view.animation.SimulationAnimation;
|
||||||
import com.novelbook.android.view.animation.SlideAnimation;
|
import com.novelbook.android.view.animation.SlideAnimation;
|
||||||
|
|
||||||
|
import java.io.BufferedOutputStream;
|
||||||
|
import java.io.File;
|
||||||
|
import java.io.FileOutputStream;
|
||||||
|
import java.io.IOException;
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
import static com.novelbook.android.utils.Config.*;
|
import static com.novelbook.android.utils.Config.*;
|
||||||
|
|
||||||
|
|
||||||
|
@ -55,6 +67,16 @@ public class PageWidget extends View {
|
||||||
private int mBgColor = 0xFFCEC29C;
|
private int mBgColor = 0xFFCEC29C;
|
||||||
private TouchListener mTouchListener;
|
private TouchListener mTouchListener;
|
||||||
|
|
||||||
|
public void setActivity(Activity activity) {
|
||||||
|
this.activity = activity;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setFrmContainer(FrameLayout frmContainer) {
|
||||||
|
this.frmContainer = frmContainer;
|
||||||
|
}
|
||||||
|
|
||||||
|
private FrameLayout frmContainer;
|
||||||
|
private Activity activity;
|
||||||
public PageWidget(Context context) {
|
public PageWidget(Context context) {
|
||||||
this(context,null);
|
this(context,null);
|
||||||
}
|
}
|
||||||
|
@ -82,8 +104,9 @@ public class PageWidget extends View {
|
||||||
mCurPageBitmap = Bitmap.createBitmap(mScreenWidth, mScreenHeight, Bitmap.Config.RGB_565); //android:LargeHeap=true use in manifest application
|
mCurPageBitmap = Bitmap.createBitmap(mScreenWidth, mScreenHeight, Bitmap.Config.RGB_565); //android:LargeHeap=true use in manifest application
|
||||||
mNextPageBitmap = Bitmap.createBitmap(mScreenWidth, mScreenHeight, Bitmap.Config.RGB_565);
|
mNextPageBitmap = Bitmap.createBitmap(mScreenWidth, mScreenHeight, Bitmap.Config.RGB_565);
|
||||||
}
|
}
|
||||||
|
int mPageMode =0;
|
||||||
public void setPageMode(int pageMode){
|
public void setPageMode(int pageMode){
|
||||||
|
mPageMode=pageMode;
|
||||||
switch (pageMode){
|
switch (pageMode){
|
||||||
case PAGE_MODE_SIMULATION:
|
case PAGE_MODE_SIMULATION:
|
||||||
mAnimationProvider = new SimulationAnimation(mCurPageBitmap,mNextPageBitmap,mScreenWidth,mScreenHeight);
|
mAnimationProvider = new SimulationAnimation(mCurPageBitmap,mNextPageBitmap,mScreenWidth,mScreenHeight);
|
||||||
|
@ -132,6 +155,14 @@ public class PageWidget extends View {
|
||||||
public Bitmap getCurPage(){
|
public Bitmap getCurPage(){
|
||||||
return mCurPageBitmap;
|
return mCurPageBitmap;
|
||||||
}
|
}
|
||||||
|
public void setetCurPage(Bitmap bitmap){
|
||||||
|
// mCurPageBitmap =bitmap;
|
||||||
|
mAnimationProvider.setetCurPage(bitmap);
|
||||||
|
}
|
||||||
|
public void setetNextPage(Bitmap bitmap){
|
||||||
|
// mCurPageBitmap =bitmap;
|
||||||
|
mAnimationProvider.setetNextPage(bitmap);
|
||||||
|
}
|
||||||
|
|
||||||
public Bitmap getNextPage(){
|
public Bitmap getNextPage(){
|
||||||
return mNextPageBitmap;
|
return mNextPageBitmap;
|
||||||
|
@ -145,7 +176,7 @@ public class PageWidget extends View {
|
||||||
protected void onDraw(Canvas canvas) {
|
protected void onDraw(Canvas canvas) {
|
||||||
// canvas.drawColor(0xFFAAAAAA);
|
// canvas.drawColor(0xFFAAAAAA);
|
||||||
canvas.drawColor(mBgColor);
|
canvas.drawColor(mBgColor);
|
||||||
// //Log.e("onDraw","isNext:" + isNext + " isRuning:" + isRuning);
|
Log.e("pagewidget onDraw","isMoveing isNext:" + isNext + " isRuning:" + isRuning);
|
||||||
if (isRuning) {
|
if (isRuning) {
|
||||||
mAnimationProvider.drawMove(canvas);
|
mAnimationProvider.drawMove(canvas);
|
||||||
} else {
|
} else {
|
||||||
|
@ -165,7 +196,7 @@ public class PageWidget extends View {
|
||||||
|
|
||||||
int x = (int)event.getX();
|
int x = (int)event.getX();
|
||||||
int y = (int)event.getY();
|
int y = (int)event.getY();
|
||||||
|
Log.d(TAG, String.format("onTouchEvent: x %s,y %s ",x,y));
|
||||||
mAnimationProvider.setTouchPoint(x,y);
|
mAnimationProvider.setTouchPoint(x,y);
|
||||||
if (event.getAction() == MotionEvent.ACTION_DOWN){ //mAnimationProvider.setCancel(false); https://github.com/PeachBlossom/treader/issues/4
|
if (event.getAction() == MotionEvent.ACTION_DOWN){ //mAnimationProvider.setCancel(false); https://github.com/PeachBlossom/treader/issues/4
|
||||||
downX = (int) event.getX();
|
downX = (int) event.getX();
|
||||||
|
@ -194,7 +225,9 @@ public class PageWidget extends View {
|
||||||
isMove = true;
|
isMove = true;
|
||||||
mTouchListener.hideAdBeforeIni() ;
|
mTouchListener.hideAdBeforeIni() ;
|
||||||
if (moveX == 0 && moveY ==0) {
|
if (moveX == 0 && moveY ==0) {
|
||||||
//Log.e(TAG,"isMove");
|
Log.e(TAG,"isMoveing");
|
||||||
|
|
||||||
|
|
||||||
//判断翻得是上一页还是下一页
|
//判断翻得是上一页还是下一页
|
||||||
if (x - downX >0){
|
if (x - downX >0){
|
||||||
isNext = false;
|
isNext = false;
|
||||||
|
@ -202,11 +235,13 @@ public class PageWidget extends View {
|
||||||
isNext = true;
|
isNext = true;
|
||||||
}
|
}
|
||||||
cancelPage = false;
|
cancelPage = false;
|
||||||
|
|
||||||
if (isNext) {
|
if (isNext) {
|
||||||
Boolean isNext = mTouchListener.nextPage();
|
Boolean isNext = mTouchListener.nextPage();
|
||||||
// calcCornerXY(downX,mScreenHeight);
|
// calcCornerXY(downX,mScreenHeight);
|
||||||
mAnimationProvider.setDirection(AnimationProvider.Direction.next);
|
mAnimationProvider.setDirection(AnimationProvider.Direction.next);
|
||||||
|
|
||||||
|
|
||||||
if (!isNext) {
|
if (!isNext) {
|
||||||
noNext = true;
|
noNext = true;
|
||||||
return true;
|
return true;
|
||||||
|
@ -220,6 +255,7 @@ public class PageWidget extends View {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//Log.e(TAG,"isNext:" + isNext);
|
//Log.e(TAG,"isNext:" + isNext);
|
||||||
}else{
|
}else{
|
||||||
//判断是否取消翻页
|
//判断是否取消翻页
|
||||||
|
@ -301,9 +337,11 @@ public class PageWidget extends View {
|
||||||
if (!noNext) {
|
if (!noNext) {
|
||||||
isRuning = true;
|
isRuning = true;
|
||||||
|
|
||||||
|
Log.d(TAG, "onTouchEvent: startanimation");
|
||||||
mAnimationProvider.startAnimation(mScroller);
|
mAnimationProvider.startAnimation(mScroller);
|
||||||
mTouchListener.showAdAfterIni();
|
mTouchListener.showAdAfterIni();
|
||||||
this.postInvalidate();
|
this.postInvalidate();
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -352,4 +390,7 @@ public class PageWidget extends View {
|
||||||
void hideAdBeforeIni();
|
void hideAdBeforeIni();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -95,5 +95,11 @@ public abstract class AnimationProvider {
|
||||||
public boolean getCancel(){
|
public boolean getCancel(){
|
||||||
return isCancel;
|
return isCancel;
|
||||||
}
|
}
|
||||||
|
public void setetCurPage(Bitmap bitmap){
|
||||||
|
mCurPageBitmap =bitmap;
|
||||||
|
}
|
||||||
|
public void setetNextPage(Bitmap bitmap){
|
||||||
|
mNextPageBitmap =bitmap;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -11,10 +11,12 @@ import android.graphics.PointF;
|
||||||
import android.graphics.Region;
|
import android.graphics.Region;
|
||||||
import android.graphics.drawable.GradientDrawable;
|
import android.graphics.drawable.GradientDrawable;
|
||||||
import android.os.Build;
|
import android.os.Build;
|
||||||
|
import android.util.Log;
|
||||||
import android.widget.Scroller;
|
import android.widget.Scroller;
|
||||||
|
|
||||||
|
|
||||||
public class SimulationAnimation extends AnimationProvider {
|
public class SimulationAnimation extends AnimationProvider {
|
||||||
|
private static final String TAG=SimulationAnimation.class.getSimpleName();
|
||||||
private int mCornerX = 1; // 拖拽点对应的页脚
|
private int mCornerX = 1; // 拖拽点对应的页脚
|
||||||
private int mCornerY = 1;
|
private int mCornerY = 1;
|
||||||
private Path mPath0;
|
private Path mPath0;
|
||||||
|
@ -84,6 +86,8 @@ public class SimulationAnimation extends AnimationProvider {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void drawMove(Canvas canvas) {
|
public void drawMove(Canvas canvas) {
|
||||||
|
|
||||||
|
Log.d(TAG, "isMoveing drawMove: ");
|
||||||
if (getDirection().equals(Direction.next)) {
|
if (getDirection().equals(Direction.next)) {
|
||||||
calcPoints();
|
calcPoints();
|
||||||
drawCurrentPageArea(canvas, mCurPageBitmap, mPath0);
|
drawCurrentPageArea(canvas, mCurPageBitmap, mPath0);
|
||||||
|
|
|
@ -23,12 +23,14 @@
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:src="@drawable/ic_format_line_spacing_black_24dp"
|
android:src="@drawable/ic_format_line_spacing_black_24dp"
|
||||||
style="@style/buttonCates"/>
|
style="@style/buttonCates"/>
|
||||||
</LinearLayout>-->
|
</LinearLayout>
|
||||||
<TextView
|
<LinearLayout
|
||||||
android:id="@+id/tvChapts"
|
|
||||||
style="@style/TextViewNovelTitle"
|
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content" />
|
android:layout_height="match_parent"
|
||||||
|
android:orientation="vertical"
|
||||||
|
>
|
||||||
|
-->
|
||||||
|
|
||||||
<android.support.v4.widget.SwipeRefreshLayout
|
<android.support.v4.widget.SwipeRefreshLayout
|
||||||
android:id="@+id/swipeLayout"
|
android:id="@+id/swipeLayout"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
|
@ -42,6 +44,7 @@
|
||||||
android:divider="@color/list_item_divider"
|
android:divider="@color/list_item_divider"
|
||||||
android:dividerHeight="1dp" />
|
android:dividerHeight="1dp" />
|
||||||
</android.support.v4.widget.SwipeRefreshLayout>
|
</android.support.v4.widget.SwipeRefreshLayout>
|
||||||
|
<!--</LinearLayout>-->
|
||||||
<Button
|
<Button
|
||||||
android:id="@+id/btnRefresh"
|
android:id="@+id/btnRefresh"
|
||||||
android:layout_width="100dp"
|
android:layout_width="100dp"
|
||||||
|
|
|
@ -51,14 +51,26 @@
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
style="@style/llOutside"
|
style="@style/llOutside"
|
||||||
android:orientation="vertical"
|
android:orientation="vertical"
|
||||||
android:layout_marginTop="-20dp"
|
android:layout_marginTop="-25dp"
|
||||||
app:layout_behavior="@string/appbar_scrolling_view_behavior">
|
app:layout_behavior="@string/appbar_scrolling_view_behavior">
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tvSource"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_gravity="center_vertical"
|
||||||
|
android:ellipsize="end"
|
||||||
|
|
||||||
|
android:lines="1"
|
||||||
|
android:padding="0dp"
|
||||||
|
android:background="@color/white"
|
||||||
|
android:text=""
|
||||||
|
android:textColor="@color/lightgray"
|
||||||
|
android:textSize="11sp" />
|
||||||
|
|
||||||
<com.flyco.tablayout.SlidingTabLayout
|
<com.flyco.tablayout.SlidingTabLayout
|
||||||
android:id="@+id/tab_layout"
|
android:id="@+id/tab_layout"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="40dp"
|
android:layout_height="35dp"
|
||||||
android:background="@color/white"
|
android:background="@color/white"
|
||||||
app:tl_indicator_color="@color/tabSelected"
|
app:tl_indicator_color="@color/tabSelected"
|
||||||
app:tl_indicator_corner_radius="1.5dp"
|
app:tl_indicator_corner_radius="1.5dp"
|
||||||
|
@ -67,6 +79,7 @@
|
||||||
app:tl_textSelectColor="@color/tabSelected"
|
app:tl_textSelectColor="@color/tabSelected"
|
||||||
app:tl_textUnselectColor="@color/grey"
|
app:tl_textUnselectColor="@color/grey"
|
||||||
app:tl_tab_space_equal ="true"
|
app:tl_tab_space_equal ="true"
|
||||||
|
android:paddingBottom="5dp"
|
||||||
/>
|
/>
|
||||||
<android.support.v4.view.ViewPager
|
<android.support.v4.view.ViewPager
|
||||||
android:id="@+id/pager"
|
android:id="@+id/pager"
|
||||||
|
|
|
@ -11,6 +11,7 @@
|
||||||
android:clipToPadding="false" android:fitsSystemWindows="true"
|
android:clipToPadding="false" android:fitsSystemWindows="true"
|
||||||
-->
|
-->
|
||||||
<FrameLayout
|
<FrameLayout
|
||||||
|
android:id="@+id/frmContainer"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent">
|
android:layout_height="match_parent">
|
||||||
|
|
||||||
|
@ -43,7 +44,7 @@
|
||||||
android:gravity="bottom"
|
android:gravity="bottom"
|
||||||
android:lines="1"
|
android:lines="1"
|
||||||
android:paddingLeft="10dp"
|
android:paddingLeft="10dp"
|
||||||
android:text="http://abc.om..fd"
|
android:text=""
|
||||||
android:textColor="@color/whitesmoke"
|
android:textColor="@color/whitesmoke"
|
||||||
android:textSize="11sp" />
|
android:textSize="11sp" />
|
||||||
</android.support.design.widget.AppBarLayout>
|
</android.support.design.widget.AppBarLayout>
|
||||||
|
@ -89,7 +90,7 @@
|
||||||
|
|
||||||
</LinearLayout>-->
|
</LinearLayout>-->
|
||||||
|
|
||||||
<FrameLayout
|
<LinearLayout
|
||||||
android:id="@+id/frmAD"
|
android:id="@+id/frmAD"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
|
@ -123,7 +124,7 @@
|
||||||
|
|
||||||
android:visibility="visible" /> <!-- -->
|
android:visibility="visible" /> <!-- -->
|
||||||
|
|
||||||
</FrameLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:id="@+id/llShelfBottom"
|
android:id="@+id/llShelfBottom"
|
||||||
|
|
|
@ -20,7 +20,7 @@
|
||||||
<string name="title_activity_book">BookActivity</string>
|
<string name="title_activity_book">BookActivity</string>
|
||||||
<string name="dummy_button">Dummy Button</string>
|
<string name="dummy_button">Dummy Button</string>
|
||||||
<string name="dummy_content">DUMMY\nCONTENT</string>
|
<string name="dummy_content">DUMMY\nCONTENT</string>
|
||||||
<string name="announce">
|
<string name="announce1">
|
||||||
" 鉴于本服务以非人工检索方式提供无线搜索、根据您输入的关键字自动生成到第三方网页的链接,本服务会提供与其他任何互联网网站或资源的链接。由于本软件无法控制这些网站或资源的内容,您了解并同意:无论此类网站或资源是否可供利用,本软件不予负责;本软件亦对存在或源于此类网站或资源之任何内容、广告、产品或其他资料不予保证或负责。因您使用或依赖任何此类网站或资源发布的或经由此类网站或资源获得的任何内容、商品或服务所产生的任何损害或损失,本软件不负任何直接或间接责任。
|
" 鉴于本服务以非人工检索方式提供无线搜索、根据您输入的关键字自动生成到第三方网页的链接,本服务会提供与其他任何互联网网站或资源的链接。由于本软件无法控制这些网站或资源的内容,您了解并同意:无论此类网站或资源是否可供利用,本软件不予负责;本软件亦对存在或源于此类网站或资源之任何内容、广告、产品或其他资料不予保证或负责。因您使用或依赖任何此类网站或资源发布的或经由此类网站或资源获得的任何内容、商品或服务所产生的任何损害或损失,本软件不负任何直接或间接责任。
|
||||||
|
|
||||||
因本服务搜索结果根据您键入的关键字自动搜索获得并生成,不代表本软件赞成被搜索链接到的第三方网页上的内容或立场。
|
因本服务搜索结果根据您键入的关键字自动搜索获得并生成,不代表本软件赞成被搜索链接到的第三方网页上的内容或立场。
|
||||||
|
@ -39,6 +39,15 @@
|
||||||
|
|
||||||
若您和本软件之间发生任何纠纷或争议,首先应友好协商解决;协商不成的,您同意将纠纷或争议提交本软件所在地的人民法院处理。"
|
若您和本软件之间发生任何纠纷或争议,首先应友好协商解决;协商不成的,您同意将纠纷或争议提交本软件所在地的人民法院处理。"
|
||||||
</string>
|
</string>
|
||||||
|
<string name="announce">
|
||||||
|
" 本软件皆在为广大小说爱好者提供小说的搜索、链接服务。但软件本身不会对链接于第三方的搜索结果作任何形式的编辑、修改或存储,用户应该自行判断链接于第三方网站上的内容的真实性、完整性、准确性,本软件对用户因此造成的损失不承担任何责任。
|
||||||
|
|
||||||
|
为更好的提升在手机终端的阅读体验,本软件同时提供阅读技术转码服务,用户可以自由的选择使用或不使用此服务。
|
||||||
|
|
||||||
|
通过本软件获得的内容仅限用户个人学习、研究、欣赏,此外的任何使用行为(复制、转载等)用户均应自行获得相关权利人的许可,否则应承担全部法律责任。
|
||||||
|
|
||||||
|
用户可以免费下载、安装、使用本软件,但未经许可不得对本软件进行任何形式的方向工程、反向编译、反向汇编;不得使用任何插件、外挂等非法工具接入本软件及系统;不得擅自复制、增加、删除本软件的数据。"
|
||||||
|
</string>
|
||||||
<string name="title_activity_main5">Main5Activity</string>
|
<string name="title_activity_main5">Main5Activity</string>
|
||||||
<string name="title_on_shelf">加入书架</string>
|
<string name="title_on_shelf">加入书架</string>
|
||||||
<string name="title_read">立即阅读</string>
|
<string name="title_read">立即阅读</string>
|
||||||
|
|
Loading…
Reference in New Issue