Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Sign in / Register
Toggle navigation
P
PDF Viewer Scanner White
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wanglei
PDF Viewer Scanner White
Commits
096d0d0c
Commit
096d0d0c
authored
Apr 12, 2025
by
guest
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改上报参数
parent
53c8cb50
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
48 additions
and
11 deletions
+48
-11
AndroidManifest.xml
app/src/main/AndroidManifest.xml
+1
-6
EventUtils.kt
.../java/com/base/pdfviewerscannerwhite/helper/EventUtils.kt
+27
-2
MyApplication.kt
...va/com/base/pdfviewerscannerwhite/helper/MyApplication.kt
+20
-3
No files found.
app/src/main/AndroidManifest.xml
View file @
096d0d0c
...
@@ -211,12 +211,7 @@
...
@@ -211,12 +211,7 @@
android:screenOrientation=
"portrait"
android:screenOrientation=
"portrait"
tools:ignore=
"DiscouragedApi,LockedOrientationActivity"
/>
tools:ignore=
"DiscouragedApi,LockedOrientationActivity"
/>
<activity
android:name=
".ui.webview.WebBrowserActivity"
android:exported=
"false"
android:launchMode=
"singleTop"
android:screenOrientation=
"portrait"
tools:ignore=
"DiscouragedApi,LockedOrientationActivity"
/>
<provider
<provider
android:name=
"androidx.core.content.FileProvider"
android:name=
"androidx.core.content.FileProvider"
...
...
app/src/main/java/com/base/pdfviewerscannerwhite/helper/EventUtils.kt
View file @
096d0d0c
...
@@ -10,6 +10,7 @@ import com.base.pdfviewerscannerwhite.utils.AppPreferences
...
@@ -10,6 +10,7 @@ import com.base.pdfviewerscannerwhite.utils.AppPreferences
import
com.base.pdfviewerscannerwhite.utils.LogEx
import
com.base.pdfviewerscannerwhite.utils.LogEx
import
org.json.JSONException
import
org.json.JSONException
import
org.json.JSONObject
import
org.json.JSONObject
import
java.util.Locale
object
EventUtils
{
object
EventUtils
{
private
val
TAG
=
"EventUtils"
private
val
TAG
=
"EventUtils"
...
@@ -45,8 +46,8 @@ object EventUtils {
...
@@ -45,8 +46,8 @@ object EventUtils {
.
put
(
"value"
,
value
)
.
put
(
"value"
,
value
)
.
put
(
"ext"
,
ext
)
.
put
(
"ext"
,
ext
)
val
s2
=
JSONObject
()
val
s2
=
JSONObject
()
.
put
(
"${pkg}_3"
,
AppPreferences
.
getInstance
().
getString
(
"Equipment"
,
""
))
.
put
(
"${pkg}_3"
,
getDeviceName
(
))
.
put
(
"${pkg}_4"
,
AppPreferences
.
getInstance
().
getString
(
"Manufacturer"
,
""
)
)
.
put
(
"${pkg}_4"
,
Build
.
MANUFACTURER
)
.
put
(
"${pkg}_5"
,
Build
.
VERSION
.
SDK_INT
)
.
put
(
"${pkg}_5"
,
Build
.
VERSION
.
SDK_INT
)
.
put
(
"${pkg}_9"
,
AppPreferences
.
getInstance
().
getString
(
"uuid"
,
""
))
.
put
(
"${pkg}_9"
,
AppPreferences
.
getInstance
().
getString
(
"uuid"
,
""
))
.
put
(
"${pkg}_10"
,
AppPreferences
.
getInstance
().
getString
(
"gid"
,
""
))
.
put
(
"${pkg}_10"
,
AppPreferences
.
getInstance
().
getString
(
"gid"
,
""
))
...
@@ -84,5 +85,29 @@ object EventUtils {
...
@@ -84,5 +85,29 @@ object EventUtils {
url
.
append
(
"?pkg=$pkg"
)
url
.
append
(
"?pkg=$pkg"
)
url
.
toString
()
url
.
toString
()
}
}
fun
getDeviceName
():
String
?
{
val
manufacturer
=
Build
.
MANUFACTURER
val
model
=
Build
.
MODEL
val
flag
=
model
.
lowercase
(
Locale
.
getDefault
()).
startsWith
(
manufacturer
.
lowercase
(
Locale
.
getDefault
()))
return
if
(
flag
)
{
if
(
model
.
isNullOrEmpty
())
{
model
}
else
{
model
.
substring
(
0
,
1
)
.
uppercase
(
Locale
.
getDefault
())
+
model
.
substring
(
1
)
.
lowercase
(
Locale
.
getDefault
())
}
}
else
{
val
ss
=
if
(
manufacturer
.
isNullOrEmpty
())
{
manufacturer
}
else
{
manufacturer
.
substring
(
0
,
1
)
.
uppercase
(
Locale
.
getDefault
())
+
manufacturer
.
substring
(
1
)
.
lowercase
(
Locale
.
getDefault
())
}
"$ss $model"
}
}
}
}
\ No newline at end of file
app/src/main/java/com/base/pdfviewerscannerwhite/helper/MyApplication.kt
View file @
096d0d0c
...
@@ -18,11 +18,15 @@ import com.base.pdfviewerscannerwhite.utils.AppPreferences
...
@@ -18,11 +18,15 @@ import com.base.pdfviewerscannerwhite.utils.AppPreferences
import
com.base.pdfviewerscannerwhite.utils.KotlinExt.toFormatMinute
import
com.base.pdfviewerscannerwhite.utils.KotlinExt.toFormatMinute
import
com.base.pdfviewerscannerwhite.utils.LogEx
import
com.base.pdfviewerscannerwhite.utils.LogEx
import
com.facebook.FacebookSdk
import
com.facebook.FacebookSdk
import
com.google.android.gms.ads.identifier.AdvertisingIdClient
import
com.reyun.solar.engine.OnAttributionListener
import
com.reyun.solar.engine.OnAttributionListener
import
com.reyun.solar.engine.OnInitializationCallback
import
com.reyun.solar.engine.OnInitializationCallback
import
com.reyun.solar.engine.SolarEngineConfig
import
com.reyun.solar.engine.SolarEngineConfig
import
com.reyun.solar.engine.SolarEngineManager
import
com.reyun.solar.engine.SolarEngineManager
import
com.tom_roush.pdfbox.android.PDFBoxResourceLoader
import
com.tom_roush.pdfbox.android.PDFBoxResourceLoader
import
kotlinx.coroutines.Dispatchers
import
kotlinx.coroutines.MainScope
import
kotlinx.coroutines.launch
import
org.json.JSONObject
import
org.json.JSONObject
import
java.util.Locale
import
java.util.Locale
import
java.util.UUID
import
java.util.UUID
...
@@ -80,6 +84,14 @@ class MyApplication : Application() {
...
@@ -80,6 +84,14 @@ class MyApplication : Application() {
}
}
fun
initApp
()
{
fun
initApp
()
{
MainScope
().
launch
(
Dispatchers
.
IO
)
{
try
{
AppPreferences
.
getInstance
()
.
put
(
"gid"
,
AdvertisingIdClient
.
getAdvertisingIdInfo
(
context
).
id
?:
""
)
}
catch
(
_
:
Exception
)
{
}
}
SolarEngineManager
.
getInstance
().
preInit
(
context
,
"81a11caa4076cd7c"
)
SolarEngineManager
.
getInstance
().
preInit
(
context
,
"81a11caa4076cd7c"
)
FacebookSdk
.
sdkInitialize
(
applicationContext
)
{
FacebookSdk
.
sdkInitialize
(
applicationContext
)
{
...
@@ -173,7 +185,12 @@ class MyApplication : Application() {
...
@@ -173,7 +185,12 @@ class MyApplication : Application() {
val
flag
=
if
(
topActivity
==
null
)
{
val
flag
=
if
(
topActivity
==
null
)
{
true
true
}
else
{
}
else
{
ConfigHelper
.
noLoadingActivities
.
all
{
!
topActivity
.
localClassName
.
contains
(
it
,
true
)
}
ConfigHelper
.
noLoadingActivities
.
all
{
!
topActivity
.
localClassName
.
contains
(
it
,
true
)
}
}
}
LogEx
.
logDebug
(
TAG
,
"flag=$flag"
+
" activity:"
+
activity
.
localClassName
)
LogEx
.
logDebug
(
TAG
,
"flag=$flag"
+
" activity:"
+
activity
.
localClassName
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment