Commit d09fd8f6 authored by mengcuiguang's avatar mengcuiguang

添加新闻sdk

parent 004f71b7
...@@ -241,6 +241,11 @@ dependencies { ...@@ -241,6 +241,11 @@ dependencies {
// 瑞狮新闻 // 瑞狮新闻
implementation 'com.tencent.mm.opensdk:wechat-sdk-android-without-mta:+' implementation 'com.tencent.mm.opensdk:wechat-sdk-android-without-mta:+'
implementation(name: 'xrsdk-release_tbs', ext: 'aar') implementation(name: 'xrsdk-release_tbs', ext: 'aar')
implementation(name: 'xrsharesdk-release_tbs', ext: 'aar')
implementation(name: 'windAd-2.25.0', ext: 'aar')
implementation 'com.scwang.smart:refresh-layout-kernel:2.0.3'
implementation 'com.scwang.smart:refresh-header-classics:2.0.3'
implementation 'com.scwang.smart:refresh-footer-classics:2.0.3'
// 枫岚 // 枫岚
implementation(name: 'mh-adsdk', ext: 'aar') implementation(name: 'mh-adsdk', ext: 'aar')
implementation(name: 'mh-adsdk-ext', ext: 'aar') implementation(name: 'mh-adsdk-ext', ext: 'aar')
......
No preview for this file type
...@@ -495,9 +495,24 @@ ...@@ -495,9 +495,24 @@
# ===================== 瑞狮新闻 START ================ # ===================== 瑞狮新闻 START ================
-keep class com.xr.xrsdk.** { *;}
-keep class com.xr.sharesdk.** { *;}
-keep class com.tencent.** {*;} -keep class com.tencent.** {*;}
-keep class com.qq.e.** {public protected *;} -keep class com.qq.e.** {public protected *;}
-keep class com.xr.xrsdk.** { *;} -keepclassmembers class * extends android.app.Activity {
public void *(android.view.View);
}
-keepclassmembers enum * {
public static **[] values();
public static ** valueOf(java.lang.String);
}
-keep class com.baidu.mobads.** { *; }
-keep class com.baidu.mobad.** { *; }
-keep class com.bun.miitmdid.core.** {*;}
# WindAd
-keep class sun.misc.Unsafe { *; }
-dontwarn com.sigmob.**
-keep class com.sigmob.**.**{*;}
# ======================= 瑞狮新闻 END ================ # ======================= 瑞狮新闻 END ================
......
...@@ -394,6 +394,21 @@ ...@@ -394,6 +394,21 @@
</provider> </provider>
<!-- sigmob -->
<activity
android:name="com.sigmob.sdk.base.common.AdActivity"
android:configChanges="keyboardHidden|orientation|screenSize"
android:theme="@android:style/Theme.DeviceDefault" />
<provider
android:name="com.sigmob.sdk.SigmobFileProvider"
android:authorities="${applicationId}.sigprovider"
android:exported="false"
android:grantUriPermissions="true">
<meta-data
android:name="android.support.FILE_PROVIDER_PATHS"
android:resource="@xml/sigmob_provider_paths" />
</provider>
<!-- 来电秀 --> <!-- 来电秀 -->
<service <service
android:name=".call.service.PhoneListenService" android:name=".call.service.PhoneListenService"
......
...@@ -17,11 +17,11 @@ object RsNewsManager { ...@@ -17,11 +17,11 @@ object RsNewsManager {
* 初始化 * 初始化
*/ */
fun init(application: Application) { fun init(application: Application) {
XRNewsManager.getInstance().init(application, APP_ID, UserManager.getInstance().userID,WX_APP_ID) XRNewsManager.getInstance().init(application, APP_ID, WX_APP_ID)
} }
fun initX5Environment(application: Application){ fun initX5Environment(application: Application){
QbSdk.initX5Environment(application, null) QbSdk.initX5Environment(application, null)
XRNewsManager.getInstance().init(application, APP_ID, UserManager.getInstance().userID,WX_APP_ID) XRNewsManager.getInstance().init(application, APP_ID, WX_APP_ID)
} }
} }
...@@ -7,6 +7,7 @@ import com.mints.fairyland.R ...@@ -7,6 +7,7 @@ import com.mints.fairyland.R
import com.mints.fairyland.common.Constant import com.mints.fairyland.common.Constant
import com.mints.fairyland.ui.activitys.base.BaseActivity import com.mints.fairyland.ui.activitys.base.BaseActivity
import com.mints.fairyland.ui.fragment.* import com.mints.fairyland.ui.fragment.*
import com.mints.fairyland.ui.widgets.seekbar.BubbleUtils
import kotlinx.android.synthetic.main.activity_wrapper.* import kotlinx.android.synthetic.main.activity_wrapper.*
import kotlinx.android.synthetic.main.header_layout.* import kotlinx.android.synthetic.main.header_layout.*
...@@ -48,6 +49,9 @@ class WrapperActivity : BaseActivity(), View.OnClickListener { ...@@ -48,6 +49,9 @@ class WrapperActivity : BaseActivity(), View.OnClickListener {
var currentFragment: Fragment? var currentFragment: Fragment?
when (wrapperType) { when (wrapperType) {
Constant.WRAPPER_TYPE_NEWS -> { Constant.WRAPPER_TYPE_NEWS -> {
layoutWrapper.visibility = View.INVISIBLE
val layoutParams = layoutWrapper.layoutParams
layoutParams.height= BubbleUtils.dp2px(30)
tv_title.text = "新闻" tv_title.text = "新闻"
currentFragment = RsNewsFragment() currentFragment = RsNewsFragment()
} }
......
...@@ -3,6 +3,7 @@ package com.mints.fairyland.ui.fragment ...@@ -3,6 +3,7 @@ package com.mints.fairyland.ui.fragment
import android.os.Bundle import android.os.Bundle
import com.mints.fairyland.R import com.mints.fairyland.R
import com.mints.fairyland.common.Constant import com.mints.fairyland.common.Constant
import com.mints.fairyland.manager.UserManager
import com.mints.fairyland.mvp.presenters.RsNewsPresenter import com.mints.fairyland.mvp.presenters.RsNewsPresenter
import com.mints.fairyland.mvp.views.RsNewsView import com.mints.fairyland.mvp.views.RsNewsView
import com.mints.fairyland.ui.activitys.AwardActivity import com.mints.fairyland.ui.activitys.AwardActivity
...@@ -25,7 +26,7 @@ class RsNewsFragment : LazyLoadBaseFragment(), RsNewsView, FinishReadNewsCallBac ...@@ -25,7 +26,7 @@ class RsNewsFragment : LazyLoadBaseFragment(), RsNewsView, FinishReadNewsCallBac
override fun onFragmentFirstVisible() { override fun onFragmentFirstVisible() {
rsNewsPresenter.attachView(this) rsNewsPresenter.attachView(this)
XRNewsManager.getInstance().addNewsFragment(supportFragmentManager, R.id.flMainRsNews, Constant.FRAGMENT_TAG_RSNEWS, this) XRNewsManager.getInstance().addNewsFragment(supportFragmentManager, R.id.flMainRsNews, Constant.FRAGMENT_TAG_RSNEWS, UserManager.getInstance().userID, this)
} }
override fun onDestroy() { override fun onDestroy() {
...@@ -35,13 +36,13 @@ class RsNewsFragment : LazyLoadBaseFragment(), RsNewsView, FinishReadNewsCallBac ...@@ -35,13 +36,13 @@ class RsNewsFragment : LazyLoadBaseFragment(), RsNewsView, FinishReadNewsCallBac
} }
override fun readSecondsSuc(coin: Int, video: Int, supr: Int) { override fun readSecondsSuc(coin: Int, video: Int, supr: Int) {
if (activity != null && !activity!!.isFinishing && coin > 0 && supr > 0) { // if (activity != null && !activity!!.isFinishing && coin > 0 && supr > 0) {
val bundle = Bundle() // val bundle = Bundle()
bundle.putString(Constant.MAIN_CARRIER_TYPE, Constant.CARRIER_RUISHINEWS) // bundle.putString(Constant.MAIN_CARRIER_TYPE, Constant.CARRIER_RUISHINEWS)
bundle.putInt(Constant.MAIN_CUR_COIN, coin) // bundle.putInt(Constant.MAIN_CUR_COIN, coin)
bundle.putString(Constant.MAIN_EXTRA_ID, video.toString()) // bundle.putString(Constant.MAIN_EXTRA_ID, video.toString())
readyGo(AwardActivity::class.java, bundle) // readyGo(AwardActivity::class.java, bundle)
} // }
} }
override fun finishRead(id: String, seconds: Int) { override fun finishRead(id: String, seconds: Int) {
......
...@@ -8,6 +8,6 @@ ...@@ -8,6 +8,6 @@
<item android:bottom="20dp"> <item android:bottom="20dp">
<bitmap <bitmap
android:gravity="bottom|center_horizontal" android:gravity="bottom|center_horizontal"
android:src="@drawable/bg_splash" /> android:src="@drawable/ic_launcher_main" />
</item> </item>
</layer-list> </layer-list>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment