Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
android
/
dayu
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
a03d0c10
authored
Jan 16, 2024
by
han xu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
隐藏 下载
parent
7c0e4b98
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
24 additions
and
24 deletions
baseSDK/src/main/res/layout/activity_webview.xml
orderCenter/src/main/java/com/dayu/order/ui/activity/PdfWebViewActivity.java
orderCenter/src/main/java/com/dayu/order/ui/activity/WebViewActivity.java
baseSDK/src/main/res/layout/activity_webview.xml
View file @
a03d0c10
...
@@ -21,11 +21,11 @@
...
@@ -21,11 +21,11 @@
/>
/>
<TextView
<!-- <TextView-->
android:id=
"@+id/tv_right_title"
<!-- android:id="@+id/tv_right_title"-->
style=
"@style/title_right_text"
<!-- style="@style/title_right_text"-->
android:textSize=
"15sp"
<!-- android:textSize="15sp"-->
android:text=
"下载"
/
>
<!-- android:text="下载" />--
>
</RelativeLayout>
</RelativeLayout>
<ImageView
style=
"@style/card_line"
/>
<ImageView
style=
"@style/card_line"
/>
...
...
orderCenter/src/main/java/com/dayu/order/ui/activity/PdfWebViewActivity.java
View file @
a03d0c10
...
@@ -50,15 +50,15 @@ public class PdfWebViewActivity extends DataBindingActivity<ActivityWebviewBindi
...
@@ -50,15 +50,15 @@ public class PdfWebViewActivity extends DataBindingActivity<ActivityWebviewBindi
mBind
.
tvTitle
.
setText
(
title
);
mBind
.
tvTitle
.
setText
(
title
);
initWebView
();
initWebView
();
mBind
.
tvRightTitle
.
setOnClickListener
(
new
View
.
OnClickListener
()
{
//
mBind.tvRightTitle.setOnClickListener(new View.OnClickListener() {
@Override
//
@Override
public
void
onClick
(
View
v
)
{
//
public void onClick(View v) {
Intent
intent
=
new
Intent
(
Intent
.
ACTION_VIEW
);
//
Intent intent = new Intent(Intent.ACTION_VIEW);
intent
.
setData
(
Uri
.
parse
(
docPath
));
//
intent.setData(Uri.parse(docPath));
// startActivity(Intent.createChooser(intent, "Choose browser"));
//
//
startActivity(Intent.createChooser(intent, "Choose browser"));
startActivity
(
intent
);
//
startActivity(intent);
}
//
}
});
//
});
}
}
private
void
initWebView
()
{
private
void
initWebView
()
{
...
...
orderCenter/src/main/java/com/dayu/order/ui/activity/WebViewActivity.java
View file @
a03d0c10
...
@@ -52,17 +52,17 @@ public class WebViewActivity extends DataBindingActivity<ActivityWebviewBinding>
...
@@ -52,17 +52,17 @@ public class WebViewActivity extends DataBindingActivity<ActivityWebviewBinding>
mId
=
bundle
.
getInt
(
Constants
.
ID
);
mId
=
bundle
.
getInt
(
Constants
.
ID
);
mUrl
=
Constants
.
WEB_ZHI_SHI
+
"?id="
+
mId
;
mUrl
=
Constants
.
WEB_ZHI_SHI
+
"?id="
+
mId
;
mBind
.
tvTitle
.
setText
(
getResources
().
getString
(
R
.
string
.
order_instruction
));
mBind
.
tvTitle
.
setText
(
getResources
().
getString
(
R
.
string
.
order_instruction
));
mBind
.
tvRightTitle
.
setText
(
getResources
().
getString
(
R
.
string
.
open_webview
));
//
mBind.tvRightTitle.setText(getResources().getString(R.string.open_webview));
mBind
.
tvRightTitle
.
setVisibility
(
View
.
VISIBLE
);
//
mBind.tvRightTitle.setVisibility(View.VISIBLE);
mBind
.
titleBack
.
setOnClickListener
(
o
->
finish
());
mBind
.
titleBack
.
setOnClickListener
(
o
->
finish
());
mBind
.
tvRightTitle
.
setOnClickListener
(
o
->
{
//
mBind.tvRightTitle.setOnClickListener(o -> {
Intent
intent
=
new
Intent
();
//
Intent intent = new Intent();
intent
.
setAction
(
Intent
.
ACTION_VIEW
);
//
intent.setAction(Intent.ACTION_VIEW);
Uri
content_url
=
Uri
.
parse
(
mUrl
);
//
Uri content_url = Uri.parse(mUrl);
intent
.
setData
(
content_url
);
//
intent.setData(content_url);
startActivity
(
Intent
.
createChooser
(
intent
,
getResources
().
getString
(
R
.
string
.
select_webview
)));
//
startActivity(Intent.createChooser(intent, getResources().getString(R.string.select_webview)));
// MobclickAgent.onEvent(mActivity,"open_web");
//
//
MobclickAgent.onEvent(mActivity,"open_web");
});
//
});
UserInfo
userInfo
=
UserManager
.
getInstance
().
getUser
();
UserInfo
userInfo
=
UserManager
.
getInstance
().
getUser
();
mToken
=
userInfo
.
getToken
();
mToken
=
userInfo
.
getToken
();
mWebView
=
new
BridgeWebView
(
mActivity
);
mWebView
=
new
BridgeWebView
(
mActivity
);
...
...
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